2022-10-05 06:46 AM
I am not sure that choosing the wrong clock frequency would affect USART communication
2022-10-05 06:55 AM
No idea what you're reading.
At 96 MHz on the APB you should be able to get baud rates into the Mbps
Async Serial should be able to sustain a few percent offset in the baud rate.
The STM32 H7 starts at 64 MHz, and I'm sure that can be divided down further, approaching DC I'd reasonably assume for a CMOS IC.
2022-10-05 07:21 AM
Thank you Tesla for your answer.
Yes, I need to set the baud rate on 115200 and I can do it. I was just wondering if the clock frequency will affect the USART communication even if we already set the proper baud rate.
2022-10-05 07:46 AM
"wondering if the clock frequency will affect the USART"
what clock are you talking about?
The H7 has many clocks sources: LSE, LSI, HSI, CSI, HSE...
You can use 3 DLL with 3 output each.
You can select individual clock source for UART.
If you select PPLQ2 as UART clock source, you can change the core clock with PLL1P without affecting the UART communication.
Maybe the article you read applies to the F103 whose maximum core frequency is limited to 72 MHz?
2022-10-05 09:21 AM
If you change the system clocks you'll need to adapt the baud rate.
The baud rate register has a fractional composition based on the fact that internally they clock it 16x or 8x over frequency so the receiver can bit align to the center of the signal.
But in OVER16 mode USARTx->BRR = APBxCLK / BaudRate
Should be able to hit 115200 baud without issues.
Now low baud rates might have a range issue, newer STM32 have U(S)ART that can use a prescaler for people who need to get into 300 or 1200 baud ranges, whilst clocking at 100's of MHz, don't ask my why they want/need to do that, or why people use 5V MCU 30 years after most everyone else moved to 3.3V.