ESP32 – JTAG debugging using C232HM (FTDI based cable)

Sysprogs forums Forums VisualGDB ESP32 – JTAG debugging using C232HM (FTDI based cable)

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #24728
    christophe
    Participant

    Hello,

    I’m trying to use a C232HM-DDHSL-0 JTAG vable (based on a FTDI chip) to debug an ESP32. I correctly connected the TDO, TDI, TCK and TMS signal as well as the 3.3v and the GND). I also use the zadig tool to install the WinUSB driver attached to the device.

    After selecting the debug method as OpenOCD, i’ve edited the interface/ftdi/esp32_devkit_v1.cfg to match the PID/VID.

    When I try to test the connection, I’ve got this following error :

     

    Open On-Chip Debugger 0.9.0 (2019-01-11)
    Licensed under GNU GPL v2
    For bug reports, read
    http://openocd.org/doc/doxygen/bugs.html
    none separate
    adapter speed: 3000 kHz
    Info : auto-selecting first available session transport “jtag”. To override use ‘transport select <transport>’.
    esp32 interrupt mask on
    VisualGDB_OpenOCD_Ready
    Info : clock speed 3000 kHz
    Info : JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
    Info : JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
    Info : accepting ‘gdb’ connection on tcp/51321
    Info : Halt timed out, wake up GDB.
    Error: timed out while waiting for target halted / 1 – 2

    Error: Target not halted
    Error: auto_probe failed
    Error: Connect failed. Consider setting up a gdb-attach event for the target to prepare target for GDB connect, or use ‘gdb_memory_map disable’.
    Error: attempted ‘gdb’ connection rejected

    Am I missing something ?

     

     

     

     

     

    #24729
    support
    Keymaster

    Hi,

    It looks like a missing reset signal (in our experiments, some probes had to use the TRST signal, while others needed SRST), so trying a few reset options in OpenOCD configuration script might resolve this. If not, please try using Olimex ARM-USB-OCD-H (we have fully tested it on our side and covered in our tutorials), or some of the ESP32 boards with on-board JTAG, that should have the necessary wiring and matching configuration scripts.

    #24737
    christophe
    Participant

    I’ve checked with another esp32 eval board (based on ESP32-WROVER-B). If I use the built-in JTAG, it works. If i remove the JTAG jumpers and plug my C232HM cable, it also works (without the need of any reset).

    But the JTAG debug on the WROOM32 is still stuck!

    #24740
    support
    Keymaster

    Sorry, it looks like something related to the wiring or layout of a specific board and is generally outside VisualGDB’s control. The only way to diagnose this that we could suggest would be to try understanding the differences between a working an a non-working setup (e.g. using a logic analyzer). Please also consider asking on the Espressif forums – you may get some insights into this from the team that designed the WROVER/WROOM boards.

    #24741
    christophe
    Participant

    Hello,

    I got something. Seems related to underpowering from the jtag cable: removing the 3v3 wire and using the power supply using the USB cable (UART), it seems working well.

     

    #24742
    support
    Keymaster

    Thanks for sharing this, it does look like the potential cause for the problem, although unfortunately it’s not something that VisualGDB could easily fix.

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.