2022-11-02 09:47 AM
I am trying to debug a program in STM32CubeIDE on a Renode emulator, with a running gdbserver, started by Renode.
So in Debug Configurations dialog, Debugger tab, there is a radiobutton Connect to remote GDB server, but when clicking Debug, it complains about no ST-link being found.
Is it possible somehow to set things up such that I'm debugging only with GDB, without requiring a hardware debugger?
2022-11-02 10:59 AM
I mean this works only with
2022-11-03 01:40 AM
Hello @Community member
First let me thank you for posting.
Unfortunately, this is emulator is not officially supported by ST.
But if you are able to make it work it is going to be interesting to share the details with the community.
Thx
Semer.
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2022-11-03 06:52 AM
I'm not sure I can, out of that batch, make a running Renode instance start a gdb server.
Perhaps one can start a new renode instance with all the stuff needed, like loading a platform model, AND starting gdbserver... I'll look into that.
Is the ST-LINK_gdbserver _the_ thing that requires the HW debugger? Because, I set in the debug config to connect to a "remote server", which souns to me like it would not do anything with the ST-LINK_gdbserver.
2022-11-03 07:09 AM
This i use with stlink remotely. But i mean isnt for renode.
Maybe this
2022-11-03 07:09 AM
Hello,
depending on how things go with what "MM..1" showed & I found out, well, if it's innate in CubeIDE to want the ST-link (or Segger) present, I have no chance of making that work, right?
Btw,
let me state that it might be in ST-Micro's interest to allow easy interoperability between their default IDE and Renode, for at least two reasons:
2022-11-03 03:36 PM
Ah, damn. Forgot about those other profile types.
I got farther with that, though I'm still doing something wrong w.r.t. starting the emulation at the right moment in all of this, or the .elf wasn't really loaded (Renode complained about PC/SP being 0), need to look into that more.
2022-11-03 04:59 PM
CubeIDE debugger has also OpenOCD option. It is opensource, you can hack it.
2024-03-07 12:21 AM - edited 2024-03-07 12:24 AM
With the hints provided by other users here in this thread, I got remote debugging of an application running on an emulated STM32 MCU in renode working:
Start the GDB server in the machine to listen on port 3333 (or any other unused port): (nucleo_l433rc_p) machine StartGdbServer 3333
In CubeIDE (v1.13.2) add a GDB Hardware Debug configuration like this: