Executing code before flash upload

poorchava
Posts: 5
Joined: Thu May 11, 2023 8:26 am

Executing code before flash upload

Postby poorchava » Mon Mar 31, 2025 8:30 am

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?

Sprite
Espressif staff
Espressif staff
Posts: 10617
Joined: Thu Nov 26, 2015 4:08 am

Re: Executing code before flash upload

Postby Sprite » Mon Mar 31, 2025 12:38 pm

What ESP32 is it, and how do you update the firmware?

Who is online

Users browsing this forum: Google [Bot], Qwantbot and 1 guest