cancel
Showing results for 
Search instead for 
Did you mean: 

LoRaWAN_End_Node_FreeRTOS application on Nucleo-WL55JC1. Problem resetting LORAWAN_APP_KEY

pe
Associate

I'm using STM32Cube_FW_WL_V1.3.0and trying to generate LoRaWAN End Node FreeRTOS. I precedently set in file se-identity.h values for LORAWAN_APP_KEY,LORAWAN, LORAWAN_NWK_KEY,LORAWAN_JOIN_EUI, as shown in the guide and everything went fine.

Now I want to assign them new values in the same manner, but after compiling the project and programming the device with ST-LINK, on boot in the serial output it shows the first ones that I set:

APPLICATION_VERSION: V1.3.0
MW_LORAWAN_VERSION: V2.5.0
MW_RADIO_VERSION: V1.3.0
L2_SPEC_VERSION: V1.0.4
RP_SPEC_VERSION: V2-1.0.1
NVM DATA RESTORED
###### AppKey: F2:54:51:E9:24:11:25:F7:A5:24:80:97:32:CC:58:CD
###### NwkKey: F2:54:51:E9:24:11:25:F7:A5:24:80:97:32:CC:58:CD

...

The output shows that the values was restored from NVM, but I can't manage to change them in NVM.

How can I force the new values into NVM. Related to this, how does the BUT3_Pin work? It activates thread Thd_LoraStoreContext ( that calls the func LmHandlerNvmDataStore)  but seems it not store the new values

Can anyone show me how do or what is the problem?

thanks 

2 REPLIES 2
STTwo-32
ST Employee

Hello @pe 

Thank you for your request. I've escalated this use case to the concerned team for more investigation (through Internal ticket number: 175276)

(PS: Internal ticket number 175276 is only for reference, not available outside of ST).

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

zandaz
Associate

image.png

Hello, you just need to change line 100 in the lora_app.h file to set #define LORAWAN_FORCE_REJOIN_AT_BOOT to true (the default value is false). This will force the device to rejoin. Otherwise, the device will restore data from the non-volatile memory.

thanks.