Electron sleep or current saving mode


#1

I have an electron deployed to reset some gear if I can’t communicate with it. I was wondering can I get the electron to sleep or use less current somehow? The whole setup is battery powered and using less current would be good. But if I put it to sleep can I still send it a command to toggle a pin and reset my gear, through my relay on that pin?
I’ll keep digging around the forum but I haven’t seen a solution yet.
Thanks!


#2

Most of the sleep modes make the Electron not respond to the cloud, which wouldn’t be helpful in your scenario.

However there is one that does: You can use stop mode sleep (pin + time) with SLEEP_NETWORK_STANDBY and the current will drop to 7 mA from around 60 mA (or more) in normal operating mode (not sending data). And you can still wake up the Electron from the cloud side.


#3

Very neat, thank you! I am fairly new at code, but do I need to physically pull D2 low to make it sleep or can I just write D2 LOW to make it sleep? My gear is deployed and remote. So no physical access right now.


#4

You need to call the command in code to send the device to sleep and pulling the pin in the direction indicated by the edge parameter (or HIGH for WKP in deep sleep) will wake the device.