Skip to main content
Associate
May 13, 2026
Question

Selecting stlink for debug session

  • May 13, 2026
  • 1 reply
  • 113 views

I have a complex product where I am running multiple micros with firmware that needs to be debugged. I have 2 stlinks plugged in. But I am stumped at trying to get the VSCode STM32 extensions to target a specific stlink.

 

My launch.json is using stlinkgdbtarget as the debug type.

"serverArgs" is where I have tried ["-i","<stlinkserial>"] but the debug session launches and in the debug output it prints multiple stlink devices detected, so the session fails.

 

Is there a way to debug if the serverArgs are even being used?

Is there a different way to select a stlink?

1 reply

Cartu38 OpenDev
Graduate II
May 14, 2026

@mroszkobt 

Should do the job !

Cartu38OpenDev_0-1778736154388.png