How to configure audio output over USB using NULCEO-L476RG?
Hi,
I want to create a simple device that streams audio from a PC to a loudspeaker via NUCLEO-L476RG board. The connection to a PC is implemented via USB connector on the X-NUCLEO-CCA02M2 board, which is plugged into NUCLEO-L476RG.
I've configured the project using STM32CubeIDE.
The USB inputs are set for Audio Device Class and I'm using SAI1 block for audio output. The SAI1 block should take the audio data from the DMA buffer.
In terms of firmware modifications, I only implement the changes that are mentioned here:
https://www.programmersought.com/article/90827167498/
The only difference is that I changed I2S HAL functions to their SAI alternatives.
Currently the issue is that, although the device is recognised by a PC as an Audio Class device, it doesn't output any data via I2S pins. Through debugging I figured out that the device doesn't enter the USBD_AUDIO_DataOut() function in usbd_audio.c file, although it fully implements USBD_AUDIO_Init().
Could anyone tell me how to approch this issuse or give a hint on why USBD_AUDIO_DataOut() function is not implemented?
Regards,
Pavels
