In this Heap tracing guide, we will follow the sysview_tracing_heap_log example project which can be obtained from Github, this project need some configuration from menuconfig and also some jumpers to be set in your devkit.
- ESP-IDF
>=v4.2
and equivalent OpenOCD and Xtensa Tools - IDF VSCode extension version
>=0.3.0
- ESP Wrover Kit (optional)
- Inside VSCode at left hand side, you will see Espressif Logo, click on that
- Click on the
Start heap tracing
button - It will prompt you to launch
OpenOCD
(if not already running), you need to allow it to launch OpenOCD - Once
OpenOCD
is launched, it will connect with OpenOCD usingTCL
atlocalhost:6666
- If everything is a success till now, it will send instruction to capture heap trace from your chip
Once heap tracing is done Stop heap tracing
button will change the state to Start Heap Tracing
again and you will be notified, now here are steps for how to parse your result and view the same.
- Inside
App Trace Archives
Section, your result will be present as archive - Click on any of the archived results.
- This will open a webview with the results, you need to click on the calculate result button
- It will parse
.svdat
file and prepare a JSON format, which will display you the graphs and tables with the info.
If you find any of the data/graph/tables represent wrong data points please help us correct/improve the same by reporting bugs here