2025-06-30 9:49 AM - last edited on 2025-07-03 12:50 AM by Andrew Neil
Hello!
I just received some custom PCBs with the STM32H747BIT6 MCU, but I’m having trouble connecting to it. I’m using a J-Link V12 and initially tried to establish the connection with jlinkexe. It correctly detects the voltage, but when attempting to connect, I always get the following error:
jlinkexe
SEGGER J-Link Commander V8.46 (Compiled Jun 26 2025 07:49:05)
DLL version V8.46, compiled Jun 26 2025 07:48:31
Connecting to J-Link via USB...O.K.
Firmware: J-Link V12 compiled Apr 1 2025 10:02:39
Hardware version: V12.00
J-Link uptime (since boot): 0d 00h 00m 44s
S/N: xxxxxxxxx
License(s): RDI, FlashBP, FlashDL, JFlash, GDB
USB speed mode: High speed (480 MBit/s)
VTref=3.335V
Type "connect" to establish a target connection, '?' for help
J-Link>connect
Please specify device / core. <Default>: STM32H747BG_M7
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 "STM32H747BG_M7" selected.
Connecting to target via SWD
ConfigTargetSettings() start
ConfigTargetSettings() end - Took 190us
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 309ms
Connect failed. Resetting via Reset pin and trying again.
ConfigTargetSettings() start
ConfigTargetSettings() end - Took 34us
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 311ms
Error occurred: Could not connect to the target device.
For troubleshooting steps visit: https://kb.segger.com/J-Link_Troubleshooting
I also tried using STM32CubeProgrammer, but I couldn’t connect to the MCU either. However, this tool displays the following errors:
18:39:25 : STM32CubeProgrammer API v2.19.0 | MacOS-64Bits
18:40:14 : UR connection mode is defined with the HWrst reset mode
18:40:40 : xxxxxxxxx
18:40:40 : Error: J-Link - Connection to target failed
18:40:40 : Error: Unable to get Access port number
18:40:40 : Voltage : 3.34V
18:40:40 : Error: Database cannot be found. DatabasePath = /Applications/STMicroelectronics/STM32Cube/STM32CubeProgrammer/STM32CubeProgrammer.app/Contents/MacOs/bin/../Data_Base/STM32_Prog_DB_0xFFF.xml
18:40:41 : Error: flash loader cannot be loaded. FlashLoaderPath = /Applications/STMicroelectronics/STM32Cube/STM32CubeProgrammer/STM32CubeProgrammer.app/Contents/MacOs/bin/FlashLoader/0xFFF.stldr
18:40:41 : Error: Database cannot be found. DatabasePath = /Applications/STMicroelectronics/STM32Cube/STM32CubeProgrammer/STM32CubeProgrammer.app/Contents/MacOs/bin/../Data_Base/STM32_Prog_DB_0xFFF.xml
Do you know what might be causing this issue?
Find attached the schematics:
2025-06-30 10:21 AM
Please show all the MCU pin's (for example were are SWDIO / SWDCLK or the SMPS pins connected?).
The Power connecton is not what I'm expecting from a device with SMPS Power supply on chip. Please refer to the Reference Manual (RM0399) Capter 7.4 for Power connection possibilities.
p.s.: R17..R21 are 0R only two of them can be mounted, can you please tell us the mounted Resistors.
2025-06-30 10:37 AM - edited 2025-06-30 10:37 AM
@JonConesa wrote:using a J-Link V12 and initially tried to establish the connection with jlinkexe.
For specific help with Segger tools & software, ask Segger:
https://www.segger.com/support/technical-support/
They have this on resolving connection issues:
https://kb.segger.com/J-Link_cannot_connect_to_the_CPU
And from ST:
https://community.st.com/t5/stm32-mcus/how-to-solve-debugger-connection-issues/ta-p/49693
As @MHoll.2 suggests, it does also depend upon working hardware; see also Application note AN4938,
Getting started with STM32H74xI/G and STM32H75xI/G MCU hardware development
2025-07-01 12:02 AM
Hi,
Apologies for the earlier incomplete information. Please find the updated connections to the MCU attached for your reference.
Regarding R17, R18, R19, and R21, only R18 and R19 are currently mounted.
2025-07-01 12:34 AM
OK, I have the following notes to Your schematic:
1) VDDLDO_1.. VDDLDO_3 should be connected together and supplied with a Voltage between 3.6V and 1.62V.
2) All three VCAP pins should be connected together (2 x 2.2uF is OK).
If the schematic is complete the main problem is the missing power on VDDLDO.
2025-07-03 12:48 AM
Hi @MHoll.2,
That seems to work! However, when I try to flash the MCU, specifically the M7 core, I’m no longer able to flash or connect to the device.
Do you know if there’s anything specific I need to do in order to perform the flashing correctly?
I’ve attached the flash configuration I’m currently using. For now, I’m only flashing the M7 core and ignoring the M4.
device STM32H747BG_M7
SelectInterface SWD
Speed 4000
erase
; Load application
loadfile Build/M7/STM32H747BIT6_CM7.hex
r
g
q
2025-07-03 6:38 AM
Unfortunatly I don't use / know the J-LINK Pod.
If You can connect to the Chip (read the CHIP ID etc) but can not write the flash, then this could be a power supply problem (the Chip will consume more power when programming the Flash).