[sdiy] STM32G4 SAI problems

rburnett at richieburnett.co.uk rburnett at richieburnett.co.uk
Sat Jul 15 22:36:45 CEST 2023


Anyone using STM32G4 with STM32CubeIDE and managed to get the SAI codec 
interface working?

I've been banging my head against a brick wall here for the past two 
days trying to configure the SAI peripheral of a Nucleo-G474RE using the 
CubeIDE graphical config tool (MX?), and still no signs of life on the 
relevant pins!  It asks me what "Audio Frequency" I want from a drop 
down menu of the usual suspects (32k, 44.1k, 48k, 96k, etc.) but the 
"Real Audio Frequency" and "Error" both stay stubbornly stuck at zero 
and greyed out.  The clock source shows as "SAI PLL Clock" but is greyed 
out (and can't be changed,) and I've tried all possible options for the 
SAI clock MUX in the actual clock config tool anyway, including an 
external I2S clock input.  Still no luck.

Why does this have to be so difficult!?  And why do chip vendors always 
provide working examples for every peripheral except SAI / I2S ! (>.<)

I have managed to get a LED blinking, and send "Hello World!" to a 
terminal via UART though, so not entirely fruitless.

-Richie,


More information about the Synth-diy mailing list