jamesza
November 23, 2017, 5:23am
1
Hi,
I need some help from the experts. I use the following command to go into sleep mode for more or less
three days.
System.sleep(SLEEP_MODE_SOFTPOWEROFF, SLEEP_MODE_SOFTPOWEROFF_SECONDS);
Sometimes the user must wake up the unit with a reset switch. I have a Normally open switch I would like to use to wake up the Electron. What would the best route to explore ?
Tx
James
ScruffR
November 23, 2017, 2:25pm
2
SLEEP_MODE_SOFTPOWEROFF
is a special kind of deep sleep where the device can be woken by a rising edge on the WKP pin.
https://docs.particle.io/reference/firmware/electron/#sleep-sleep-
Note: You can also wake the device "prematurely" by applying a rising edge signal to the WKP pin.
System.sleep(SLEEP_MODE_SOFTPOWEROFF, long seconds) is just like SLEEP_MODE_DEEP, with the added benefit that it also sleeps the Fuel Gauge.
2 Likes