cancel
Showing results for 
Search instead for 
Did you mean: 

How to do the pin connections for STM32L476RGT6U on PCB so that a program can be uploaded?

Prajnyajit
Associate II

I'm trying to mount STM32L476RGT6U on pcb. I want to upload program using IDE to the controller on the pcb. Please advice me the suitable connection diagram to fullfill this particular requirement.​

27 REPLIES 27
Prajnyajit
Associate II

If I use an ST-LINK V2, whose pins are as shown as follows.

0693W00000FAiyeQAD.jpg 

as per your suggestion, should I need to connect

  1. NRST (of MCU) to TRSR (ST-LINK V2)
  2. PA13 to TMS
  3. PA14 to TCK
  4. GND to GND

Is it so ? Aksing you to get confirmation. If so, should I pulldown BOOT0 to the ground?

In this way can I debug and upload the program to MCU?

Hi,

I have modified as per your suggestion please let me know if it is right or not. Here I have made the BOOT0 to GND because I am using JTAG. Will it work?

0693W00000FAkrlQAD.jpg0693W00000FAktvQAD.jpg0693W00000FAkuAQAT.jpg

If you don’t plan test system bootloader , then BOOT0 to GND , otherwise to GND over R 10k for example.
When your code don’t plan use PA13,14 then SWD will work without NRST then you realy use GND and two wires.
And no NRST isnt connected to TRST...

On a polite note, "When your code don't plan use..." what do you mean by this statement?

Anyway, I have modified it right away. Now, BOOT0 can be connected to VDD or GND (thorough R=10K) as per requirement and

TRST (ST-LINK V2) is connected to NRST of MCU. Will it work right now? Other pins of STM Lin V2 should remain unconnected right?

0693W00000FAl9AQAT.jpg

Ahhhh ...
TRST is JTAG reset signal and is not used for your config , you need connect MCU RST pin 10 from your image STLINK V2 and your schematics !!! You place signal rst to GND line
And when you don’t understand "When your code don't plan use..." stop ask here !!!
This mean you don’t configure any function in code to this pins.

See, very frankly I'm speaking. Your English is very difficult to understand that's why I'm confused sometimes and having difficulty. Thank you anyway. I'll take help from someone else.

What Pin# on the MCU does pin 7 on the header go to? NJTRST (PB4?)

Pin 10 here should be MCU NRST/NRESET

If you expect your code to run when the board powers up, BOOT0 should be low

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

0693W00000FApKbQAL.jpg0693W00000FApKlQAL.jpgYes, as per the reference manual TRST which is pin 7 on the header will go to PB4 (Pin 56 of STM32L476RGT6U).

Pin 10 which is MCU RST on the header, will go to NRST (Pin 7 of STM32L476RGT6U).

Ok! I got it, Boot0 will be lowered after the program is uploaded and ready to run. Isn't it?

I have complied with all the changes you have told and attaching the schematic here. Can you please verify?

NOTE: I've another doubt that, I have connected NRST with Pin 10 of ST-LINK V2 and is grounded as per the reference manual screenshot attached. So is it correct or not? Will, it (NRST & Pin 10 of Header) be grounded or not?