https://github.com/wokwi/esp32-arduino-debug
Docker container for source-level debugging of ESP32 Arduino applications (using xtensa-GDB)
https://github.com/wokwi/esp32-arduino-debug
Last synced: 4 months ago
JSON representation
Docker container for source-level debugging of ESP32 Arduino applications (using xtensa-GDB)
- Host: GitHub
- URL: https://github.com/wokwi/esp32-arduino-debug
- Owner: wokwi
- Created: 2022-01-18T18:36:41.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-10-01T10:50:41.000Z (9 months ago)
- Last Synced: 2025-01-16T14:51:30.704Z (5 months ago)
- Language: Dockerfile
- Size: 8.79 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ESP32 Arduino Core Debug Environment
Docker container with ESP IDF + ESP32 Arduino Core with full debugging symbols
## Building the container
```
docker build -t wokwi/esp32-arduino-debug .
```## Using the container
First, you need to compile the Arduino project using the copy of `arduino-cli` installed in the container.
Assuming that your Sketch directory is /home/uri/projects/blink, run the following command:
```
docker run -v /home/uri/projects:/workspace wokwi/esp32-arduino-debug arduino-cli compile -e -b esp32:esp32:esp32doit-devkit-v1 /workspace/blink
```You can replace `esp32:esp32:esp32doit-devkit-v1` with the FQBN (fully qualified board name) you want to compile your project for.
The compiled binary file (and the ELF file with the symbols) will reside in /home/uri/projects/blink/build/esp32.esp32.esp32doit-devkit-v1.
Then, run GDB as follows:
```
docker run -it -v /home/uri/projects:/workspace wokwi/esp32-arduino-debug xtensa-esp32-elf-gdb -ex "file /workspace/blink/esp32.esp32.esp32doit-devkit-v1/blink.ino.elf"
```You can use a different GDB version (e.g. `xtensa-esp32s2-elf-gdb` or `xtensa-esp32s3-elf-gdb`), depending on the MCU you are working with.