Skip to main content
Graduate
February 7, 2023
Question

ST-Link V2 SWD connection by using just SW_DAT, SW_CLK and GND.

  • February 7, 2023
  • 4 replies
  • 4720 views

I have a custom board powered by using USB, if I need to program a firmware by using the SWD feature in the ST-Link V2 Probe, may I connect just following 3 pins (without VDD) ?

- TMS_SWDIO (pin 7)

- TCK_SWCLK (pin 9)

- GND

Do I need also to connect VDD to the custom board even if the board is powered by USB ?

Thanks

    This topic has been closed for replies.

    4 replies

    Super User
    February 7, 2023

    Yes, these 3 wires will do. No need to connect VDD. On a real ST-LINK this is meant to be an input for detecting/measuring board voltage and/or connecting a level converter for 1.8V etc..

    hth

    KnarfB

    MaxCAuthor
    Graduate
    February 7, 2023

    Hello KnarfB,

    thank you for the feedback

    Just to put a detail: we are using a ST-LINK/V2-ISOL probe device.

    We are using that 3 pins but the probe doesn't Connect to the board, the STM32CubeProgrammed issues an Error. This why I made that question, in order to be sure we don't need other pins.

    Regards

    Max

    Super User
    February 7, 2023

    Haven't used the ISOL, but it make sense that VDD is needed to feed the board side of the isolated coupler, Hmm. Not sure, and don't have schematics, sorry.

    hth

    KnarfB

    MaxCAuthor
    Graduate
    February 7, 2023
    Hello KnarfB,
    I tested the Connection by using a standard ST-Link V2 Probe without success. The issue is the same.
    Regards
    Max
    Get Outlook for Android
    Super User
    February 7, 2023

    What chip, what software? Did it/something work ever before? Do you have a known good similar board like Nucelo or DK? Is the flash programmed?

    Graduate II
    February 7, 2023

    On the authentic ST-LINK/V2 the VDD on Pin 1 (VTarget) is used to power voltage appropriate buffers

    Connecting NRST is also recommended as it permits "Connect Under Reset" to work, allowing the ST-LINK to gain control of the MCU quickly/effectively, and in situations where user code may disrupt the mode/function of SWDIO/SWCLK.