FreeRTOS Thread Debugging with SW4STM32
Hi,
I’m a happy user of SW4STM32 and STM32CubeMX under linux (ubuntu 64).
Nevertheless, I recently tried to use thread debugging of a FreeRTOS based application within SW4STM32 for a CubeMX generated project. Here is a blog post showing how to configure OpenOCD in order to show the FreeRTOS tasks (Simply tell openOCD that you are using a RTOS by adding “-rtos FreeRTOS” to the “$_TARGETNAME” configure line in the target scripts file):
https://mcuoneclipse.com/2016/04/09/freertos-thread-debugging-with-eclipse-and-openocd
As SW4STM32 debug is based on OpenOCD and GDB, everything is going fine: all freeRTOS tasks appears in the debug view when I stop the execution of the program!
Nevertheless, this only work when the program execution is stopped in the first created task, and it works only once. Then, the debug session closed (GDB and OpenOCD “terminated”) with this error message in openOCD console view:
Error: Error reading first thread item location in FreeRTOS thread list
Any idea of what is going wrong ?
This could be a really great feature if it works out of the box !
Thanks in advance and for all the work made on SW4STM32.
Best regards,
BDufay