2024-01-19 11:26 AM
Hello ST Community,
I'm encountering difficulties while attempting to connect and debug my STM32 microcontroller, and I'm seeking guidance from the community. I have erased the full chip flash memory and uploaded my code but suddenly I start getting these error messages,
Error Messages:
1. In ST-Link Utility:
Can not connect to target!
If you're trying to connect to an STM32W1xx device, please select Normal or HotPlug mode from Target->Settings menu.
If you're trying to connect to a low-frequency application, please select a lower SWD Frequency mode from Target->Settings menu.
2. In Cube Programmer:
UR connection mode is defined with the HWrst reset mode
ST-LINK SN : 003F00164741500420383733
ST-LINK FW : V3J13M4
Board : STM32H7B3I-DK
Voltage : 3.28V
Error: No STM32 target found! If your product embeds Debug Authentication, please perform a discovery using Debug Authentication.
3. In CubeIDE :
---------------------
Starting server with the following options:
Persistent Mode : Disabled
Logging Level : 1
Listen Port Number : 61234
Status Refresh Delay : 15s
Verbose Mode : Disabled
SWD Debug : Enabled
InitWhile : Enabled
Target no device found
Error in initializing ST-LINK device.
Reason: No device found on target.
----------------------
Steps Taken:
- Verified physical connections.
- Powered the microcontroller adequately.
- Used ST-Link utility and CubeIDE for debugging.
- Configured the software environment for SWD.
I've also tried initiating a hard reset by pulling the NRST pin low, but unfortunately, I'm still encountering the same error.
I'm reaching out to the community for insights into resolving the connectivity issue. If anyone has encountered similar problems or has expertise in debugging STM32 microcontrollers, your input would be highly appreciated, I am still a beginner in this field.
- Debugger/Programmer: ST-LINK V3J13M4
- Development Board: STM32H7B3I-DK
Solved! Go to Solution.
2024-01-19 01:14 PM
Hi @STTwo-32 ,
Thank you for your response, I want to bring to your attention that I have set the mode to Power Down and it connected successfully.
Thank you!
2024-01-19 11:52 AM - edited 2024-01-19 01:34 PM
Hello @Ayoub_Bnina and welcome to the ST Community :smiling_face_with_smiling_eyes:.
I suggest you Make sure that your STLink firmware is upgraded. You can also try to "Connect under reset" or "power down" mode. Finally, you can refer to this post for more details.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2024-01-19 01:14 PM
Hi @STTwo-32 ,
Thank you for your response, I want to bring to your attention that I have set the mode to Power Down and it connected successfully.
Thank you!
2024-01-19 01:36 PM
Happy to know that .
So, I think you can select as best answer the post that solved your issue.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2024-05-20 02:59 AM
Hi @STTwo-32 ,
Can not connect to target!
same issue with the STM32H735VGH controller.
I have kept it in "Connect under reset" or "power down" mode but same issue,no change
even I have upgraded STLink firmware.
target is not connecting--> I have tried with all the setting in STM cube programmer.
2024-09-05 01:42 AM
how did you solved the above issue. i am getting same error.
Error in initializing ST-LINK device.
Reason: No device found on target.
please let me know
2024-09-05 02:27 AM
2024-09-05 02:30 AM
Hello @marimuthu02111982 and welcome to the community.
I suggest you to open a new thread if my previous comment doesn't answer your question and tell which board you are using/ which tool and post a screenshot a the message you face.
Thank you for your understanding.
2024-09-09 06:05 AM
Install ST-Link UTILITY latest version 4.6.0
Make sure that STM32 CubeIde is not in debug mode then use ST-Link UTILITY latest version 4.6.0
Now, open ST-Link UTILITY latest version 4.6.0
hold down the reset button in your PCB while clicking Target-->connect.
then the target will be connected and
Release reset button on the PCB, and then click on Erase chip in ST-Link UTILITY.
You need to try this few times.
actually ,i have done the above solution because i have dumped wrong code into the microcontroller.
for that i have to erase the chip(microcontroller).