cancel
Showing results for 
Search instead for 
Did you mean: 

STM32 Flash software

MasonNam
Associate

Hi Mr/Mrs,

I have one problem about flash software for Stm32F103C8T6. When I compile and flash software for the first time, everything is OK. But, I have changed code and compile successfully then software can not flash to board. I see that there is one different point about SWDIO. At second time, it is “No target device”. I have tried switch Boot 0 into 1 and software flash success. I also tried with new target board and issue is similar. Here, I have used ST-Link V2 mini for Stm8, Stm32 and target board Stm32f103c8t6 via Keil C IDE.

Could you please help me check and give for me some tips to resolve this problem? Thanks so much!

3 REPLIES 3
Imen.D
ST Employee

Hello @MasonNam ,

Upgrade the ST-Link firmware and use the latest release of STM32CubeProgrammer.

Make sure that your debug pins (SWDIO, SWCLK) are free, reserved for debug.

Please follow the checklist in this article How to solve connection errors when connecting and programming the STM32 target board, this may help you to solve the issue.

 

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
Peter BENSCH
ST Employee

@MasonNam 

You won't be able to update the ST-LINK/V2 Mini with the STM32CubeProgrammer because the ST-LINK/V2 Mini in the coloured tin can is an illegal clone. You probably also have a Blue Pill in front of you, right? You can also assume that this is built using a faked MCU.

Regards
/Peter

In order 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.

Pay specific attention to what you're doing to PA13/PA14 pins, if you're recommitting those, or choosing an option to disable JTAG/SWD operation.

Adding a brief spin delay in Reset_Handler might help provide time for the debugger to wrestle control, also connect NRST to permit "Connect Under Reset" to be a viable method.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..