- Issue when debugging STM32 board with zephyr openocd
Re: Issue when debugging STM32 board with zephyr openocd
toggle quoted messageShow quoted text
Thanks for this answer.
I did not build with specific optimization flag, I did not enable symbol generation neither.
Steps to reproduce are as follows:
$make BOARD=nucleo_f4... debug
after few steps I end up in unexpected function
Using mainline openocd, with same .elf and same sequence, gdb runs as expected.
On 17 February 2017 at 16:45, Felipe Neves <ryukokki.felipe@...>
Did you build the zephyr project with some optimization flags? such -Os?
Also, in menu config during kernel configuration phase, have you enabled the debug symbol generation?
Also, you need to tell your gdb instance to break in main, for exemple after start the openocd and gdb issue load command to halt microcontroller and flash the firmware
then before start the debug, set a break command on main function, then issue run command, It should work properly.
If you have further question I'll happy to help you :)
Join email@example.com to automatically receive all group messages.