cancel
Showing results for 
Search instead for 
Did you mean: 

Issue on Semihosting on CUBE IDE

JSILV.2
Senior

Salutations for all.

I programmed my CUBE IDE on Debug Mode by the recipe-> https://community.st.com/s/article/how-to-use-semihosting-with-stm32cubeide-and-stm32. It Works.

But when I STOP the running program on CUBE IDE the TARGET STOP the program either. And if I shut off the CUBE IDE, the TARGET seems as not have the Embedded program on it. If I run the TARGET powered alone, it seems like not have any Embedded program.

If I use one program copy but without the semihosting features, using the ST-Link GDB Server, the target works alone even disconnected from CUBE IDE.

Question: What should I do in order to have the Embedded Program into TARGET even Flashing on CUBE IDE by the ST-LINK Open OCD? Is it possible?

The Semihosting Feature is very useful for development.

Regards.

3 REPLIES 3
Pavel A.
Evangelist III

A program built with semihosting depends on the debugger and is not expected to run standalone.

(of course, a program can detect that debugger isn't connected, and avoid calling semihosted functions).

Dear Pavel.

I am referring that the functions that should runs in the target is OUTSIDE the semihosting ones. For example, I made a simple Blinking LED into the debuggered program with the semihosting and even this LED blinking does not runs. But a clean program (without Semihosting) works as expected even when the Target are standalone.

Comments are welcome.

Regards

So if you want to run standalone, just do not build with semihosting ?

Do you call initialize_monior_handles?