cancel
Showing results for 
Search instead for 
Did you mean: 

"No STM32 target found!" with ST Link by using STM32CubeProgrammer with a STM32H750VB. (SWD was not turned on in CubeMX). Is there any way to fix this?

MMax.3
Associate II

 16:32:00 : ST-LINK FW : V2J39S7

 16:32:00 : Board      : --

 16:32:00 : Voltage    : 3.22V

 16:32:00 : Error: No STM32 target found!

7 REPLIES 7

Connect under reset

Pull BOOT0 High, so your code doesn't start

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
MM..1
Chief II

What you mean as SWD was not... and are you sure your connection between MCU and STLINK is ok_?

TDK
Guru

SWD doesn't need to be selected in CubeMX in order for it to work. SWD pins are in SWD mode by default. Changing them to another function will stop SWD from working.

If you feel a post has answered your question, please click "Accept as Solution".
ssipa.1
Associate II

Hello mmax

In order to fix STM32CubeProgrammer No STM32 Target Found

many are going through the same problem as me.

What I did in my case was just use the following pins from the SWD connector.

I used pin 2 - SWCLK, pin 3 - GND, and pin 4 - SWDIO

Pin 1 of the SWD connector is a fake 3v3, so I used pin 4 of the CN6 connector that provides 3v3.

MMax.3
Associate II

Thanks for all the replies.

I've tried what @Community member​ did, but no success.

Also googled it before asking (thought I was going crazy).

So I ordered a brand new ST-Link V2 (by an official reseller stated by ST).

I tried it out with STM32CubeProgrammer, I got in (can read memory).

Apparently the chip wasn't locked, I assumed it was, due to the error I got.

(I work with multiple CubeMX windows open to test stuff, I thought I had used a project which didn't had that SWD-setting setup, so it would explain the error).

!Here comes the bad part!:

I thought it would work by now..

But then I started debugging with Atollic TrueStudio, it asked me to update the firmware, so I did.

After that I tried Debugging again. It gives me basically the same error:

"Error in initializing ST-LINK device."

Then I tried ST32CubeProgrammer again, it gave me the same error.

A different laptop with just STM32CubeProgrammer gives the same error.

I use the following wiring setup, table 4:

um1075-stlinkv2-incircuit-debuggerprogrammer-for-stm8-and-stm32-stmicroelectronics.pdf

20-pin STM32-connector, SWD:

3V3 -> 1 (MCU VDD)

GND -> 4

SWDIO -> 7

SWCLK -> 9

My problems kinda started when I installed STM32Studio (to make a switch from TrueStudio) and also updated my other software tools to the latest version.

I also tried updating the drivers again (STSW-LINK009), but no success.

The following chips I've tried: STM32F103, STM32H750.

Also tried different cables.

@ssipa.1​:

Which programmer do you use?

I use: https://www.st.com/bin/ecommerce/api/image.PF251168.en.feature-description-include-personalized-no-cpn-large.jpg

Don't think it's a driver issue, but maybe useful information?

Device Manager details:

winusb.sys 10.0.19041.1

WdfCoInstaller01009.dll 1.9.7600.16385

WinUSBCoInstaller2.dll 6.1.7600.16585

VID = 0483, PID = 3748, REV_0100

What firmware does STM32 Cube Programmer report as being on the device.  V2J39S7 seems reasonably current

What board is this? Custom?

Lack of connectivity generally means the IC is unresponsive. So power, both to VDD, and VDDA.

Check VCAP pins are at ~1.25V and have correct capacitors placed.

Check idle state of NRST

Connect NRST to the debugger so it can gain control of the MCU if you've reprogrammed or reconfigured PA13/PA14 pins. This allows "Connect Under Reset" modes to actually be successful.

An NRST is not the same as a POWER-UP reset on H7's.

BOOT0 HIGH causes the device to reset into ROM mode, this can be helpful for a number of reasons.

I'm not sure the H750 is particularly prone to this unlike Dual MCU H7's, but if the SMPS/LDO mode, or VOS are setting wrong in your clock settings code the H7 can be unresponsive.

For H7 in this locked state the method I've found most effective is to tie BOOT0 HIGH with a jumper or bridge, and to COMPLETELY power cycle the boards a couple of times, the access with STM32 Cube Programmer and BULK ERASE the code, and double check the OPTIONS BYTES. Avoid any parasitic powering via debugger or GPIOs.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..

You are welocome @Community member​ 

Yes the same program