Difference between forceFullWakeCycle() and pauseSleep()


I am struggling to understand what code is executed directly after the wake callback function and which peripherals are activated. How does the behavior of forceFullWakeCycle() differ from pauseSleep() except for not pausing sleep permanently? What does ‘cycle’ refer to?

I am trying to control whether the device needs to be fully operational by checking what woke it up and possibly returning to sleep immediately.

Appreciate any help or experiences.

Device: Particle Tracker One 524M
Device-Os: 5.3.0
Tracker-Edge: Latest commit on develop branch

There are two different options when waking:

  • A full wake cycle connects to the cloud, typically to publish a loc event.
  • A short wake cycle only wakes up, typically to read a sensor, then goes back to sleep without connecting to cellular.

Forcing a full wake cycle is done when you are on a short wake cycle, but realize that the incident you are handing needs to be uploaded to the cloud immediately instead of waiting until the next scheduled full wake cycle.

Pausing sleep prevents sleep from occurring after the location event has been sent on a full wake cycle. This is used when you have outstanding operations that need to complete that will take longer than the default wake duration.

Thanks for the quick reply. I understand the application concept of using forceFullWakeCycle(). However, what exactly is executed is still unclear to me.

In my case, I am waking up from a cellular request which is why the device is connected to cellular anyways. When looking at the serial monitor I can barely see anything coming in when on a short wake cycle in contrast to regular operation. Do I have to call Tracker::instance().loop() from the wake callback manually or is that a no-go? What code is executed when in a short wake cycle?

Oh, that’s a different situation entirely.

When you are using a cellular standby mode with cloud connected, wake on cellular, the modem and cloud connection are always on, so there are essentially no log messages on wake, because everything is already initialized.

I’m not positive Tracker Edge is designed to work in that mode, because short and full wake cycles are pretty much the same with regards to the cellular modem, it’s just that one publishes and one does not. However, you should be seeing the same lack of log messages in both cases, which is making me think it might not be working properly in Tracker Edge.

As a side note, the difference between staying awake all the time and using wake on cellular with cloud active on the nRF52840 (including the Tracker) is such a small percentage of the power used by the modem you may not save much power at all.