Lora Node 151 low power issue

It took some time, but I managed to run an example of LoRaWAN with STM32CubeIDE + STM32CubeProgrammer. Data gets sent to the gateway.
But I’m not able to get the module into low power mode (few uA), it still consumes 1.3mA while sleeping between sending data. I believe it is done here: RtcEnterLowPowerStopMode().

Did anyone manage to get into low power mode? I managed to find some example from ST.COM page, but it uses ~200 LOC to get into low power mode. Have not tested it yet and not sure if simple copy/paste will work here.

Did you use the newest version example code?

Can you confirm the node had both “join” and “sent data done”? Only success joined and sent data done, can makes the node into sleep mode.

Are you testing the current on the positive side of the battery?

The example is LoRaWAN_151CC_CubeIDE.zip shared by Heltec support (date inside ZIP is 22/Jul/2019).

I have 1ch gateway based on Heltec WiFi LoRa 32 (V2) and https://github.com/things4u/ESP-1ch-Gateway-v5.0. Connecting to TTN. I’m also using SDR to monitor actual over the air activity.

Initially, Lora Node 151 had more than 10mA sleep current, and I did the following:

  • Switched from OTAA to ABP - OVER_THE_AIR_ACTIVATION = 0
  • Removed confirm request - LORAWAN_CONFIRMED_MSG_ON = false
  • Switched off ADR - LORAWAN_ADR_ON = 0
  • Reduced to 3 channels - USE_SEMTECH_DEFAULT_CHANNEL_LINEUP = 0
  • Changed default datarate - LORAWAN_DEFAULT_DATARATE = DR_5

And I get 1.3mA, but that’s still much more than expected running off the battery.

Testing on positive, but there should be no difference ?!?

The example code is the newest version, and it’s working well as we had tested.


I just update this document, maybe it can help your debug.

Have some update, I attached serial debugging with USE_DEBUGGER and saw what happens. Here is the outcome:

  1. ISSUE - Using OTAA - the device does not receive an acknowledgment message and keeps waiting and sending out new join messages. I see that router does send it back on the same frequency.

  2. OK - Using ABP and CONFIRMED_MSG_ON = 1 it receives confirmation and goes into the deep sleep of 3uA.

  3. ISSUE - Using ABP and CONFIRMED_MSG_ON = 0 it still waits for the confirmation message and does not go to sleep.

Double check the configuration of your gateway and server, ensure that the OTAA mode can join the network normally, send and receive data normally, and the sleep state will not be a problem.

I’m mostly focusing on ABP and CONFIRMED_MSG_ON = 0. It should send a message and go to deep sleep, the gateway is not needed here, so there cannot be a problem with the gateway.

Not the gateway, check your server configuration.

I think I got some more understanding. The issue probably is in my gateway as it is 1CH and somehow response it sends is not understood by node, but I’m thinking for the workaround. Is it possible for the example provided to make an adjustment so that the node does not wait for response RX1 / RX2 ? It just sends and goes to sleep?

Yes, that’s the problem.

Maybe you need fix the code yourself, we did’t support single Channel Gateway currently.