@@ -46,6 +46,9 @@ STATS_SECT_START(ble_phy_stats)
46
46
STATS_SECT_ENTRY (tx_good )
47
47
STATS_SECT_ENTRY (tx_fail )
48
48
STATS_SECT_ENTRY (tx_late )
49
+ STATS_SECT_ENTRY (tx_late_sched )
50
+ STATS_SECT_ENTRY (tx_late_frame )
51
+ STATS_SECT_ENTRY (tx_late_field )
49
52
STATS_SECT_ENTRY (tx_bytes )
50
53
STATS_SECT_ENTRY (rx_starts )
51
54
STATS_SECT_ENTRY (rx_aborts )
@@ -63,6 +66,9 @@ STATS_NAME_START(ble_phy_stats)
63
66
STATS_NAME (ble_phy_stats , tx_good )
64
67
STATS_NAME (ble_phy_stats , tx_fail )
65
68
STATS_NAME (ble_phy_stats , tx_late )
69
+ STATS_NAME (ble_phy_stats , tx_late_sched )
70
+ STATS_NAME (ble_phy_stats , tx_late_frame )
71
+ STATS_NAME (ble_phy_stats , tx_late_field )
66
72
STATS_NAME (ble_phy_stats , tx_bytes )
67
73
STATS_NAME (ble_phy_stats , rx_starts )
68
74
STATS_NAME (ble_phy_stats , rx_aborts )
@@ -1462,6 +1468,7 @@ ble_phy_tx(ble_phy_tx_pducb_t pducb, void *pducb_arg, uint8_t end_trans)
1462
1468
if (CMAC -> CM_EXC_STAT_REG & CMAC_CM_EXC_STAT_REG_EXC_FIELD_ON_THR_EXP_Msk ) {
1463
1469
ble_phy_disable ();
1464
1470
g_ble_phy_data .end_transition = BLE_PHY_TRANSITION_NONE ;
1471
+ STATS_INC (ble_phy_stats , tx_late_field );
1465
1472
STATS_INC (ble_phy_stats , tx_late );
1466
1473
rc = BLE_PHY_ERR_RADIO_STATE ;
1467
1474
} else {
@@ -1515,6 +1522,7 @@ ble_phy_tx_set_start_time(uint32_t cputime, uint8_t rem_usecs)
1515
1522
CMAC -> CM_EV_LINKUP_REG = CMAC_CM_EV_LINKUP_REG_LU_FRAME_START_2_TMR1_9_0_EQ_X_Msk ;
1516
1523
1517
1524
if ((int32_t )(ll_val32 - cmac_timer_read32 ()) < 0 ) {
1525
+ STATS_INC (ble_phy_stats , tx_late_sched );
1518
1526
goto tx_late ;
1519
1527
}
1520
1528
@@ -1531,6 +1539,7 @@ ble_phy_tx_set_start_time(uint32_t cputime, uint8_t rem_usecs)
1531
1539
* need to assume tx_late and abort.
1532
1540
*/
1533
1541
if (CMAC -> CM_EXC_STAT_REG & CMAC_CM_EXC_STAT_REG_EXC_FRAME_START_Msk ) {
1542
+ STATS_INC (ble_phy_stats , tx_late_frame );
1534
1543
goto tx_late ;
1535
1544
}
1536
1545
0 commit comments