cancel
Showing results for 
Search instead for 
Did you mean: 

Programming STM32U031C8U6 with ST-LinkV3

MaxBrt
Associate

Good morning,
I would like to request support regarding the programming and debugging of the STM32U031C8U6 microcontroller. It is mounted on a custom-designed board, and I am experiencing issues connecting to the microcontroller via SWD for programming and/or debugging using an ST-LinkV3 updated to the latest version (V3.J16.M8.B5.S1), with STM32CubeProgrammer and STM32CubeIDE. The microcontroller is never detected.
Note: With the ST-LinkV2 programmer, I am able to perform both programming and debugging without issues using the same software tools.

 

Many thanks in advance to anyone who can help me!

1 ACCEPTED SOLUTION

Accepted Solutions
MaxBrt
Associate

Thank you all,

I found the problem!!. Basically, if I use the JTAG20 header on the V2 and connect only the SWD pins, it works correctly. However, if I connect the same pins on the V3, it doesn’t work. Instead, it works when I connect the board using the SWD header pins.

I thought they were the same thing, but clearly I was wrong.

View solution in original post

6 REPLIES 6
Pavel A.
Super User

Have you connected the target voltage pin?  ST-LinkV3 needs it.

 

mƎALLEm
ST Employee

Hello @MaxBrt and welcome to the community,

You need to share the schematic so others can help you efficiently.

Thank you

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.
Andrew Neil
Super User

Welcome to the forum.

For best results, please see How to write your question to maximize your chances to find a solution.

 


@MaxBrt wrote:

 It is mounted on a custom-designed board,


So, as @mƎALLEm said, you need to supply full details of the board - in particular, the schematics.

Also show how the ST-Link is connected.

Some good, clear photos of your setup would also help.

 

Some Knowledge Base articles on debugger connection issues:

How to solve connection errors when connecting and programming the STM32 target board.

How to solve debugger connection issues

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.
TDK
Super User

Show a picture of the setup, showing connecting between chip and programmer.

Ensure the board is powered. The programmer generally does not provide this.

Show a picture of STM32CubeProgrammer screen when it fails to detect the chip.

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

Thank you all,

I found the problem!!. Basically, if I use the JTAG20 header on the V2 and connect only the SWD pins, it works correctly. However, if I connect the same pins on the V3, it doesn’t work. Instead, it works when I connect the board using the SWD header pins.

I thought they were the same thing, but clearly I was wrong.


@MaxBrt wrote:

I found the problem!!.


Great - thanks for feeding back.

Now please mark your post as the solution:

https://community.st.com/t5/community-guidelines/help-others-to-solve-their-issues/ta-p/575256

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.