-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: esp_usb_jtag: could not find or open device! (OCD-943) #327
Comments
@aygh4266 Did you burn any efuse to use JTAG pins instead of USB-SERIAL-JTAG? By default usb-serial-jtag is enabled. And, for the ESP-PROG you can use |
OK I understand it better right now. So basically there are two option to debug the esp idf. Using USB-Serial-JTAG by default or using JTAG with external debugger like ESP PROG. So before I burn the efuse, I am trying to use the USB SERIAL JTAG but I still having issues. I tried this command openocd -f board/esp32s3-builtin.cfg for the serial builtin. And got this output: Open On-Chip Debugger v0.12.0-esp32-20240318 (2024-03-18-18:26) |
Update: I can flash the esp32 using the JTAG but can't debug. Maybe it is a VSCode issue, since i am using esp idf extension |
We are about to release the new idf extension which will be faster than the current one. You can download it from here and give it a try. espressif/vscode-esp-idf-extension#1207 (comment) Then you can report your debugging issue there or here with the verbose logs. As I see from your logs, you don't have an issue with the usb-serial-jtag. |
@aygh4266 closing this. Feel free to re-open if you have any other issues. |
@erhankur Following are the debug logs:
|
@PragatiGarg-eaton Please try installing the drivers using the online installer: https://dl.espressif.com/dl/esp-idf/ For the C3, we have a customized WinUSB driver. You can install it from the link. And for the other error, try this command
You need to specify both an interface file and the target. |
Reference: https://www.esp32.com/viewtopic.php?f=12&t=21007#p76800, http://esp32.io/viewtopic.php?t=42394#p140421 and http://esp32.io/viewtopic.php?t=42394#p140421 @erhankur, I’m using the ESP32-C2-DevKitM-1 (revision v0.2) and have already tried connecting a USB/TTL converter to the GPIO18 and GPIO19 pins on the board, but it hasn’t worked. Do you think swapping the resistors, as mentioned, is necessary to use USB/JTAG? The resistors are very small and difficult to solder/desolder, so if there are any other alternatives, I’d prefer to avoid risking damage to the board |
Ah, yes, I forgot that the USB connector is connected to the serial bridge, not a built-in USB device. So, you will need a cable like this: https://www.adafruit.com/product/4448 You don't need to touch the resistors. Just connect the green and white wires to GPIO19 and GPIO18, respectively. |
Yeah, I already gave it a try, it is not working even after the USB/ttl connections. |
Please make sure to use a breakout cable instead of a USB/TTL converter. |
Okay, I'll check with this once. |
Hi @erhankur I tried by connecting breakout cable to GPIO18/19 as you mentioned and as per https://docs.espressif.com/projects/esp-idf/en/stable/esp32c3/api-guides/jtag-debugging/configure-builtin-jtag.html
cc: @igrr |
OpenOCD version
v0.12.0-esp32-20240318
Operating System
Windows 11
Using an IDE ?
VSCode
OpenOCD command line
openocd -f board/esp32s3-builtin.cfg
ESP-IDF version
v5.2.2
Problem Description
Hello everyone,
I am trying to debug my code on my ESP32-S3-DevKitM-1 using esp-prog.
I think it is PID VID issue, since the PID VID on my PORT are follwing USB\VID_0403&PID_6010&MI_00 (libwdi autogenerated).
I have tried to reconfigure the esp32s3-builtin.cfg using these commands:
adapter driver ftdi
ftdi vid_pid 0x0403 0x6010
ftdi layout_init 0x0008 0x000b
ftdi layout_signal nSRST -data 0x0020 -oe 0x0020
adapter speed 20000
transport select jtag
set ESP32_ONLYCPU 1
source [find target/esp32s3.cfg]
but I still got another error:
Open On-Chip Debugger v0.12.0-esp32-20240318 (2024-03-18-18:26)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : ftdi: if you experience problems at higher adapter clocks, try the command "ftdi tdo_sample_edge falling"
Info : clock speed 20000 kHz
Error: JTAG scan chain interrogation failed: all ones
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
Error: esp32s3.cpu0: IR capture error; saw 0x1f not 0x01
Warn : Bypassing JTAG setup events due to errors
Warn : [esp32s3.cpu0] Unexpected OCD_ID = ffffffff
Error: [esp32s3.cpu0] Examination failed
Warn : target esp32s3.cpu0 examination failed
Warn : [esp32s3.cpu1] Unexpected OCD_ID = ffffffff
Error: [esp32s3.cpu1] Examination failed
Warn : target esp32s3.cpu1 examination failed
Info : starting gdb server for esp32s3.cpu0 on 3333
Info : Listening on port 3333 for gdb connections
The Pin Connection is okay. Any help would be appreicated.
Debug Logs
Expected behavior
OpenOCD connected successfully to the board
Screenshots
No response
The text was updated successfully, but these errors were encountered: