cancel
Showing results for 
Search instead for 
Did you mean: 

LoRaWAN StopJoin - what is this?

Andrew Larkin
Associate III

The LoRaWAN middleware End-node (lora-app.c) includes a "Join Switch" mechanism set up around the StopJoinTimer, the OnStopJointTimeEvent function, and the StopJoin() task function.

The StopJoin function appears to be used to toggle between ABP and OTAA Activation modes.  I'm not sure why you might want to do that but Ok - it may have to do with other uses cases such as the AT command firmware.

As it stands within the End Node generated code, it appears to be dormant code as nothing ever seems to start the StopJoinTimer.

But, if it were started by the application, it looks like it may go into a bit of a loop. The StopJoin() function restarts the StopJoinTimer at the end of the function, which means it will called back after JOIN_TIME (2000ms) to swap activation mode again.  As a Join usually requires about 5 seconds before the Rx window opens, I am thinking this might actually end up stopping any OTAA Join before it has a chance to succeed.

Possibly I have completely misunderstood what is going on here but so far I have not found any documentation that explains what is going on here, how to use it, or why it exists.

4 REPLIES 4
HeikoK
Associate

I'm also confused about this and do not understand, for what use case this shall be implemented in a real end node application.

It seems to be (only) example, demonstration or test code to switch from OTAA to ABP (and maybe back) using

LmHandlerStop() and LmHandlerJoin(), triggered by BUT2_Pin and StopJoinTimer.

Egolt.1
Associate II

Is it possible to have a device that support the two activation mode? How come? And what will be its definition at the LNS? It can't be both, isn't it?

I think that with the "AT" command style firmware, you should be able to switch between activation modes as the device is acting as a modem with fixed firmware under the control of a separate MCU.  This is the only scenario that I have been able to think of.

As far as a given LNS is concerned, the node is exclusively OTAA or ABP.

Thank you @Andrew Larkin for you reply, I'm not using the "AT" FW but I understand your answer.

Will it be possible to talk with you directly? eyal@egmbed.com