Loading...
 
Skip to main content

System Workbench for STM32


Hi, can you try to set optimizations to "None" in compiler options ?

And see if it is better.

Rgds,
Laurent


Hello.

Thanks for the sugestion.

I already did that, but the result was the same.

In fact, I test all the optimizations to see if there was any difference ... but it always the same 😑


Maybe you can try to disable write protection by programming option bytes first (with STLink utility for example).
You can remove the 2 lines added in startup tab:
monitor halt
monitor flash protect 0 0 11 off

Then, you can reprogram your protections when it is working fine.

On the right side, we see uwTick volatile variable, is it used for the systick and the delay ?
Or should it be used ?

Rgds,
Laurent

If I remove these lines, I get all that crap like this:

Error erasing flash with vFlashErase packet, etc...

But I'll try again sooner your suggestion.

The uwTick variable is inside the Hal_GetTick() and this is where the program is retained.


I just tried to import the GPIO toggle example from F0 HAL V1.7.0 and there is no issue.
Tested on a Nucleo F031 board.
I just changed the C compiler optim to "O None" instead of -Os (size).

Can you try the example and if working, try to fetch the differences.

Rgds,
Laurent



I'm definitely not getting any breakthrough.
I created a new, simple project, to just blink an LED.
I can use ST-Link to program without problems ... but I can not debug.

Here is the project.
https://meocloud.pt/link/598784ec-fa1d-42d8-af76-7cb16e4d0636/debug.rar/


What am I doing wrong?

At work I'm using a setup very similar to this, but with an STM32F302. The debug runs smoothly


I think the problem is with the programmer.
I'm using one of these ST-Link clones.

At work I tested it and does not work either.
Can someone confirm me if you can debug with a programmer like this?

Hi,

If it is a clone without reset line :
Can you try to modify the debug configurations, in debugger tab, openocd options, add: -c "reset_config none"

And see if it is better.

Rgds,
Laurent


 
Collapse/expand modules below