stm32 Microcontroller System Memory Boot Mode Stmicroelectronics
stm32 Microcontroller System Memory Boot Mode Stmicroelectronics
Application note
STM32 microcontroller system memory boot mode
Introduction
The bootloader is stored in the internal boot ROM (system memory) of STM32 devices, and is
programmed by ST during production. Its main task is to download the application program to the
internal Flash memory through one of the available serial peripherals (such as USART, CAN,
USB, I2C, SPI). A communication protocol is defined for each serial interface, with a compatible
command set and sequence. This document applies to the products listed in Table 1, referred to
as STM32 throughout the document. It describes the supported peripherals and hardware
requirements to consider when using the bootloader of STM32 devices.
Contents
1 General information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
2 Related documents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3 Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
List of tables
List of figures
1 General information
2 Related documents
For each supported product (listed in Table 1) refer to the following documents available
from www.st.com:
• Datasheet or databrief
• Reference manual
• Application notes
– AN3154: CAN protocol used in the STM32 bootloader
– AN3155: USART protocol used in the STM32 bootloader
– AN3156: USB DFU protocol used in the STM32 bootloader
– AN4221: I2C protocol used in the STM32 bootloader
– AN4286: SPI protocol used in the STM32 bootloader
– AN5405: FDCAN protocol used in the STM32 bootloader
a. Arm is a registered trademark of Arm Limited (or its subsidiaries) in the US and/or elsewhere.
3 Glossary
C0 Series:
STM32C011xx is used to refer to STM32C011xx devices.
STM32C031xx is used to refer to STM32C031xx devices.
F0 Series:
STM32F03xxx is used to refer to STM32F030x4, STM32F030x6, STM32F038x6,
STM32F030xC, STM32F031x4 and STM32F031x6 devices.
STM32F04xxx is used to refer to STM32F042x4 and STM32F042x6 devices.
STM32F05xxx and STM32F030x8 devices is used to refer to STM32F051x4,
STM32F051x6, STM32F051x8, STM32F058x8 and STM32F030x8 devices.
STM32F07xxx is used to refer to STM32F070x6, STM32F070xB, STM32F071xB
STM32F072x8 and STM32F072xB devices.
STM32F09xxx is used to refer to STM32F091xx and STM32F098xx devices.
F1 Series:
STM32F10xxx is used to refer to Low-density, Medium-density, High-density, Low-
density value line, Medium-density value line and High-density value line devices:
Low-density devices are STM32F101xx, STM32F102xx and STM32F103xx
microcontrollers where the Flash memory density ranges between 16 and
32 Kbytes.
Medium-density devices are STM32F101xx, STM32F102xx and STM32F103xx
microcontrollers where the Flash memory density ranges between 64 and
128 Kbytes.
High-density devices are STM32F101xx and STM32F103xx microcontrollers
where the Flash memory density ranges between 256 and 512 Kbytes.
Low-density value line devices are STM32F100xx microcontrollers where the
Flash memory density ranges between 16 and 32 Kbytes.
Medium-density value line devices are STM32F100xx microcontrollers where
the Flash memory density ranges between 64 and 128 Kbytes.
High-density value line devices are STM32F100xx microcontrollers where the
Flash memory density ranges between 256 and 512 Kbytes.
STM32F105xx/107xx is used to refer to STM32F105xx and STM32F107xx devices.
STM32F10xxx XL-density is used to refer to STM32F101xx and STM32F103xx
devices where the Flash memory density ranges between 768 Kbytes and 1 Mbyte.
F2 Series:
STM32F2xxxx is used to refer to STM32F215xx, STM32F205xx, STM32F207xx and
SMT32F217xx devices.
F3 Series:
STM32F301xx/302x4(6/8) is used to refer to STM32F301x4, STM32F301x6,
STM32F301x8, STM32F302x4, STM32F302x6 and STM32F302x8 devices.
STM32F302xB(C)/303xB(C) is used to refer to STM32F302xB, STM32F302xC,
STM32F303xB and STM32F303xC devices.
STM32F302xD(E)/303xD(E) is used to refer to STM32F302xD, STM32F302xE,
STM32F303xD and STM32F303xE devices.
STM32F303x4(6/8)/334xx/328xx is used to refer to STM32F303x4, STM32F303x6,
STM32F303x8, STM32F334x4, STM32F334x6, STM32F334x8, and STM32F328x8
devices.
STM32F318xx is used to refer to STM32F318x8 devices.
STM32F358xx is used to refer to STM32F358xC devices.
STM32F373xx is used to refer to STM32F373x8, STM32F373xB and STM32F373xC
devices.
STM32F378xx is used to refer to STM32F378xC devices.
STM32F398xx is used to refer to STM32F398xE devices.
F4 Series:
STM32F40xxx/41xxx is used to refer to STM32F405xx, STM32F407xx,
STM32F415xx and SMT32F417xx devices.
STM32F401xB(C) is used to refer to STM32F401xB and STM32F401xC devices.
STM32F401xD(E) is used to refer to STM32F401xD and STM32F401xE devices.
STM32F410xx is used to refer to STM32F410x8 and STM32F410xB devices.
STM32F411xx is used to refer to STM32F411xD and STM32F411xE devices.
STM32F412xx is used to refer to STM32F412Cx, STM32F412Rx, STM32F412Vx and
STM32F412Zx devices.
STM32F413xx/423xx is used to refer to STM32F413xG, STM32F413xH and
STM32F423xH devices.
STM32F42xxx/43xxx is used to refer to STM32F427xx, STM32F429xx,
STM32F437xx and STM32F439xx devices.
STM32F446xx is used to refer to STM32F446xE and STM32F446xC devices.
STM32F469xx/479xx is used to refer to STM32F469xE, STM32F469xG,
STM32F469xI, STM32F479xG and STM32F479xI devices.
F7 Series:
STM32F72xxx/73xxx is used to refer to STM32F722xx, STM32F723xx,
STM32F732xx and STM32F733xx devices.
STM32F74xxx/75xxx is used to refer to STM32F745xx, STM32F746xx and
STM32F756xx devices.
STM32F76xxx/77xxx is used to refer to STM32F765xx, STM32F767xx,
STM32F769xx, STM32F777xx and STM32F779xx devices.
G0 Series:
STM32G03xxx/04xxx is used to refer to STM32G03xxx and STM32G04xxx devices.
STM32G07xxx/08xxx is used to refer to STM32G07xxx and STM32G08xxx devices.
STM32G0B1xx/C1xx is used to refer to STM32GB1xx and STM32G0C1xxx devices.
Note: BOOT_LOCK implementation is product dependent, refer to reference manual for more
details.
In addition to patterns described above, user can execute bootloader by performing a jump
to system memory from user code. Before jumping to bootloader user must:
• Disable all peripheral clocks
• Disable used PLL
• Disable interrupts
• Clear pending interrupts
System memory boot mode can be exited by getting out from bootloader activation
condition and generating hardware reset or using Go command to execute user code.
Note: When executing the Go command, the peripheral registers used by the bootloader are not
initialized to their default reset values before jumping to the user application. They must be
reconfigured in the user application if they are used. So, if the IWDG is being used in the
application, the IWDG prescaler value has to be adapted to meet the requirements of the
application (since the prescaler was set to its maximum value). For some products, not all
reset values are set. For more information refer to the known limitations detailed for each
product bootloader versions.
Note: For STM32 devices having the Dual Bank Boot feature, to jump to system memory from
user code the user has first to remap the System Memory bootloader at address
0x00000000 using SYSCFG register (except for STM32F7 Series), then jump to bootloader.
For STM32F7 Series, the user has to disable nDBOOT and/or nDBANK features (in option
bytes), then jump to bootloader.
Note: For STM32 devices embedding bootloader using the DFU/CAN interface in which the
external clock source (HSE) is required for DFU/CAN operations, the detection of the HSE
value is done dynamically by the bootloader firmware and is based on the internal oscillator
clock (HSI, MSI). When (because of temperature variations or other conditions) the internal
oscillator precision is altered above the tolerance band (1% around the theoretical value),
the bootloader might calculate a wrong HSE frequency value. In this case, the bootloader
DFU/CAN interfaces might malfunction or not work at all.
+V 1
R
RX 2 TX
RS232
Transceiver
STM32
UART Host TX RX Microcontroller
GND GND
MSv35098V1
1. A pull-up resistor must be added, if pull-up resistor are not connected in host side.
2. An RS232 transceiver must be connected to adapt voltage level (3.3 to 12 V) between STM32 device and
host.
Note: +V typically is 3.3 V and R typically 100 KΩ.These values depend upon the application and
the used hardware.
To use the DFU, connect the microcontroller USB interface to a USB host (i.e. a PC).
1
+V
10K
36K
1.5K
VBus
DP DP
STM32
USB Host
DM DM Microcontroller
GND GND
MS35037V1
1. This additional circuit permits to connect a pull-up resistor to DP pin using VBus when needed. Refer to
product section (table describing STM32 configuration in system memory boot mode) to know if an external
pull-up resistor must be connected to DP pin.
Note: +V typically is 3.3 V. This value depends upon the application and the used hardware.
To use the I2C bootloader, connect the host (master) and the desired I2Cx interface (slave)
together via the data (SDA) and clock (SCL) pins. A 1.8 KΩ pull-up resistor has to be
connected to both SDA and SCL lines.
1.8K
1.8K
SCL SCL
STM32
I2C Host
SDA SDA Microcontroller
GND GND
MS35038V1
Note: +V is typically 3.3 V. This value depends upon the application and the used hardware.
To use the SPI bootloader, connect the host (master) and the desired SPIx interface (slave)
together via the MOSI, MISO and SCK pins. The NSS pin must be connected to GND. A
pull-down resistor must be connected to the SCK line.
NSS
MOSI MOSI
STM32
MISO MISO
SPI Host Microcontroller
SCK SCK
R
GND GND
MS35039V1
Note: R is typically 10 KΩ. This value depends on the application and the used hardware.
To use the CAN interface, the host has to be connected to the RX and TX pins of the desired
CANx interface via CAN transceiver and a serial cable. A 120 Ω resistor must be added as
terminating resistor.
RX CAN_H TX
CAN CAN STM32
CAN Host
120
120
Transceiv Transceiv
TX er er RX Microcontroller
CAN_L
GND GND
MS35040V1
Note: When a bootloader firmware supports DFU, it is mandatory that no USB Host is connected
to the USB peripheral during the selection phase of the other interfaces. After selection
phase, the user can plug a USB cable without impacting the selected bootloader execution
except commands which generate a system reset.
It is recommended to keep the RX pins of unused bootloader interfaces (USART_RX,
SPI_MOSI, CAN_RX and USB D+/D- lines if present) at a known (low or high) level at the
startup of the bootloader (detection phase). Leaving these pins floating during the detection
phase might lead to activating unused interfaces.
The table below lists the valid memory areas, depending upon the bootloader commands.
connection until the correct answer is received. Once correct answer is received the
rest of the communication is not impacted by software jitter).
It is also possible to reduce software jitter by reducing baudrate value (i.e. use
56000 bps instead of 115200).
Table 6 provides the maximum software jitter value for the baudrate 115200 bps.
The lower the baudrate the lower the software jitter.
• Baudrate detection using UART auto-baudrate feature.The devices using this
mechanism do not present any software jitter.
STM32F0 4 bytes
STM32F1 4 bytes
STM32F2 4 bytes
STM32F3 4 bytes
STM32F4 4 bytes
STM32F7 8 bytes
STM32G0 4 bytes
STM32G4 4 bytes
STM32H7 8 bytes
STM32L0 8 bytes
STM32L1 8 bytes
STM32L4 8 bytes
STM32L5 16 bytes
STM32WB 8 bytes
STM32WL 8 bytes
STM32U5 16 bytes
Example of alignment:
• 4 bytes: 0x08000014 is aligned and passes, 0x08000012 is not aligned and fails
• 8 bytes: 0x08000010 is aligned and passes, 0x08000014 is not aligned and fails
Note: On some products (STM32F4 and STM32F7) it is possible to change the alignment
constraint by writing in the device feature space.
Application Application
ExitSecureMemory
3
2
ExitSecureMemory 3
2
Application Application
Note: For more information regarding the option bytes configuration refer to the reference manual.
Note: An example of a function that can be used to call the “ExitSecureMemory” is in Appendix A.
STM32G07xxx/08xxx 0x1FFF6800
STM32G03xxx/04xxx 0x1FFF1E00
STM32G0
STM32G0Bxxx/0Cxxx 0x1FFF6800
STM32G05xxx/061xx 0x1FFF6800
STM32G47xxx/48xxx 0x1FFF6800
STM32G4 STM32G431xx/441xx 0x1FFF6800
STM32G491xx/4A1xx 0x1FFF6800
Jump to secure
memory address
R1=Magic number
No and
R2=User address
Yes
Flash dual bank
Check link register to know from Jump to ExitSecArea() Single bank Dual bank
which bank happening the jump function
MS51971V1
1. The Bootloader does not check the integrity of the user address, it is up to the user to ensure the validity of the address to
jump to.
Note: On WLCSP12, SO8N, TSSOP20 and UFQFN20 packages USART1 PA9/PA10 IOs are
remapped on PA11/PA12.
System Reset
Configure I2Cx
0x7F received on
yes
USARTx
yes
no
Disable all interrupt
Disable all interrupt
sources and other
sources and other
no I2Cx Address
Detected interfaces clock’s interfaces clock’s
Execute Configure
BL_I2C_Loop for USARTx
I2Cx
Execute
BL_USART_Loop
for USARTx
MS52813V1
Note: On TSSOP20 and UFQFN28 packages USART1 PA9/PA10 IOs are remapped on
PA11/PA12.
System Reset
Configure I2Cx
0x7F received on
yes
USARTx
yes
no
Disable all interrupt
Disable all interrupt
sources and other
sources and other
no I2Cx Address
Detected interfaces clock’s interfaces clock’s
Execute Configure
BL_I2C_Loop for USARTx
I2Cx
Execute
BL_USART_Loop
for USARTx
MS52813V1
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
Note: After the STM32F03xx4/6 devices has booted in bootloader mode, serial wire debug (SWD)
communication is no longer possible until the system is reset. This is because the SWD
uses the PA14 pin (SWCLK) which is already used by the bootloader (USART1_TX).
System Reset
0x7F received on
USARTx
no
yes
Disable all
interrupt sources
Configure
USARTx
Execute
BL_USART_Loop
for USARTx
MS35015V1
Note: After the STM32F030xC devices have booted in bootloader mode using USART2, the serial
wire debug (SWD) communication is no more possible until the system is reset, because
SWD uses PA14 pin (SWCLK) which is already used by the bootloader (USART2_RX).
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Configure I2Cx
yes
MSv36789V1
Table 17. STM32F05xxx and STM32F030x8 devices configuration in system memory boot mode
Bootloader Feature/Peripheral State Comment
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
Note: After the STM32F05xxx and STM32F030x8 devices have booted in bootloader mode, the
serial wire debug (SWD) communication is no more possible until the system is reset,
because SWD uses PA14 pin (SWCLK), already used by the bootloader (USART2_TX).
System Reset
0x7F received on
USARTx
no
yes
Disable all
interrupt sources
Configure
USARTx
Execute
BL_USART_Loop
for USARTx
MS35014V1
Note: After the STM32F04xxx devices have booted in bootloader mode using USART2, the serial
wire debug (SWD) communication is no more possible until the system is reset, because
SWD uses PA14 pin (SWCLK) which is already used by the bootloader (USART2_RX).
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
Note: Due to empty check mechanism present on this product, it is not possible to jump from user
code to system bootloader. Such jump results in a jump back to user Flash memory space.
But if the first 4 bytes of User Flash (at 0x0800 0000) are empty at the moment of jump (i.e.
erase first sector before jump or execute code from SRAM while Flash is empty), then
system bootloader is executed when jumped to.
System Reset
Configure I2Cx
0x7F received
yes
on USARTx
yes
no
Disable all interrupt
Disable all interrupt
sources and other
sources and other
I2Cx Address
Detected yes interfaces clock’s interfaces clock’s
Disable other
no interfaces clock’s Execute Configure
no BL_I2C_Loop for USARTx
I2Cx
USB
Detected Execute DFU
bootloader using USB Execute
interrupts BL_USART_Loop
for USARTx
MS35025V1
V10.0 Initial bootloader version At bootloader startup, the HSITRIM value is set to 0 (in
HSITRIM bits on RCC_CR register) instead of default
value (16), as a consequence a deviation is generated
Add dynamic support of in crystal measurement.
USART/USB interfaces on For better results, use the smallest supported crystal
V10.1
PA11/12 IOs for small value (i.e. 4 MHz).
packages. PA13 is set in input pull-up mode even if not used by
the bootloader.
Note: If HSI deviation exceeds 1% the bootloader might not function correctly.
Note: After the STM32F070x6 devices have booted in bootloader mode using USART2, the serial
wire debug (SWD) communication is no more possible until the system is reset, because
SWD uses PA14 pin (SWCLK) which is already used by the bootloader (USART2_RX).
The bootloader has two cases of operation depending on the presence of the external clock
(HSE) at bootloader startup:
• If HSE is present and has a value of 24, 18, 16, 12, 8, 6, 4 MHz, the system clock is
configured to 48 MHz with HSE as clock source. The DFU interface, USART1,
USART2 and I2C1 are functional and can be used to communicate with the bootloader
device.
• If HSE is not present, the HSI is kept as default clock source and only USART1,
USART2 and I2C1 are functional.
The external clock (HSE) must be kept if it is connected at bootloader startup because it is
used as system clock source.
Note: Due to empty check mechanism present on this product, it is not possible to jump from user
code to system bootloader. Such jump results in a jump back to user Flash space, but if the
first 4 bytes of User Flash (at 0x0800 0000) are empty at the moment of jump (i.e. erase first
sector before jump or execute code from SRAM while Flash is empty), then system
bootloader is executed when jumped to.
System Reset
yes
Configure USB
Configure I2Cx
0x7F received
yes
on USARTx
yes
no
Disable all interrupt
sources and other
interfaces clock’s
I2Cx Address
Detected yes
Disable all interrupt
Disable other sources and other Configure
interfaces clock’s interfaces clock’s USARTx
no
no
MSv36794V1
V10.2 Initial bootloader version At bootloader startup, the HSITRIM value is set to
0 (in HSITRIM bits on RCC_CR register) instead
of default value (16), as a consequence a
Clock configuration fixed deviation is generated in crystal measurement.
V10.3
to HSI 8 MHz For better results, use the smallest supported
crystal value (i.e. 4 MHz).
Note: If HSI deviation exceeds 1% the bootloader might not function correctly.
Note: After the STM32F070xB devices have booted in bootloader mode using USART2, the serial
wire debug (SWD) communication is no more possible until the system is reset, because
SWD uses PA14 pin (SWCLK) which is already used by the bootloader (USART2_RX).
The bootloader has two cases of operation depending on the presence of the external clock
(HSE) at bootloader startup:
• If HSE is present and has a value of 24, 18, 16, 12, 8, 6, 4 MHz, the system clock is
configured to 48 MHz with HSE as clock source. The DFU interface, USART1,
USART2 and I2C1 are functional and can be used to communicate with the bootloader
device.
• If HSE is not present, the HSI is kept as default clock source and only USART1,
USART2 and I2C1 are functional.
The external clock (HSE) must be kept if it is connected at bootloader startup because it is
used as system clock source.
System Reset
yes
Configure USB
Configure I2Cx
0x7F received
yes
on USARTx
yes
no
Disable all interrupt
sources and other
interfaces clock’s
I2Cx Address
Detected yes
Disable all interrupt
Disable other sources and other Configure
interfaces clock’s interfaces clock’s USARTx
no
no
MSv36795V1
V10.2 Initial bootloader version At bootloader startup, the HSITRIM value is set to
(0) (in HSITRIM bits on RCC_CR register) instead
of default value (16), as a consequence a
deviation is generated in crystal measurement.
Clock configuration fixed For better results, use the smallest supported
V10.3
to HSI 8 MHz crystal value (i.e. 4 MHz).
PA13 is set in alternate push-pull mode even if not
used by the bootloader.
Note: After the STM32F071xx/072xx devices have booted in bootloader mode using USART2, the
serial wire debug (SWD) communication is no more possible until the system is reset,
because SWD uses PA14 pin (SWCLK) which is already used by the bootloader
(USART2_RX).
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Configure I2Cx
0x7F received on
yes
USARTx
yes
no
Disable all interrupt
Disable all interrupt
sources and other
sources and other
I2Cx Address
Detected yes interfaces clock’s interfaces clock’s
Disable other
no interfaces clock’s Execute Configure
no BL_I2C_Loop for USARTx
I2Cx
USB
Detected Execute DFU
bootloader using USB Execute
interrupts BL_USART_Loop
for USARTx
MS35026V1
Note: After the STM32F09xxx devices have booted in bootloader mode using USART2, the serial
wire debug (SWD) communication is no more possible until the system is reset, because
SWD uses PA14 pin (SWCLK) which is already used by the bootloader (USART2_RX).
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Configure I2Cx
yes
MSv36789V1
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
0x7F received on
USARTx
No
Yes
Disable all
interrupt sources
Configure
USARTx
Execute
BL_USART_Loop
for USARTx
MS35004V1
Note: The bootloader ID format is applied to all STM32 devices families except the STM32F1xx
family. The bootloader version for the STM32F1xx applies only to the embedded device’s
bootloader version and not to its supported protocols.
The system clock is derived from the embedded internal high-speed RC for USARTx
bootloader. This internal clock is used also for DFU and CAN bootloaders but only for the
selection phase. An external clock (8 MHz, 14.7456 MHz or 25 MHz) is required for DFU
and CAN bootloader execution after the selection phase.
System Reset
Configure USB
USB cable
yes
Detected
no yes
Disable all
interrupt sources HSE= 8MHz,
no 0x7F received on
USARTx 14.7456MHz or
Configure 25 MHz
USARTx
no
yes
Frame detected on Execute
CANx BL_USART_Loop
Reconfigure System
for USARTx
clock to 48MHz and
yes USB clock to 48 MHz
Generate System
yes
reset
Reconfigure System
clock to 48MHz
Disable all
interrupt sources
Configure CAN
Execute
BL_CAN_Loop for
CANx
MS35005V1
Note: The bootloader ID format is applied to all STM32 devices families except the STM32F1xx
family. The bootloader version for the STM32F1xx applies only to the embedded device’s
bootloader version and not to its supported protocols.
• The values of the vector table at the beginning of the bootloader code are different. The
user software (or via JTAG/SWD) reads 0x1FFFE945 at address 0x1FFFB004 for
bootloader V2.0 0x1FFFE9A1 for bootloader V2.1, and 0x1FFFE9C1 for bootloader
V2.2.
• The DFU version is the following:
– V2.1 in bootloader V2.1
– V2.2 in bootloader V2.2.
It can be read through the bcdDevice field of the DFU Device Descriptor.
Workaround
• For 64-pin packages
None. The bootloader cannot be used.
• For 100-pin packages
Depending on the used peripheral, the pins for the unused peripherals have to be kept
at a high level during the bootloader activation phase as described below:
– If USART1 is used to connect to the bootloader, PD6 and PB5 have to be kept at a
high level.
– If USART2 is used to connect to the bootloader, PA10, PB5, PA11 and PA12 have
to be kept at a high level.
– If CAN2 is used to connect to the bootloader, PA10, PD6, PA11 and PA12 have to
be kept at a high level.
– If DFU is used to connect to the bootloader, PA10, PB5 and PD6 have to be kept
at a high level.
Note: This limitation applies only to STM32F105xx and STM32F107xx devices with a date code
below 937. STM32F105xx and STM32F107xx devices with a date code higher or equal to
937 are not impacted. See STM32F105xx and STM32F107xx datasheets for where to find
the date code on the device marking.
Workaround
None.
Workaround
None.
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
yes
If Value
@0x08080000 is
yes
within int. SRAM
address Jump to user code
in Bank2
no no
If Value
@0x08000000 is
yes
within int. SRAM
address Jump to user code
in Bank1
no
Disable all
interrupt sources
no
MS35006V1
Note: The bootloader ID format is applied to all STM32 devices families except the STM32F1xx
family. The bootloader version for the STM32F1xx applies only to the embedded device
bootloader version and not to its supported protocols.
The system clock is derived from the embedded internal high-speed RC. No external quartz
is required for the bootloader code.
System Reset
0x7F received on
USARTx
no
yes
Disable all
interrupt sources
Configure
USARTx
Execute
BL_USART_Loop
for USARTx
MS35010V1
The system clock is derived from the embedded internal high-speed RC for USARTx
bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but only for
the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
System Reset
Configure
Configure USB OTG FS
USARTx
device
Execute
0x7F received on BL_USART_Loop
USARTx for USARTx
yes
no
yes
Execute
Execute DFU BL_CAN_Loop for
bootloader using USB CANx
interrupts
MS35011V1
The bootloader has two case of operation depending on the presence of the external clock
(HSE) at bootloader startup:
• If HSE is present and has a value of 24, 18, 16, 12, 9, 8, 6, 4 or 3 MHz, the system
clock is configured to 48 MHz with HSE as clock source. The DFU interface, USART1
and USART2 are functional and can be used to communicate with the bootloader
device.
• If HSE is not present, the HSI is kept as default clock source and only USART1 and
USART2 are functional.
The external clock (HSE) must be kept if it is connected at bootloader startup because it is
used as system clock source.
System Reset
HSE= 24,
18, 16, 12, 9, 8, 6, 4, no
3 MHz ?
Yes
yes
USB cable
Detected & USB
configured Disable all interrupt
yes
sources and other
interfaces clock’s Disable other
no interfaces clock’s
Configure
USARTx
0x7F received on
Execute DFU
USARTx
no Execute bootloader using USB
BL_USART_Loop interrupts
for USARTx
MS35027V1
The bootloader has two case of operation depending on the presence of the external clock
(HSE) at bootloader startup:
• If HSE is present and has a value of 24, 18, 16, 12, 9, 8, 6, 4 or 3 MHz, the system
clock is configured to 48 MHz with HSE as clock source. The DFU interface, USART1
and USART2 are functional and can be used to communicate with the bootloader
device.
• If HSE is not present, the HSI is kept as default clock source and only USART1 and
USART2 are functional.
The external clock (HSE) must be kept if it is connected at bootloader startup because it is
used as system clock source.
System Reset
yes
Configure USB
yes
USB configured
and cable Detected yes Execute DFU
Disable all bootloader using USB
interrupt sources interrupts
no
Configure
0x7F received USARTx
no on USARTx
Execute
BL_USART_Loop
for USARTx
MS35016V3
The bootloader has two cases of operation depending on the presence of the external clock
(HSE) at bootloader startup:
• If HSE is present and has a value of 24, 18, 16, 12, 9, 8, 6, 4 or 3 MHz, the system
clock is configured to 48 MHz with HSE as clock source. The DFU interface, USART1
and USART2 are functional and can be used to communicate with the bootloader
device.
• If HSE is not present, the HSI is kept as default clock source and only USART1 and
USART2 are functional.
The external clock (HSE) must be kept if it is connected at bootloader startup because it is
used as system clock source.
System Reset
yes
Reconfigure System clock to
48 MHz using HSE
System Init (Clock, GPIOs,
IWDG, SysTick)
USB cable
detected & USB yes
configured yes
Disable other
Configure USARTx interfaces clock’s
0x7F received on
no USARTx
Execute Execute DFU
BL_USART_Loop for bootloader using USB
USARTx interrupts
MSv36790V1
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Disable all
interrupt sources
Configure I2Cx
yes
I2C Address
detected yes Execute
BL_I2C_Loop for
Configure
I2Cx
USARTx
no
Execute
0x7F received on BL_USART_Loop
USARTx for USARTx
no
MS35029V2
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Disable all
interrupt sources
Configure I2Cx
yes
I2C Address
detected yes Execute
BL_I2C_Loop for
Configure
I2Cx
USARTx
no
Execute
0x7F received on BL_USART_Loop
USARTx for USARTx
no
MS35028V2
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Disable all
interrupt sources
Configure I2Cx
yes
I2C Address
detected yes Execute
BL_I2C_Loop for
Configure
I2Cx
USARTx
no
Execute
0x7F received BL_USART_Loop
on USARTx for USARTx
no
MS35019V2
The bootloader has two case of operation depending on the presence of the external clock
(HSE) at bootloader startup:
• If HSE is present and has a value of 24, 18, 16, 12, 9, 8, 6, 4 or 3 MHz, the system
clock is configured to 48 MHz with HSE as clock source. The DFU interface, USART1
and USART2 are functional and can be used to communicate with the bootloader
device.
• If HSE is not present, the HSI is kept as default clock source and only USART1 and
USART2 are functional.
Note: The external clock (HSE) must be kept if it is connected at bootloader startup because it is
used as system clock source.
System Reset
HSE = 24,
18, 16, 12, 9, 8, 6, 4,
3 MHz
no
yes
Configure USB
yes
USB configured
and cable Detected Execute DFU
yes Disable all bootloader using USB
interrupt sources interrupts
no
Configure
0x7F received USARTx
no on USARTx
Execute
BL_USART_Loop
for USARTx
MS35016V4
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
Disable all
interrupt sources
Configure I2Cx
yes
I2C Address
detected yes Execute
BL_I2C_Loop for
Configure
I2Cx
USARTx
no
Execute
0x7F received BL_USART_Loop
on USARTx for USARTx
no
MS35018V2
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
System Reset
Disable all
interrupt sources
Configure I2Cx
MSv36791V1
The system clock is derived from the embedded internal high-speed RC for USARTx
bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but only for
the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
Configure
Configure USB OTG FS
USARTx
device
Execute
0x7F received on BL_USART_Loop
USARTx for USARTx
yes
no
yes
Execute
Execute DFU BL_CAN_Loop for
bootloader using USB CANx
interrupts
MS35012V3
The system clock is derived from the embedded internal high-speed RC for USARTx, I2Cx
and SPIx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device)
but only for the selection phase. An external clock multiple of 1 MHz (between 4 and
26 MHz) is required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
Execute
0x7F received on
USARTx BL_USART_Loo
p for USARTx
no yes
Frame detected
on CANx no HSE detected
yes
no HSE detected no
Generate System
yes
Yes reset
USB cable
Detected
Reconfigure System
clock to 60MHz and Disable all
Disable all interrupt USB clock to 48 MHz interrupt sources
no sources
no
yes
Reconfigure System
Execute DFU clock to 60MHz
Execute
I2Cx Address BL_I2C_Loop for bootloader using
Detected I2Cx USB interrupts
Configure CAN
yes
no Execute
Disable all BL_CAN_Loop for
interrupt sources CANx
SPIx detects
Synchro
mechanism Execute
BL_SPI_Loop for
SPIx
MS35012V2
The system clock is derived from the embedded internal high-speed RC for USARTx, I2Cx
and SPIx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device)
but only for the selection phase. An external clock multiple of 1 MHz (between 4 and
26 MHz) is required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
no
The system clock is derived from the embedded internal high-speed RC for USARTx, I2Cx
and SPIx bootloaders. This internal clock is also used for DFU (USB FS Device) but only for
the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
no
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
System Reset
Configure I2Cx
Configure SPIx
0x7F received
yes
on USARTx
no
I2Cx Address
yes
Detected
Configure USARTx
SPIx detects Synchro yes
mechanism
MSv38431V2
The system clock is derived from the embedded internal high-speed RC for USARTx, I2Cx
and SPIx bootloaders. This internal clock is also used for DFU (USB FS Device) but only for
the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
no
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
no
yes
I2Cx Address
Detected
no
HSE detected no no HSE detected
no Configure CANx
Execute DFU
bootloader using USB
USB cable interrupts Execute
yes
Detected BL_CAN_Loop for
CANx
MSv38454V2
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
no
yes
I2C Address
Detected
no
HSE detected no no HSE detected
no Configure CAN
Execute DFU
bootloader using USB
USB cable interrupts Execute
yes
Detected BL_CAN_Loop for
CAN2
MSv42229V1
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
Figure 40. Dual bank boot implementation for STM32F42xxx/43xxx Bootloader V7.x
System Reset
If Boot0 = 0
yes
no
If Value of first
address of Bank2 is
yes
within int. SRAM
address(1)
Protection level2 no
Set Bank Swap to
enabled
Bank2
no
Protection level2 no
yes
enabled
Set Bank Swap to Set Bank Swap to Set Bank Swap to
Bank1 Bank1 Bank2
no
MS35021V1
1. CCM RAM is not considered valid as stack pointer address for the dual bank boot mechanism.
Bootloader
Configure
Configure I2Cx USARTx
Execute
0x7F received BL_USART_Loop
on USARTx for USARTx
yes
no
Execute
BL_I2C_Loop for
I2Cx
I2C Address
Detected yes
HSE detected
no no
yes yes
Frame detected
no on CANx HSE detected no Disable all
interrupt sources
Generate System
no yes reset
Reconfigure System
clock to 60MHz
Reconfigure System
USB cable clock to 60MHz and
Detected USB clock to 48 MHz Configure CAN
MS35022V1
The system clock is derived from the embedded internal high-speed RC for USARTx, I2Cx
and SPIx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device)
but only for the selection phase. An external clock multiple of 1 MHz (between 4 and
26 MHz) is required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
Figure 42. Dual bank boot implementation for STM32F42xxx/43xxx bootloader V9.x
System Reset
If Boot0 = 0
yes
no
If Value of first
address of Bank2 is
yes
within int. SRAM
address(1) Protection level2
no
Set Bank Swap to enabled
Bank2
no
Protection level2 no
yes
enabled
Set Bank Swap to Set Bank Swap to Set Bank Swap to
Bank1 Bank1 Bank2
no
MS35023V1
1. CCM RAM is not considered valid as stack pointer address for the dual bank boot mechanism.
Bootloader
Execute
BL_USART_Loop for
0x7F received USARTx
on USARTx
no Execute
BL_I2C_Loop for
yes
I2Cx
I2C Address
Detected
Execute
no
yes BL_SPI_Loop for
SPIx
Synchro
mechanism detected
on SPIx yes
no HSE detected
no
HSE detected
Frame detected yes
no yes no
on CANx
Disable all interrupt
sources
yes
no Generate System
reset
Reconfigure System clock
Reconfigure System to 60MHz
USB cable clock to 60MHz and
Detected USB clock to 48 MHz
Configure CAN
MS35024V1
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
Disable all
System Init (Clock, GPIOs,
interrupt sources
IWDG, SysTick)
yes
Configure
Configure USB OTG FS
USARTx
device
Execute
Configure I2Cx BL_USART_Loop
for USARTx
0x7F received
on USARTx
Disable all
yes interrupt sources
no
Execute
I2C Address BL_I2C_Loop for
Detected I2Cx
Execute
Synchro mechanism BL_SPI_Loop for
detected on SPIx SPIx
yes
no HSE detected
no
no
yes yes
Frame detected
on CANx HSE detected no Disable all
interrupt sources
Generate System
yes reset
no Reconfigure System
clock to 60MHz
Reconfigure System
clock to 60MHz and
USB cable USB clock to 48 MHz Configure CAN
Detected
MSv36763V1
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 48 MHz) is
required for CAN and DFU bootloaders execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
Figure 45. Dual bank boot implementation for STM32F469xx/479xx Bootloader V9.x
System Reset
If Boot = 0 no
yes
If value of
first address of Bank2
yes
is within int. SRAM
address
Set Bank Swap to
Bank2
no
Jump to user code Protection
no
in Bank2 level2 enabled
Continue Bootloader
If value of
execution
first address of Bank1
yes
is within int. SRAM yes
address
no If value of
first address of Bank2
yes
is within int. SRAM
Protection address
yes
level2 enabled
no
Continue Bootloader Jump to user code Jump to user code Jump to user code
execution in Bank1 in Bank1 in Bank2
MSv38429V1
Bootloader
0x7F received
yes
on USARTx
no
I2C Address
yes
Detected
no
no HSE detected
Frame detected
yes
on CANx Reconfigure
Reconfigure System System clock to
clock to 60MHz and 60MHz
USB clock to 48 MHz
no
Configure CAN
Execute DFU
USB cable bootloader using USB
yes
Detected interrupts
Execute
BL_CAN_Loop for
CAN2
no
MSv38430V2
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
6\VWHP5HVHW
6\VWHP,QLW&ORFN*3,2V
,:'*6\V7LFN \HV
&RQILJXUH86%27*)6
GHYLFH \HV
'LVDEOHDOOLQWHUUXSW
\HV VRXUFHVDQGRWKHU
LQWHUIDFHVFORFNV
&RQILJXUH,&[
'LVDEOHDOOLQWHUUXSW 'LVDEOHDOOLQWHUUXSW
VRXUFHVDQGRWKHU VRXUFHVDQGRWKHU &RQILJXUH
LQWHUIDFHVFORFNV LQWHUIDFHVFORFNV 86$57[
&RQILJXUH63,[
QR
\HV
,&$GGUHVV
'HWHFWHG
QR
+6(GHWHFWHG QR QR +6(GHWHFWHG
6\QFKURPHFKDQLVP *HQHUDWH6\VWHP
GHWHFWHGRQ63,[ \HV UHVHW \HV
'LVDEOHDOOLQWHUUXSW
'LVDEOHRWKHU
VRXUFHVDQGRWKHU
QR LQWHUIDFHVFORFNV
LQWHUIDFHVFORFNV
QR
QR &RQILJXUH&$1
([HFXWH')8
ERRWORDGHUXVLQJ86%
86%FDEOH LQWHUUXSWV ([HFXWH
\HV
'HWHFWHG %/B&$1B/RRSIRU
&$1[
06Y9
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
yes
Execute Execute
BL_I2C_Loop BL_USART_Loop
0x7F received on for I2Cx for USARTx
USARTx
yes
no
I2C Address
Detected HSE detected no no HSE detected
no Generate System
yes reset yes
MSv37792V1
The system clock is derived from the embedded internal high-speed RC for USARTx, I2Cx
and SPIx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device)
but only for the selection phase. An external clock multiple of 1 MHz (between 4 and
26 MHz) is required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
System Reset
no
yes
I2C Address
Detected
no
HSE detected no no HSE detected
no Configure CAN
Execute DFU
bootloader using USB
USB cable interrupts Execute
yes
Detected BL_CAN_Loop for
CAN2
MSv36793V1
The system clock is derived from the embedded internal high-speed RC for USARTx and
I2Cx bootloaders. This internal clock is also used for CAN and DFU (USB FS Device) but
only for the selection phase. An external clock multiple of 1 MHz (between 4 and 26 MHz) is
required for CAN and DFU bootloader execution after the selection phase.
Note: Due to HSI deviation and since HSI is used to detect HSE value, the user must use low
frequency rather than high frequency HSE crystal values (low frequency values are better
detected due to larger error margin). For example, it is better to use 8 MHz instead of
25 MHz.
Figure 50. Dual bank boot implementation for STM32F76xxx/77xxx Bootloader V9.x
System Reset
nDBANK = 0 &
yes
nDBOOT = 0
no
If boot address is in
yes
Bank2
no
Jump to address
defined by
BOOT_ADDx
If boot address is in
no yes
Bank1
Set Bank Swap to
Bank1
no
Jump to address
defined by
BOOT_ADDx
Protection level2
yes
enabled
no
Jump to AXIM-Flash
Continue Bootloader
base address 0x0800
execution
0000
MSv38482V2
1. Only BOOT_ADD0 value is considered whatever the BOOT0 pin state, as described in Known limitation under Table 88.
2. ITCM RAM is not considered valid as stack pointer address for the dual bank boot mechanism.
Bootloader
I2C Address
Detected HSE detected no no HSE detected
Generate System
no reset
yes yes
MSv38483V2
Note: On SO8, WLCSP18, TSSOP20 and UFQFN28 packages USART1 PA9/PA10 IOs are
remapped on PA11/PA12.
System Reset
Configure I2Cx
0x7F received on
yes
USARTx
yes
no
Disable all interrupt
Disable all interrupt
sources and other
sources and other
no I2Cx Address
Detected interfaces clock’s interfaces clock’s
Execute Configure
BL_I2C_Loop for USARTx
I2Cx
Execute
BL_USART_Loop
for USARTx
MS52813V1
Bootloader
Configure I2Cx
yes
Configure SPIx
yes
0x7F received
on USARTx yes
Disable all other
no interfaces clocks
no
Execute Execute Execute
BL_SPI_Loop BL_I2C_Loop BL_USART_Loop
no for SPIx for I2Cx for USARTx
Synchro mechanism
detected on SPIx
MS51450V1
System Reset
yes
Reconfigure System clock to
60 MHz using HSE System Init (Clock, GPIOs,
IWDG, SysTick)
Configure USB
Configure I2Cx
yes
Configure SPIx
Disable all interrupt
sources and other
interfaces clock’s
0x7F received
Disable all interrupt
on USARTx
sources and other Configure
interfaces clock’s USARTx
no
Disable all interrupt
sources and other Execute Execute
interfaces clocks BL_I2C_Loop for
I2Cx Address BL_USART_Loop
I2Cx for USARTx
Detected
Execute
BL_SPI_Loop
for SPIx
no
USB cable
Detected & USB Execute DFU
configured bootloader using USB
interrupts
MS54534V2
System Reset
Configure I2Cx
no
I2C Address
yes
Detected
no
no
Execute DFU
Synchro mechanism yes bootloader using USB
detected on SPIx
interrupts
no
MS52834V1
System Reset
Configure I2Cx
0x7F received on
yes
USARTx
yes
no
Disable all interrupt
Disable all interrupt
sources and other
sources and other
no I2Cx Address
Detected interfaces clock’s interfaces clock’s
Execute Configure
BL_I2C_Loop for USARTx
I2Cx
Execute
BL_USART_Loop
for USARTx
MS52813V1
System Reset
no
I2C Address
yes
Detected
no
Disable other
Synchro mechanism interfaces clocks
yes
detected on SPIx
Execute DFU
bootloader using USB
no
interrupts
no
MS51432V1
System Reset
no
I2C Address
yes
Detected
no
Disable other
Synchro mechanism interfaces clocks
yes
detected on SPIx
Execute DFU
bootloader using USB
no
interrupts
no
MS51432V1
Figure 59. Dual bank boot implementation for STM32G47xxx/48xxx bootloader V13.x
System Reset
If Boot from
FLASH
no
yes
V13.3 (0xD3) Initial bootloader version Boot from bank2 is not working
System Reset
no
I2C Address
yes
Detected
no
Disable other
Synchro mechanism interfaces clocks
yes
detected on SPIx
Execute DFU
bootloader using USB
no
interrupts
no
MS51432V1
System Reset
Configure
USB OTG FS Device
Configure I2Cx
no
I2Cx address
yes
detected
no
SPIx detects
no Synchro yes
mechanism
no
MS54027V2
Note: To connect to the bootloader USART1 using PB14/PB15 pins, user must send two
synchronization bytes.
DFU mode does not support USBREGEN mode. If STM32 is powered by 1.8 V source, it is
not possible to use the BL DFU unless 3.3 V is provided
System Reset
Configure
USB OTG FS Device
Configure I2Cx
no
I2Cx address
yes
detected
no
SPIx detects
no Synchro yes
mechanism
no
MSv45966V4
System Reset
Configure
USB OTG FS Device
Configure I2Cx
no
I2Cx address
yes
detected
no
SPIx detects
no Synchro yes
mechanism
no
MSv45966V4
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
Note: Due to empty check mechanism present on this product, it is not possible to jump from user
code to system bootloader. Such jump results in a jump back to user Flash memory space.
But if the first 4 bytes of user lash memory (at 0x0800 0000) are empty at the moment of the
jump (i.e. erase first sector before jump or execute code from SRAM while Flash is empty),
then system bootloader is executed when jumped to.
System Reset
Disable all
interrupt sources
Configure SPIx
0x7F received
yes
on USARTx
MSv38476V1
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
The bootloader Read/Write commands do not support SRAM space for this product.
System Reset
Disable all
interrupt sources
Configure SPIx
0x7F received on
yes
USARTx
Disable all other
interfaces clocks
no
yes Configure
Disable all other USARTx
interfaces clocks
SPIx detects
no Execute
Synchro
BL_USART_Loop
mechanism Execute for USARTx
BL_SPI_Loop for
SPIx
MS35035V1
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
System Reset
Disable all
interrupt sources
Configure SPIx
0x7F received on
yes
USARTx
Disable all other
interfaces clocks
no
yes Configure
Disable all other USARTx
interfaces clocks
SPIx detects
no Execute
Synchro
BL_USART_Loop
mechanism Execute for USARTx
BL_SPI_Loop for
SPIx
MS35035V1
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
Figure 67. Dual bank boot implementation for STM32L07xxx/08xxx bootloader V4.x
System Reset
If Boot0 = 0 no
yes
If Value of first
address of Bank2 is Protection
within int. SRAM
yes no
level2 enabled
address
Set Bank Swap to
Bank2
Continue Bootloader
no Jump to user yes
execution
code in Bank2
no
no
Protection
level2 enabled
yes
Continue Bootloader
Jump to user Jump to user Jump to user
execution
code in Bank1 code in Bank1 code in Bank2
MSv38477V1
Bootloader
0x7F received on
yes
USARTx
Disable all
interrupt sources
no
Configure
USARTx
USB cable
yes
Detected
no Execute
Execute DFU bootloader BL_USART_Loop
using USB interrupts for USARTx
MSv38442V1
The system clock is derived from the embedded internal high-speed RC for all bootloader
interfaces. No external quartz is required for bootloader operations.
Figure 69. Dual bank boot implementation for STM32L07xxx/08xxx bootloader V11.x
System Reset
If Boot0 = 0 no
yes
If Value of first
address of Bank2 is Protection
within int. SRAM
yes no
level2 enabled
address
Set Bank Swap to
Bank2
Continue Bootloader
no Jump to user yes
execution
code in Bank2
no
no
Protection
level2 enabled
yes
Continue Bootloader
Jump to user Jump to user Jump to user
execution
code in Bank1 code in Bank1 code in Bank2
MSv38477V1
Bootloader
Disable all
interrupt sources
Configure I2Cx
Configure SPIx
0x7F received
yes
on USARTx
no
I2Cx Address
yes
detected
no
yes Disable all other
no interfaces clocks
MSv38443V2
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
0x7F received on
USARTx
no yes
Disable all
interrupt sources
Configure
USARTx
Execute
BL_USART_Loop
for USARTx
MS35033V1
The system clock is derived from the embedded internal high-speed RC, no external quartz
is required for the bootloader execution.
System Reset
0x7F received on
USARTx
no yes
Disable all
interrupt sources
Configure
USARTx
Execute
BL_USART_Loop
for USARTx
MS35007V1
The system clock is derived from the embedded internal high-speed RC for the USARTx
bootloader. This internal clock is also used the for DFU bootloader but only for the selection
phase. An external clock in the range of [24, 16, 12, 8, 6, 4, 3, 2] MHz is required for the
execution of the DFU bootloader after the selection phase.
System Reset
Configure USB
USB cable
yes
Detected
no
Generate System
yes yes reset
Reconfigure System
Disable all clock to 32MHz and
interrupt sources USB clock to 48 MHz
Configure
Execute DFU
USARTx
bootloader using USB
interrupts
Execute
BL_USART_Loop
for USARTx
MS35008V1
The system clock is derived from the embedded internal high-speed RC for USARTx
bootloader. This internal clock is used also for DFU bootloader but only for the selection
phase. An external clock in the range of [24, 16, 12, 8, 6, 4, 3, 2] MHz is required for DFU
bootloader execution after the selection phase.
System Reset
Protection
no yes
level2 enabled
If Value
@0x08030000 is
yes yes
within int. SRAM
address Jump to user code
in Bank2 If Value
no no @0x08030000 is
yes
within int. SRAM
If Value address
@0x08000000 is Jump to user code
yes in Bank2
within int. SRAM
address Jump to user code no
in Bank1
no If Value
@0x08000000 is
Continue Bootloader execution yes
within int. SRAM
address
Jump to user code
Disable all in Bank1
interrupt sources no
CPU blocked
System Init (Clock, GPIOs, (halted)
IWDG, SysTick)
Configure USB
yes
yes
no yes
The system clock is derived from the embedded internal high-speed RC for USARTx
bootloader. This internal clock is used also for DFU bootloader but only for the selection
phase. An external clock in the range of [24, 16, 12, 8, 6, 4, 3, 2] MHz is required for DFU
bootloader execution after the selection phase.
System Reset
no
yes yes
If Value
no If Value @0x08040000 is @0x08040000 is within yes
yes
within int. SRAM address int. SRAM address
Configure USB
Reconfigure System
clock to 32MHz and
USB cable USB clock to 48 MHz
detected
yes
no yes
Execute DFU
bootloader using USB
0x7F received interrupts
Configure USARTx
on USARTx
Execute BL_USART_Loop
no for USARTx
MS35034V3
Note: If VDDUSB pin is not connected to VDD, then SPI Flash memory write operations may be
corrupted due to voltage issue. For more details, please refer to product’s datasheet and
errata sheet.
Figure 76. Dual bank boot Implementation for STM32L412xx/422xx bootloader V9.x
System Reset
If Boot0 = 0
yes
no
If Value of first
address of Bank2 is
yes
within int. SRAM
address(1)
Protection level2 no
Set Bank Swap to
enabled
Bank2
no
Protection level2 no
yes
enabled
Set Bank Swap to Set Bank Swap to Set Bank Swap to
Bank1 Bank1 Bank2
no
MS35021V1
System Reset
no
I2C Address
yes
Detected
no
Disable other
Synchro mechanism interfaces clocks
yes
detected on SPIx
Execute DFU
bootloader using USB
no
interrupts
no
MS51432V1
Note: If VDDUSB pin is not connected to VDD, then SPI Flash memory write operations may be
corrupted due to voltage issue. For more details, please refer to product’s datasheet and
errata sheet.
Figure 78. Dual bank boot Implementation for STM32L3x2xx/44xxx bootloader V9.x
System Reset
If Boot0 = 0
yes
no
If Value of first
address of Bank2 is
yes
within int. SRAM
address(1)
Protection level2 no
Set Bank Swap to
enabled
Bank2
no
Protection level2 no
yes
enabled
Set Bank Swap to Set Bank Swap to Set Bank Swap to
Bank1 Bank1 Bank2
no
MS35021V1
System Reset
Configure SPIx
0x7F received on
USARTx yes
HSE detected no
no
Generate System
I2C Address yes reset
yes
Detected
Disable all interrupt
sources and other
no
interfaces clocks
no
Disable other Configure CAN
no interfaces clocks
Frame detected
on CANx yes
Execute DFU Execute
bootloader using USB BL_CAN_Loop for
no interrupts CANx
USB cable
yes
Detected
MSv38484V1
Note: If VDDUSB pin is not connected to VDD, then SPI Flash memory write operations may be
corrupted due to voltage issue. For more details, please refer to product’s datasheet and
errata sheet.
Figure 80. Dual bank boot Implementation for STM32L45xxx/46xxx bootloader V9.x
System Reset
If Boot0 = 0
yes
no
If Value of first
address of Bank2 is
yes
within int. SRAM
address(1)
Protection level2 no
Set Bank Swap to
enabled
Bank2
no
Protection level2 no
yes
enabled
Set Bank Swap to Set Bank Swap to Set Bank Swap to
Bank1 Bank1 Bank2
no
MS35021V1
System Reset
no
I2C Address
yes
Detected HSE detected no
Generate System
no reset
yes
Reconfigure System
no clock to 60 MHz
no
MSv45964V1
Figure 82. Dual bank boot implementation for STM32L47xxx/48xxx bootloader V10.x
System Reset
If Boot0 = 0
no
yes
Bootloader
LSE detected no
yes
Configure USB clock to 48
MHz with HSI as clock source
Configure USB clock to 48
MHz with MSI as clock source
0x7F received
on USARTx
Disable all
yes
interrupt sources
no
Execute
BL_I2C_Loop for
I2C Address I2Cx
Detected yes
MSI used as USB
no
clock source
no
yes HSE detected no
In case, the HSE is present, the system clock and USB clock is configured respectively to
72 MHz and 48 MHz with PLL (clocked by HSE) as a clock source.
Note: If VDDUSB pin is not connected to VDD, then SPI Flash memory write operations may be
corrupted due to voltage issue. For more details, please refer to product’s datasheet and
errata sheet.
Figure 84. Dual bank boot implementation for STM32L47xxx/48xxx bootloader V9.x
System Reset
If Boot0 = 0
no
yes
Bootloader
LSE detected no
yes
System Init(Clock,
GPIOs,IWDG,Systick)
Configure USB OTG FS device Disable all interrupt Disable all interrupt sources
Disable all interrupt sources
sources and other and other interfaces clocks
and other interfaces clocks
interfaces clocks
0x7F received on
yes
USARTx
MSI used as USB clock
no source
yes
I2C Address
yes no
Detected
no
HSE detected no no HSE detected
Synchro mechanism yes
detected on SPIx yes
yes
no yes Generate System yes
Reconfigure System reset
no USB cable clock to 60 MHz
Detected Reconfigure System clock
to 72 MHz and USB clock
no Configure CAN to 48 MHz
Frame yes
detected on Execute
CANx BL_CAN_Loop Execute DFU bootloader
for CANx using USB interrupts
MSv38404V1
Note: If VDDUSB pin is not connected to VDD, then SPI Flash memory write operations may be
corrupted due to voltage issue. For more details, please refer to product’s datasheet and
errata sheet.
Figure 86. Dual bank boot Implementation for STM32L496xx/4A6xx bootloader V9.x
System Reset
If Boot0 = 0
yes
no
If Value of first
address of Bank2 is
yes
within int. SRAM
address(1)
Protection level2 no
Set Bank Swap to
enabled
Bank2
no
Protection level2 no
yes
enabled
Set Bank Swap to Set Bank Swap to Set Bank Swap to
Bank1 Bank1 Bank2
no
MS35021V1
System Reset
no
I2C Address
yes HSE detected no
Detected
Generate System
no reset
yes
Reconfigure System
no clock to 60 MHz
no
MSv44808V1
Figure 88. Dual bank boot implementation for STM32L4P5xx/4Q5xx bootloader V9.x
System Reset
If Boot0 = 0
no
yes
System Reset
Configure I2Cx
Configure SPIx
no
HSE detected no
Synchro mechanism
yes
detected on SPIx
Generate
yes System reset
Frame detected on
Reconfigure System
CANx
clock to 60 MHz
Disable other
no interfaces clocks Configure CAN
MS49689V1
Figure 90. Dual bank boot implementation for STM32L4Rxxx/STM32L4Sxxx bootloader V9.x
System Reset
If Boot0 = 0
no
yes
System Reset
Configure I2Cx
Configure SPIx
no
HSE detected no
Synchro mechanism
yes
detected on SPIx
Generate
yes System reset
Frame detected on
Reconfigure System
CANx
clock to 60 MHz
Disable other
no interfaces clocks Configure CAN
MS49689V1
Number of
Sub- Number of Number of status
Data Status data
Function Opcode data sent Data sent data data
received received
(2 bytes) (2 bytes) received received
(2 bytes)
Trust zone
disable
Must be run when 0x82 0x4 0x0 0x0 NA 0x1 0x0
TZEN = 1 and
RDP = 1
Regression from
RDP L1 to RDP
0.5
0x82 0x4 0x1 0x0 NA 0x1 0x0
Must be run when
TZEN = 1 and
RDP = 1
Note: USB special commands are slightly different from the other protocols as per the USB
protocol specificities:
• No Opcode is used, Sub-Opcode is used directly
• Sub-Opcode is treated in a single byte and not two bytes
• Data is sent on USB frame byte per byte. No need to add number of data to be
transmitted
• Returned data and status is formatted on the USB native protocol
System Reset
Configure I2Cx
no
I2C Address
yes
Detected
no
no
Execute DFU
Synchro mechanism yes bootloader using USB
detected on SPIx
interrupts
no
MS52834V1
Bootloader
Disable all
interrupt sources
Configure I2Cx
Configure SPIx
0x7F received
yes
on USARTx
no
I2Cx Address
yes
detected
no
yes Disable all other
no interfaces clocks
MSv38443V2
System Reset
Configure I2Cx
Configure SPIx
no
Synchro mechanism
yes
detected on SPIx
no
Disable other
interfaces clocks
no
Execute DFU
USB cable bootloader using
yes
Detected USB interrupts
MS51473V1
Note: Instability when performing multiple resets during operations ongoing causing Overrun or
FrameError errors on USART Bootloader and not recoverable unless Hardware Reset is
performed. Fixed by workaround in FUS V1.0.1 and V1.0.2.
System Reset
Disable all
interrupt sources
Configure SPIx
0x7F received
yes
on USARTx
MSv38476V1
Number of
Sub- Number of Number of status
Data Status data
Function Opcode data sent Data sent data data
received received
(2 bytes) (2 bytes) received received
(2 bytes)
Trust zone
disable
Must be run when 0x82 0x4 0x0 0x0 NA 0x1 0x0
TZEN = 1 and
RDP = 1
Regression from
RDP L1 to RDP
0.5
0x82 0x4 0x1 0x0 NA 0x1 0x0
Must be run when
TZEN = 1 and
RDP = 1
Unlock write
protection
0x82 0x4 0xYY02(1) 0x0 NA 0x1 0x0
Must be run when
RDP = 1
1. 0xYY can have 4 values (0: WRP area, 1: WRP1A, 2: WRP2A, 3: WRP1B, 4: WRP2B)
Note: USB special commands are slightly different from the other protocols as per the USB
protocol specificities:
• No Opcode is used, Sub-Opcode is used directly
• Sub-Opcode is treated in a single byte and not two bytes
• Data is sent on USB frame byte per byte. No need to add number of data to be
transmitted
• Returned data and status is formatted on the USB native protocol
System Reset
Configure I2Cx
no
I2C Address
yes
Detected
no
no
Execute DFU
Synchro mechanism yes bootloader using USB
detected on SPIx
interrupts
no
MS52834V1
The bootloader protocol command set and sequences for each serial peripheral are the
same for all STM32 devices. However, some parameters depend on device and bootloader
version:
• PID (Product ID)
• Valid RAM memory addresses (RAM area used during bootloader execution is not
accessible) accepted by the bootloader when the Read Memory, Go and Write Memory
commands are requested.
• System Memory area.
Table 159 shows the values of these parameters for each STM32 device.
0x20000000 -
STM32C011xx 0x443 0x51
0x20002FFF 0x1FFF0000 -
C0
0x20002000 - 0x1FFF17FF
STM32C031xx 0x453 0x52
0x200017FF
0x20000800 -
STM32F05xxx and STM32F030x8 0x440 0x21
0x20001FFF 0x1FFFEC00 -
0x20000800 - 0x1FFFF7FF
STM32F03xx4/6 0x444 0x10
0x20000FFF
0x20001800 - 0x1FFFD800 -
STM32F030xC 0x442 0x52
0x20007FFF 0x1FFFF7FF
0x1FFFC400 -
STM32F04xxx 0x445 0xA1 NA
0x1FFFF7FF
F0
0x1FFFC400 -
STM32F070x6 0x445 0xA2 NA
0x1FFFF7FF
0x1FFFC800 -
STM32F070xB 0x448 0xA2 NA
0x1FFFF7FF
0x20001800 - 0x1FFFC800 -
STM32F071xx/072xx 0x448 0xA1
0x20003FFF 0x1FFFF7FF
0x1FFFD800 -
STM32F09xxx 0x442 0x50 NA
0x1FFFF7FF
0x20000200 -
Low-density 0x412 NA
0x200027FF
0x20000200 -
Medium-density 0x410 NA
0x20004FFF
0x20000200 - 0x1FFFF000 -
STM32F10xxx High-density 0x414 NA
0x2000FFFF 0x1FFFF7FF
Medium-density value 0x20000200 -
F1 0x420 0x10
line 0x20001FFF
0x20000200 -
High-density value line 0x428 0x10
0x20007FFF
0x20001000 - 0x1FFFB000 -
STM32F105xx/107xx 0x418 NA
0x2000FFFF 0x1FFFF7FF
0x20000800 - 0x1FFFE000 -
STM32F10xxx XL-density 0x430 0x21
0x20017FFF 0x1FFFF7FF
0x20 0x20002000 - 0x1FFF0000 -
F2 STM32F2xxxx 0x411
0x33 0x2001FFFF 0x1FFF77FF
0x20001400 -
STM32F373xx 0x41
0x20007FFF
0x432
0x20001000 -
STM32F378xx 0x50
0x20007FFF
STM32F302xB(C)/303xB(C) 0x41 0x20001400 -
0x422
STM32F358xx 0x50 0x20009FFF
0x20002000 -
0x31
0x2001FFFF
STM32F40xxx/41xxx 0x413
0x20003000 -
0x91
0x2001FFFF
0x70 0x20003000 -
STM32F42xxx/43xxx 0x419
0x91 0x2002FFFF
0x20003000 -
STM32F401xB(C) 0x423 0xD1
0x2000FFFF
0x20003000 -
STM32F401xD(E) 0x433 0xD1
0x20017FFF
0x20003000 - 0x1FFF0000 -
F4 STM32F410xx 0x458 0xB1
0x20007FFF 0x1FFF77FF
0x20003000 -
STM32F411xx 0x431 0xD0
0x2001FFFF
0x20003000 -
STM32F412xx 0x441 0x90
0x2003FFFF
0x20003000 -
STM32F446xx 0x421 0x90
0x2001FFFF
0x20003000 -
STM32F469xx/479xx 0x434 0x90
0x2005FFFF
0x20003000 -
STM32F413xx/423xx 0x463 0x90
0x2004FFFF
0x20004000 - 0x1FF00000 -
STM32F72xxx/73xxx 0x452 0x90
0x2003FFFF 0x1FF0EDBF
0x20004000 - 0x1FF00000 -
0x70
0x2004FFFF 0x1FF0EDBF
F7 STM32F74xxx/75xxx 0x449
0x20004000 - 0x1FF00000 -
0x90
0x2004FFFF 0x1FF0EDBF
0x20004000 - 0x1FF00000 -
STM32F76xxx/77xxx 0x451 0x93
0x2007FFFF 0x1FF0EDBF
0x20001000 - 0x1FFF0000 -
STM32G03xxx/04xxx 0x466 0x52
0x20001FFF 0x1FFF1FFF
0x20002700 - 0x1FFF0000 -
STM32G07xxx/08xxx 0x460 0xB2
0x20009000 0x1FFF6FFF
0x1FFF0000 -
0x20004000 - 0x1FFF6FFF
STM32G0B0xx 0x467 0xD0
0x20020000 0x1FFF8000 -
G0
0x1FFFEFFF
0x1FFF0000 -
0x20004000 - 0x1FFF6FFF
STM32G0B1xx/0C1xx 0x467 0x92
0x20020000 0x1FFF8000 -
0x1FFFEFFF
0x20001000 - 0x1FFF0000 -
STM32G05xxx/061xx 0x456 0x51
0x20002000 0x1FFF1FFF
0x20004000 – 0x1FFF0000 -
STM32G431xx/441xx 0x468 0xD4
0x20005800 0x1FFF7000
0x20004000 – 0x1FFF0000 -
G4 STM32G47xxx/48xxx 0x469 0xD5
0x20018000 0x1FFF7000
0x20004000 - 0x1FFF0000 -
STM32G491xx/A1xx 0x479 0xD2
0x2001C000 0x1FFF7000
0x20004100 -
0x2001FFFF 0x1FF00000 -
STM32H72xxx/73xxx 0x483 0x93
0x24004000 - 0x1FF1E7FF
0x2404FFFF
0x20004100 -
0x2001FFFF 0x1FF00000 -
H7 STM32H74xxx/75xxx 0x450 0x90
0x24034000 - 0x1FF1E7FF
0x2407FFFF
0x20004100 -
0x2001FFFF 0x1FF00000 -
STM32H7A3xx/B3xx 0x480 0x92
0x24034000 - 0x1FF13FFF
0x2407FFFF
0x1FF00000 -
STM32L01xxx/02xxx 0x457 0xC3 NA
0x1FF00FFF
0x20001000 - 0x1FF00000 -
STM32L031xx/041xx 0x425 0xC0
0x20001FFF 0x1FF00FFF
0x20001000 - 0x1FF00000 -
L0 STM32L05xxx/06xxx 0x417 0xC0
0x20001FFF 0x1FF00FFF
0x20001000 -
0x41
0x20004FFF 0x1FF00000 -
STM32L07xxx/08xxx 0x447
0x20001400 - 0x1FF01FFF
0xB2
0x20004FFF
0x20000800 -
STM32L1xxx6(8/B) 0x416 0x20
0x20003FFF
STM32L1xxx6(8/B)A 0x429 0x20 0x20001000 -
STM32L1xxxC 0x427 0x40 0x20007FFF 0x1FF00000 -
L1
0x1FF01FFF
0x20001000 -
STM32L1xxxD 0x436 0x45
0x2000BFFF
0x20001000 -
STM32L1xxxE 0x437 0x40
0x20013FFF
0x20002100 - 0x1FFF0000 -
STM32L412xx/422xx 0x464 0xD1
0x20008000 0x1FFF6FFF
0x20003100 - 0x1FFF0000 -
STM32L43xxx/44xxx 0x435 0x91
0x2000BFFF 0x1FFF6FFF
0x20003100 - 0x1FFF0000 -
STM32L45xxx/46xxx 0x462 0x92
0x2001FFFF 0x1FFF6FFF
0x20003000 -
0xA3
0x20017FFF 0x1FFF0000 -
L4 STM32L47xxx/48xxx 0x415
0x20003100 - 0x1FFF6FFF
0x92
0x20017FFF
0x20003100 - 0x1FFF0000 -
STM32L496xx/4A6xx 0x461 0x93
0x2003FFFF 0x1FFF6FFF
0x20003200 - 0x1FFF0000 -
STM32L4Rxx/4Sxx 0x470 0x95
0x2009FFFF 0x1FFF6FFF
0x20004000 - 0x1FFF0000 -
STM32L4P5xx/Q5xx 0x471 0x90
0x2004FFFF 0x1FFF6FFF
0x20004000 - 0x0BF90000 -
L5 STM32L552xx/562xx 0x472 0x92
0x2003FFFF 0x0BF97FFF
0x20005000 - 0x1FFF0000 -
STM32WB10xx/15xx 0x494 0xB1
0x20040000 0x1FFF7000
WB
0x20004000 - 0x1FFF0000 -
STM32WB30xx/35xx/50xx/WB55xx 0x495 0xD5
0x2000BFFF 0x1FFF7000
0x20002000 - 0x1FFF0000 -
WL STM32WLE5xx/WL55xx 0x497 0xC4
0x2000FFFF 0x1FFF3FFF
0x20004000 - 0x0BF90000 -
U5 STM32U575xx/ STM32U585xx 0x482 0x92
0x200BFFFF 0x0BF9FFFF
74 Bootloader timings
This section presents the typical timings of the bootloader firmware to be used to ensure
correct synchronization between host and STM32 device.
Two types of timings are described:
• STM32 device bootloader resources initialization duration.
• Communication interface selection duration.
After these timings the bootloader is ready to receive and execute host commands.
STM32F03xx4/6 1.612 NA
STM32F05xxx and STM32F030x8 devices 1.612 NA
STM32F04xxx 0.058 NA
STM32F071xx/072xx 0.058 NA
HSE connected 3
STM32F070x6 200
HSE not connected 230
HSE connected 6
STM32F070xB 200
HSE not connected 230
Table 160. Bootloader startup timings (ms) for STM32 devices (continued)
Minimum bootloader
Device HSE timeout
startup
STM32F09xxx 2 NA
STM32F030xC 2 NA
STM32F10xxx 1.227 NA
PA9 pin low 1.396
STM32F105xx/107xx NA
PA9 pin high 524.376
STM32F10xxx XL-density 1.227 NA
V2.x 134 NA
STM32F2xxxx
V3.x 84.59 0.790
HSE connected 45
STM32F301xx/302x4(6/8) 560.5
HSE not connected 560.8
HSE connected 43.4
STM32F302xB(C)/303xB(C) 2.236
HSE not connected 2.36
HSE connected 7.53 NA
STM32F302xD(E)/303xD
HSE not connected 146.71 NA
STM32F303x4(6/8)/334xx/328xx 0.155 NA
STM32F318xx 0.182 NA
STM32F358xx 1.542 NA
HSE connected 43.4
STM32F373xx 2.236
HSE not connected 2.36
STM32F378xx 1.542 NA
STM32F398xx 1.72 NA
V3.x 84.59 0.790
STM32F40xxx/41xxx
V9.x 74 96
STM32F401xB(C) 74.5 85
STM32F401xD(E) 74.5 85
STM32F410xx 0.614 NA
STM32F411xx 74.5 85
STM32F412xx 0.614 180
STM32F413xx/423xx 0.642 165
V7.x 82 97
STM32F429xx/439xx
V9.x 74 97
STM32F446xx 73.61 96
STM32F469xx/479xx 73.68 230
STM32F72xxx/73xxx 17.93 50
Table 160. Bootloader startup timings (ms) for STM32 devices (continued)
Minimum bootloader
Device HSE timeout
startup
STM32F74xxx/75xxx 16.63 50
STM32G03xxx/04xxx 0.390 NA
STM32G07xxx/08xxx 0.390 NA
STM32G0Bxxx/Cxxx 0.390 NA
STM32G05xxx/061xx 0.390 NA
STM32G4xxxx 0.390 NA
STM32H72xxx/73xxx 53.975 NA
STM32H74xxx/75xxx 53.975 2
STM32H7A3xx/B3xx 53.975 NA
STM32L01xxx/02xxx 0.63 NA
STM32L031xx/041xx 0.62 NA
STM32L05xxx/06xxx 0.22 NA
V4.x 0.61 NA
STM32L07xxx/08xxx
V11.x 0.71 NA
STM32L1xxx6(8/B)A 0.542 NA
STM32L1xxx6(8/B) 0.542 NA
STM32L1xxxC 0.708 80
STM32L1xxxD 0.708 80
STM32L1xxxE 0.708 200
STM32L43xxx/44xxx 0.86 100
STM32L45xxx/46xxx 0.86 NA
LSE connected 55
V10.x 100
LSE not connected 2560
STM32L47xxx/48xxx
LSE connected 55.40
V9.x 100
LSE not connected 2560.51
STM32L412xx/422xx 0.86 NA
STM32L496xx/4A6xx 76.93 100
STM32L4P5xx /Q5xx NA NA
STM32L4Rxx/4Sxx NA NA
STM32L552xx/562xx 0.390 NA
STM32WB10xx/15xx/30xx/35xx/50xx/55xx 0.390 NA
STM32WLE5xx/WL55xx 0.390 NA
STM32U575xx/85xx 0.390 NA
a b a
Bootloader
execution time
1. Receiving any other character different from 0x7F (or line glitches) will cause bootloader to start
communication using a wrong baudrate. Bootloader measures the signal length between rising edge of first
1 bit in 0x7F to the falling edge of the last 1 bit in 0x7F to deduce the baudrate value
2. Bootloader does not re-align the calculated baudrate to standard baudrate values (i.e. 1200, 9600,
115200..).
Note: For STM32F105xx/107xx line devices, PA9 pin (USB_VBUS) is used to detect the USB host
connection. The initialization of USB peripheral is performed only if PA9 is high at detection
phase which means that a host is connected to the port and delivering 5 V on the USB bus.
When PA9 level is high at detection phase, more time is required to initialize and shutdown
the USB peripheral. To minimize bootloader detection time when PA9 pin is not used, keep
PA9 state low during USART detection phase from the moment the device is reset until a
device ACK is sent.
Table 161. USART bootloader minimum timings (ms) for STM32 devices
One USART USART USART
Device
byte sending configuration connection
Table 161. USART bootloader minimum timings (ms) for STM32 devices (continued)
One USART USART USART
Device
byte sending configuration connection
Table 161. USART bootloader minimum timings (ms) for STM32 devices (continued)
One USART USART USART
Device
byte sending configuration connection
Device
reset
a
Bootloader
execution time
Bootloader
ready to start
detection phase
MSv35042V1
Note: For STM32F105xx/107xx devices, if the external HSE crystal frequency is different from
25 MHz (14.7456 MHz or 8 MHz), the device performs several unsuccessful enumerations
(with connect / disconnect sequences) before being able to establish a correct connection
with the host. This is due to the HSE automatic detection mechanism based on Start Of
Frame (SOF) detection.
Table 162. USB bootloader minimum timings (ms) for STM32 devices
Device USB connection
STM32F04xxx 350
STM32F070x6 TBD
STM32F070xB 320
HSE = 25 MHz 460
STM32F105xx/107xx HSE = 14.7465 MHz 4500
HSE = 8 MHz 13700
STM32F2xxxx 270
STM32F301xx/302x4(6/8) 300
STM32F302xB(C)/303xB(C) 300
STM32F302xD(E)/303xD 100
STM32F373xx 300
V3.x 270
STM32F40xxx/41xxx
V9.x 250
Table 162. USB bootloader minimum timings (ms) for STM32 devices (continued)
Device USB connection
STM32F401xB(C) 250
STM32F401xD(E) 250
STM32F411xx 250
STM32F412xx 380
STM32F413xx/423xx 350
V7.x
STM32F429xx/439xx 250
V9.x
STM32F446xx 200
STM32F469xx/479xx 270
STM32F72xxx/73xxx 320
STM32F74xxx/75xxx 230
STM32G0B1xx/C1xx 300
STM32G4xxxx 300
STM32H72xxx/73xxx 53.9764
STM32H74xxx/75xxx 53.9764
STM32H7A3xx/B3xx 53.9764
STM32L07xxx/08xxx 140
STM32L1xxxC 849
STM32L1xxxD 849
STM32L412xx/422xx 820
STM32L43xxx/44xxx 820
STM32L45xxx/46xxx 330
V10.x
STM32L47xxx/48xxx 300
V9.x
STM32L496xx/4A6xx 430
STM32L4P5xx/4Q5xx NA
STM32L4Rxx/4Sxx NA
STM32L552xx/L562xx 300
STM32WB30xx/35xx/50xx/55xx 300
STM32U575xx/85xx 300
a b
Bootloader
execution time
Device Bootloader
acknowledges its ready to receive
address and and execute
stretch line commands
a
Duration of start + 1 byte sending through I2C (depends on communication speed)
b Duration of I2C line stretching
MS35043V1
Note: For I2C communication, a timeout mechanism is implemented and it must be respected to
execute bootloader commands correctly. This timeout is implemented between two I2C
frames in the same command (eg: for Write memory command a timeout is inserted
between command sending frame and address memory sending frame). Also the same
timeout period is inserted between two successive data receptions or transmissions in the
same I2C frame. If the timeout period is elapsed a system reset is generated to avoid
bootloader crash.
In erase memory command and read-out unprotect command, the duration of the operation
must be taken into consideration when implementing the host side. After sending the code
of pages to be erased, the host must wait until the bootloader device performs page erasing
to complete the remaining steps of erase command.
Table 163. I2C bootloader minimum timings (ms) for STM32 devices
Start condition
I2C line
Device + one I2C byte I2C connection I2C timeout
stretching
sending
Table 163. I2C bootloader minimum timings (ms) for STM32 devices (continued)
Start condition
I2C line
Device + one I2C byte I2C connection I2C timeout
stretching
sending
Table 163. I2C bootloader minimum timings (ms) for STM32 devices (continued)
Start condition
I2C line
Device + one I2C byte I2C connection I2C timeout
stretching
sending
STM32L4Rxx/4Sxx NA NA NA NA
STM32L552xx/L562xx 0.0225 0.0020 0.0245 1000
STM32WB10xx/15xx/30xx/35xx/50xx/55xx 0.0225 0.0020 0.0245 1000
STM32U575xx/85xx 0.0225 0.0020 0.0245 1000
a b a
Bootloader
execution time
Table 164. SPI bootloader minimum timings (ms) for STM32 devices
Device One SPI byte sending Delay between two bytes SPI connection
/**
**************************************************************************
****
* @file main.c
**************************************************************************
****
*/
/* Includes ---------------------------------------------------------------
---*/
#include "main.h"
/**
* @brief Main program
* @param None
* @retval None
*/
int main(void)
{
ConfigClock();
if (exit_with_magic_number)
{
JUMP_WITH_PARAM(exit_secure_memory_address, magic_number,
application_address);
}
else
{
JUMP_WITHOUT_PARAM(exit_secure_memory_address);
}
}
/**
* @brief ConfigClock
* @param None
* @retval None
*/
static void ConfigClock(void)
{
/* Will be developped as per the template of the needed project */
}
/**
* @brief JUMP_WITHOUT_PARAM
* @param jump_address
* @retval None
*/
void JUMP_WITHOUT_PARAM(uint32_t jump_address)
{
asm ("LDR R1, [R0]"); // jump_address
asm ("LDR R2, [R0,#4]");
asm ("MOV SP, R1");
asm ("BX R2");
}
/**
* @brief JUMP_WITH_PARAM
* @param jump_address, magic, applicationVectorAddress
* @retval None
*/
void JUMP_WITH_PARAM(uint32_t jump_address, uint32_t magic, uint32_t
applicationVectorAddress))
{
asm ("MOV R3, R0"); // jump_address
asm ("LDR R0, [R3]");
asm ("MOV SP, R0");
asm ("LDR R0, [R3,#4]");
asm ("BX R0");
}
75 Revision history
IWDG added to Table : The system clock is derived from the embedded internal high-
speed RC, no external quartz is required for the bootloader execution.. Note added.
BL changed bootloader in the entire document.
Go command description modified in Table : The system clock is derived from the
embedded internal high-speed RC, no external quartz is required for the bootloader
execution.
Number of bytes awaited by the bootloader corrected in Section 2.4: Read Memory
command.
Note modified below Figure 10: Go command: host side.
19-Nov-2009 5
Note removed in Section 2.5: Go command and note added.
Start RAM address specified and note added in Section 2.6: Write Memory command.
All options are erased when a Write Memory command is issued to the Option byte
area.
Figure 11: Go command: device side modified.
Figure 13: Write Memory command: device side modified.
Note added and bytes 3 and 4 sent by the host modified in Section 2.7: Erase Memory
command.
Note added to Section 2.8: Write Protect command.
Application note restructured. Value line and connectivity line device bootloader added
09-Mar-2010 6 (Replaces AN2662).
Introduction changed. Glossary added.
Related documents: added XL-density line datasheets and programming manual.
Glossary: added XL-density line devices.
Table 3: added information for XL-density line devices.
20-Apr-2010 7 Section 4.1: Bootloader configuration: updated first sentence.
Section 5.1: Bootloader configuration: updated first sentence.
Added Section 6: STM32F10xxx XL-density devices bootloader.
Table 65: added information for XL-density line devices.
08-Oct-2010 8 Added information for high-density value line devices in Table 3 and Table 65.
14-Oct-2010 9 Removed references to obsolete devices.
26-Nov-2010 10 Added information on ultralow power devices.
Added information related to STM32F205/215xx and STM32F207/217xx devices.
13-Apr-2011 11
Added Section 32: Bootloader timing
Updated:
– Table 12: STM32L1xxx6(8/B) bootloader versions
06-Jun-2011 12 – Table 17: STM32F2xxxx configuration in System memory boot mode
– Table 18: STM32F2xxxx bootloader V2.x versions
– Table 20: STM32F2xxxx bootloader V3.x versions
Added information related to STM32F405/415xx and STM32F407/417xx bootloader,
and STM32F105xx/107xx bootloader V2.1.
28-Nov-2011 13
Added value line devices in Section 4: STM32F10xxx devices bootloader title and
overview.
I2
Added information related to C throughout the document.
Streamlined Table 1: Applicable products and Section 1: Related documents.
Modified Table 3: Embedded bootloaders as follows:
– Replaced "V6.0" with "V1.0"
– Replaced "0x1FFFF7A6" with "0x1FFFF796" in row STM32F31xx
– Replaced "0x1FFF7FA6" with "0x1FFFF7A6" in row STM32F051xx
Updated figures 6, 9 and 11.
Added Note: in Glossary and Note: in Section 3.1: Bootloader activation.
Replaced:
06-Feb-2013 16 – "1.62 V" with "1.8 V" in tables17, 19, 19, 22, 21, 27, 37 and 59
– "5 Kbyte" with "4 Kbyte" in row RAM of Table 33
– "127 pages (2 KB each)" with "4 KB (2 pages of 2 KB each)" in rows F3 of Table 65
– "The bootloader ID is programmed in the last two bytes of the device system
memory" with "The bootloader ID is programmed in the last byte address - 1 of the
device system memory" in Section 3.3: Hardware connection requirement.
– "STM32F2xxxx devices revision Y" by "STM32F2xxxx devices revision X and Y" in
Section 10: STM32F2xxxx devices bootloader
– “Voltage Range 2” with “Voltage Range 1” in tables 11, 15 and 26.
Updated:
– Introduction
– Section 2: Glossary
– Section 3.3: Hardware connection requirement
– Section 7: STM32L1xxx6(8/B) devices bootloader to include STM32L100 value line
– Section 32.2: USART connection timing
– Section 34.2: USB bootloader timing characteristics
21-May-2013 17 – Section 34.3: I2C bootloader timing characteristics
– Table 1: Applicable products
– Table 3: Embedded bootloaders
– Table 25: STM32F051xx configuration in System memory boot mode
– Table 27: STM32F031xx configuration in System memory boot mode
– Table 65: Bootloader device-dependent parameters
– Figure 17: Bootloader selection for STM32F031xx devices
Added Section 19: STM32F429xx/439xx devices bootloader.
Add:
– Figure 1 to Figure 5, Figure 75, Figure 10, Figure 29, Figure 30, Figure 28, from
Figure 42 to Figure 97, Figure 101
– Table 4, Table 129, Table 130, from Table 13 to Table 52, from Table 53 to Table 50,
from Table 75 to Table 76, from Table to Table 164
– Section 38.4, Section 35.2, Section 74.1, Section 74.5
– Section 7 ,Section 25, Section 26, Section 24, from Section 19 to Section 64
– note under Figure 1, Figure 2, Figure 3 and Figure 4
Updated:
19-May-2014 18 – Updated starting from Section 4 to Section 9 and Section 20, Section 35 and
Section 35 the chapter structure organized in three subsection: Bootloader
configuration, Bootloader selection and Bootloader version.
Updated Section 64 and Section 74
– Updated block diagram of Figure 29 and Figure 24.
– Fixed I2C address for STM32F429xx/439xx devices in Table 73
– Table 1, Table 2, Table 3, Table 31, Table 123, Table 125, Table 127, Table 35,
Table 37, Table 57, Table 159
– from Figure 18, to Figure 32, Figure 12, from Figure 97 to Figure 101
– note on Table 124
Updated:
– notes under Table 2
– Figure 74 and Figure 75
– Section 3: Glossary
– replaced any reference to STM32F427xx/437xx with STM32F42xxx/43xxx on
Section 35: STM32F42xxx/43xxx devices bootloader
– replace any occurrence of ‘STM32F072xx’ with ‘STM32F07xxx’
– replace any occurrence of ‘STM32F051xx’ with ‘STM32F051xx and STM32F030x8
devices’.
– comment field related to OTG_FS_DP and OTG_FS_DM on Table 31, Table 37,
Table 57, Table 129, Table 73, Table 75, Table 19, Table 25, Table 61, Table 63 and
29-Jul-2014 19 Table 67
– comment field related to USB_DM on Table 129.
– replace reference to "STM32F429xx/439xx" by "STM32F42xxx/43xxx” on Table 3
– comment field related to SPI2_MOSI, SPI2_MISO, SPI2_SCK and SPI2_NSS pins
on Table 75
Added:
– note under Table 2
– reference to STM32F411 on Table 1, Section 3: Glossary, Table 160, Table 161,
Table 162, Table 163
– Section 32: STM32F411xx devices bootloader
Removed reference to STM32F427xx/437xx on Table 3, Section 3: Glossary,
Table 159, Table 160, Table 161, Table 162
Updated:
– comment in “SPI1_NSS pin" and "SPI2_NSS pin" rows on Table 129 and Table 115
24-Nov-2014 20 – comment in "SPI1_NSS pin", "SPI2_NSS pin" and "SPI3_NSS pin" rows on Table 61,
Table 63 and Table 67
– Figure 1
Updated:
– Table 1, Table 3, Table 29, Table 33, Table 123, Table 35, Table 37, Table 38,
Table 57, Table 129, Table 17, Table 18, Table 13, Table 41, Table 73, Table 75,
Table 19, Table 20, Table 25, Table 26,Table 39, Table 121, Table 137, Table 159,
Table 160, Table 161, Table 162 and Table 163
11-Mar-2015 21 – Figure 83
– Chapter 3: Glossary
– Section 4.1 and Section 4.4
Added:
– Section 64: STM32L47xxx/48xxx devices bootloader and Section 36: STM32F446xx
devices bootloader
Added:
– Section 11: STM32F070x6 devices bootloader
– Section 12: STM32F070xB devices bootloader
– Section 14: STM32F09xxx devices bootloader
– Section 21: STM32F302xD(E)/303xD(E) devices bootloaderSection 27:
STM32F398xx devices bootloader
– Section 38: STM32F72xxx/73xxx devices bootloader
– Section 64.2: Bootloader V9.x
09-Jun-2015 22
– Notes 1 and 2 on Figure 98
Updated:
– Table 1
– Section 3: Glossary
– Table 2
– Table 3
– Section 4.4: Bootloader memory management
– Table 159, Table 160, Table 161, Table 162 and Table 163
Added:
– Section 31: STM32F410xx devices bootloader
– Section 37: STM32F469xx/479xx devices bootloader
– Section 53: STM32L031xx/041xx devices bootloader
– Section 55: STM32L07xxx/08xxx devices bootloader
29-Sep-2015 23
Updated:
– Table 1
– Section 3: Glossary
– Table 3
– Figure 83, Table 139, Table 160, Table 161, Table 162, Table 163
Updated:
– Table 1, Table 3, Table 159, Table 160, Table 161, Table 162, Table 163
– Section 37
02-Nov-2015 24
Added:
– Note on Section 28.2.1
– Section 33
Updated:
01-Dec-2015 25 – Section 4.1, Section 55
– Table 159
Updated:
– Table 1, Table 3, Table 70, Table 118, Table 120, Table 159
– Section 3, Section 55.1.1, Section 55.2.1, Section 64
03-Mar-2016 26
Added:
– Section 52: STM32L01xxx/02xxx devices bootloader
– Figure 67, Figure 69
Added:
– Section 40: STM32F76xxx/77xxx devices bootloader, Section 62:
STM32L43xxx/44xxx devices bootloader.
– Note on: Section 4.1: Bootloader activation, Section 10.1: Bootloader configuration,
Section 11.1: Bootloader configuration, Figure 40: Dual bank boot implementation for
STM32F42xxx/43xxx Bootloader V7.x, Figure 42: Dual bank boot implementation for
STM32F42xxx/43xxx bootloader V9.x
Updated:
– Table 1: Applicable products, Table 2: Bootloader activation patterns, Table 15:
STM32F030xC configuration in system memory boot mode, Table 21: STM32F070x6
21-Apr-2016 27 configuration in system memory boot mode, Table 23: STM32F070xB configuration
in system memory boot mode, Table 27: STM32F09xxx configuration in system
memory boot mode, Table 39: STM32F301xx/302x4(6/8) configuration in system
memory boot mode, Table 41: STM32F302xB(C)/303xB(C) configuration in system
memory boot mode, Table 43: STM32F302xD(E)/303xD(E) configuration in system
memory boot mode, Table 51: STM32F373xx configuration in system memory boot
mode, Table 61: STM32F401xB(C) configuration in system memory boot mode,
Table 63: STM32F401xD(E) configuration in system memory boot mode, Table 67:
STM32F411xx configuration in system memory boot mode, Table 138:
STM32L47xxx/48xxx bootloader V10.x versions, Table 140: STM32L47xxx/48xxx
bootloader V9.x versions, Table 159: Bootloader device-dependent parameters
– Section 3: Glossary,
Updated:
– Table 1: Applicable products, Table 15: STM32F030xC configuration in system
memory boot mode, Table 17: STM32F05xxx and STM32F030x8 devices
configuration in system memory boot mode, Table 19: STM32F04xxx configuration in
system memory boot mode, Table 21: STM32F070x6 configuration in system
memory boot mode, Table 23: STM32F070xB configuration in system memory boot
mode, Table 25: STM32F071xx/072xx configuration in system memory boot mode,
Table 27: STM32F09xxx configuration in system memory boot mode, Table 31:
STM32F105xx/107xx configuration in system memory boot mode, Table 33:
STM32F10xxx XL-density configuration in system memory boot mode, Table 35:
STM32F2xxxx configuration in system memory boot mode, Table 37: STM32F2xxxx
configuration in system memory boot mode, Table 39: STM32F301xx/302x4(6/8)
configuration in system memory boot mode, Table 41: STM32F302xB(C)/303xB(C)
configuration in system memory boot mode, Table 43: STM32F302xD(E)/303xD(E)
configuration in system memory boot mode, Table 45:
STM32F303x4(6/8)/334xx/328xx configuration in system memory boot mode,
Table 47: STM32F318xx configuration in system memory boot mode, Table 49:
STM32F358xx configuration in system memory boot mode, Table 51: STM32F373xx
configuration in system memory boot mode, Table 53: STM32F378xx configuration in
system memory boot mode, Table 55: STM32F398xx configuration in system
memory boot mode, Table 57: STM32F40xxx/41xxx configuration in system memory
boot mode, Table 59: STM32F40xxx/41xxx configuration in system memory boot
mode, Table 61: STM32F401xB(C) configuration in system memory boot mode,
Table 63: STM32F401xD(E) configuration in system memory boot mode, Table 67:
STM32F411xx configuration in system memory boot mode, Table 73:
05-Sep-2016 28
STM32F42xxx/43xxx configuration in system memory boot mode, Table 75:
STM32F42xxx/43xxx configuration in system memory boot modeTable 77:
STM32F446xx configuration in system memory boot mode, Table 79:
STM32F469xx/479xx configuration in system memory boot mode, Table 83:
STM32F74xxx/75xxx configuration in system memory boot mode, Table 85:
STM32F74xxx/75xxx configuration in system memory boot mode, Table 115:
STM32L05xxx/06xxx configuration in system memory boot mode, Table 121:
STM32L1xxx6(8/B)A configuration in system memory boot mode, Table 123:
STM32L1xxx6(8/B) configuration in system memory boot mode, Table 125:
STM32L1xxxC configuration in system memory boot mode, Table 127:
STM32L1xxxD configuration in system memory boot mode, Table 129:
STM32L1xxxE configuration in system memory boot mode, Table 134:
STM32L43xxx/44xxx bootloader versions, Table 137: STM32L47xxx/48xxx
configuration in system memory boot mode, Table 159: Bootloader device-dependent
parameters
– Section 62.1: Bootloader configuration
– Figure 26: Bootloader selection for STM32F303x4(6/8)/334xx/328xx, Figure 27:
Bootloader selection for STM32F318xx, Figure 29: Bootloader selection for
STM32F373xx devices, Figure 30: Bootloader selection for STM32F378xx devices,
Figure 33: Bootloader V9.x selection for STM32F40xxx/41xxx, Figure 36: Bootloader
V11.x selection for STM32F410xx, Figure 38: Bootloader V9.x selection for
STM32F412xx, Figure 46: Bootloader V9.x selection for STM32F469xx/479xx,
Figure 51: Bootloader V9.x selection for STM32F76xxx/77xxx, Figure 70: Bootloader
V11.x selection for STM32L07xxx/08xxx, Figure 83: Bootloader V10.x selection for
STM32L47xxx/48xxx
Updated:
– Table 1: Applicable products, Section 3: Glossary, Section 4.1: Bootloader activation,
Table 3: Embedded bootloaders, Table 14: STM32F09xxx devices bootloader,
Table 16: STM32F105xx/107xx devices bootloader, Table 17: STM32F10xxx XL-
density devices bootloader, Table 18: STM32F2xxxx devices bootloader, Table 19:
STM32F301xx/302x4(6/8) devices bootloader, Table 20:
STM32F302xB(C)/303xB(C) devices bootloader, Table 22:
STM32F303x4(6/8)/334xx/328xx devices bootloader, Table 24: STM32F358xx
devices bootloader, Table 27: STM32F398xx devices bootloader, Table 31:
STM32F410xx devices bootloader, Table 34: STM32F413xx/423xx devices
bootloader, Table 63: STM32F401xD(E) configuration in system memory boot mode,
Section 16.3.1: How to identify STM32F105xx/107xx bootloader versions,
Section 30.1: Bootloader configuration, Table 65: STM32F410xx configuration in
system memory boot mode, Table 67: STM32F411xx configuration in system
07-Dec-2016 29 memory boot mode, Table 69: STM32F412xx configuration in system memory boot
mode, Section 32.1: Bootloader configuration, Table 74: STM32F42xxx/43xxx
bootloader V7.x versions, Table 76: STM32F42xxx/43xxx bootloader V9.x versions,
Table 87: STM32F76xxx/77xxx configuration in system memory boot mode,
Table 88: STM32F76xxx/77xxx bootloader V9.x versions, Table 112:
STM32L01xxx/02xxx bootloader versions, Table 120: STM32L07xxx/08xxx
bootloader V11.x versions, Table 133: STM32L43xxx/44xxx configuration in system
memory boot mode, Table 134: STM32L43xxx/44xxx bootloader versions, Table 138:
STM32L47xxx/48xxx bootloader V10.x versions, Table 159: Bootloader device-
dependent parameters, Table 160: Bootloader startup timings (ms) for STM32
devices, Table 162: USB bootloader minimum timings (ms) for STM32 devices,
Table 162: USB bootloader minimum timings (ms) for STM32 devices, Table 163: I2C
bootloader minimum timings (ms) for STM32 devices
Added:
– Section 34: STM32F413xx/423xx devices bootloader
Updated:
– Table 1: Applicable products, Table 3: Embedded bootloaders, Table 18:
STM32F05xxx and STM32F030x8 devices bootloader versions, Table 19:
STM32F04xxx configuration in system memory boot mode, Table 20: STM32F04xxx
bootloader versions, Table 22: STM32F070x6 bootloader versions, Table 24:
STM32F070xB bootloader versions, Table 25: STM32F071xx/072xx configuration in
system memory boot mode, Table 26: STM32F071xx/072xx bootloader versions,
Table 27: STM32F09xxx configuration in system memory boot mode, Table 28:
STM32F09xxx bootloader versions, Table 39: STM32F301xx/302x4(6/8)
configuration in system memory boot mode, Table 42: STM32F302xB(C)/303xB(C)
bootloader versions, Table 88: STM32F76xxx/77xxx bootloader V9.x versions,
Table 111: STM32L01xxx/02xxx configuration in system memory boot mode,
13-Mar-2017 30 Table 134: STM32L43xxx/44xxx bootloader versions, Table 159: Bootloader device-
dependent parameters, Table 139: STM32L47xxx/48xxx configuration in system
memory boot mode, Table 160: Bootloader startup timings (ms) for STM32 devices,
Table 161: USART bootloader minimum timings (ms) for STM32 devices, Table 162:
USB bootloader minimum timings (ms) for STM32 devices, Table 163: I2C
bootloader minimum timings (ms) for STM32 devices, Table 164: SPI bootloader
minimum timings (ms) for STM32 devices
– Section 3: Glossary, Section 8.1: Bootloader configuration, Section 16.3.3: USART
bootloader Get-Version command returns 0x20 instead of 0x22, RPN reference in
Section 62: STM32L43xxx/44xxx devices bootloader and in Section 64:
STM32L47xxx/48xxx devices bootloader
Added Section 38: STM32F72xxx/73xxx devices bootloader and Section 65:
STM32L496xx/4A6xx devices bootloader
Updated:
– Table 1: Applicable products, Table 2: Bootloader activation patterns, Table 3:
Embedded bootloaders, Table 32: STM32F105xx/107xx bootloader versions,
Table 37: STM32F2xxxx configuration in system memory boot mode, Table 41:
STM32F302xB(C)/303xB(C) configuration in system memory boot mode, Table 49:
STM32F358xx configuration in system memory boot mode, Table 51: STM32F373xx
configuration in system memory boot mode, Table 53: STM32F378xx configuration in
system memory boot mode, Table 59: STM32F40xxx/41xxx configuration in system
memory boot mode, Table 61: STM32F401xB(C) configuration in system memory
boot mode, Table 63: STM32F401xD(E) configuration in system memory boot mode,
Table 67: STM32F411xx configuration in system memory boot mode, Table 73:
STM32F42xxx/43xxx configuration in system memory boot mode, Table 77:
STM32F446xx configuration in system memory boot mode, Table 79:
STM32F469xx/479xx configuration in system memory boot mode, Table 81:
STM32F72xxx/73xxx configuration in system memory boot mode, Table 83:
04-Jul-2017 31 STM32F74xxx/75xxx configuration in system memory boot mode, Table 85:
STM32F74xxx/75xxx configuration in system memory boot mode, Table 107:
STM32H74xxx/75xxx configuration in system memory boot mode, Table 125:
STM32L1xxxC configuration in system memory boot mode, Table 127:
STM32L1xxxD configuration in system memory boot mode, Table 129:
STM32L1xxxE configuration in system memory boot mode, Table 135:
STM32L45xxx/46xxx configuration in system memory boot mode, Table 159:
Bootloader device-dependent parameters, Table 160: Bootloader startup timings
(ms) for STM32 devices, Table 161: USART bootloader minimum timings (ms) for
STM32 devices, Table 162: USB bootloader minimum timings (ms) for STM32
devices, Table 163: I2C bootloader minimum timings (ms) for STM32 devices
– Introduction, Section 3: Glossary
– Figure 79: Bootloader V9.x selection for STM32L43xxx/44xxx
Added:
– Section 50: STM32H74xxx/75xxx devices bootloader, Section 63:
STM32L45xxx/46xxx devices bootloader
Updated Table 3: Embedded bootloaders, Table 108: STM32H74xxx/75xxx bootloader
version, Table 141: STM32L496xx/4A6xx configuration in system memory boot mode,
Table 142: STM32L496xx/4A6xx bootloader version, Table 159: Bootloader device-
dependent parameters, Table 160: Bootloader startup timings (ms) for STM32 devices,
16-Feb-2018 32 Table 161: USART bootloader minimum timings (ms) for STM32 devices, Table 162:
USB bootloader minimum timings (ms) for STM32 devices, Table 163: I2C bootloader
minimum timings (ms) for STM32 devices.
Added Section 67: STM32L4Rxxx/4Sxxx devices bootloader
Updated Note: in Section 10.1: Bootloader configuration, Note: in Section 11.1:
07-Aug-2018 33
Bootloader configuration
Updated:
– Table 1: Applicable products, Table 2: Bootloader activation patterns, Table 3:
Embedded bootloaders, Table 71: STM32F413xx/423xx configuration in system
memory boot mode, Table 107: STM32H74xxx/75xxx configuration in system
memory boot mode, Table 108: STM32H74xxx/75xxx bootloader version, Table 113:
STM32L031xx/041xx configuration in system memory boot mode, Table 134:
STM32L43xxx/44xxx bootloader versions, Table 135: STM32L45xxx/46xxx
configuration in system memory boot mode, Table 142: STM32L496xx/4A6xx
bootloader version, Table 153: STM32WB30xx/35xx/50xx/55xx bootloader versions,
08-Jul-2019 38 Table 159: Bootloader device-dependent parameters, Table 160: Bootloader startup
timings (ms) for STM32 devices, Table 161: USART bootloader minimum timings
(ms) for STM32 devices, Table 162: USB bootloader minimum timings (ms) for
STM32 devices, Table 163: I2C bootloader minimum timings (ms) for STM32 devices
– Section 3: Glossary, Section 4.1: Bootloader activation, Section 41.1: Bootloader
configuration, Section 46.1: Bootloader configuration
– Figure 62: Bootloader V9.x selection for STM32H74xxx/75xxx, Figure 90: Dual bank
boot implementation for STM32L4Rxxx/STM32L4Sxxx bootloader V9.x
Added Note: in Section 4.2, Note: in Section 15.3, Note: in Section 50.1, Note: in
Section 52.1, Section 41: STM32G03xxx/ STM32G04xxx devices bootloader
Updated:
– Table 1: Applicable products, Table 2: Bootloader activation patterns, Table 3:
Embedded bootloaders, Table 90: STM32G03xx/04xxx bootloader versions,
Table 132: STM32L412xx/422xx bootloader versions, Table 134:
STM32L43xxx/44xxx bootloader versions, Table 136: STM32L45xxx/46xxx
bootloader versions, Table 138: STM32L47xxx/48xxx bootloader V10.x versions,
Table 140: STM32L47xxx/48xxx bootloader V9.x versions, Table 142:
STM32L496xx/4A6xx bootloader version, Table 144: STM32L4P5xx/4Q5xx
16-Sep-2019 39 bootloader versions, Table 159: Bootloader device-dependent parameters,
Table 160: Bootloader startup timings (ms) for STM32 devices, Table 161: USART
bootloader minimum timings (ms) for STM32 devices, Table 162: USB bootloader
minimum timings (ms) for STM32 devices, Table 163: I2C bootloader minimum
timings (ms) for STM32 devices
– Section 3: Glossary, Section 4.2: Bootloader identification
Added Figure 59: Dual bank boot implementation for STM32G47xxx/48xxx bootloader
V13.x, Section 68: STM32L552xx/STM32L562xx devices bootloader, note in
Section 70.3: Bootloader version
Updated Table 3: Embedded bootloaders, Table 149: STM32L552xx/562xx bootloader
03-Oct-2019 40
versions, Table 153: STM32WB30xx/35xx/50xx/55xx bootloader versions
Updated:
– Table 82: STM32F72xxx/73xxx bootloader V9.x versions, Table 84:
STM32F74xxx/75xxx bootloader V7.x versions, Table 86: STM32F74xxx/75xxx
bootloader V9.x versions, Table 88: STM32F76xxx/77xxx bootloader V9.x versions,
Table 89: STM32G03xxx/G04xxx configuration in system memory boot mode,
25-Oct-2019 41 Table 108: STM32H74xxx/75xxx bootloader version, Table 144:
STM32L4P5xx/4Q5xx bootloader versions, Table 147: STM32L552xx/562xx
configuration in system memory boot mode, Table 160: Bootloader startup timings
(ms) for STM32 devices, Table 161: USART bootloader minimum timings (ms) for
STM32 devices, Table 163: I2C bootloader minimum timings (ms) for STM32 devices
– Section 18: STM32F2xxxx devices bootloader
Updated:
– Table 1: Applicable products, Table 2: Bootloader activation patterns, Table 3:
Embedded bootloaders, Table 159: Bootloader device-dependent parameters,
Table 160: Bootloader startup timings (ms) for STM32 devices, Table 161: USART
bootloader minimum timings (ms) for STM32 devices, Table 162: USB bootloader
05-Dec-2019 42 minimum timings (ms) for STM32 devices, Table 163: I2C bootloader minimum
timings (ms) for STM32 devices
– Section 3: Glossary
Added: Section 51: STM32H7A3xx/B3xx devices bootloader, Section 66:
STM32L4P5xx/4Q5xx devices bootloader, Section 71: STM32WLE5xx/55xx devices
bootloader
Updated:
– Table 1: Applicable products, Table 2: Bootloader activation patterns, Table 3:
Embedded bootloaders, Table 99: STM32G431xx/441xx configuration in system
memory boot mode, Table 101: STM32G47xxx/48xxx configuration in system
memory boot mode, Table 102: STM32G47xxx/48xxx bootloader version, Table 108:
STM32H74xxx/75xxx bootloader version, Table 110: STM32H7A3xx/7B3xx
bootloader version, Table 144: STM32L4P5xx/4Q5xx bootloader versions, Table 147:
STM32L552xx/562xx configuration in system memory boot mode, Table 149:
STM32L552xx/562xx bootloader versions, Table 152:
STM32WB30xx/35xx/50xx/55xx configuration in system memory boot mode,
Table 159: Bootloader device-dependent parameters
– Section 3: Glossary, Section 39: STM32F74xxx/75xxx devices bootloader,
Section 41.1: Bootloader configuration, Section 42.1: Bootloader configuration,
Section 46.1: Bootloader configuration, Section 47.1: Bootloader configuration,
Section 50.1: Bootloader configuration
Added:
– Section 4.5: Bootloader UART baudrate detection, Section 4.6: Programming
04-Jun-2020 43
constraints, Section 4.7: ExitSecureMemory feature
– Note: in: Section 28.1.1: Bootloader configuration, Section 28.2.1: Bootloader
configuration, Section 29.1: Bootloader configuration, Section 30.1: Bootloader
configuration, Section 32.1: Bootloader configuration, Section 33.1: Bootloader
configuration, Section 34.1: Bootloader configuration, Section 35.1.1: Bootloader
configuration, Section 35.2.1: Bootloader configurationSection 36.1: Bootloader
configuration, Section 37.1: Bootloader configuration, Section 38.1: Bootloader
configuration, Section 39.1.1: Bootloader configuration, Section 39.2.1: Bootloader
configuration, Section 40.1: Bootloader configuration
– Figure 78: Dual bank boot Implementation for STM32L3x2xx/44xxx bootloader V9.x,
Figure 80: Dual bank boot Implementation for STM32L45xxx/46xxx bootloader V9.x,
Figure 86: Dual bank boot Implementation for STM32L496xx/4A6xx bootloader V9.x
– Appendix A: Example of function to use the “ExitSecureMemory” function
Deleted Figure 48. Access to securable memory area from the bootloader for
STM32G03xxx/G04xxx, Figure 50. Access to securable memory area from the
bootloader for STM32G07xxx/G08xxx, Figure 52. Access to securable memory area,
Figure 54. Access to securable memory area
Upadated:
– Table 3: Embedded bootloaders, Table 89: STM32G03xxx/G04xxx configuration in
system memory boot mode, Table 101: STM32G47xxx/48xxx configuration in system
memory boot mode, Table 134: STM32L43xxx/44xxx bootloader versions, Table 136:
02-Dec-2020 46
STM32L45xxx/46xxx bootloader versions
Added following notes:
– Note: on page 317, Note: on page 324, Note: on page 332, Note: on page 344, Note:
on page 351
Updated:
– Table 1: Applicable products, Table 3: Embedded bootloaders, Table 8:
ExitSecureMemory entry address, Table 88: STM32F76xxx/77xxx bootloader V9.x
versions, Table 101: STM32G47xxx/48xxx configuration in system memory boot
mode, Table 131: STM32L412xx/422xx configuration in system memory boot mode,
Table 133: STM32L43xxx/44xxx configuration in system memory boot mode,
Table 135: STM32L45xxx/46xxx configuration in system memory boot mode,
Table 139: STM32L47xxx/48xxx configuration in system memory boot mode,
Table 141: STM32L496xx/4A6xx configuration in system memory boot mode,
Table 143: STM32L4P5xx/4Q5xx configuration in system memory boot mode,
16-Feb-2021 47 Table 145: STM32L4Rxxx/4Sxxx configuration in system memory boot mode,
Table 147: STM32L552xx/562xx configuration in system memory boot mode,
Table 152: STM32WB30xx/35xx/50xx/55xx configuration in system memory boot
mode, Table 159: Bootloader device-dependent parameters, Table 160: Bootloader
startup timings (ms) for STM32 devices, Table 161: USART bootloader minimum
timings (ms) for STM32 devices, Table 162: USB bootloader minimum timings (ms)
for STM32 devices, Table 163: I2C bootloader minimum timings (ms) for STM32
devices
– Section 3: Glossary
Added Section 43: STM32G0B0xx device bootloader and Section 44:
STM32G0B1xx/0C1xx device bootloader
Updated:
– Table 1: Applicable products, Table 3: Embedded bootloaders, Table 8:
ExitSecureMemory entry address, Table 159: Bootloader device-dependent
parameters, Table 160: Bootloader startup timings (ms) for STM32 devices,
01-Apr-2021 48
Table 161: USART bootloader minimum timings (ms) for STM32 devices, Table 163:
I2C bootloader minimum timings (ms) for STM32 devices
Added Section 45: STM32G05xxx/061xx devices bootloader and Section 48:
STM32G491xx/4A1xx devices bootloader
Updated:
– Section 3: Glossary, Section 28.2.1: Bootloader configuration
– Table 3, Table 13,from Table 15 to Table 20, from Table 23 to Table 28, Table 29,
Table 31, Table 33, Table 37, Table 39, Table 41, Table 43, Table 45, Table 47,
Table 49, Table 51, Table 53, Table 55, Table 57, Table 59, Table 60, Table 61,
Table 63, Table 65, Table 67, Table 69, Table 71, Table 73, Table 75, Table 77,
06-Jul-2021 49 Table 79, Table 81, Table 83, Table 85, Table 87, Table 89, Table 91, Table 93,
Table 95, Table 97, Table 99, Table 101, Table 102, Table 103, Table 105, Table 107,
Table 109, Table 109, Table 111, Table 113, Table 115, Table 116, Table 117,
Table 119, Table 121, Table 123, Table 124, Table 125, Table 126, Table 127,
Table 129, Table 130, Table 131, Table 133, Table 135, Table 137, Table 139,
Table 141, Table 143, Table 145, Table 147, Table 152, Table 154, Table 159
Added Table 148: STM32L552cc/562xx spacial commands and Section 69:
STM32WB10xx/15xx devices bootloader
Updated:
– Section 3: Glossary, Section 43.1: Bootloader configuration, Section 44.1:
Bootloader configuration,
23-Sep-2021 50
– Table 1, Table 2, Table 3, Table 92, Table 106, Table 108, Table 110, Table 134,
Table 151, Table 153, Table 159, Table 160, Table 161, Table 162, Table 163
Added Section 72: STM32U575xx/85xx devices bootloader
Updated:
20-Oct-2021 51 – Table 3, Table 60,Table 92, Table 106,Table 159
– Section 28.2.1: Bootloader configuration
Updated:
– Section 3: Glossary, Section 4.1: Bootloader activation,
– Table 1, Table 2, Table 3, Table 7, Table 92, Table 108, Table 159
04-Feb-2022 52
– Figure 54
Added Section 5: STM32C011xx devices bootloader and Section 6: STM32C031xx
devices bootloader
Updated:
– Table 3, Table 105, Table 106, Table 159.
01-Mar-2022 53 – Section 4.1: Bootloader activation, , Section 41.1: Bootloader configuration,
Section 42.1: Bootloader configuration, Section 43.1: Bootloader configuration,
Section 45.1: Bootloader configuration
Updated:
20-Apr-2022 54
– Table 3, Table 105, Table 109, Table 110, Table 159
STMicroelectronics NV and its subsidiaries (“ST”) reserve the right to make changes, corrections, enhancements, modifications, and
improvements to ST products and/or to this document at any time without notice. Purchasers should obtain the latest relevant information on
ST products before placing orders. ST products are sold pursuant to ST’s terms and conditions of sale in place at the time of order
acknowledgement.
Purchasers are solely responsible for the choice, selection, and use of ST products and ST assumes no liability for application assistance or
the design of Purchasers’ products.
Resale of ST products with provisions different from the information set forth herein shall void any warranty granted by ST for such product.
ST and the ST logo are trademarks of ST. For additional information about ST trademarks, please refer to www.st.com/trademarks. All other
product or service names are the property of their respective owners.
Information in this document supersedes and replaces information previously supplied in any prior versions of this document.