From 61f83741b0138e8e70613885c982bab004c61c6a Mon Sep 17 00:00:00 2001 From: zul Date: Sun, 13 Feb 2022 21:11:08 +0100 Subject: [PATCH] Fixed Join Request retransmission timing (Interop test) On interop test 1.2.2.4, Join Request retransmission is expected to be 6 s + worst case air transmission. This delay is to accommodate for JoinAccept through RX2. The `call_in` in process_reception_timeout of RX2-window adds 500 ms delay between RX2 symbol-interrupt-timeout and the next join request retransmission. This is an isolated change and only affect the retransmission of Join Request. Adding this delay improves the chance of succeeding test 1.2.2.4 (subset of 1.2.2) --- connectivity/lorawan/source/LoRaWANStack.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/connectivity/lorawan/source/LoRaWANStack.cpp b/connectivity/lorawan/source/LoRaWANStack.cpp index d60fa0b9d4..8d8770dd5c 100644 --- a/connectivity/lorawan/source/LoRaWANStack.cpp +++ b/connectivity/lorawan/source/LoRaWANStack.cpp @@ -756,7 +756,10 @@ void LoRaWANStack::process_reception_timeout(bool is_timeout) _loramac.on_radio_rx_timeout(is_timeout); if (slot == RX_SLOT_WIN_2 && !_loramac.nwk_joined()) { - state_controller(DEVICE_STATE_JOINING); + const int ret = _queue->call_in( + 500, this, &LoRaWANStack::state_controller, DEVICE_STATE_JOINING); + MBED_ASSERT(ret != 0); + (void)ret; return; }