2025-11-19 9:23 AM
I call HAL_UART_Init() with LPUART1 at 20Mbaud but when I activate assertion it fail at IS_UART_BAUDRATE().
The IS_UART_BAUDRATE() is not correct for LPUART that can have a baudrate up to 53.3 Mbaud.
Also for UART, the comparaison in IS_UART_BAUDRATE() should be <= instead of < like in IS_LL_USART_BAUDRATE().
2025-11-19 9:37 AM
> LPUART that can have a baudrate up to 53.3 Mbaud
This can't possibly be correct. What clock settings are getting you up to 53.3 Mbaud?
> Also for UART, the comparaison in IS_UART_BAUDRATE() should be <= instead of < like in IS_LL_USART_BAUDRATE()
Agreed.
2025-11-20 12:17 AM
Why wouldn't it be possible ? LPUART can generate 9600 baud from 32768 Hz.
From RM: lpuart_ker_ck_pres must range from 3 x baud rate to 4096 x baud rate.
So with 160 MHz, 53.3 Mbaud is possible.
You can also check with CubeMX.
2025-11-24 12:54 AM
Because of lack of official response, i have open an issue on github:
https://github.com/STMicroelectronics/stm32u5xx-hal-driver/issues/28