I’ve been using the debugger with my ESP32 on platform.io for a while and it’s been working fine. But suddenly I am getting an error every time I try to launch it now.
The last part of the log says:
** Verify Failed **
.pioinit:14: Error in sourced command file:
Protocol error with Rcmd
I can program it and it runs, but I can’t use the debugger anymore. I’ve tried reinstallingthe USB drivers for teh ESP-Prog board and reinstalling the WinUSB with Zadig.exe but it still fails. The log has a lot of info in it but I am not familiar with how to investigate this Rcmd issue.
Reading symbols from d:\Work\pio\2021-05-19-pio\esp32\unit_tests.pio\build\esp32dev\firmware.elf…
PlatformIO Unified Debugger → Redirecting...
PlatformIO: debug_tool = esp-prog
PlatformIO: Initializing remote target…
Open On-Chip Debugger v0.11.0-esp32-20220706 (2022-07-06-15:48)
Licensed under GNU GPL v2
For bug reports, read
OpenOCD: Bug Reporting
adapter speed: 20000 kHzWARNING: boards/esp-wroom-32.cfg is deprecated, and may be removed in a future release.
adapter speed: 5000 kHzInfo : tcl server disabled
Info : telnet server disabled
Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED
Info : clock speed 5000 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.cpu0] Debug controller was reset.
Info : [esp32.cpu0] Core was reset.
Info : [esp32.cpu1] Debug controller was reset.
Info : [esp32.cpu1] Core was reset.
Info : starting gdb server for esp32.cpu0 on pipe
Info : accepting ‘gdb’ connection from pipe
Info : [esp32.cpu0] Target halted, PC=0x4013A63E, debug_reason=00000000
Info : Set GDB target to ‘esp32.cpu0’
Info : [esp32.cpu1] Target halted, PC=0x40095034, debug_reason=00000000
Warn : No symbols for FreeRTOS!
Info : [esp32.cpu0] Target halted, PC=0x40092612, debug_reason=00000001
Info : Flash mapping 0: 0x10020 → 0x3f400020, 115 KB
Info : Flash mapping 1: 0x30020 → 0x400d0020, 434 KB
Info : [esp32.cpu0] Target halted, PC=0x40092612, debug_reason=00000001
Info : Auto-detected flash bank ‘esp32.cpu0.flash’ size 4096 KB
Info : Using flash bank ‘esp32.cpu0.flash’ size 4096 KB
Info : [esp32.cpu0] Target halted, PC=0x40092612, debug_reason=00000001
Info : Flash mapping 0: 0x10020 → 0x3f400020, 115 KB
Info : Flash mapping 1: 0x30020 → 0x400d0020, 434 KB
Info : Using flash bank ‘esp32.cpu0.irom’ size 436 KB
Info : [esp32.cpu0] Target halted, PC=0x40092612, debug_reason=00000001
Info : Flash mapping 0: 0x10020 → 0x3f400020, 115 KB
Info : Flash mapping 1: 0x30020 → 0x400d0020, 434 KB
Info : Using flash bank ‘esp32.cpu0.drom’ size 116 KB
Info : New GDB Connection: 1, Target esp32.cpu0, state: halted
Warn : keep_alive() was not invoked in the 1000 ms timelimit. GDB alive packet not sent! (1023 ms). Workaround: increase “set remotetimeout” in GDB
0x4013a63e in esp_pm_impl_waiti () at /Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf-public/components/hal/esp32/include/hal/cpu_ll.h:183
183 /Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf-public/components/hal/esp32/include/hal/cpu_ll.h: No such file or directory.
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)
Info : [esp32.cpu0] requesting target halt and executing a soft reset
JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
[esp32.cpu0] requesting target halt and executing a soft reset
Info : [esp32.cpu0] Debug controller was reset.
Info : [esp32.cpu0] Core was reset.Target is already running an algorithm
Failed to start algorithm (-4)!
PROF: Flash verified in 98.262 ms
**** Verification failure! ****
target_hash 8cef9e…000
file_hash: f94c5d…a17f0
** Verify Failed **
.pioinit:14: Error in sourced command file:
Protocol error with Rcmd