ESP32 stuck/glitched after repeated brownout
Posted: Fri May 16, 2025 10:26 pm
I have built a battery(li-ion) powered product around the ESP32-MINI-1-H4.
I did not include a reset button, thinking it would not be necessary. There is no hard shut-down either. Shutdown of the product is handled by sleep mode.
When the battery is discharged below ~3V, brownout reset is triggered(there is some drop on LDO as well). This should not happen in normal operation, but can happen if the user doesn't charge the product for extended period of time.
As the brownout reset is triggered, current draw decreases, bringing the voltage above the brownout threshold. The cycle repeats few times. After several cycles, the ESP gets stuck. I am assuming hardware level glitch.
Even after charging the battery, ESP doesn't resume operation, because it is still stuck in this glitched state.
The only way to restore operation is to dismantle the product, connect a programmer(USB<->UART transceiver) and toggle reset pin from there.
While there are some hardware level mitigations I could incorporate into the next revision, I already have 200 pieces in the wild and replacing them all is financially impossible for me. I need a SW fix.
Any Idea how to solve this? I was unable to find any other mention of this issue on the internet, which is also pretty surprising to me.
Thank you
I did not include a reset button, thinking it would not be necessary. There is no hard shut-down either. Shutdown of the product is handled by sleep mode.
When the battery is discharged below ~3V, brownout reset is triggered(there is some drop on LDO as well). This should not happen in normal operation, but can happen if the user doesn't charge the product for extended period of time.
As the brownout reset is triggered, current draw decreases, bringing the voltage above the brownout threshold. The cycle repeats few times. After several cycles, the ESP gets stuck. I am assuming hardware level glitch.
Even after charging the battery, ESP doesn't resume operation, because it is still stuck in this glitched state.
The only way to restore operation is to dismantle the product, connect a programmer(USB<->UART transceiver) and toggle reset pin from there.
While there are some hardware level mitigations I could incorporate into the next revision, I already have 200 pieces in the wild and replacing them all is financially impossible for me. I need a SW fix.
Any Idea how to solve this? I was unable to find any other mention of this issue on the internet, which is also pretty surprising to me.
Thank you