Debugging with GDB/Eclipse?
Posted: Tue Mar 08, 2016 11:11 am
I set everything up for debugging STM32 targets with Eclipse (Onboard ST-LINK/V2 on a F4DISCOVERY, st-util GDB target, gdb for ARM, and Eclipse plugins). A simple blinking led works and lets me set breakpoints and step through functions.
Then I proceeded to configure an Eclipse project for MicroPython: I added the source tree to a Makefile project, changed the build directory to ./stmhal and declared DEBUG=1, BOARD=STM32F4DISCOVERY and V=1. It compiles successfully, launches debug, programs the chip and it seems to "hang". If I pause the execution I can see that it's stuck at Reset_Handler, more specifically at a line that says ldr sp, =_estack.
Is it possible to debug MicroPython like this? Am I missing something?
Then I proceeded to configure an Eclipse project for MicroPython: I added the source tree to a Makefile project, changed the build directory to ./stmhal and declared DEBUG=1, BOARD=STM32F4DISCOVERY and V=1. It compiles successfully, launches debug, programs the chip and it seems to "hang". If I pause the execution I can see that it's stuck at Reset_Handler, more specifically at a line that says ldr sp, =_estack.
Is it possible to debug MicroPython like this? Am I missing something?