802.15.4 STM S2LP driver update

Update STM S2LP driver to version v1.0.8
pull/14565/head
Arto Kinnunen 2021-04-14 13:43:43 +03:00
parent e287b93b8d
commit ce38709dbf
1 changed files with 6 additions and 2 deletions

View File

@ -848,8 +848,12 @@ static void rf_cca_timer_interrupt(void)
rf_flush_tx_fifo();
tx_finnish_time = rf_get_timestamp();
if (device_driver.phy_tx_done_cb) {
if (rf_state == RF_RX_STARTED) {
device_driver.phy_tx_done_cb(rf_radio_driver_id, mac_tx_handle, PHY_LINK_CCA_FAIL_RX, 0, 0);
} else {
device_driver.phy_tx_done_cb(rf_radio_driver_id, mac_tx_handle, PHY_LINK_CCA_FAIL, 0, 0);
}
}
} else {
if (status == PHY_RESTART_CSMA) {
if (device_driver.phy_tx_done_cb) {
@ -1143,7 +1147,7 @@ static void rf_irq_task_process_irq(void)
tx_finnish_time = rf_get_timestamp();
rf_update_tx_active_time();
TEST_TX_DONE
device_driver.phy_tx_done_cb(rf_radio_driver_id, mac_tx_handle, PHY_LINK_CCA_FAIL, 1, 0);
device_driver.phy_tx_done_cb(rf_radio_driver_id, mac_tx_handle, PHY_LINK_CCA_FAIL_RX, 1, 0);
rf_send_command(S2LP_CMD_SABORT);
rf_poll_state_change(S2LP_STATE_READY);
rf_send_command(S2LP_CMD_FLUSHTXFIFO);