2013-01-18 05:49 PM
I have recently assembled the first prototype of a new board I'm working on for a project and have so far been unsuccessful in connecting to it with the STM32 ST-LINK Utility. The chip I'm using is the STM32F407VET (100-pin package) silicon revision Z. I am using the ST-Link/V2 programmer.
Here's what I've tried:1) Programming over SWD with NRST, SWIO, SWCLK, 3V3 (from target), GND connected as described in the ST-Link manual gives ''No target connected.'' Checked that the preferences were set to use SWD and not JTAG and tried both combinations of ''Connect under Reset'' (not sure what this does - but got same result either way).2) Programming over JTAG got the same error (got ''Unkown target connected'' a few times as well).3) With BOOT0 pin connected (directly) to 3.3V, got a 0x79 response from sending 0x7f over USART3 (via Sparkfun 3.3V FTDI board). No response with BOOT0 connected to GND through a 10k pull-down.4) Checked with an oscilloscope that SWDIO and SWCK were active when trying to connect.Here's some info about my board, including some mistakes I've noticed since making this first version.1) VBAT was originally tied to ground. Not sure if this did anything but de-soldered pin and connected to 3.3V with no effect. It's currently not connected to anything.2) BOOT1 is connected via 10k resistor to GND.3) PDR_ON connected directly to GND.4) With the programming not connected, I get 1.259V on VCAP (pin 49) and 0V on VCAP2 (pin 73). Both 2.2uF capacitors are a bit further away from the chip than they probably should be with VCAP2 being .5 inches between pin and capacitor.5) I'm 99.99% sure the chip is in the correct orientation, with the dot in the pin1 corner (bottom left corner when oriented so the text is readable).Looking at the power inputs, I've noticed they are very noisy (probably thanks to the switching regulator I'm using for 5V - 3.3V regulator in series after it). I could definitely see how this could be a problem and am trying to fix it (will post results shortly), but it's curious that my USART3 experiment still worked. Anything else I could try or anything I'm doing wrong? Thanks!EDIT: I tried again with a clean external power supply powering the 3.3V lines on the board with no success.2013-01-18 06:47 PM
Well you seem to have been quite thorough.
VCAP2 being 0V is a bit odd, I'd expect ~1.2V, perhaps compare/contrast with an STM32F4-Discovery board. Make sure VDDA is connected, check that NRST isn't clamped to ground via the internal POR, though suspect it's not as the USART3 test works.2013-01-18 08:19 PM
2013-01-18 08:46 PM
So VDDA actually wasn't connected. Must have been an error in PCB manufacturing as there was just a small trace connecting it to pin 21 (VREF+) which was then connected to 3.3V. I've fixed this with a solder bridge and still no luck. Everything is the same as I originally reported, including VCAP2. Any reason why VCAP2 would be 0V?
The reset pin is 0V except for a 400ms 3.3V pulse when I attempt to connect (tested with scope).I have a discovery board on the way, but probably won't get here for a week or so.2013-01-19 04:34 AM
VCAP_2 (pin 73) is right beside VSS (pin 74). Are you sure there is not a solder bridge?
After you fix VCAP_2, make sure all VDDA, VREF and VSSA are properly connected.2013-01-19 01:56 PM
Not sure exactly what I did, but I'm now getting 1.25V on VCAP2, but can no longer communicate with it over USART3, and am still having the same error with the ST-Link Utility. I've checked all the other pins you've mentioned and they seem fine. Perhaps I've damaged the chip through all my messing with it?
2013-01-19 03:29 PM
I don't have my notes with me but later I can check what I did with BOOT0, BOOT1 etc.
Of course, make sure RESET and VBAT are not grounded.2013-01-19 05:32 PM
The VBAT pin actually got broken off so is just floating. This happened before the USART test. Would this cause issues? I'll be putting together another one of this revision of the board in a couple of days. The NRST pin is active low correct? I have a button between NRST and GND with a 10k pull-up and high-side capacitor on the NRST line.
Thanks2013-01-19 07:07 PM
NRST being stuck low is indicative that the device is being held in reset, most likely because the internal supplies are below threshold, or the internal clocks aren't running.