About SAI - DMA protocol
Hi,
I need to understand better how the "HAL_SAI_Receive_DMA(&hsai_BlockB1,ADC_Buffer,CodecBuffer_Size)" works.
I've a codec connected to the SAI 1 of a STMH723 MPU and I implemented a Ping-Pong routine to acquire and send the data to the Codec; two Callback function swap the buffers:
uint8_t ADC_Buffer[80000] __attribute__ ((aligned (4)));
void HAL_SAI_RxCpltCallback(SAI_HandleTypeDef *hsai_BlockB1){
adcp31=(q31_t *)&ADC_Buffer[BUFFER_SIZE_R/2];
RxDataReady1=1;
}
void HAL_SAI_RxHalfCpltCallback(SAI_HandleTypeDef *hsai_BlockB1){
adcp31=(q31_t *)&ADC_Buffer;
dacp31=(q31_t *)&DAC_Buffer;
RxDataReady=1;
}
If I write HAL_SAI_Receive_DMA(&hsai_BlockB1,ADC_Buffer,20000) what happens (in details) ?
Thank you
