Skip to main content
Explorer II
June 12, 2026
Question

Flashing STM device from other STM using USART internal bootloader protocol.

  • June 12, 2026
  • 2 replies
  • 56 views

Hi,

I do have two STM32H563 devices connected together via UART. I would like to use one as a ‘programmer/flasher’ and the other as a ‘target’. On the ‘target’ MCU I would like to use an already in-built bootloader available over USART1. The only problem is the programming/flashing implementation on the ‘programming’ MCU. Is there any example code available somewhere that contains such an implementation? I can see that there is this code publicly available:
https://github.com/STMicroelectronics/stm32-mw-openbl
...but it only contains implementation of the bootloader protocol for the target device, not the programming/flashing one.

I am trying to evaluate the effort needed to make such an implementation to happen. I would like to avoid writing my own bootloader with my own custom protocol (although at the moment this seems like an easier option to be honest).

Kind regards

2 replies

Andrew Neil
Super User
June 12, 2026

I don’t think there are examples published, but the proticol is documented here:

AN3155How to use USART protocol in bootloader on STM32 MCUs

A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
mƎALLEm
ST Technical Moderator
June 12, 2026

​​​​​And AN2606 “Introduction to system memory boot mode on STM32 MCUs”

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.