cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F0 nBOOT1 bit

brunoluvizotto
Associate II
Posted on May 18, 2014 at 17:55

Dear friends

,

I am really inclined to use the STM32F050 microcontroller. I would like to use its internal bootloader, but while I was reading the documentation (AN2606), I found the following:

''The hardware required to put the STM32F050xx devices into System memory boot mode consists of any circuitry, switch or jumper, capable of holding the BOOT0 pin high while nBOOT1 bit in the option bytes (starting at address 0x1FFFF800) is set to value 1. The setting of this bit can be done through the STLINK utility or an equivalent tool.''

The question is: if I don't want to have a JTAG / SWD interface, how can I ensure that I will be able to enter the internal flash loader? Is the nBOOT1 bit set when it comes from the 

factory

?

Thank you in Advance,

Bruno Luvizotto

#stm32f0-nboot1-bootloader-flash
6 REPLIES 6
Posted on May 18, 2014 at 18:01

For the most part the STM32 series just needs BOOT0 High to get to System Loader mode, and Low to get to FLASH. You'd need to review the STM32F0 documentation, and experiment with a board to get confidence. The F0 is a bit under-whelming for my needs, so haven't spent a lot of time looking at them.

You can write the options bytes from your own code. You can likely bring up the System Loader from your own code.
Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
brunoluvizotto
Associate II
Posted on May 19, 2014 at 02:07

Clive, thank you for your answer.

The problem is that I need to run the internal bootloader at least once, so I could program the flash with my code, and to achieve that, I need to have nBOOT1 high. =)

By the way: thanks for all your answers. They have helped me a lot in the last few weeks.

Posted on May 19, 2014 at 03:35

I'm sure the initial state of the options (erased) is described in at least one of the manuals (data sheet, or reference)

It wouldn't make sense to ship a part that wouldn't enter the System Loader with BOOT0 High so it could be programmed via the serial port.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
brunoluvizotto
Associate II
Posted on May 19, 2014 at 18:48

I agree with you. I just wanted to be sure!

I read the manuals a few times, but I'll search a little bit more.

Thank you again.

brunoluvizotto
Associate II
Posted on May 19, 2014 at 20:07

For those who have the same question:

Refer to Section 4.1.1 of the RM0091 for default factory value of the nBOOT1 bit. It's set after production.

rodion_gork
Associate II
Posted on January 01, 2016 at 06:53

Hi! May I ask whether you finally succeeded in connecting to STM32F0 via USART / bootloader? For I currently seem to have trouble with it and couldn't get what is wrong...

I connect VDD, VSS, PA9 and PA10 (as TX and RX, the first of them with pull-up) and tie BOOT0 to VDD... and I get no answer from the device still.