This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Is the st-linkv2 SWJ capable?

Hello, i'm working with a custom board with a STM32L151RD and a st-linkv2. For debugging purpose i only have access to SWD pins:
SWCLK (PA14)
SWDIO (PA13)
TRACESWO (PB3)
NRST

But the microcontroller is JTAG wired by default, so my question is:
When i select the SWD protocol on the ST-linkv2 it automatically send the special sequence on the SWDIOTMS pin is used to switch between JTAG-DP and SW-DP?

Explanation from the reference manual:

29.3.1 Mechanism to select the JTAG-DP or the SW-DP
By default, the JTAG-Debug Port is active.
If the debugger host wants to switch to the SW-DP, it must provide a dedicated JTAG
sequence on TMS/TCK (respectively mapped to SWDIO and SWCLK) which disables the
JTAG-DP and enables the SW-DP. This way it is possible to activate the SWDP using only
the SWCLK and SWDIO pins.
This sequence is:
1. Send more than 50 TCK cycles with TMS (SWDIO) =1
2. Send the 16-bit sequence on TMS (SWDIO) = 0111100111100111 (MSB transmitted
first)
3. Send more than 50 TCK cycles with TMS (SWDIO) =1

Regards