2020-06-12 06:44 PM
Hello all,
I'm designing a num pad using the STMF103 MCUs you can find on the Blue Pill board. However, I am having issues uploading the code to my board via SWD. I get this classic error:
Error in initializing ST-LINK device.
Reason: (4) No device found on target .
I've tried tampering with the debug settings but I guess it might just be a matter of me designing the interface wrong, which confuses me because I cross-referenced the schematic of the Blue Pill board I prototyped my project with, and they have the exact same setup with SWDIO and SWCLK going directly to the MCU. Anyways I've linked my schematic and I'd appreciate if someone more seasoned than me tells me where my hang-up is.
Thanks.
2020-06-12 07:24 PM
Usually means the chip is non-functional / non-responsive.
Check Power, Check part orientation
Check Voltage on VDDA, Check level observed on NRST
For an External ST-LINK, make sure pin 1/2 is connected to the 3V supply
2020-06-12 09:46 PM
NRST and VBAT unconnected... Seriously? And it is highly recommended to bring NRST out to debug interface to be able to use "Connect Under Reset" mode. Instead of copying cheap Chinese crap, you should copy the reference schematic from AN2586 and ST's Nucleo and other boards.
Also consider moving to more decent STM32 series.
2020-06-13 02:54 AM
Indeed it is time to stop using the "F103 blue pill" and to switch to the "F411 Black pill". Like this one:
2020-06-13 05:43 AM
Why do I need NRST and VBAT connected? The datasheet shows an active internal pullup on NRST, and states that VBAT is a backup voltage pin when VCC is not present. I don't see how that is relevant to the SWD interface not working. And yes I've looked at other schematics as well. Thanks.
2020-06-13 05:46 AM
Thanks for the recommendation, I will check it out for sure, but for now I have a couple of F103 MCUs that I would like to use and I would rather try to solve the problem instead of discarding it and switching over, unless it really is the MCUs fault (it's probably mine).
2020-06-13 07:14 AM
Thank you clive1. It was indeed the chip and not the routing. You are a hero! 8)