SAI - get best clock accuracy
Hi :)
This is related to my other post (https://community.st.com/s/question/0D53W00000EcBvNSAV/sai-no-signal-on-mclk-pin) but I thought it would be more organised to make two posts since the question is different.
How do I get the best audio clock accuracy using the separate SAI PLL without fiddling manually with all the values?
The SAI clock should be one of these, or as close as possible to be accurate:

I tried just entering the value in CubeMX but clearly it is not possible to get exactly those values so CubeMX cannot manage.
What I would like ideally is a simple way to say I want fs=44.1kHz audio freq for ex and then the tool tries to get a SAI clock as close as possible as one of the possible frequencies (128fs, 256fs, etc.).
I actually found the perfect tool - exactly what I'm describing - but it is for the I2S and not the SAI which uses different master clocks. (for those interested, the tool is an excel sheet: https://www.st.com/resource/en/application_note/dm00039457-clock-configuration-tool-for-stm32f40xx41xx427x437x-microcontrollers-stmicroelectronics.pdf )
My question to you: how do you do it, you just fiddle manually with the values until you get something close?
Thanks
Simon
