cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L0 Bootloader

julien239955_st
Associate II
Posted on July 27, 2015 at 10:25

Hello all,

I'm new in using STM32 microcontrollers.

I have my own board with a STM32L051 microcontroller and I need to use the bootloader.

I've a jumper to the BOTT0 pin to set to hight or low.

I don't have change anything on the nBOOT1 bit.

My probleme is that when I set BOOT0 pin to hight, connect the USART1 to my computer, the Flash Loader Demonstrator tool don't see the STM32L051.

I've check with a serial spy, my computer send the code ''0x7F'' but no answer from my board...

May be I've missed something during configuration or other...

Is there some one to help me ?

Thanks in advance !!

#stm32 #uart #bootloader
5 REPLIES 5
Posted on July 27, 2015 at 13:03

And is this board functional in any other way? Can you upload code to it via SWD/JTAG? Does the USART work when you code a small echo program?

Is the USART even wire up properly, and to what?

The USART uses CMOS levels, not RS232 ones. The System Loader expects EVEN parity.

There's virtually no design details, so it's hard to know if you missed anything. Do you have the analogue supplies connected? What's the voltage on NRST?

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
julien239955_st
Associate II
Posted on July 27, 2015 at 13:54

Hi clive1,

Yes, my board is functional, I can upload code with SWD.

The USART is also functioning, I'm using it in my software, with a cable FTDI TTL-232-3V3.

The NRST is connected to the alimentation by a 10K resistor.

The alimentation come from 2 batteries AAA. I've also tried with an external power supply.

And here is the configuration of the Flash Loader Demonstrator :

Baud Rate : 115200

Data Bits : 8

Parity : Even

Echo : Disabled

Timeout : 5s

Sorry if I forgot some details...

Posted on July 27, 2015 at 14:31

Really no insight here as to if the Flash Loader Demonstrator is L0 ready.

I'd personally use RealTerm and send the 0x7F in hex mode with that.

The alternative is that BOOT0 = HIGH @ RESET isn't getting it into the System Loader, you could perhaps call into it manually.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
julien239955_st
Associate II
Posted on July 29, 2015 at 15:11

I've try to send the 0x7F command with RealTerm.

I don't received the 0x79 acknowledge commande (or other..).

To test if the bootloader is running or not, in my software I turn ON a LED.

I've flashed the STM32L051 using SWD.

Turn ON my board with BOOT0 = 0, the LED is ON.

I turn OFF my board, 

Turn ON my board with BOOT0 = 1, the LED is OFF.

But I don't know if the STM32 boot in System memory or in Embedded SRAM (I don't know the value of nBOOT1...)

julien239955_st
Associate II
Posted on July 29, 2015 at 17:17

I've try to do exactly what is done in the ST example (https://www.youtube.com/watch?v=cvKC-4tCRgw)

And it's working !!

So my cable, the bootloader and the Flash Loader Demonstrator are OK.

May be the nBOOT1 bit is not with the good value ?

But, how to do this ?

Thanks for your help