Page 1 of 1

Executing code before flash upload

Posted: Mon Mar 31, 2025 8:30 am
by poorchava
In my product, ESP32 manages its own power. As soon as possible after startup, it asserts a POWER_HOLD line which keeps the power enabled after the user has released the power button.

There is a problem with firmware update: as soom as the ESP32 is reset into bootloader, the GPIO controlling the POWER_HOLD line is reset, then device looses power and therefore the firmware update is impossible.

Is there a way to either set the GPIO state before the flash upload is executed, set default GPIO state in fuses of somehow retain GPIO state through reset?

Re: Executing code before flash upload

Posted: Mon Mar 31, 2025 12:38 pm
by Sprite
What ESP32 is it, and how do you update the firmware?