Arduino IDE 2.3.9 Debugging [sharing]
-
Just to share what I have done to get the debugging start working.
Setup
- Windows 11
- Adruino IDE Version 2.3.9
- M5Stack StickS3
Symptom
- when clicking the Start Debugging button, encounter error messages as follows:
Waiting for gdb server to start...[2026-06-07T13:03:42.505Z] SERVER CONSOLE DEBUG: onBackendConnect: gdb-server session connected. You can switch to "DEBUG CONSOLE" to see GDB interactions. "C:\\Users\\dandu\\AppData\\Local\\Arduino15\\packages\\m5stack\\tools\\openocd-esp32\\v0.12.0-esp32-20251215/bin/openocd" -c "gdb_port 50000" -c "tcl_port 50001" -c "telnet_port 50002" -s "c:\\Users\\dandu\\Documents\\M5Stack\\StickS3\\Pong" -f "C:/Program Files/Arduino IDE/resources/app/plugins/cortex-debug/extension/support/openocd-helpers.tcl" -f board/esp32s3-builtin.cfg Open On-Chip Debugger v0.12.0-esp32-20251215 (2025-12-15-18:17) Licensed under GNU GPL v2 For bug reports, read http://openocd.org/doc/doxygen/bugs.html DEPRECATED! use 'gdb port', not 'gdb_port' DEPRECATED! use 'tcl port' not 'tcl_port' DEPRECATED! use 'telnet port', not 'telnet_port' CDRTOSConfigure Info : esp_usb_jtag: VID set to 0x303a and PID to 0x1001 Info : esp_usb_jtag: capabilities descriptor set to 0x2000 Info : Listening on port 50001 for tcl connections Info : Listening on port 50002 for telnet connections Error: libusb_open() failed with LIBUSB_ERROR_NOT_FOUND Error: esp_usb_jtag: could not find or open device!Diagnosis
- It is the driver for USB JTAG/serial debug unit (Interface 2) that causes issue.
Reasons
- Using Zadig, found that the current driver is WINUSB (v10.0.26100.1150)
- The v10.0.x WinUSB driver is Microsoft's newer inbox driver that Windows sometimes auto-installs. It has been observed to be incompatible with OpenOCD's libusb on ESP32-S3 JTAG, causing exactly the LIBUSB_ERROR_NOT_FOUND error you saw. Visual Micro's own documentation explicitly warns about this: visualmicro
Fix
- install Zadig
- replace/downgrade driver for USB JTAG/serial debug unit (Interface 2) to WinUSB (v6.1.7600.16385). NOTE: select "Install Driver" by clicking the dropbox on the button. The default option in the dropbox should be "Install WCID Driver" which will not help, it will still be the incompatible v10.0.x driver after Zadig installed the driver.
Note
- on the USB JTAG/serial debug unit (Interface 0), the driver usbser (v10.0.26100.8328) is fine. There are Internet post that suggest replacing it with USB Serial (CDC). No need to make "Start Debugging" working.
References
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login