Lora-net / lr1110_modem_application_example

11 stars 13 forks source link

LR1110 resets after 120 sec and Wifi scanning is unsuccessful #4

Closed kvkc97 closed 1 year ago

kvkc97 commented 2 years ago

I modified the LR1110 Modem application to work with a custom board with controller STM32WB55RGV6. My code is updated in the following link. https://github.com/kvkc97/lr1110_modem_application_example I have tried the example code for WiFi scanning. The procedure for scanning was implemented based on the sample wifi scanning example and can be found in main.c file in the given path. https://github.com/kvkc97/lr1110_modem_application_example/blob/master/Core/Src/main.c The top layer functions and flow was maintained the same and certain changes in bottom layer was done to incorporate to STM32WB controller. I can read the modem version correctly using lr1110_modem_get_version and the result was displayed. However, when I am using wifi scanning, an error is occurred due to the wifi timeout(10 sec). Also, LR1110 gets reset after 120sec. The error is attached. image I read from the user manual that there is a watchdog timer switched on in LR1110 which initiates reset after 120 sec. Can this be the issue of LR1110 reset. If so how can it be switched off?

Since I can read the modem version correctly, I am assuming the hal functions are working properly. Also, Wifi scanning was done successfully in the same hardware in Transceiver mode. So there is no issue with the hardware. Could you please help me solve this issue. @matthieuantoine @smtcbboulet The LR1110 reset issue was also noted while using the lr1110 Modem-E Class A/C device implementation in main_lorawan.c file.

smtcbboulet commented 2 years ago

Hello,

I read from the user manual that there is a watchdog timer switched on in LR1110 which initiates reset after 120 sec. Can this be the issue of LR1110 reset. If so how can it be switched off?

No you can't, in fact if you have have this watchdog which occurs it means that the Modem-E is in error and stick somewhere. I suspect that your Modem-E is not well initialized. What is the return status when you launch your wifi scan ?

Because you are using a STM32WB55RG I encourage you to use as example this repo : https://github.com/Lora-net/lora_edge_tracker_ref_design it's using the same MCU as you, you should test with the same smtc_hal / radio driver and radio HAL

regards,

Benjamin

smtc-bot commented 1 year ago

Thank you for your inquiry.

Customers are encouraged to submit technical questions via our dedicated support portal at https://semtech.force.com/ldp/ldp_support.

We invite all users to visit the LoRa Developer Portal Forum at https://forum.lora-developers.semtech.com and to join the thriving LoRa development community!