Electronics > Microcontrollers

How many pins are required to program an STM32 chip?

(1/4) > >>

Do I just need 3 pins? SWDIO, SWCLK and GND?


--- Quote from: AQUAMAN on May 23, 2021, 07:54:35 pm ---Do I just need 3 pins? SWDIO, SWCLK and GND?

--- End quote ---

yes, but it is convenient to have reset as well

Reset pin required too, if you use the SWDIO/SWCK pins as GPIO, or if wakeup from low power mode needed. But it is not mandatory.

And your target device should have Vcc, otherwise you should connect that too.

Seconding what has been said above: answer is: it depends on what you want to do, the context, etc.

As said above, a nRST pin from the SWD probe is a good addition. Without it, you may be unable to access your MCU through SWD if it's in a low-power state, so if you plan on using low-power states, it could be extremely annoying if you don't have this pin. Actually been there before.

As to Vcc/Vdd, it all depends on your target voltage and on the SWD probe you're going to use. If the latter has an embedded level shifter, it's a good idea (or even sometimes mandatory, depending on the probe) to connect the target's Vdd to the corresponding pin of the probe.

So you said too little. What's your target Vdd, what's your MCU and what's your SWD probe? Is this for a particular project or do you want a more generic solution?


[0] Message Index

[#] Next page

There was an error while thanking
Go to full version