Trouble uploading code to ESP32-S3-WROOM-1

zchoffin
Posts: 1
Joined: Tue May 16, 2023 7:20 pm

Trouble uploading code to ESP32-S3-WROOM-1

Postby zchoffin » Tue May 16, 2023 7:46 pm

I've been trying to connected to the ESP32 board I've designed for research and have been unable to get the system to connect to the ESP32.

I'm using a CP2102 and a auto reset circuit to upload code to the ESP32, every time I've tried to upload data to the code i get a
"timed out receiving header packet" error

The circuit i'm using for the ESP32 and the CP2102 are here:
ESP32_Uart_bridge.PNG
ESP32_Uart_bridge.PNG (59.58 KiB) Viewed 2646 times
esp32_board.PNG
esp32_board.PNG (82.13 KiB) Viewed 2646 times
I've tried some different software configurations for uploading but still haven't been able to achieve a download. manually pulling the IO0 and EN pins don't transmit a response to a serial monitor that would say its in download mode. My computer will recognize the CP2102 in usb devices.

I'm using Arduino to test upload the code.

using a scope My esp32 RX line is receiving chatter
RX_Line (3).JPEG
RX_Line (3).JPEG (761.11 KiB) Viewed 2646 times
IO0 is receiving this signal
https://imgur.com/X1DGslZ

I was hoping maybe some people have some advice I can revise the circuit to test correct some output issues.

ESP_Sprite
Posts: 9766
Joined: Thu Nov 26, 2015 4:08 am

Re: Trouble uploading code to ESP32-S3-WROOM-1

Postby ESP_Sprite » Wed May 17, 2023 7:45 am

Probably not the issue, but the TPS7A0533 can only output 200mA. You need a LDO that does 500mA or more for the ESP32 to function correctly. Your scope is displaying the serial signal *from* the ESP32, right? If so, I'd figure out why you're not seeing that on the PC.

jamargevicius
Posts: 2
Joined: Thu May 18, 2023 7:07 pm

Re: Trouble uploading code to ESP32-S3-WROOM-1

Postby jamargevicius » Thu May 18, 2023 8:10 pm

Hi ... what IDE are you using? Maybe I can help. Here is my experience using ESP32-S3-WROOM-1 which I designed successfully into a board and program it with a USB-UART interface module.

I use the Arduino IDE ver 1.8.19, and had to add in the File/Preference window, down below in "Additional Board Manager" this line:
https://raw.githubusercontent.com/espre ... index.json, https://dl.espressif.com/dl/package_esp32_index.json .... specifically it's the github one that provides support for the ESP32-S3. Arduino IDE ver 2 doesn't support this chip (yet), so I had to revert back to ver 1.8 to get to it.

As for the USB-UART connection: I've tried successfully with interface modules with the FT232 chip and those with the CP2102 chip. The CP2102 chip is also on the ESP32-dev boards which I've used. I've used the CH340 chip only indirectly as it comes standard on the ESP32-CAM_MB (motherbord), and on the ESP32 WROOM programmer board (which may be what you're using). The boot software in the ESP expects to see the nRST line (aka the CHP_PU3 pin) to be low to put the chip in reset, then the GPIO-0 line to go low ... while the nRST line is low .. then both to go hi eventually. A problem is that most interface circuits (e.g. those on most dev boards) have the nRST line going high just as the GPIO-0 line is going low, and boot doesn't happen. A "fix" to this is to put a capacitor on the nRST line to "slow it down from going hi", thus achieving a boot without having to push any buttons.

In my case (and this may relate to your issue), I use the FT232 chip module to drive the CHP_PU line (the nRST line) from the nRTS line of the FT232 (that's the Ready To Send line, which go low when the FT232 is "ready to send"); it is interfaced to the ESP32 via a diode with the cathode facing the FT232; the ESP32 CHP_PU pin needs a pullup of 10K, and a "keep down to ground" of 0.1uF capacitor (or higher). For the GPIO-0 line, the FT232 chip's nDTR (Data Terminal Ready - goes low when the FT232 chip is "ready"), is used, again interfacing to the ESP32 with a diode whose cathode faces the FT232 chip; a pullup of 10K is used on the GPIO-0 pin on some boards I've explored, but I find I don't need it.

Now, for my issue: I can program the S3-WROOM when I select ESP32S3 Dev Module in the Arduino IDE, but after it successfully loads, when I invoke the Serial Monitor, the nRTS and nDTR of the FT232 chip go low, effectively putting the device in reset (ARGHH!). What I found as a workaround is to select instead (after the code is loaded) the ESP32 Dev Module ... this allows the signals to stay high, and the serial monitor works fine.

I hope this helps a little, and anyone who knows more about the esptool.py software (or whatever runs the USB-UART system in serial monitor mode) can explain why the Arduino's ESP32S3 Dev Module acts strangely in Serial Monitor mode.... maybe it's a bug which needs fixing.

Who is online

Users browsing this forum: No registered users and 61 guests