We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
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
Ok, But you have the most visited ARM microcontroller related forum, and there is a chance that someone will actually help me with my problem. But thanks anyway for your answer Regards..