I have no experience with ST tools, which are Windows only.
but I suggest you first figure out how to use these tools outside Eclipse, and then consider integrating them with Eclipse.
I can program the generated hex code via STM32St-Link Utility outside of eclipse.
I don't know where to look.
Is the generated hex file not working properly (but why is debugging over openocd no problem).
OK. This is probably a problem with migrating files from CubeMX into Eclipse.
I created a new project in eclipse with the blinky template and here I can programm over st-link.
Everything is ok.
So I have to check what I did wrong by integrating the setup created by cubemx.
does the application flashed with the GUI version of the tool work properly?
if so, using exactly the same hex, try to manually flash it from a terminal. play with the command line options until you succeed.
no it didn't work.
The application did't start. It was the same behavior.
I think that migrating the generated Code from CubeMX into my Eclipse project was wrong.
Thank you for your help.
if you are using semihosting to output the messages, your application runs only when connected to the debugger.
projects generated by the GNU ARM Eclipse templates have a more elaborated exception handler that fakes the debug channle when running standalone.
disable all printf() calls and the application should blink standalone. be sure you power cycle the board after programming.
I disabled all printf() calls but the application didn't blink.
To be honest I don't know exactly where to look when something went wrong.
Can you recommend some papers to read for a solid start?
ah, sorry, newlib issues some semihosting calls anyway.
create a new build configuration and remove rdimon completely.
it would be much easier to use blinky projects created by the wizard, you can select with/without semihosting at project creation, and later enable/disable with a simple symbol definition.
Out of curiosity, where is the difference?
When I create a project with Empty content I can't run it standalone.
when I do the same thing with blinky content I can run the program standalone.
I deleted the code in the blinky example and wrote this.
#define led GPIO_PIN_13
main(int argc, char* argv)
p.Mode = GPIO_MODE_OUTPUT_PP;
p.Pin = led;
p.Pull = GPIO_PULLUP;
p.Speed = GPIO_SPEED_LOW;
// Infinite loop, never return.
It is exactly the same like in the "empty" project but here it is blinking. In the "empty" project the LED turns on and stays on.
The difference is in the SysTick_Handler(void) function.
If you create an empty Project the callback is empty.
If you create an blinky Project the callback has the function HAL_IncTick(); in it.
it was the same problem like here.
Hi how do you flash a programm permanently with stlink-v2.
I made a simple Blink project and when I debug the LED turns off and on also an output at the console.
The stlink tool configuration.
the Prompt say all ok but the LED isn't blinking.
What do I miss?
Every hint to solve this is massivly appreciated.