8#ifndef _FSL_SAI_SDMA_H_
9#define _FSL_SAI_SDMA_H_
26#define FSL_SAI_SDMA_DRIVER_VERSION (MAKE_VERSION(2, 5, 3))
58#if defined(__cplusplus)
84 sdma_handle_t *dmaHandle,
85 uint32_t eventSource);
105 sdma_handle_t *dmaHandle,
106 uint32_t eventSource);
126 uint32_t mclkSourceClockHz,
127 uint32_t bclkSourceClockHz);
147 uint32_t mclkSourceClockHz,
148 uint32_t bclkSourceClockHz);
231#if defined(__cplusplus)
int32_t status_t
Type used for all status and error return values.
Definition: fsl_common.h:225
#define SAI_XFER_QUEUE_SIZE
SAI transfer queue size, user can refine it according to use case.
Definition: fsl_sai.h:204
void SAI_TransferTerminateReceiveSDMA(I2S_Type *base, sai_sdma_handle_t *handle)
Terminate all the SAI sdma receive transfer.
void SAI_TransferRxSetFormatSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_transfer_format_t *format, uint32_t mclkSourceClockHz, uint32_t bclkSourceClockHz)
Configures the SAI Rx audio format.
status_t SAI_TransferSendSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_transfer_t *xfer)
Performs a non-blocking SAI transfer using DMA.
void SAI_TransferTxSetFormatSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_transfer_format_t *format, uint32_t mclkSourceClockHz, uint32_t bclkSourceClockHz)
Configures the SAI Tx audio format.
status_t SAI_TransferReceiveSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_transfer_t *xfer)
Performs a non-blocking SAI receive using SDMA.
void SAI_TransferAbortReceiveSDMA(I2S_Type *base, sai_sdma_handle_t *handle)
Aborts a SAI receive using SDMA.
void SAI_TransferAbortSendSDMA(I2S_Type *base, sai_sdma_handle_t *handle)
Aborts a SAI transfer using SDMA.
void SAI_TransferTxSetConfigSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_transceiver_t *saiConfig)
void SAI_TransferTerminateSendSDMA(I2S_Type *base, sai_sdma_handle_t *handle)
Terminate all the SAI sdma send transfer.
void SAI_TransferRxSetConfigSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_transceiver_t *saiConfig)
void(* sai_sdma_callback_t)(I2S_Type *base, sai_sdma_handle_t *handle, status_t status, void *userData)
SAI SDMA transfer callback function for finish and error.
Definition: fsl_sai_sdma.h:32
void SAI_TransferRxCreateHandleSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_sdma_callback_t callback, void *userData, sdma_handle_t *dmaHandle, uint32_t eventSource)
Initializes the SAI Rx SDMA handle.
void SAI_TransferTxCreateHandleSDMA(I2S_Type *base, sai_sdma_handle_t *handle, sai_sdma_callback_t callback, void *userData, sdma_handle_t *dmaHandle, uint32_t eventSource)
Initializes the SAI SDMA handle.
Definition: MIMXRT1052.h:23296
SAI DMA transfer handle, users should not touch the content of the handle.
Definition: fsl_sai_sdma.h:36
uint32_t count
Definition: fsl_sai_sdma.h:43
sai_sdma_callback_t callback
Definition: fsl_sai_sdma.h:46
size_t transferSize[SAI_XFER_QUEUE_SIZE]
Definition: fsl_sai_sdma.h:50
volatile uint8_t queueDriver
Definition: fsl_sai_sdma.h:52
void * userData
Definition: fsl_sai_sdma.h:47
uint8_t channelNums
Definition: fsl_sai_sdma.h:40
sdma_handle_t * dmaHandle
Definition: fsl_sai_sdma.h:37
uint8_t channel
Definition: fsl_sai_sdma.h:39
volatile uint8_t queueUser
Definition: fsl_sai_sdma.h:51
sdma_buffer_descriptor_t bdPool[SAI_XFER_QUEUE_SIZE]
Definition: fsl_sai_sdma.h:48
uint8_t channelMask
Definition: fsl_sai_sdma.h:41
sai_transfer_t saiQueue[SAI_XFER_QUEUE_SIZE]
Definition: fsl_sai_sdma.h:49
uint32_t state
Definition: fsl_sai_sdma.h:44
uint32_t eventSource
Definition: fsl_sai_sdma.h:45
uint8_t fifoOffset
Definition: fsl_sai_sdma.h:42
uint8_t bytesPerFrame
Definition: fsl_sai_sdma.h:38
sai transceiver configurations
Definition: fsl_sai.h:395
SAI transfer structure.
Definition: fsl_sai.h:415