I2S + DMA
Hello!
I’m trying to output a sine wave on my CS4344 DAC using I2S and DMA but it’s not going well...
First step was to output the correct clocks ie LRCLK = 44.1kHz and MCLK = 256 * LRCLK = 11.289MHz.
I tried several PLLI2S set ups and I never get exactly the right values. The closest I got was : MCLK = 11.36 MHz and LRCLK = 44.943 kHz (that might also be because my old oscilloscope isn’t so precise).
I figured it was good enough and wrote the DMA transfer part. I just get some kind og fluctuating pulse signal on the output of my DAC...
Could someone help me figuring out if the problem comes from my code or from the hardware? To be honest I’m really lost here : every piece of code that I find online is different from the other and there’s not much resource for a beginner to start with...
You’ll find attached my main.c and my STM32F4xx_hal_msp.c.
I hope someone here can make it a bit clearer for me, it’s all mixed up in my head!
Thanks a lot