Skip to main content
wmeng.2
Associate
December 21, 2022
Question

STM32CubeProgrammer UART bootloader write error

  • December 21, 2022
  • 3 replies
  • 1682 views

Recently I used Stm32cubeprogrammer to write programs via UART. I can connect to the MCU, I can also read the data, but the download fails.

Have you encountered similar problems?

0693W00000WLUsmQAH.png0693W00000WLUtGQAX.png0693W00000WLUtfQAH.png 

This topic has been closed for replies.

3 replies

Bubbles
ST Employee
December 21, 2022

Hi @Community member​,

the SWP connection works?

Have you tried reading the OB to see if there is something preventing erase or write in the flash?

BR,

J

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Bubbles
ST Employee
December 21, 2022

sorry I meant SWD

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
wmeng.2
wmeng.2Author
Associate
December 22, 2022

I can read and write using the SWD interface, but not with UART

wmeng.2
wmeng.2Author
Associate
December 22, 2022

I can read and write using the SWD interface, but not with UART

Aziz BRIGUI
Technical Moderator
January 2, 2023

Hello @Community member​,

Sorry for the late comment,

Could you share a screenshot of STM32CubeProgrammer GUI when connected via ST-LINK (To know the bootloader version and the rev ID) ? Could you also specify the full name of the device you're using ?

A verbose 3 log could be useful as well.

Thanks,

Aziz

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
wmeng.2
wmeng.2Author
Associate
January 4, 2023
Hello Aziz.
The chip model I use is STM32G031G8U6.
id1989@qq.com
Aziz BRIGUI
Technical Moderator
January 4, 2023

Hello @Community member​,

There are some limitations in the earlier versions of the bootloader, especially on packages with less than 32 pins (you can check AN2606 page 225 for further details). If you have bootloader V5.2, I suggest keeping PA3 at high level and doing the test with UART1 (PA9, PA10).

Also I suggest commenting here to improve the chance of response.

Thanks for understanding,

Aziz

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.