The 800µA mystery
Out of the box, an ESP32-C3 dev board entering deep sleep should pull tens of microamps. The first time I ran the canonical example from the ESP-IDF documentation on a brand-new Espressif ESP32-C3-DevKitM-1, the Joulescope read 807µA. That is two orders of magnitude wrong.
The cause turned out to be five issues stacked on top of each other. We'll work through them in order of impact, and the rail will drop from 807µA to 11.8µA.
RTC memory survives
Wi-Fi station credentials live in NVS by default, which is in flash — but the NVS handle and the negotiated IP lease don't have to. Both can be parked in RTC slow memory, which retains across deep sleep at zero cost.
The smallest change that gets you a 60-millisecond Wi-Fi reassociation on wake instead of a four-second handshake. The savings show up directly in cycle charge.
// sdkconfig CONFIG_ESP_BROWNOUT_DET=n CONFIG_PM_ENABLE=y CONFIG_FREERTOS_USE_TICKLESS_IDLE=y
GPIO holds — the silent leakers
Any GPIO floating into a CMOS input on a peripheral chip is a current path you cannot see on the schematic. gpio_hold_en() on every pin that drives a peripheral, before esp_deep_sleep_start(), is non-negotiable on a production board.
- Strap pins: hold even if the strap value matches reset.
- SPI flash CS lines: definitely hold high.
- Anything driving an LED through a current-limiting resistor: explicitly hold low.
The BOR brown-out trap
The brown-out detector in the ESP32-C3 is enabled by default, draws roughly 17µA on its own, and is unnecessary in deep sleep because the chip will already be in a known low-power state. Disable it for the sleep window only and re-enable it on wake.
This is the change that takes the project from "very good" to "datasheet-grade." It alone accounts for the last 20µA of headroom.
Bench log — final capture
One full wake-do-work-sleep cycle, captured on the PPK2 at 100 kS/s. Sleep floor at 11.8µA, peak active at 82mA, wake-to-MQTT-publish in 284ms. Total cycle charge: 6.4mC — which on 2× alkaline AAs yields just over three years of one-publish-per-five-minutes.
Conclusion
You can ship an ESP32-C3 product that runs on a pair of AAs for years if you treat deep sleep as a configuration problem rather than a single function call. Every microamp on this bench is now accounted for. If yours isn't, email me a PPK2 log and we'll find the leak.