cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F746VGT7 firmware update fails via UART

Nchen.1
Associate III

Hi all,

I'm having a firmware issue with updating my MCU via UART

After reading AN2606 and AN3155, I try to do the following:

  • Disable all interrupts and save a register with unique value
  • Call system reset
  • Jump to bootloader on the beginning of SystemInit
  • Update the FW via USART1 (PA9, PA10) with baudrate 115200

What I get is a fallback to baudrate 1200, which means baudrate auto detection failed.

I have to mention that it works well in the same method I describe with USART3 (PB10, PB11) and it also works on USART1 (PA9, PA10) if I'm remove my code logic and jump to bootloader from the same place (SystemInit)

I still couldn't figure it out and would appreciate if someone could help me

Thanks for your help

11 REPLIES 11
Piranha
Chief II

Sounds like there are some floating pins, which are detected by the system bootloader. Read the AN2606 sections "4.3 Hardware connection requirements" and "48 STM32G491xx/4A1xx devices bootloader". Especially this:

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.

I actually missed that.

Right above this note, there are schemes that shows the typical connection for the mentioned lines, and D+ connected to a pull up relies on VBUS, which means it’s floating when USB disconnected.

As it’s not mentioned, what’s the recommended resistor value I need to choose? Is it matters for USB if it’s a pull up or down? It worked well with 100k but I don’t want to damage the USB communication for future uses