esp-usb-bridge: Cannot make it work on OSX 10.15.7 connected to an ESP32 (EUB-46)
Board: ESP32-S2-Saola-1
Target: ESP32-DevKitC
Developing on an iMac (Retina 5K, 27-inch, 2017) running OSX 10.15.7 (Catalina)
OSX detects only one Serial USB device:

PlatformIO IDE on VSCode detects two serial ports:
- /dev/cu.SLAB_USBtoUART
- /dev/cu.usbserial-1420
The /dev/cu.SLAB_USBtoUART port can be opened and the monitor output of the esp-usb-bridge can be seen:
The /dev/cu.usbserial-1420 can not be opened by any serial terminal and no USB Mass Storage device of any kind appears on finder.
Trying to debug the target with the following platformio.ini config:
[env:esp32dev]
board = esp32dev
platform = espressif32
framework = arduino
build_flags =
-DCORE_DEBUG_LEVEL=3
-Wno-unused-variable
-Wno-unused-but-set-variable
-Wno-unused-function
-Wno-format-extra-args
monitor_speed = 115200
monitor_encoding = UTF-8
monitor_filters =
direct
esp32_exception_decoder
debug_init_break = tbreak setup
debug_tool = esp-bridge
debug_port = /dev/cu.SLAB_USBtoUART
upload_port = /dev/cu.usbserial-1420
monitor_port = /dev/cu.usbserial-1420
produces on the DEBUG CONSOLE when trying to Start Debug (skip PreDebug, already built):
Processing esp32dev (board: esp32dev; platform: espressif32; framework: arduino)
--------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32dev.html
PLATFORM: Espressif 32 (2023.2.0+sha.59388ed) > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-bridge) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 @ 2.0.7
- tool-esptoolpy @ 1.40501.0 (4.5.1)
- tool-mklittlefs @ 1.203.210628 (2.3)
- tool-mkspiffs @ 2.230.0 (2.30)
- toolchain-xtensa-esp32 @ 8.4.0+2021r2-patch5
Converting led_blink.ino
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 32 compatible libraries
Scanning dependencies...
Dependency Graph
|-- CircularBuffer @ 1.3.3
Building in debug mode
Compiling .pio/build/esp32dev/src/led_blink.ino.cpp.o
Building .pio/build/esp32dev/bootloader.bin
Generating partitions .pio/build/esp32dev/partitions.bin
esptool.py v4.6-dev
Creating esp32 image...
Merged 1 ELF section
Successfully created esp32 image.
Compiling .pio/build/esp32dev/FrameworkArduino/Esp.cpp.o
Compiling .pio/build/esp32dev/FrameworkArduino/FirmwareMSC.cpp.o
...........
...........
Compiling .pio/build/esp32dev/FrameworkArduino/wiring_shift.c.o
Archiving .pio/build/esp32dev/libFrameworkArduino.a
Indexing .pio/build/esp32dev/libFrameworkArduino.a
Linking .pio/build/esp32dev/firmware.elf
Retrieving maximum program size .pio/build/esp32dev/firmware.elf
Checking size .pio/build/esp32dev/firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [ ] 4.2% (used 13700 bytes from 327680 bytes)
Flash: [= ] 9.9% (used 129169 bytes from 1310720 bytes)
Building .pio/build/esp32dev/firmware.bin
esptool.py v4.6-dev
Creating esp32 image...
Merged 2 ELF sections
Successfully created esp32 image.
========================= [SUCCESS] Took 39.15 seconds =========================
undefinedOpen On-Chip Debugger v0.11.0-esp32-20220706 (2022-07-06-15:49)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'jtag'
Info : esp_usb_jtag: VID set to 0x303a and PID to 0x1002
Info : esp_usb_jtag: capabilities descriptor set to 0x30a
adapter speed: 40000 kHz
WARNING: boards/esp-wroom-32.cfg is deprecated, and may be removed in a future release.
Warn : Transport "jtag" was already selected
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Error: esp_usb_jtag: could not find or open device!
Reading symbols from /Users/alberto/dev/trh-esp32/.pio/build/esp32dev/firmware.elf...
PlatformIO Unified Debugger -> https://bit.ly/pio-debug
PlatformIO: debug_tool = esp-bridge
PlatformIO: Initializing remote target...
Ignoring packet error, continuing...
warning: unrecognized item "timeout" in "qSupported" response
Ignoring packet error, continuing...
.pioinit:11: Error in sourced command file:
Remote replied unexpectedly to 'vMustReplyEmpty': timeout
And no debug session is started.
One line catch my attention, but I don’t know what it means nor how to fix it.
Error: esp_usb_jtag: could not find or open device!
Deleting platformio.ini lines (leaving only he debug_tool = esp-bridge one:
debug_port = /dev/cu.SLAB_USBtoUART
upload_port = /dev/cu.usbserial-1420
monitor_port = /dev/cu.usbserial-1420
produces almost the same result:
(compile lines skipped)
Open On-Chip Debugger v0.11.0-esp32-20220706 (2022-07-06-15:49)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'jtag'
Info : esp_usb_jtag: VID set to 0x303a and PID to 0x1002
Info : esp_usb_jtag: capabilities descriptor set to 0x30a
adapter speed: 40000 kHz
WARNING: boards/esp-wroom-32.cfg is deprecated, and may be removed in a future release.
Warn : Transport "jtag" was already selected
Info : tcl server disabled
Info : telnet server disabled
Error: esp_usb_jtag: could not find or open device!
.pioinit:11: Error in sourced command file:
Remote connection closed
Can anyone throw me any hint there??
Thanks !!!
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 22
I see no obvious issue in the log. But the team for openocd is more experienced in that. Let’s wait for their response…
Yes, the following is shown in your log:
There is a lot of communication through JTAG. You won’t get the above by luck. The JTAG wiring should be OK.