We are using nrf52840 to integrate with LoRa(RFM95W) and when we are trying to keep the board into sleep mode(SYSTEM ON MODE) but, it is not going to sleep. Here ,we are using the power management library to keep the board into sleep mode and timers to wake microcontroller up from sleep mode.
nrf_pwr_mgmt_init(); nrf_pwr_mgmt_run(); and we are also tried using this functions
__WFE();
__SEV();
__WFE();
But, nothing is keeping microcontroller into system on sleep mode.
Those three lines are in a while loop and inbuilt timer which is called in nrf_pwr_mgmt_init() was configured and used .
Without LoRa, the sleep was working but from the moment we integrate LoRa with the sleep mode, nrf52840 doesn't go to sleep.
We want to LoRa goto sleep for every 30 seconds and then wakeup transfer data.
Regards,
Nagari Gopal.