Error when setting UART Baudrate <= 2400 on a STM32H5 #16679
Replies: 2 comments
-
It seems that CPU and bus frequency might be not set correctly:
The first value could/should be 250'000'000 and not 160'000'000. More over: I am not sure if this applies here but on the pyboard https://docs.micropython.org/en/latest/library/pyb.UART.html#methods |
Beta Was this translation helpful? Give feedback.
-
The problem ist most likely related to the bus frequency. After increasing the CPU speed and unintentionally with it the bus speed (see DrTom/micropython-wrap@08b2fc1) the So the question is now: how do I configure the bus speed properly. It seems that
should rather be |
Beta Was this translation helpful? Give feedback.
-
I get an
ValueError: set baudrate 2500 is not within 5% of desired value
whenever I try to set a baudrate to 2400 or lower and it seems that the lowest value the UART port will assume is actually 2500.The board is the following: https://github.com/WeActStudio/WeActStudio.STM32H5_64Pin_CoreBoard and the board configuration is here: https://github.com/DrTom/micropython-wrap/tree/main/boards/STM32H562RG_WAS.
Is there something wrong with the my configuration or is there a Problem with micropython UARTs on the H5?
I have seen there were similar issues in the past. Some of them were related to the LPUART controller. The latter seems not to be the case here: the board has 1 LPUART but I can reproduce the problem when using UART2 or UART3.
Beta Was this translation helpful? Give feedback.
All reactions