Skip to main content
Associate III
May 8, 2025
Solved

STM32L011F4U6 can't enter bootloader

  • May 8, 2025
  • 6 replies
  • 821 views

I connect the PB9-BOOT0 to VDD, then power up the board, but it just run from flash(application program), not the bootloader, what's the matter? 

I am not firmilar with ISP, I suppose it should enter bootloader, and wait for ISP program to communicate.

I want to confirm, besides connect PB9-BOOT0 to VDD, is there any other thing need be done? 

Best answer by Chaima_M

Hello @STM32L09 ,

 First, please try to connect the device using STM32CubeProgrammer instead of the STM32 Flash loader demonstrator.

About nBoot0_SW, this is either nSWBoot0 or nBOOT0_SEL, depending upon the product.

 

 

 

6 replies

STM32L09Author
Associate III
May 8, 2025

STM32L09_0-1746701095355.png

PA9, PA10 used for bootloader, and the connection is tested.

TDK
Super User
May 8, 2025

See AN2606 for the full list of options which can cause the bootloader to start. Notably, there are option bytes which can be set to ignore the value of the BOOT0 pin.

STM32 microcontroller system memory boot mode - Application note

TDK_0-1746709755525.png

 

Typically, and by default, setting BOOT0 high during reset is enough to start the bootloader.

"If you feel a post has answered your question, please click ""Accept as Solution""."
STM32L09Author
Associate III
May 8, 2025

Yes, I  noticed if it's a empty device, to enter bootloader, the BOOT0 need be connect to GND, I use a empty device, and seems enter bootloader, but in this page the list is empty, nothing to choose, and go to next, select the hex file, fail to download.

STM32L09_0-1746713611591.png 

STM32L09_1-1746713629764.png

For the programed MCU, when PB9-BOOT0 connect to VDD, why it can't enter bootloader after reset? I didn't set the option byte, nBoot1 is 1 by default, what's nBoot0_SW mean? I didn't find it in reference manual.

thanks.

  

Chaima_M
ST Employee
May 8, 2025

Hello @STM32L09 , 

Please check your nBOOT1 bit and nBOOT_SEL bit as stated in RM0377 section 2.4 Boot configuration. 

 

STM32L09Author
Associate III
May 8, 2025

thanks for your reply.

STM32L09_0-1746714084443.png

STM32L09_1-1746714239228.png

 

by default nBOOT1 is 1, nBOOT_SET is 0, and I connect BOOT0 to VDD, I don't know why it doesn't enter bootloader?

Chaima_M
Chaima_MAnswer
ST Employee
May 8, 2025

Hello @STM32L09 ,

 First, please try to connect the device using STM32CubeProgrammer instead of the STM32 Flash loader demonstrator.

About nBoot0_SW, this is either nSWBoot0 or nBOOT0_SEL, depending upon the product.

 

 

 

STM32L09Author
Associate III
May 9, 2025

Currently, by using STM32CubeProgrammer, the empty MCU can enter bootloader by connecting BOOT0 PIN to GND, and also can be programed.

and I found that nBOOT1 is 0 for a empty MCU. I think this is why the programed MCU can't enter bootloader by connect BOOT0 PIN to VDD. this is strange, the RM says default nBOOT1 is 1. How can I set nBOOT1 to 1 for the programed MCU?

STM32L09_0-1746749733640.png

 

 

 

STM32L09_1-1746714239228.png

STM32L09Author
Associate III
May 9, 2025

STM32L09_0-1746760200863.png

I use STVP to reprogram FLASH option byte, then the programed MCU can als enter bootloader.

STM32L09Author
Associate III
May 9, 2025

summarize for STM32L011F4 to enter bootloader:

1. empty MCU: connect PB9-BOOT0 to GND,  it can enter bootloader, and use STM32CubeProgrammer, through USART2, set FLASH option byte, nBOOT1 =1, after programed, it still can enter bootloader by connect PB9-BOOT0 to VDD.

2. programed MCU: if nBOOT1 is 0, need to set nBOOT1 to 1, we can use STVP to program FLASH option byte.(because STM32CubeProgrammer not support ST-LINK V1)

 

above is the method we use PB9-BOOT0 to control enter bootloader.