DM-01 · Blog · REV 2026.11
[tutorial]
Power Budgeting an ESP32 for Weeks of Battery Life
2025-04-10 · 1 min read
What actually drains your battery in a deep-sleep IoT project, and how to measure it instead of guessing.
The naive math
An 18650 cell holds roughly 2500 mAh. If your device sleeps at 10 µA and wakes for 5 seconds every 10 minutes at 80 mA, the average draw is about 0.7 mA — months of runtime. So why did my first build die in four days?
The spreadsheet said months. The multimeter said four days. That gap is where embedded engineering actually happens.
Where the power actually goes
- The dev board, not the chip. The USB-UART bridge and power LED on a typical DevKit draw more in "sleep" than the ESP32 itself does awake.
- Sensor quiescent current. The BME280 is frugal, but the breakout board's regulator isn't.
- Wi-Fi association. Scanning and joining a network can take 2–4 seconds — most of the wake window.
Fixes that mattered
- Cut the power LED trace (or use a bare module).
- Power the sensor from a GPIO through a MOSFET so it's truly off during sleep.
- Cache the router's BSSID and channel in RTC memory to skip scanning.
Measure it
A cheap USB power meter is useless at these currents. A µCurrent or even a multimeter in series on the battery line tells you the truth. My final numbers: 9 µA asleep, 1.8 s average wake.
#esp32 #embedded #low-power #hardware