cancel
Showing results for 
Search instead for 
Did you mean: 

How to use the standalone ST-LINK capability of my nucleo after I cut the PCB?

BCora.1
Associate III

Hello,

in the user manual of my Nucleo L152RE, on page 16, it's written:

"""

Cuttable PCB

The STM32 Nucleo board is divided into two parts: ST-LINK part and target STM32 part.

The ST-LINK part of the PCB can be cut out to reduce the board size. In this case the

remaining target STM32 part can only be powered by VIN, E5V and 3.3V on ST morpho

connector CN7 or VIN and 3.3V on Arduino connector CN6. It is still possible to use the

ST-LINK part to program the main STM32 using wires between CN4 and SWD signals

available on ST morpho connector (SWCLK CN7 pin 15 and SWDIO CN7 pin 13).

"""

(source: https://www.st.com/resource/en/user_manual/dm00105823-stm32-nucleo64-boards-mb1136-stmicroelectronics.pdf#page=16 )

So I'd be very happy to cut my board into two parts. I could power the MCU part with a 3V battery when I only need to run my program. And I could connect the MCU back to the ST-LINK part using jumper cables when I need to flash the microcontroller again. That would be awesome.

But I'm not sure I understand what pin I should connect to what pin to reconnect the ST-LINK to the MCU. I must connect the pin 15 of CN7 to what and the pin 17 of CN7 to what?

I can see the CN4/SWD block on the ST-LINK part of the board but there are 5 pins here, not two. So what do I have to connect to exactly?

1 ACCEPTED SOLUTION

Accepted Solutions
KnarfB
Principal III
10 REPLIES 10
KnarfB
Principal III

Looks like this:

0693W000003POwpQAG.jpg

BCora.1
Associate III

Awesome, that's exactly what I needed, thank you!

But why do they use an external power supply? After the cut it's no longer possible to power the MCU from the USB power that comes from the ST-LINK part?

TDK
Guru

> After the cut it's no longer possible to power the MCU from the USB power that comes from the ST-LINK part?

Correct. This is how most (all?) ST programmers operate. It doesn't look like they expose 3.3V anywhere convenient on the st-link programmer side.

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

Thanks for the reply!

3.3V would be no problem since that's what I plan to power the MCU with anyway. However, on the figure, they show a 8V DC power supply.

Will it work if I just supply the MCU with 3V (using the MCU's 3V pin) ? Or do I have to supply more voltage and use the 5V pin because there's some stuff in the MCU part that needs the bigger voltage for the ST-LINK to operate correctly?

TDK
Guru

> Will it work if I just supply the MCU with 3V (using the MCU's 3V pin) ? Or do I have to supply more voltage and use the 5V pin because there's some stuff in the MCU part that needs the bigger voltage for the ST-LINK to operate correctly?

The user manual goes into detail on the different power configurations. They don't suggest supplying 3V directly, but give a similar option:

0693W000003POzKQAW.png

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

I've read that page of the manual. Don't they just mean that if you power the board only through the +3.3V pin (and not connecting to USB) then the ST-LINK is not powered? At least that's what I understand. But what I plan to do is power the ST-LINK part through USB of course. That's how I plan to flash the chip even after cutting the board: by connecting the ST-LINK part to the computer via USB. Am I misunderstanding something here?

TDK
Guru

You need to power two things: the ST-Link programmer and the target board. The programmer is powered by USB, nothing else required. This is telling you how to power the target board that you've just separated from the programmer. Maybe that's not what you're asking.

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

Ok, thanks. Maybe my writing is a bit confusing. I've understood already how to power the target board with a 3V battery after separating the two parts. I can power the target board with a 3V battery and this target board will do its thing alone.

My question was how to use the ST-LINK again after that, to reprogram the target.

My guess is that the ST-LINK doesn't need additional power than the USB to function. So, you just need to provide power to the target through battery. I was wondering if there was a reason for the 8V power supply they use in the figure posted by KnarfB. Can't I just use the 3V pin with a 3V battery just like when the target board is all alone?

There are several powering options. I used VIN (7..12 V DC) which gets converted and stabilized on the board.