ESP32 C3 goes straight to download mode on first power
Posted: Sun Jun 02, 2024 8:53 pm
I have a startup problem with a custom board with an ESP32 C3 Mini 1 module. There are several threads with similar topics here, but they don't solve the problem. This is how the problem manifests itself:
If the board has not been powered for a long while, it'll go straight to dowload mode:
In this mode, no code is executed and there is no timeout. The device will just sit there doing nothing. If you then boot or re-apply power, it'll boot normally:
The problem is that for this but to be reproducable, I have to wait up to 30 minutes. If I don't wait this long, the device will boot as normal from SPI Flash. This is likely due to a capacitor getting discharged or something like that, but I obviously need these devices to always power on and never ever go into this upload mode unless requested to. The error is repeatable as long as I wait for it to "discharge".
I have a 0.1uF on the BOOT pin (GPIO9) but I have no pullup. According to the ESP32 C3 datasheet (3.3 Strapping Pins), the BOOT pin is pulled up internally, so you should not need an external pullup (though it likely does not hurt either):
EN (Pin 8) has a 10k pullup and is connected with a 0.1uF cap to GND
BOOT (GPIO09, pin 23) is connected with a 0.1uF cap to GND
GPIO08 (pin 22) has a 10k pullup and is connected with a 0.1uF cap to GND
The board is powered from 5V USB that drive an AZ1117H-3.3TRG1 that is decoupled with 0.1uF and 10uF.
On the C3, GPIO08 is used as GPIO00 is used on other ESP modules. As opposed to other modules, on the C3 this pin is floating by default. I initially had a 10k Pullup on this pin. Removing the 10k pullup will also produce the problem, but with a different message on startup:
The boards are to be used in a product that cannot have this problem as it won't be possible to "just boot" the device. Has anybody seen and solved this problem before?
J
If the board has not been powered for a long while, it'll go straight to dowload mode:
Code: Select all
Build:Feb 7 2021
rst:0x1 (POWERON),boot:0x4 (DOWNLOAD(USB/UART0/1))
waiting for download
Code: Select all
Build:Feb 7 2021
rst:0x1 (POWERON),boot:0xc (SPI_FAST_FLASH_BOOT)
SPIWP:0xee
mode:DIO, clock div:1
I have a 0.1uF on the BOOT pin (GPIO9) but I have no pullup. According to the ESP32 C3 datasheet (3.3 Strapping Pins), the BOOT pin is pulled up internally, so you should not need an external pullup (though it likely does not hurt either):
The board is simple:GPIO9 connected to the chip’s internal weak pull-up resistor at chip reset.
EN (Pin 8) has a 10k pullup and is connected with a 0.1uF cap to GND
BOOT (GPIO09, pin 23) is connected with a 0.1uF cap to GND
GPIO08 (pin 22) has a 10k pullup and is connected with a 0.1uF cap to GND
The board is powered from 5V USB that drive an AZ1117H-3.3TRG1 that is decoupled with 0.1uF and 10uF.
On the C3, GPIO08 is used as GPIO00 is used on other ESP modules. As opposed to other modules, on the C3 this pin is floating by default. I initially had a 10k Pullup on this pin. Removing the 10k pullup will also produce the problem, but with a different message on startup:
Code: Select all
Build:Feb 7 2021
rst:0x1 (POWERON),boot:0x0 (USB_BOOT)
wait usb download
J