From 86e6a82d8304f6e585d82a1ee362e3781ffbb63d Mon Sep 17 00:00:00 2001 From: Zhanglong Xia Date: Tue, 9 Apr 2024 23:09:59 +0800 Subject: [PATCH] [nrf528xx] clear psdu_being_received in CRCOK handler (#776) The flag psdu_being_received is set to True when the radio driver receives the FCF field of the data frame, and the flag will be cleared after the ACK is sent out if the ACK is required. Sometimes, the ACK is failed to be sent out, which causes the flag to be set to True forever. Then the radio driver can't send out any frames. The sdk-nrfxlib (https://github.com/nrfconnect/sdk-nrfxlib/blob/main/nrf_802154/driver/src/nrf_802154_trx.c#L2492) clears the flag `psdu_being_received` in the CRCOK handler. This commit clears the flag `psdu_being_received` when the irq_crcok_state_rx() is handled. Ref: https://nrfsupport.atlassian.net/browse/NRF11-73 --- .../NordicSemiconductor/drivers/radio/nrf_802154_core.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/third_party/NordicSemiconductor/drivers/radio/nrf_802154_core.c b/third_party/NordicSemiconductor/drivers/radio/nrf_802154_core.c index d623ecb9..b5260845 100644 --- a/third_party/NordicSemiconductor/drivers/radio/nrf_802154_core.c +++ b/third_party/NordicSemiconductor/drivers/radio/nrf_802154_core.c @@ -2087,6 +2087,10 @@ static void irq_crcok_state_rx(void) m_flags.rssi_started = true; +#if !NRF_802154_DISABLE_BCC_MATCHING + m_flags.psdu_being_received = false; +#endif + #if NRF_802154_DISABLE_BCC_MATCHING uint8_t num_data_bytes = PHR_SIZE + FCF_SIZE; uint8_t prev_num_data_bytes = 0;