E
E
eegmak2021-03-15 17:52:21
STM
eegmak, 2021-03-15 17:52:21

Is it possible to update stm32 firmware by uart while working?

stm32f103c8t6 is connected via uart to the "controlling device" (smartphone / pc / router)
ws2812b matrix is ​​connected to it.
I am currently writing code on growth to manage this matrix.
And the process is quite long - first I try to write something, then I switch one switch, connect the usb-uart adapter to the PC and upload the new compiled code.
I thought about whether it is possible to update the firmware on a command from uart, for example:
in uart we send "switch to the firmware mode", after which we "upload" the firmware.
Perhaps this is due to the bootloader, can it be written on the grow?
For example, "bluepill" is connected to the router via uart + ws2812b matrix, I am writing a new code on a PC, I send a command to flash the firmware itself to the uart of the router?
Is this possible and where to dig to study the topic?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vasily Bannikov, 2021-03-15
@vabka

There are two options:
1. Go programmatically to DFU and push new firmware from the outside: blog.abuksigun.com/2014/05/stm32f4-dfu.html
2. Write a bootloader: https://microtechnics.ru/mikrokontroller-i-bootloa.. In the
article, the code is in C, but it is not very complicated and you can easily find by keywords how all this can be done on a growth.
PS: https://github.com/JitterCompany/bootloader-stm32l-rust

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question