2021-04-24 11:47 PM
On an ST Nucleo board with STM32h743, it has an 8MHz crystal for HSE, and I am able to configure the PLL's to show a 200MHz CPU clock and a 100MHz peripheral clock. These frequencies are displayed as round figures, no decimal.
When I move to a third party STM32H743VIT design (DevEBox module), it has a 25MHz crystal. It seemed to me that getting to 200/100 should be straightforward: divide by 25 to get to 1MHz, multiply up x400 to get to 400MHz, divide back down to 200 and 100.
However, the Cube clock configuration panel shows odd extra decimals no matter what, i.e. "200.1875MHz". I think I need to just get it running and do some kind of external verification of what clock rates are actually occurring, because I don't know which of these things is true:
a) it's not possible to turn 25MHz HSE into 200.00/100.00 MHz on an STM32H743
b) it's possible, but CubeMX/CubeIDE are just doing the math wrong
c) the tool is actually coming up with a good config, and the real freqs are good, but they are displayed wrong for some reason
Attached the ioc's from the Nucleo (good, 8MHz crystal) and the DevEBox STM32H743 module (25MHz crystal, bad).
2021-04-25 01:23 AM
Clear the "fracn1" to zero. And divide that 400/25 by 5 to get 80/5, which is a better configuration.
2021-04-25 11:01 AM
Much appreciated. It was right there and I missed it. This is the first project I set up in Cube IDE that wasn't based on a Nucleo board config and I hadn't seen that field active before.