ESP8266 Deep Sleep Mode

Share on facebook
Share on google
Share on twitter
Share on linkedin
A VPN is an essential component of IT security, whether you’re just starting a business or are already up and running. Most business interactions and transactions happen online and VPN

My Adafruit HUZZAH Feather ESP8266 consumes 0.080 amps (80 ma) in normal operation. With one wire and a single line of code, I can drop that to about 0.010 amps (10 ma), according to my USB power monitor.

I connected a wire from GPIO16 (pin 16) to RESET (RST).

I’m using the Arduino IDE to program my ESP8266, so at the end of my loop, I insert

void loop() {
    // other code in my sketch

    ESP.deepSleep(60e6);
}

Which puts the ESP8266 to sleep for 60 seconds, and then reboots, running through my code once more before going back to sleep. This greatly extends my battery life. You can change the 60 to whatever number of seconds you want the unit to sleep.

With a Adafruit TPL5110 Low Power Timer you can drop the power consumption of nearly any microcontroller or circuit to 20ua, for about $5.

Steve Spence

Steve Spence

Leave a Reply

1 thought on “ESP8266 Deep Sleep Mode”

  1. Let’s say my device is on battery, and asleep. I sporadically plug in power to charge it. Would that wake the device up, or would it keep sleeping?

Leave a Comment

Your email address will not be published. Required fields are marked *