Skip to main content
Associate
May 16, 2024
Solved

NUCLEO-WBA55CG JTAG/SWD not able to connect via JLink

  • May 16, 2024
  • 1 reply
  • 2568 views

I am attempting to connect to the STM32WBA55CG using a JLink Compact Plus following the following instructions from SEGGER: https://wiki.segger.com/ST_NUCLEO-WBA55CG.

This connection fails as the DAP is not responding. The output from JLink is attached below:

 

 

SEGGER J-Link Commander V7.96g (Compiled May 8 2024 15:03:51)
DLL version V7.96g, compiled May 8 2024 15:03:24

Connecting to J-Link via USB...O.K.
Firmware: J-Link V12 compiled Apr 23 2024 10:41:21
Hardware version: V12.00
J-Link uptime (since boot): 0d 00h 39m 37s
S/N: 852002069
License(s): RDI, FlashBP, FlashDL, JFlash, GDB
USB speed mode: High speed (480 MBit/s)
VTref=3.303V


Type "connect" to establish a target connection, '?' for help
J-Link>connect
Please specify device / core. <Default>: STM32WBA55CG
Type '?' for selection dialog
Device>
Please specify target interface:
 J) JTAG (Default)
 S) SWD
 T) cJTAG
TIF>S
Specify target interface speed [kHz]. <Default>: 4000 kHz
Speed>
Device "STM32WBA55CG" selected.


Connecting to target via SWD
InitTarget() start
SWD selected. Executing JTAG -> SWD switching sequence.
Error: Failed to initialized DAP.
Can not attach to CPU. Trying connect under reset.
SWD selected. Executing JTAG -> SWD switching sequence.
Error: Failed to initialized DAP.
Connecting to CPU via connect under reset failed.
InitTarget() end - Took 303ms
Connect failed. Resetting via Reset pin and trying again.
InitTarget() start
SWD selected. Executing JTAG -> SWD switching sequence.
Error: Failed to initialized DAP.
Can not attach to CPU. Trying connect under reset.
SWD selected. Executing JTAG -> SWD switching sequence.
Error: Failed to initialized DAP.
Connecting to CPU via connect under reset failed.
InitTarget() end - Took 305ms
Error occurred: Could not connect to the target device.
For troubleshooting steps visit: https://wiki.segger.com/J-Link_Troubleshooting

 

 

I am able to connect to the device using the STM32CubeProgrammer with the embedded STLINK, but I prefer to use a JLink for development to keep all our debug tools identical between products.


Please advise.

Best answer by sfarnswo

After some investigation of a SWD trace from the board, it appears as though the on-board STLINK was holding the SWCLK signal high and not allowing the attached JLink probe to toggle the signal. Removing R34 from the board has resolved the issue.

1 reply

sfarnswoAuthorBest answer
Associate
May 17, 2024

After some investigation of a SWD trace from the board, it appears as though the on-board STLINK was holding the SWCLK signal high and not allowing the attached JLink probe to toggle the signal. Removing R34 from the board has resolved the issue.