ESP32 & PIO Unified Debugger

Yes :smile: Let me fix it ASAP :blush:
I’ll back here.

Please open PIO IDE Terminal and type pio update. Does it work with new PIO Core+ 1.4.1?

Yes. Is working now :slight_smile:

Reading symbols from c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/firmware.elf...
done.
PlatformIO Unified Debugger > http://bit.ly/pio-debug
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
	http://openocd.org/doc/doxygen/bugs.html
none separate
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
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
Info : accepting 'gdb' connection from pipe
Info : Target halted. PRO_CPU: PC=0x400E8E5E (active)    APP_CPU: PC=0x400E8E5E 
esp32: target state: halted
Info : Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x4008B82F 
Info : Auto-detected flash size 4096 KB
Info : Using flash size 4096 KB
0x400e8e5e in __udivmoddi4 (rp=0x0, d=<optimized out>, n=<optimized out>) at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libgcc/libgcc2.c:1120
1120	/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 1073511828!
Hardware assisted breakpoint 1 at 0x400e7740: 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
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: target state: halted
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
esp32: target state: halted
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: target state: halted
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
esp32: target state: halted
** Programming Started **
auto erase enabled
Info : Use core0 of target 'esp32'
** Programming Started **
auto erase enabled
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E2 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E2 
Info : Use core0 of target 'esp32'
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
wrote 16384 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin in 0.978438s (16.353 KiB/s)
** Programming Finished **
wrote 16384 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin in 0.978438s (16.353 KiB/s)
** Programming Finished **
** Verify Started **
Info : Use core0 of target 'esp32'
** Verify Started **
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
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.331810s (44.406 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.331810s (44.406 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
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
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: target state: halted
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
esp32: target state: halted
** Programming Started **
auto erase enabled
Info : Use core0 of target 'esp32'
** Programming Started **
auto erase enabled
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Info : Use core0 of target 'esp32'
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
wrote 4096 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/partitions.bin in 0.642631s (6.224 KiB/s)
** Programming Finished **
wrote 4096 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/partitions.bin in 0.642631s (6.224 KiB/s)
** Programming Finished **
** Verify Started **
Info : Use core0 of target 'esp32'
** Verify Started **
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
read 3072 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/partitions.bin and flash bank 0 at offset 0x00008000 in 0.307821s (9.746 KiB/s)
contents match
** Verified OK **
read 3072 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/partitions.bin and flash bank 0 at offset 0x00008000 in 0.307821s (9.746 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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: target state: halted
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
esp32: target state: halted
** Programming Started **
auto erase enabled
Info : Use core0 of target 'esp32'
** Programming Started **
auto erase enabled
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E2 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E2 
Info : Use core0 of target 'esp32'
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
wrote 8192 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin in 0.792545s (10.094 KiB/s)
** Programming Finished **
wrote 8192 bytes from file C:/Users/Calin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin in 0.792545s (10.094 KiB/s)
** Programming Finished **
** Verify Started **
Info : Use core0 of target 'esp32'
** Verify Started **
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
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.325811s (24.554 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.325811s (24.554 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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: target state: halted
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 
esp32: target state: halted
** Programming Started **
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
esp32: target state: halted
auto erase enabled
** Programming Started **
auto erase enabled
Info : Use core0 of target 'esp32'
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E2 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E2 
Info : Use core0 of target 'esp32'
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E0 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076E0 
wrote 217088 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/firmware.bin in 3.736851s (56.732 KiB/s)
** Programming Finished **
wrote 217088 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/firmware.bin in 3.736851s (56.732 KiB/s)
** Programming Finished **
** Verify Started **
Info : Use core0 of target 'esp32'
** Verify Started **
Use core0 of target 'esp32'
Info : Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
Target halted. PRO_CPU: PC=0x40091D07 (active)    APP_CPU: PC=0x400076DD 
read 214960 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/firmware.bin and flash bank 0 at offset 0x00010000 in 1.100367s (190.774 KiB/s)
contents match
** Verified OK **
read 214960 bytes from file c:/Users/Calin/Documents/PlatformIO/Projects/esp32_blink/.pioenvs/esp-wrover-kit/firmware.bin and flash bank 0 at offset 0x00010000 in 1.100367s (190.774 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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x5000004B (active)    APP_CPU: PC=0x00000000 
esp32: target state: halted
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 
esp32: target state: halted
Target halted. PRO_CPU: PC=0x40000400 (active)    APP_CPU: PC=0x40000400 
esp32: target state: halted
PlatformIO: Initialization completed
PlatformIO: Resume the execution to `debug_init_break = thb app_main`
Info : Target halted. PRO_CPU: PC=0x400E7740 (active)    APP_CPU: PC=0x400E8FA2 
Target halted. PRO_CPU: PC=0x400E7740 (active)    APP_CPU: PC=0x400E8FA2 
[New Thread 1073511836]
[New Thread 1073510424]
[New Thread 1073514528]
[New Thread 1073502764]
[New Thread 1073498936]
[New Thread 1073501256]
[New Thread 1073503920]
[Switching to Thread 1073509012]

Temporary breakpoint 
1, app_main () at C:\Users\Calin\.platformio\packages\framework-arduinoespressif32\cores\esp32\main.cpp:22
22	{
Info : active_cpu: 0, changed to 1, reson = 0x8011cc11
Info : Target halted. PRO_CPU: PC=0x400D7894             APP_CPU: PC=0x400D0AE7 (active)
active_cpu: 0, changed to 1, reson = 0x8011cc11
Target halted. PRO_CPU: PC=0x400D7894             APP_CPU: PC=0x400D0AE7 (active)
[New Thread 1073422388]
[Switching to Thread 1073422388]

Breakpoint 
2, loop () at src\main.cpp:13
13	    digitalWrite(2,!digitalRead(2));

Thanks! Do you use Zadig tool?

Yes. I set the ft2232 channel 0 to WinUSB for debug and channel 1 is using ftdi drivers (com port)
I never tested with both channels on stetted as com ports…
I know that GDB require libusb on windows for ftdi based Jtag’s.

Could you provide a screenshot here? I would like to add this information to our docs. I think it’s so useful. Also, would be thankful if you explain in a few words what need to configure.

  1. Download and install FTDI drivers from http://www.ftdichip.com/Drivers/VCP.htm

  2. Connect the debugger to PC USB and check the device manager to see if the drivers are installed properly:

  3. Download Zadig tool from https://zadig.akeo.ie/

  4. Open Zadig Tool and go to Options->List All Devices
    zadig1

5.Select the FT2232 channel you want to use as Jtag.
In case of Wrover-Kit, is channel 0: “Dual RS232-HS (interface 0)”, according to Wrover-Kit schematic:

wrover-jtag

If you use FT2232h minimodule, you can use any channel.
The debugger work’s with FT4232h minimodule too (tested).
In this case, you have 4 channels to chose from :slight_smile:
It work’s even with cheap FT232x chip (ex. UM232H , UM232H-B modules).

  1. Select WinUSB
  2. Click Replace Driver

Capture2

After operation completed, disconnect and reconnect the device to USB port

Now you can use PIO Debugger on ESP32

PS.

In case that other channel (channel 1 in case of wrover-kit) is not detected as com port (used by esptool for flashing),
you must enable the VCP mode on channel 1, this way:

  1. On device manager, right click on “USB Serial Converter B” - >Properties ->Advanced
  2. Select “Load VCP” then click OK.

vcp

Then, the FT2232 channel 2 should be detected as Com Port on device manager:

Wiring for Olimex JTAG debuggers

2 Likes

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.