ESP32-C3-MINI Programmation Issues

antoinesvsn
Posts: 5
Joined: Tue Aug 31, 2021 2:41 pm

ESP32-C3-MINI Programmation Issues

Postby antoinesvsn » Tue Aug 31, 2021 4:21 pm

Hello,

We currently have issues with the programmation of ESP32C3MINI1-H4.
We produced 12 PCB with this module on it and don't succeeded in reprogramming them on our PCB with JTAG protocol.
We have also Development boards (ESP32-DEVKITM-1) of this module, and the JTAG programmation works well on it.

When we unsolder the module of the Development Board to program it on JTAG by wiring only pins IO4,IO5,IO6,IO7 to the ESP-PROG Board, it works:

C:\esp-idf>openocd -f board/esp32c3-ftdi.cfg
Open On-Chip Debugger v0.10.0-esp32-20210401 (2021-04-01-15:46)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
force hard breakpoints
adapter speed: 5000 kHz

Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : clock speed 5000 kHz
Info : JTAG tap: esp32c3.cpu tap/device found: 0x00005c25 (mfg: 0x612 (Espressif Systems), part: 0x0005, ver: 0x0)
Info : datacount=2 progbufsize=16
Info : Examined RISC-V core; found 1 harts
Info : hart 0: XLEN=32, misa=0x40101104
Info : Listening on port 3333 for gdb connections


When we take our module bought on Mouser to do the same thing, it doesn't work:

C:\esp-idf>openocd -f board/esp32c3-ftdi.cfg
Open On-Chip Debugger v0.10.0-esp32-20210401 (2021-04-01-15:46)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
force hard breakpoints
adapter speed: 5000 kHz

Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : clock speed 5000 kHz
Error: JTAG scan chain interrogation failed: all zeroes
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
Error: esp32c3.cpu: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
Error: dtmcontrol is 0. Check JTAG connectivity/board power.
Info : Listening on port 3333 for gdb connections


Moreover, when we solder the modules we bought on Mouser on the Development Board, neither JTAG nor UART programmation works.

It seems like there is a difference between the Development Board module and the one we supplied on Mouser.
The only difference we can notice for now is that there is "D1H4" written on Development Board modules, and "XXH4" written on the ones we supplied.

We don't know if it is that difference that cause the issue of programmation we face...

Thanks for any help.

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

Re: ESP32-C3-MINI Programmation Issues

Postby ESP_Sprite » Wed Sep 01, 2021 3:14 am

I think that your own modules are one of our early revisions, while the later ones are production (ECO3) versions. The earlier revisions had issues with the build-in USB serial-JTAG peripheral, so they were fused to accept external JTAG instead. The newer (=current) ones have a working USB serial-JTAG peripheral, and JTAG is routed there by default. You can either switch to using the internal USB serial/JTAG peripheral on GPIO18/19, or you can use the serial flasher to blow the fuse that routes the JTAG signal (DIS_USB_JTAG, from memory).

antoinesvsn
Posts: 5
Joined: Tue Aug 31, 2021 2:41 pm

Re: ESP32-C3-MINI Programmation Issues

Postby antoinesvsn » Wed Sep 01, 2021 4:30 pm

Thank you for your help.

How do I use the serial flasher to blow the fuse in question ? I didn't find that in the datasheet...

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

Re: ESP32-C3-MINI Programmation Issues

Postby ESP_Sprite » Fri Sep 03, 2021 11:04 am

Something like

Code: Select all

espefuse.py --port /dev/ttyACM0 burn_efuse JTAG_SEL_ENABLE
should do the trick.

antoinesvsn
Posts: 5
Joined: Tue Aug 31, 2021 2:41 pm

Re: ESP32-C3-MINI Programmation Issues

Postby antoinesvsn » Fri Sep 03, 2021 1:51 pm

We tried to blow the fuse with the serial flasher and also to use the internal USB/JTAG peripheral on GPIO18/19, but both of these solution don't work and it seems like the device doesn't connect :

espefuse.py -p COM7 burn_efuse JTAG_SEL_ENABLE
Connecting........_____....._____....._____....._____....._____....._____....._____

A fatal error occurred: Failed to connect to Espressif device: Timed out waiting for packet header


We don't have any solution left ...

Thank you in advance for your help.

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

Re: ESP32-C3-MINI Programmation Issues

Postby ESP_Sprite » Sat Sep 04, 2021 1:51 am

Do you actually see an USB device appearing when connecting to GPIO18/19?

antoinesvsn
Posts: 5
Joined: Tue Aug 31, 2021 2:41 pm

Re: ESP32-C3-MINI Programmation Issues

Postby antoinesvsn » Mon Sep 06, 2021 1:10 pm

We see an USB device connecting to the computer, but this device is not recognized by the PC, so we can't do anything with this connection.

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

Re: ESP32-C3-MINI Programmation Issues

Postby ESP_Sprite » Tue Sep 07, 2021 12:42 am

That is odd. What OS runs on that PC? Also, when you tried the serial connection, did you make sure the C3 was in download mode (GPIO9 pulled down when the C3 reset)?

john11
Posts: 14
Joined: Wed Jan 13, 2021 7:37 pm

Re: ESP32-C3-MINI Programmation Issues

Postby john11 » Tue Sep 07, 2021 7:52 am

I didn't see the usb-device until I booted the C3 in download mode...

antoinesvsn
Posts: 5
Joined: Tue Aug 31, 2021 2:41 pm

Re: ESP32-C3-MINI Programmation Issues

Postby antoinesvsn » Tue Sep 07, 2021 3:58 pm

We tried to connect the chip to a Windows 10 PC, then to a Linux one, but we faced the same problem.

We actually see an USB Device connecting on Port COM of the PC, but the Device is always connecting and disconnecting from the port, so we don't have time to program it.
Pulling IO9 down doesn't change anything to the problem.

Who is online

Users browsing this forum: Baidu [Spider] and 294 guests