Closed ma3oun closed 1 year ago
I have also tried the "no_reset" and "no_reset_no_sync" options without much success. I get "Failed to connect to ESP32-C3: No serial data received"
Could you please also share the output of dmesg
after attaching the device and trying to flash?
I have already given the output of dmesg
after attaching the device. When I try to flash it, dmesg
outputs nothing more.
Hi @ma3oun,
this seems to be an issue with the drivers. Esptool fails due to the host system failing to set the RTS line. Inspecting your backtrace, you can actually see the error originates in pySerial
, not esptool
. I am not sure how to solve the drivers issue
I have also tried the "no_reset" and "no_reset_no_sync" options without much success. I get "Failed to connect to ESP32-C3: No serial data received"
Using the no_reset
option requires you to put the ESP into the download mode manually (by pressing the RESET
button while holding down the BOOT
button - if your board has these). You can read about the process here.
This could be the workaround to your issue - place the devkit manually into the download mode and then run esptool with the --before no_reset
option.
You can see a similar issue being discussed here.
Thanks @radimkarnis . Luckily, I can pull-down GPIO9 on my custom board and I was able to flash the board using the before no_reset
option, as explained in the link you provided.
Now, I can again flash the board directly from Arduino IDE without any custom option. This leads me to think that the problem seems to be in the bootloader.
Now, I can again flash the board directly from Arduino IDE without any custom option.
In that case, the previously flashed code interfered with the USB console in pins IO18
and IO19
.
I will update the documentation to mention this, I will leave this ticket open until then. Thanks for the report!
Operating System
Ubuntu 22.04 LTS
Esptool Version
4.5.1
Python Version
Python 3.9.13
Chip Description
ESP32-C3-MINI-1
Device Description
I'm using a custom board, using a design similar to this The ESP32 connects to the PC directly by USB (IO18 and IO19)
Hardware Configuration
I'm using a USB-C port on the board to connect to USB 2.0 or 3.0 standard ports on my PC. The ESP32 interacts with a INA3221 current sensor by I2C.
How is Esptool Run
Terminal (python esptool.py ...) and latest Arduino IDE (lolin C3 board selected)
Full Esptool Command Line that Was Run
python esptool.py -t --before usb_reset --chip esp32c3 write_flash --no-compress 0x00 ~/Arduino/BlinkWithoutDelay/build/esp32.esp32.lolin_c3_mini/BlinkWithoutDelay.ino.bin
Esptool Output
More Information
The PC seems to recognize the ESP32 when the USB cable is plugged in. dmesg output:
Aduino IDE terminal output after selecting the "Lolin C3 mini board":
Other Steps to Reproduce
No response
I Have Read the Troubleshooting Guide