2023-03-13 12:03 PM
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:
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
Solved! Go to Solution.
2023-03-31 12:00 AM
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.
2023-03-31 10:31 PM
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