The ESP32S2 and ESP32S3 Modules are being adopted many boards, all of which can now be debugged using an External Hardware debugger, directly in Visual Studio, with vMicro!
This page applies to all ESP32S2 / ESP32S3 Modules. See these pages for the Standard ESP32, and ESP32C3 via USB or ESP32C3 via JTAG.
NOTE: If you are using ESP32 Core v2.0.1 or 2.0.2 there is an issue with the GDB.exe reported here. Roll Back to v2.0.0 to ensure this is reliable, or use v2.0.3 onwards which have the issue resolved.
External Debug Interface: JTAG
To see a list of all debuggers currently supported within vMicro please click here.
NOTE: If using External JTAG debugging any SDCard functionality will need to be removed as this conflicts with the JTAG pin assignments.
All boards support the vMicro Software Debugger which only requires the Serial interface to work
External Debugger Connections
To connect your JTAG debugger to the ESP32S2 / ESP32S3 board you will need to connect the below pins:
Specific Probe Wiring Diagrams
Jlink Wiring Diagram
ESP-PROG Wiring Diagram
FT2232 Mini Module
ESP-DEVKIT Wiring Diagram
Then you will also need to connect your Debugger to the PC on one USB port, and the ESP32 on another USB Port
There is also a video guide to the software and driver setup described below
Ensure you have Visual Studio and the vMicro Extension Installed
Open your Sketch and select the Debug > Hardware, and the relevant Debugger you have available
NOTE - The vMicro > Debugger > Compiler Optimization MUST be set to "No Optimization" for this board to function with the debugger
You may need to install an additional USB Driver on Interface 0 of your debugger to allow it to function with this software - check in the debugger list here
Remember - If you have installed a new driver, you may have to do it again if you connect the debugger to a different USB port next time.....
- Ensure you have the Debug Configuration selected from the Configuration Manager Window
- If you know where you want the first breakpoint in your code, add it now
- To start the debugging process, you can either:
- "Debug > Attach to Process" button if your code has already been uploaded to the ESP32 board
- "Debug > Start Debugging" if your code has not been uploaded
Congratulations - you should have the debugger running, and further windows can be opened from the "Debug > Windows" menu once you have started debugging
There is also a video guide on this below: