I have a STM32F103C8T6 (aka blue pill) and worked with it.
Sometimes - due a reason I don't understand - after debugging it (using Eclipse), the connection is lost and I cannot start a new debug session.
The only thing to do is the following time consuming procedure:
- Close Eclipse
- Start ST-Link Utility
- In the menu ST-LINK/Firmware Update, selecting button Device Connect (to see if the ST Link stick can connect).
- In case of an error, reinsert it (Windows shows Unknown USB Device) and redo the previous step
- In case of no error, it shows the version: V2.J27.S6 STM32+STM8 Debugger
- Than on the STM32 I have to press and hold the reset button
- Select the menu option Target/Erase Chip
- Release the button (in time, otherwise repeating the previous step)
- Than the chip is erased.
- Than start Eclipse again and I can continue
This is already a very tedious operation... is there a better solution? Or by what reason the debugging session causes the STM32 to lose the ability to start a new debugging session?
And even than in some cases I get the following error when trying to debug:
23:23:02 : Can not connect to target!
If you're trying to connect to an STM32W1xx device, please select Normal or HotPlug mode from Target->Settings menu.
If you're trying to connect to a low frequency application , please select a lower SWD Frequency mode from Target->Settings menu.
23:23:03 : No target connected
The Eclipse project configuration file fragment:
# use software system reset
reset_config none
set CONNECT_UNDER_RESET 0