2014-01-21 01:36 AM
I'm having some troubles connecting an ST-Link to a STM32f0 microcontroller. Did is what i did/tried:
When i tried to connect with ST-Link Utility I get error ''Can not connect to target!''. I used the same ST-Link to connect to a STM32F051 Discovery Board (disabled on board st-link) and succesfully connected, so driver and connections seem ok.
Next thing i tried was resetting the MCU with BOOT0 pulled to +3,6V. I send 0x7F to USART1 with HyperTerminal and received 0x79 back. So the bootloader (and thus internal clock?) seem to be working.Does anyone have any idea? Is a different approach required for first time programming?Thanks for the help!Ronald2014-01-21 05:19 AM
I have had some success using a 100ohm resistor between SWDIO and GND. It's not a very stable solution though (only works in particular configuration with a lot of jumper wires). Anyone had such an issue before?
2014-01-21 05:31 AM
Well that certainly doesn't sound right?
You should probably consider connecting NRST to the 20-pin JTAG header. BOOT0 should probably use a 10K connected to either GND or 3.6V to select mode. Though in a blank device you should be able to program/connect in either. You can send hex characters in HyperTerminal? Try RealTerm 9600 8E1, the response to 0x7F should be 0x79, not 0x7F2014-01-21 08:01 AM
It indeed doesn't sound right, but sometimes it does work strangely. I connected NRST to the 20 pin header and to +3.6V using 10k pullup. BOOT0 is pulled low with 10k pulldown. It makes no difference.
I did send the ASCI character corresponding to 0x7F and got a 0x79 response (sorry for the typo in my first post, corrected it now). So do the SWDIO and SWDCLK need any pulldown or -up connections other than the 100R is used?I found another thread with the same issue. It is unsolved however:2014-01-21 08:53 AM
I have the biggest problem with the 100R, as this is likely masking other problems.
What version of firmware do you have on the ST-Link? Please draw a schematic of your current connections.2014-02-06 01:29 AM
Hi,
I have the same problem connecting to a STM32F I tried to use the Debugger on an STM32F0DISCOVERY-Board. Therefore I disconnected the Jumpers on CN2 and the Soldering bridges on SB19 and SB When I tried to connect to the Controller via STM32 ST-LINK Utility, it can't connect. I have tried holding BOOT0 HI or LO with no success. Leaving NRST open had although no effect. Trying to erase the chip with CoIDE gave an ''Check Connection'' Error. You find my basic schematic attached. I hope anyone has an Idea! EDIT: My Current-Consumption is about 2.5mA so I guess the Chip is operating Thanks! Johannes ________________ Attachments : STM32F051_Programming.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I1Jf&d=%2Fa%2F0X0000000blC%2FFqp.ixilwjPgakYtIShNuvrxijcOpvoGwfS4l5Tmmko&asPdf=false2016-12-18 03:01 AM
First the device should not be protected [jtag disabled]. Second, the swd (swdio, sck) signal quality over wires should be good on oscilloscope and finally add decoupling capacitors to the dip adaptor. St link as i recall monitors vdd line to check if target mcu is present and powered. Good luck!