cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F103C8T6 - Cant be found?

VK4KYT
Associate

Hi all,

I'm very new to the STM32 world but still trying to figure out how things work.

I have installed the STM32CubIDE software without issue, but my problems start when I try to develop and upload a blink application.

No matter what I do, the ST-Link server starts but is unable to find the connected "Blue Pill" (BP) board.  The LED power lights on both the ST-Link and the BP board are on, but that's as far as it goes.

The BP board that I have has three small push buttons, the usual power rest button and two others labeled HRST and BOOT0.  It does not have the big jumper header that I see in most on-line images.   
I'm not sure (and cannot find) information on how these buttons should be treated and what their purpose is.

Can anyone suggest how I should go about troubleshooting further?

Many thanks

Luke.  VK4KYT

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Press the BOOT0 all the time, then connect the 3.3V power on, then use ST-LINK scan.  if this doesn't work, this board should be damaged.

Peter

View solution in original post

8 REPLIES 8

It's not an ST-LINK, and as such won't be found as one.

If you have an external ST-LINK you can use the SWDIO/SWCLK pins to wire it up.

The BOOT0 button might permit you to bring the board up as a "STM32 BOOT" device, a USB DFU device, and that could be used with STM32 Cube Programmer in USB mode, and uploaded via DFU. The STM32F1 is like 15 years old, I don't recollect which models support DFU mode, they all support UART mode.

https://www.youtube.com/watch?v=L670v-Oghs4

If the part doesn't support DFU mode, you can use STM32 Cube Programmer and UART1 via PA9/PA10, and program out of the ROM based System Loader via a COM port

Many of the BluePills have fake chips. The gum-stick ST-LINKs are also fake/counterfeit.

For a simple experience, perhaps look at a NUCLEO board which integrates an ST-LINK via a second MCU

 

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

Thank you for your reply.

The more I delve into this, the more I'm starting to think that I have a faulty Blue Pill board!

I've been using the Cube IDE which basically just told me that no target device was found.

A YouTube Video suggested using the Cube Programmer which gives a bit more feedback as follows.

 

07:03:38 : UR connection mode is defined with the HWrst reset mode
07:03:38 : ST-LINK SN : 142816089218303030303032
07:03:38 : ST-LINK FW : V2J45S7
07:03:38 : Board : --
07:03:38 : Voltage : 3.12V
07:03:38 : Error: Unable to get core ID
07:03:38 : Error: No STM32 target found! If your product embeds Debug Authentication, please perform a discovery using Debug Authentication

 

So it appears that my ST-LINK is good, but that no STM32 target could be found connected to it.  I have tried reversing the data lines but without any gain. I was pretty confident that I had them correct in the first instance.

I will order a new Blue Pill or two and try again.

Thanks for your input.

Luke

jalks
Associate

Hi Luke, sounds like you're on the right track! For the Blue Pill, you’ll need to ensure that the BOOT0 pin is set correctly. To upload code via ST-Link, make sure BOOT0 is low (0V) for normal boot mode. If it's high, the board tries to boot from other sources. Try pressing the 'Reset' button before programming to ensure the board is in the correct state. Also, check that the ST-Link drivers are properly installed. Hope that helps!

Thanks for the reply ...

I have tried everything you suggested ... still no success. :(

The output from STM32CubeIDE says:

STMicroelectronics ST-LINK GDB server. Version 7.9.0

Copyright (c) 2024, STMicroelectronics. All rights reserved.

 

Starting server with the following options:

Persistent Mode : Disabled

Logging Level : 1

Listen Port Number : 61234

Status Refresh Delay : 15s

Verbose Mode : Disabled

SWD Debug : Enabled

InitWhile : Enabled

 

Target no device found

 

 

 

Error in initializing ST-LINK device.

Reason: No device found on target.

 

I'd love to be able to change some of the server options like "verbose mode" and "logging level" but I've not been able to discover how to do that.

 

From the above, it seems like ST-LINK is discovered, and working fine, but the Blue Pill that is connected to it cant be found.

 

Any other ideas? I'm totally out of ideas at this point.

 

Luke

 

HWrst mode won't work unless you're connecting NRST. Assuming you just do 3V3,GND,SWDIO,SWCLK

I might check an old version of ST-LINK Utilities, it might be less fussy about counterfeit Chip ID's

A picture of the chip/setup might be instructive.

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

1000014121.jpg

1000014120.jpg

1000014119.jpg

 here are the pics of the setup ... the st-link looks authentic, but now, I'm so sure about the chip itself.  Although I've been led to believe that the WeAct Studio product is good.

Press the BOOT0 all the time, then connect the 3.3V power on, then use ST-LINK scan.  if this doesn't work, this board should be damaged.

Peter

Hi there,

Thanks for your input.

I didn't know about the St-Link Utility ... found it and used it in conjunction with you instructions.

I was still unable to detect the STM32F103 but I was able to detect and read the STM32F411 Black Pill board that I bought at the same time.

I suspect you may well be right about the F103 board ... it may be damaged or broken.

I'll continue my learning with the Black Pill for now and see how it goes.

Cheers

Luke