ESP32 & PIO Unified Debugger

and again… back to debugger problems…

Reading symbols from c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/firmware.elf...
done.
PlatformIO Unified Debugger > http://bit.ly/pio-debug
PlatformIO: Initializing remote target...
Open On-Chip Debugger 0.10.0-dev (2018-07-24-09:39)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.org/doc/doxygen/bugs.html
adapter speed: 20000 kHz
esp32 interrupt mask on
Info : tcl server disabled
Info : telnet server disabled
Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED
Info : ftdi: if you experience problems at higher adapter clocks, try the command "ftdi_tdo_sample_edge falling"
Info : clock speed 20000 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 : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Detected debug stubs @ 3ffc3210 on core0 of target 'esp32'
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : accepting 'gdb' connection from pipe
Info : Target halted. PRO_CPU: PC=0x400E649E (active)    APP_CPU: PC=0x400E649E 
Info : Not full dbg stub table 1 of 2
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x400E649E 
Info : Flash mapping 0: 0x0 -> 0x0, 0 KB
Info : Flash mapping 1: 0x0 -> 0x0, 0 KB
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x400E649E 
Info : Auto-detected flash size 4096 KB
Info : Using flash size 4096 KB
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x400E649E 
Info : Flash mapping 0: 0x0 -> 0x0, 0 KB
Info : Flash mapping 1: 0x0 -> 0x0, 0 KB
Info : Using flash size 0 KB
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x400E649E 
Info : Flash mapping 0: 0x0 -> 0x0, 0 KB
Info : Flash mapping 1: 0x0 -> 0x0, 0 KB
Info : Using flash size 0 KB
0x400e649e in __udivmoddi4 (rp=0x0, d=<optimized out>, n=<optimized out>) at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libgcc/libgcc2.c:1193
1193	/builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libgcc/libgcc2.c: No such file or directory.
Not implemented stop reason (assuming exception): undefined
Error: Too large number of threads 1073511932!
Hardware assisted breakpoint 1 at 0x400e4d64: file C:\Users\Calin\.platformio\packages\framework-arduinoespressif32\cores\esp32\main.cpp, line 22.
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)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu1: Current bits set: BreakIn BreakOut RunStallIn
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Info : esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
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)
JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Info : esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
wrote 16384 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin in 0.905478s (17.670 KiB/s)
wrote 16384 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin in 0.905478s (17.670 KiB/s)
** Programming Finished **
** Verify Started **
** Programming Finished **
** Verify Started **
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
read 15088 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin and flash bank 0 at offset 0x00001000 in 0.264849s (55.633 KiB/s)
contents match
** Verified OK **
read 15088 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin and flash bank 0 at offset 0x00001000 in 0.264849s (55.633 KiB/s)
contents match
** Verified OK **
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)
JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Info : esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
wrote 4096 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/partitions.bin in 0.598656s (6.682 KiB/s)
wrote 4096 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/partitions.bin in 0.598656s (6.682 KiB/s)
** Programming Finished **
** Programming Finished **
** Verify Started **
** Verify Started **
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
read 3072 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/partitions.bin and flash bank 0 at offset 0x00008000 in 0.267846s (11.200 KiB/s)
contents match
read 3072 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/partitions.bin and flash bank 0 at offset 0x00008000 in 0.267846s (11.200 KiB/s)
** Verified OK **
contents match
** Verified OK **
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)
JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Info : esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
** Programming Started **
auto erase enabled
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
wrote 8192 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin in 0.692601s (11.551 KiB/s)
wrote 8192 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin in 0.692601s (11.551 KiB/s)
** Programming Finished **
** Programming Finished **
** Verify Started **
** Verify Started **
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
read 8192 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin and flash bank 0 at offset 0x0000e000 in 0.260851s (30.669 KiB/s)
contents match
** Verified OK **
read 8192 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin and flash bank 0 at offset 0x0000e000 in 0.260851s (30.669 KiB/s)
contents match
** Verified OK **
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)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Info : esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
** Programming Started **
auto erase enabled
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
wrote 180224 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/firmware.bin in 3.973708s (44.291 KiB/s)
wrote 180224 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/firmware.bin in 3.973708s (44.291 KiB/s)
** Programming Finished **
** Verify Started **
** Programming Finished **
** Verify Started **
Info : Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x4009170E (active)    APP_CPU: PC=0x40000400 
read 179344 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/firmware.bin and flash bank 0 at offset 0x00010000 in 0.866501s (202.124 KiB/s)
contents match
** Verified OK **
read 179344 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp32dev/firmware.bin and flash bank 0 at offset 0x00010000 in 0.866501s (202.124 KiB/s)
contents match
** Verified OK **
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)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
cpu0: Current bits set: BreakIn BreakOut RunStallIn
cpu1: Current bits set: BreakIn BreakOut RunStallIn
Info : esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Debug controller was reset (pwrstat=0x5F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
Info : esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
esp32: Core was reset (pwrstat=0x1F, after clear 0x0F).
Info : Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
PlatformIO: Initialization completed
PlatformIO: Resume the execution to `debug_init_break = thb app_main`
Error: esp32: Faied to read insn (-4)!
Error: esp32: Faied to add SW BP!
Error: can't add breakpoint: resource not available
Warning:
Cannot insert breakpoint 2.
Cannot access memory at address 0x400d0977
  1. Please use triple of ` when inserting long texts. See my edit above.
  2. We updated openocd-esp32 to the latest version yesterday. It seems that they have introduced a bug. We will revert back to the previous version.

Yep… i found the bug:

On …/openocd\scripts\target\esp32.cfg the line

“gdb_breakpoint_override hard”

was removed.
Adding this instruction at line 100, fix the problem :slight_smile:

PS.
Tnx for posting suggestion. I am not very familiar with this type of forum…

The latest release of OpenOCD for ESP32 is broken. We reverted back to the previous version. Please run pio update.

I have problems too with my OLIMEX ARM-USB-OCD-H and Adafruit Huzzah32 (ESP-32) board.

but first I have to note that driver installation is a litte different from the example.

The first step of installing FTDI driver is not applicable to this OLIMEX debugger since :

After following driver installation process described in Olimex documentation (see chap. 3.3.3 of https://www.olimex.com/Products/ARM/JTAG/_resources/ARM-USB-OCD_and_OCD_H_manual.pdf), I wanted to start th debug session with F5.

And it gave these errors in the debug console:

Reading symbols from c:/Users/sds-emb/Documents/PlatformIO/Projects/ProjectHuzzah32Arduino/.pioenvs/featheresp32/firmware.elf...
done.
PlatformIO Unified Debugger > xxxxcensored (I can put only 2 links)
PlatformIO: Initializing remote target...
Open On-Chip Debugger 0.10.0-dev (2018-06-04-09:51)
Licensed under GNU GPL v2
For bug reports, read
	xxxcensored
adapter speed: 20000 kHz
esp32 interrupt mask on
force hard breakpoints
Info : tcl server disabled
Info : telnet server disabled
Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED
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 zeroes
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
Error: esp32.cpu0: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
cpu0: Current bits set: none
cpu1: Current bits set: none
Info : accepting 'gdb' connection from pipe
Error: cpu1: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates target still busy!
Error: cpu1: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu1: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: Exception reading acchi!

Info : active_cpu: 0, changed to 1, reson = 0xffffffff
Info : Target halted. PRO_CPU: PC=0x00000000             APP_CPU: PC=0x00000000 (active)
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : esp32: Failed writing 4 bytes at address 0x3FF5F064, data - a1, 3a, d8, 50, a1, 3a, d8, 50
embedded:startup.tcl:21: Error: 
in procedure 'halt' 
in procedure 'ocd_bouncer' 
in procedure 'esp_core_halt' 
in procedure 'esp32' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 44
in procedure 'ocd_bouncer' 
at file "embedded:startup.tcl", line 21

esp32: target state: halted
Info : Use core1 of target 'esp32'
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : cpu0: Failed reading 7416 bytes at address 0x40090000
Error: no working area available, can't alloc space for stub code!
Error: Failed to load stub (-308)!
Error: Algorithm run faied (-308)!
Info : Auto-detected flash size 0 KB
Error: Failed to probe flash, size 0 KB
Info : esp32: Debug controller was reset (pwrstat=0xFF, after clear 0xFF).
Info : esp32: Core was reset (pwrstat=0xFF, after clear 0xFF).
warning: while parsing target memory map (at line 2): Required element <memory> is missing
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1016). Workaround: increase "set remotetimeout" in GDB
Warn : cpu0: Failed reading 2 bytes at address 0x400E4A88
0x00000000 in ?? ()
Not implemented stop reason (assuming exception): undefined
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : cpu0: Failed reading 4 bytes at address 0x3FF00030
Error: Failed to read target memory (-4)!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1054). Workaround: increase "set remotetimeout" in GDB
Warn : cpu0: Failed reading 4 bytes at address 0x3FFC25B0
Error: Could not read FreeRTOS thread count from target
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1004). Workaround: increase "set remotetimeout" in GDB
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1006). Workaround: increase "set remotetimeout" in GDB
Warn : cpu0: Failed reading 2 bytes at address 0x400E4CCB
Hardware assisted breakpoint 1 at 0x400e4ccb: file C:\Users\sds-emb\.platformio\packages\framework-arduinoespressif32\cores\esp32\main.cpp, line 23.
Error: JTAG scan chain interrogation failed: all ones
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
JTAG scan chain interrogation failed: all ones
Check JTAG interface, timings, target power, etc.
Trying to use configured scan chain anyway...
Error: esp32.cpu0: IR capture error; saw 0x1f not 0x01
Warn : Bypassing JTAG setup events due to errors
cpu0: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
esp32.cpu0: IR capture error; saw 0x1f not 0x01
Bypassing JTAG setup events due to errors
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
cpu0: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Warn : cpu0: Failed reading 76 bytes at address 0x50000000
Error: esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
cpu0: Failed reading 76 bytes at address 0x50000000
esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
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: esp32.cpu0: IR capture error; saw 0x1f not 0x01
Warn : Bypassing JTAG setup events due to errors
JTAG scan chain interrogation failed: all ones
cpu0: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Check JTAG interface, timings, target power, etc.
Trying to use configured scan chain anyway...
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
esp32.cpu0: IR capture error; saw 0x1f not 0x01
Bypassing JTAG setup events due to errors
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
cpu0: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Warn : cpu0: Failed reading 76 bytes at address 0x50000000
Error: esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
cpu0: Failed reading 76 bytes at address 0x50000000
esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
Info : TAP esp32.cpu0 does not have IDCODE
Info : TAP esp32.cpu1 does not have IDCODE
Info : TAP auto0.tap does not have IDCODE
Info : TAP auto1.tap does not have IDCODE
Info : TAP auto2.tap does not have IDCODE
TAP esp32.cpu0 does not have IDCODE
Info : TAP auto3.tap does not have IDCODE
Info : TAP auto4.tap does not have IDCODE
Info : TAP auto5.tap does not have IDCODE
Info : TAP auto6.tap does not have IDCODE
TAP esp32.cpu1 does not have IDCODE
TAP auto0.tap does not have IDCODE
TAP auto1.tap does not have IDCODE
TAP auto2.tap does not have IDCODE
Info : TAP auto7.tap does not have IDCODE
Info : TAP auto8.tap does not have IDCODE
Info : TAP auto9.tap does not have IDCODE
Info : TAP auto10.tap does not have IDCODE
TAP auto3.tap does not have IDCODE
TAP auto4.tap does not have IDCODE
TAP auto5.tap does not have IDCODE
TAP auto6.tap does not have IDCODE
Info : TAP auto11.tap does not have IDCODE
Info : TAP auto12.tap does not have IDCODE
Info : TAP auto13.tap does not have IDCODE
Info : TAP auto14.tap does not have IDCODE
TAP auto7.tap does not have IDCODE
TAP auto8.tap does not have IDCODE
TAP auto9.tap does not have IDCODE
TAP auto10.tap does not have IDCODE
Info : TAP auto15.tap does not have IDCODE
Info : TAP auto16.tap does not have IDCODE
Info : TAP auto17.tap does not have IDCODE
Info : TAP auto18.tap does not have IDCODE
TAP auto11.tap does not have IDCODE
TAP auto12.tap does not have IDCODE
TAP auto13.tap does not have IDCODE
TAP auto14.tap does not have IDCODE
Warn : Unexpected idcode after end of chain: 21 0x00000000
Warn : Unexpected idcode after end of chain: 53 0x00000000
Warn : Unexpected idcode after end of chain: 85 0x00000000
TAP auto15.tap does not have IDCODE
TAP auto16.tap does not have IDCODE
TAP auto17.tap does not have IDCODE
TAP auto18.tap does not have IDCODE
Warn : Unexpected idcode after end of chain: 117 0x00000000
Warn : Unexpected idcode after end of chain: 149 0xfffffff8
Error: double-check your JTAG setup (interface, speed, ...)
Unexpected idcode after end of chain: 21 0x00000000
Unexpected idcode after end of chain: 53 0x00000000
Unexpected idcode after end of chain: 85 0x00000000
Error: Trying to use configured scan chain anyway...
Error: esp32.cpu0: IR capture error; saw 0x1f not 0x01
Warn : Bypassing JTAG setup events due to errors
Unexpected idcode after end of chain: 117 0x00000000
Unexpected idcode after end of chain: 149 0xfffffff8
double-check your JTAG setup (interface, speed, ...)
cpu0: Current bits set: none
Trying to use configured scan chain anyway...
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
esp32.cpu0: IR capture error; saw 0x1f not 0x01
Bypassing JTAG setup events due to errors
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu0: Current bits set: none
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : cpu0: Failed reading 76 bytes at address 0x50000000
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: Failed reading 76 bytes at address 0x50000000
embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
Info : JTAG tap: esp32.cpu0 tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Warn : JTAG tap: esp32.cpu0       UNEXPECTED: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Error: JTAG tap: esp32.cpu0  expected 1 of 1: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
Info : JTAG tap: esp32.cpu1 tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: esp32.cpu0 tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: esp32.cpu0       UNEXPECTED: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Warn : JTAG tap: esp32.cpu1       UNEXPECTED: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Error: JTAG tap: esp32.cpu1  expected 1 of 1: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu0  expected 1 of 1: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
JTAG tap: esp32.cpu1 tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto0.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto1.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: esp32.cpu1       UNEXPECTED: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: esp32.cpu1  expected 1 of 1: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
Info : JTAG tap: auto2.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto3.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto0.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto1.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto4.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto5.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto2.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto3.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto6.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto7.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto4.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto5.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto8.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto9.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto6.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto7.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto10.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto11.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto8.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto9.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto12.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto13.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto10.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto11.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto14.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : JTAG tap: auto15.tap tap/device found: 0x7fffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0x7)
JTAG tap: auto12.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto13.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : TAP auto16.tap does not have IDCODE
Info : TAP auto17.tap does not have IDCODE
Info : TAP auto18.tap does not have IDCODE
Info : TAP auto0.tap does not have IDCODE
JTAG tap: auto14.tap tap/device found: 0xffffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
JTAG tap: auto15.tap tap/device found: 0x7fffffff (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0x7)
Warn : Unexpected idcode after end of chain: 580 0x00000002
Warn : Unexpected idcode after end of chain: 612 0x00000000
Warn : Unexpected idcode after end of chain: 644 0x00000000
TAP auto16.tap does not have IDCODE
TAP auto17.tap does not have IDCODE
TAP auto18.tap does not have IDCODE
TAP auto0.tap does not have IDCODE
Error: double-check your JTAG setup (interface, speed, ...)
Error: Trying to use configured scan chain anyway...
Error: esp32.cpu0: IR capture error; saw 0x1f not 0x01
Unexpected idcode after end of chain: 580 0x00000002
Unexpected idcode after end of chain: 612 0x00000000
Unexpected idcode after end of chain: 644 0x00000000
Warn : Bypassing JTAG setup events due to errors
double-check your JTAG setup (interface, speed, ...)
cpu0: Current bits set: none
Trying to use configured scan chain anyway...
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
esp32.cpu0: IR capture error; saw 0x1f not 0x01
Bypassing JTAG setup events due to errors
cpu0: Current bits set: none
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : cpu0: Failed reading 76 bytes at address 0x50000000
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: Failed reading 76 bytes at address 0x50000000
embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
esp32_soc_reset 551 err=-4
in procedure 'program_esp32' 
in procedure 'reset' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32' 
in procedure 'program_error' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
Error: JTAG scan chain interrogation failed: all ones
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
JTAG scan chain interrogation failed: all ones
Check JTAG interface, timings, target power, etc.
Error: esp32.cpu0: IR capture error; saw 0x1f not 0x01
Warn : Bypassing JTAG setup events due to errors
Trying to use configured scan chain anyway...
cpu0: Current bits set: none
esp32.cpu0: IR capture error; saw 0x1f not 0x01
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Bypassing JTAG setup events due to errors
cpu0: Current bits set: none
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu1: Current bits set: BreakIn BreakOut RunStallIn DebugModeOut
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : cpu0: Failed reading 76 bytes at address 0x50000000
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: esp32_soc_reset 551 err=-4
in procedure 'reset' 
in procedure 'ocd_bouncer'


cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: Failed reading 76 bytes at address 0x50000000
esp32_soc_reset 551 err=-4
in procedure 'reset' 
in procedure 'ocd_bouncer'


PlatformIO: Initialization completed
PlatformIO: Resume the execution to `debug_init_break = thb app_main`
Info : esp32: Debug controller was reset (pwrstat=0xFF, after clear 0xFF).
Info : esp32: Core was reset (pwrstat=0xFF, after clear 0xFF).
Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (2020). Workaround: increase "set remotetimeout" in GDB
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1011). Workaround: increase "set remotetimeout" in GDB
Error: Exception reading pc!

Info : active_cpu: 0, changed to 1, reson = 0xffffffff
Info : Target halted. PRO_CPU: PC=0x00000000             APP_CPU: PC=0x00000000 (active)
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1015). Workaround: increase "set remotetimeout" in GDB
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : keep_alive() was not invoked in the 1000ms timelimit. GDB alive packet not sent! (1001). Workaround: increase "set remotetimeout" in GDB
Warn : esp32: Failed writing 4 bytes at address 0x3FF5F064, data - a1, 3a, d8, 50, a1, 3a, d8, 50
embedded:startup.tcl:21: Error: 
in procedure 'esp_core_halt' 
in procedure 'esp32' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 44
in procedure 'ocd_bouncer' 
at file "embedded:startup.tcl", line 21

esp32: target state: halted
Info : esp32: Debug controller was reset (pwrstat=0xFF, after clear 0xFF).
Info : esp32: Core was reset (pwrstat=0xFF, after clear 0xFF).
Error: cpu0: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: cpu1: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates target still busy!
cpu0: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates target still busy!
cpu0: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu1: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu1: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu1: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_resume (line 446): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu1: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu1: esp32_write_dirty_registers (line 326): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: cpu0: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: cpu1: xtensa_resume (line 446): DSR (FFFFFFFF) indicates target still busy!
cpu0: xtensa_resume (line 446): DSR (FFFFFFFF) indicates target still busy!
cpu0: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu1: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu1: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu1: xtensa_resume (line 446): DSR (FFFFFFFF) indicates target still busy!
cpu1: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu1: xtensa_resume (line 446): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates target still busy!
cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates target still busy!
cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: Exception reading pc!

Info : active_cpu: 1, changed to 0, reson = 0xffffffff
Info : active_cpu: 0, changed to 1, reson = 0xffffffff
Info : Target halted. PRO_CPU: PC=0x00000000             APP_CPU: PC=0x00000000 (active)
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_read_memory (line 603): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : cpu0: Failed reading 4 bytes at address 0x3FFC25B0
Error: Could not read FreeRTOS thread count from target
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : esp32: Failed writing 4 bytes at address 0x3FF5F064, data - a1, 3a, d8, 50, a1, 3a, d8, 50
embedded:startup.tcl:21: Error: 
in procedure 'esp_core_halt' 
in procedure 'esp32' called at file "C:/Users/sds-emb/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 44
in procedure 'ocd_bouncer' 
at file "embedded:startup.tcl", line 21

Exception reading pc!

active_cpu: 1, changed to 0, reson = 0xffffffff
active_cpu: 0, changed to 1, reson = 0xffffffff
Target halted. PRO_CPU: PC=0x00000000             APP_CPU: PC=0x00000000 (active)

Program received signal 
SIGINT, Interrupt.
0x00000000 in ?? ()

while OLIMEX tool Led is blinking

After that I tried to put some breakpoints, an push starts, nothing happens, the blinky arduino code doesn’t even make the led blink on the board.

I had the following error messages on the debug console:

Warn : xtensa_read_memory: esp32: target not halted
Warn : xtensa_read_memory: esp32: target not halted
Warn : WARNING! The target is already running. All changes GDB did to registers will be discarded! Waiting for target to halt.
WARNING! The target is already running. All changes GDB did to registers will be discarded! Waiting for target to halt.
Info : Halt timed out, wake up GDB.
Warn : target esp32 is not halted
Error: FreeRTOS_update_threads not TARGET_HALTED!
Warn : xtensa_read_memory: esp32: target not halted
Error: Could not read FreeRTOS thread count from target
Halt timed out, wake up GDB.
[
Remote target] #1 stopped.
0x00000000 in ?? ()
Warn : WARNING! The target is already running. All changes GDB did to registers will be discarded! Waiting for target to halt.
WARNING! The target is already running. All changes GDB did to registers will be discarded! Waiting for target to halt.

And the Olimex tool led is still blinking

My hardware set up is Windows 8.1, VSCode (last version), pio core version 3.6.1a1

And the hardware wiring is the one described here : Debugging ESP32 · Pro/open62541-arduino Wiki · GitHub

*** UPDATE1 ***
After two or tree tries my Adafruit HUZZAH32 has stopped to work, I can not even upload the simple blinky example to normal process: The PC does not even detect the board !!!

More details: Since there is already Blinky programm in it, when I plug it in my PC (or a powered USB hub) it blinks 1 or 2 secs, then it stops and the board warms up.

*** UPDATE2 *** Update after a last retry, the CP2104 component burnt ! I can’t programm the Adafruit board trough USB anymore !
I think however that the target is still programmable via JTAG controller (if it is correctly wired). Correct me if I’m wrong.

Yes. It can be programmed by Jtag.
-Make sure the Jtag is connected correctly to the target board.
-Make sure you set on platformio.ini “debug_tool = olimex-arm-usb-ocd-h” or “debug_tool = ftdi”
I never tested platformio with olimex jtag… but it should work like any other ftdi based jtag.
Still, i recommend using the zadig solution for the driver. Is tested and working.

Zadig is recommended inside the documentation protocol of the Olimex tool so I used Zadig.

I didn’t succed into programming it via the JTAG, I don’t know if the wiring is correct, I didn’t find any documentation which explain how to connect it exept that link I gave above. I’ve noticed him about what happened and he answered:

Thanks for the info, but as always with microcontroller programming: You really have to know what you are doing. There can be many reasons why your board broke. The only think I know for sure is that the procedure worked for me. Note that I did not use platform.io at all…

Have you seen this Olimex ARM-USB-OCD-H — PlatformIO latest documentation ?

Yes, but there is no information in Adafruit website of where are the pins of JTAG debugging on their Adafruit Huzzah32 board

So I based myself on this schema below from this tutorial (next link): Debugging ESP32 · Pro/open62541-arduino Wiki · GitHub

How to configure PlatformIO in order to upload the firmware via the Olimex JTAG debugger ?

Use 'Pio Debug" and platformio will compile the project, upload to target using Jtag, then will start the debug session.

Please take a look at hint on your screenshot. AVAILABLE: ...., CURRENT: ..., upload_protocol = ....
http://docs.platformio.org/en/latest/projectconf/section_env_upload.html#upload-protocol

Thanks, I removed the connection to the 3V which makes my dev board shutdown, I added the configuration of the upload_protcol.

And I got this (and the upload failed):


Processing featheresp32 (platform: espressif32; board: featheresp32; framework: arduino)
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
PLATFORM: Espressif 32 > Adafruit ESP32 Feather
SYSTEM: ESP32 240MHz 320KB RAM (4MB Flash)
DEBUG: CURRENT(olimex-arm-usb-ocd-h) EXTERNAL(esp-prog, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny)
Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF MODES: FINDER(chain) COMPATIBILITY(soft)
Collected 24 compatible libraries
Scanning dependencies...
No dependencies
Retrieving maximum program size .pioenvs\featheresp32\firmware.elf
Checking size .pioenvs\featheresp32\firmware.elf
Memory Usage -> http://bit.ly/pio-memory-usage
DATA:    [          ]   4.2% (used 13884 bytes from 327680 bytes)
PROGRAM: [=         ]  13.6% (used 178024 bytes from 1310720 bytes)
Configuring upload protocol...
AVAILABLE: esp-prog, esptool, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny
CURRENT: upload_protocol = olimex-arm-usb-ocd-h
Uploading .pioenvs\featheresp32\firmware.bin
Open On-Chip Debugger 0.10.0-dev (2018-06-04-09:51)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
adapter speed: 20000 kHz
esp32 interrupt mask on
force hard breakpoints
Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED
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 zeroes
Error: Check JTAG interface, timings, target power, etc.
Error: Trying to use configured scan chain anyway...
Error: esp32.cpu0: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
cpu0: Current bits set: none
cpu1: Current bits set: none
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: esp32.cpu0: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
cpu0: Current bits set: none
cpu1: Current bits set: none
Error: timed out while waiting for target halted / 1 - 2
Error: timed out while waiting for target halted / 1 - 2
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: esp32_fetch_all_regs (line 201): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Error: Exception reading interrupt!

Info : Target halted. PRO_CPU: PC=0x00000000 (active)    APP_CPU: PC=0x00000000
esp32: target state: halted
Error: Exception reading ccompare0!

Info : Target halted. PRO_CPU: PC=0x00000000 (active)    APP_CPU: PC=0x00000000
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : esp32: Failed writing 4 bytes at address 0x3FF5F048, data - 00, 00, 00, 00, 00, 00, 00, 00
embedded:startup.tcl:21: Error:
in procedure 'program_esp32'
in procedure 'reset' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'
in procedure 'ocd_process_reset'
in procedure 'ocd_process_reset_inner' called at file "embedded:startup.tcl", line 248
in procedure 'esp32' called at file "embedded:startup.tcl", line 312
in procedure 'ocd_bouncer'
in procedure 'esp_core_halt'
in procedure 'esp32' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 45
in procedure 'ocd_bouncer'
at file "embedded:startup.tcl", line 21

esp32: target state: halted
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
Warn : esp32: Failed writing 4 bytes at address 0x3FF0002C, data - 00, 00, 00, 00, e8, dd, 28, 00
Error: xtensa_write_uint32_list: error writing to 3ff0002c
Warn : esp32_soc_reset xtensa_write_uint32_list (reg_value_pairs_post) err=-4
Error: esp32_soc_reset: Couldn't halt target before SoC reset! (xtensa_assert_reset returned -4)
Error: esp32_soc_reset: Couldn't halt target before SoC reset! (xtensa_assert_reset returned -4)
embedded:startup.tcl:21: Error:
in procedure 'program_esp32'
in procedure 'reset' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'
in procedure 'ocd_process_reset'
in procedure 'ocd_process_reset_inner' called at file "embedded:startup.tcl", line 248
in procedure 'esp32' called at file "embedded:startup.tcl", line 312
in procedure 'ocd_bouncer'
in procedure 'esp_core_halt'
in procedure 'esp32' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 45
in procedure 'ocd_bouncer'
at file "embedded:startup.tcl", line 21
in procedure 'program_esp32'
in procedure 'reset' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
in procedure 'ocd_bouncer'

embedded:startup.tcl:454: Error: ** Unable to reset target **
in procedure 'program_esp32'
in procedure 'program_error' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
at file "embedded:startup.tcl", line 454
*** [upload] Error 1
============================================================================================== [ERROR] Took 6.84 seconds ==============================================================================================
Le processus du terminal s'est achevé avec le code de sortie 1

Le terminal sera réutilisé par les tâches, appuyez sur une touche pour le fermer.
```

There is something wrong with the connection between Jtag and the ESP32 board…
Try to swap TDI/TDO pins…

@botofancalin I did it and these are the results:

    > Executing task: C:\Users\c\.platformio\penv\Scripts\platformio.exe run --target upload <

    Processing featheresp32 (platform: espressif32; board: featheresp32; framework: arduino)
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Verbose mode can be enabled via `-v, --verbose` option
    PLATFORM: Espressif 32 > Adafruit ESP32 Feather
    SYSTEM: ESP32 240MHz 320KB RAM (4MB Flash)
    DEBUG: CURRENT(olimex-arm-usb-ocd-h) EXTERNAL(esp-prog, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny)
    Library Dependency Finder -> http://bit.ly/configure-pio-ldf
    LDF MODES: FINDER(chain) COMPATIBILITY(soft)
    Collected 24 compatible libraries
    Scanning dependencies...
    No dependencies
    Retrieving maximum program size .pioenvs\featheresp32\firmware.elf
    Checking size .pioenvs\featheresp32\firmware.elf
    Memory Usage -> http://bit.ly/pio-memory-usage
    DATA:    [          ]   4.2% (used 13884 bytes from 327680 bytes)
    PROGRAM: [=         ]  13.6% (used 178024 bytes from 1310720 bytes)
    Configuring upload protocol...
    AVAILABLE: esp-prog, esptool, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny
    CURRENT: upload_protocol = olimex-arm-usb-ocd-h
    Uploading .pioenvs\featheresp32\firmware.bin
    Open On-Chip Debugger 0.10.0-dev (2018-06-04-09:51)
    Licensed under GNU GPL v2
    For bug reports, read
    http://openocd.org/doc/doxygen/bugs.html
    adapter speed: 20000 kHz
    esp32 interrupt mask on
    force hard breakpoints
    Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED
    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 zeroes
    Error: Check JTAG interface, timings, target power, etc.
    Error: Trying to use configured scan chain anyway...
    Error: esp32.cpu0: IR capture error; saw 0x00 not 0x01
    Warn : Bypassing JTAG setup events due to errors
    cpu0: Current bits set: none
    cpu1: Current bits set: none
    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: esp32.cpu0: IR capture error; saw 0x00 not 0x01
    Warn : Bypassing JTAG setup events due to errors
    cpu0: Current bits set: none
    cpu1: Current bits set: none
    Error: timed out while waiting for target halted / 1 - 2
    Error: timed out while waiting for target halted / 1 - 2
    Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates target still busy!
    Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
    Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
    Error: Exception reading ccompare0!

    Info : active_cpu: 0, changed to 1, reson = 0xffffffff
    Info : Target halted. PRO_CPU: PC=0x00000000             APP_CPU: PC=0x00000000 (active)
    esp32: target state: halted
    Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates target still busy!
    Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
    Error: cpu0: esp32_fetch_all_regs (line 171): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
    Error: Exception reading pc!

    Info : active_cpu: 1, changed to 0, reson = 0xffffffff
    Info : Target halted. PRO_CPU: PC=0x00000000 (active)    APP_CPU: PC=0x00000000
    Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
    Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
    Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
    Warn : esp32: Failed writing 4 bytes at address 0x3FF60064, data - a1, 3a, d8, 50, a1, 3a, d8, 50
    embedded:startup.tcl:21: Error:
    in procedure 'program_esp32'
    in procedure 'reset' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
    in procedure 'ocd_bouncer'
    in procedure 'ocd_process_reset'
    in procedure 'ocd_process_reset_inner' called at file "embedded:startup.tcl", line 248
    in procedure 'esp32' called at file "embedded:startup.tcl", line 312
    in procedure 'ocd_bouncer'
    in procedure 'esp_core_halt'
    in procedure 'esp32' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 47
    in procedure 'ocd_bouncer'
    at file "embedded:startup.tcl", line 21

    esp32: target state: halted
    Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates target still busy!
    Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an exception!
    Error: cpu0: xtensa_write_memory (line 711): DSR (FFFFFFFF) indicates DIR instruction generated an overrun!
    Warn : esp32: Failed writing 76 bytes at address 0x50000000, data - 00, 00, 00, 00, 00, 00, 00, 00
    Error: esp32_soc_reset 632 err=-4
    Error: esp32_soc_reset: Couldn't halt target before SoC reset! (xtensa_assert_reset returned -4)
    Error: esp32_soc_reset: Couldn't halt target before SoC reset! (xtensa_assert_reset returned -4)
    embedded:startup.tcl:21: Error:
    in procedure 'program_esp32'
    in procedure 'reset' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
    in procedure 'ocd_bouncer'
    in procedure 'ocd_process_reset'
    in procedure 'ocd_process_reset_inner' called at file "embedded:startup.tcl", line 248
    in procedure 'esp32' called at file "embedded:startup.tcl", line 312
    in procedure 'ocd_bouncer'
    in procedure 'esp_core_halt'
    in procedure 'esp32' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 47
    in procedure 'ocd_bouncer'
    at file "embedded:startup.tcl", line 21
    in procedure 'program_esp32'
    in procedure 'reset' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 123
    in procedure 'ocd_bouncer'

    embedded:startup.tcl:454: Error: ** Unable to reset target **
    in procedure 'program_esp32'
    in procedure 'program_error' called at file "C:\Users\c\.platformio\packages\tool-openocd-esp32/share/openocd/scripts/target/esp32.cfg", line 124
    at file "embedded:startup.tcl", line 454
    *** [upload] Error 1
    ============================================================================================== [ERROR] Took 7.38 seconds ==============================================================================================
    Le processus du terminal s'est achevé avec le code de sortie 1

    Le terminal sera réutilisé par les tâches, appuyez sur une touche pour le fermer.

Still, there are connection problems…
Please check the connection. It should be like this:
TDI -> GPIO12
TCK -> GPIO13
TMS ->GPIO14
TDO -> GPIO15
TRST -> EN (Reset)
GND -> GND

I don’t have the Olimex Jtag.
Maybe the Olimex use the other channel of FT2232 as Jtag. That can be investigated on the Jtag schematic.
I use various FT232H and FT2232D chip’s as jtag’s, even from old salvaged pcb’s and they all work once they are connected properly.

As you can see in the schema I posted above all of this is respected except that VCC which was connected to the 3V board.

As I said just 2 comments before, I removed the VCC connection (which causes mes problems) then I did the test with the result above (see 2 comments before).

I did another test by connecting TRST to RST pin instead of EN. This, because EN is not a reset pin

However, it gave me always the same answer : “unable to reset target”