Created
June 11, 2018 18:02
-
-
Save sovcik/f489c60f36840e5f1ca52a013c96121b to your computer and use it in GitHub Desktop.
Parse ESP stack trace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @echo off | |
| rem set following to point to addr2line executable | |
| set addr2linecmd=xtensa-lx106-elf-addr2line.exe | |
| rem set following to point to executable you would like to debug | |
| rem executable has to be compiled with -ggdb option in order to include debug info | |
| set exename=c:\.......\.pioenvs\nodemcu\firmware.elf | |
| rem set following to point to filecontaining stacktrace - only addresses | |
| set stacktracefile=stack.txt | |
| for /F "tokens=2,3,4,5" %%i in (%stacktracefile%) do ( | |
| for /F "eol=? tokens=* USEBACKQ" %%f in (`%addr2linecmd% -p --exe=%exename% %%i %%j %%k %%l`) do @echo %%f | |
| ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment