7#ifndef _FSL_ASRC_P2P_EDMA_H_
8#define _FSL_ASRC_P2P_EDMA_H_
24#define FSL_ASRC_EDMA_DRIVER_VERSION (MAKE_VERSION(2, 1, 0))
27#define ASRC_XFER_IN_QUEUE_SIZE 4U
28#define ASRC_XFER_OUT_QUEUE_SIZE (ASRC_XFER_QUEUE_SIZE * 2U)
93#if defined(__cplusplus)
159 uint32_t inSampleRate,
160 uint32_t outSampleRate);
238#if defined(__cplusplus)
enum _asrc_channel_pair asrc_channel_pair_t
ASRC channel pair mask.
struct _asrc_in_edma_handle asrc_in_edma_handle_t
void ASRC_TransferOutCreateHandleEDMA(ASRC_Type *base, asrc_edma_handle_t *handle, asrc_channel_pair_t channelPair, asrc_edma_callback_t callback, edma_handle_t *outDmaHandle, const asrc_p2p_edma_config_t *periphConfig, void *userData)
Initializes the ASRC OUT eDMA handle.
Definition: fsl_asrc_edma.c:164
void ASRC_TransferInTerminalEDMA(ASRC_Type *base, asrc_edma_handle_t *handle)
Terminate In ASRC Convert.
Definition: fsl_asrc_edma.c:424
struct _asrc_out_edma_handle asrc_out_edma_handle_t
void(* asrc_edma_callback_t)(ASRC_Type *base, asrc_edma_handle_t *handle, status_t status, void *userData)
ASRC eDMA transfer callback function for finish and error.
Definition: fsl_asrc_edma.h:33
void ASRC_TransferInCreateHandleEDMA(ASRC_Type *base, asrc_edma_handle_t *handle, asrc_channel_pair_t channelPair, asrc_edma_callback_t callback, edma_handle_t *inDmaHandle, const asrc_p2p_edma_config_t *periphConfig, void *userData)
Initializes the ASRC IN eDMA handle.
Definition: fsl_asrc_edma.c:117
void(* asrc_start_peripheral_t)(bool start)
ASRC trigger peripheral function pointer.
Definition: fsl_asrc_edma.h:36
void ASRC_TransferOutAbortEDMA(ASRC_Type *base, asrc_edma_handle_t *handle)
Aborts a ASRC OUT transfer using eDMA.
Definition: fsl_asrc_edma.c:400
void ASRC_TransferInAbortEDMA(ASRC_Type *base, asrc_edma_handle_t *handle)
Aborts a ASRC IN transfer using eDMA.
Definition: fsl_asrc_edma.c:376
status_t ASRC_TransferSetChannelPairConfigEDMA(ASRC_Type *base, asrc_edma_handle_t *handle, asrc_channel_pair_config_t *asrcConfig, uint32_t inSampleRate, uint32_t outSampleRate)
Configures the ASRC P2P channel pair.
Definition: fsl_asrc_edma.c:207
#define ASRC_XFER_IN_QUEUE_SIZE
ASRC IN edma QUEUE size.
Definition: fsl_asrc_edma.h:27
void ASRC_TransferOutTerminalEDMA(ASRC_Type *base, asrc_edma_handle_t *handle)
Terminate Out ASRC Convert.
Definition: fsl_asrc_edma.c:453
struct _asrc_p2p_edma_config asrc_p2p_edma_config_t
destination peripheral configuration
status_t ASRC_TransferEDMA(ASRC_Type *base, asrc_edma_handle_t *handle, asrc_transfer_t *xfer)
Performs a non-blocking ASRC m2m convert using EDMA.
Definition: fsl_asrc_edma.c:350
uint32_t ASRC_GetOutSamplesSizeEDMA(ASRC_Type *base, asrc_edma_handle_t *handle, uint32_t inSampleRate, uint32_t outSampleRate, uint32_t inSamplesize)
Get output sample buffer size can be transferred by edma.
Definition: fsl_asrc_edma.c:241
int32_t status_t
Type used for all status and error return values.
Definition: fsl_common.h:225
Definition: MIMXRT1166_cm4.h:9338
asrc channel pair configuation
Definition: fsl_asrc.h:274
ASRC DMA transfer handle.
Definition: fsl_asrc_edma.h:82
asrc_channel_pair_t channelPair
Definition: fsl_asrc_edma.h:85
void * userData
Definition: fsl_asrc_edma.h:86
asrc_in_edma_handle_t in
Definition: fsl_asrc_edma.h:83
asrc_edma_callback_t callback
Definition: fsl_asrc_edma.h:87
asrc_out_edma_handle_t out
Definition: fsl_asrc_edma.h:84
Definition: fsl_asrc_edma.h:47
uint32_t sampleWidth
Definition: fsl_asrc_edma.h:52
const asrc_p2p_edma_config_t * peripheralConfig
Definition: fsl_asrc_edma.h:60
volatile uint8_t queueDriver
Definition: fsl_asrc_edma.h:57
uint32_t * asrcQueue[ASRC_XFER_IN_QUEUE_SIZE]
Definition: fsl_asrc_edma.h:54
uint32_t state
Definition: fsl_asrc_edma.h:58
edma_handle_t * inDmaHandle
Definition: fsl_asrc_edma.h:48
size_t transferSize[ASRC_XFER_IN_QUEUE_SIZE]
Definition: fsl_asrc_edma.h:55
uint32_t fifoThreshold
Definition: fsl_asrc_edma.h:53
volatile uint8_t queueUser
Definition: fsl_asrc_edma.h:56
uint8_t tcd[(ASRC_XFER_IN_QUEUE_SIZE+1U) *sizeof(edma_tcd_t)]
Definition: fsl_asrc_edma.h:50
Definition: fsl_asrc_edma.h:65
uint32_t * asrcQueue[ASRC_XFER_OUT_QUEUE_SIZE]
Definition: fsl_asrc_edma.h:72
edma_handle_t * outDmaHandle
Definition: fsl_asrc_edma.h:66
uint32_t state
Definition: fsl_asrc_edma.h:76
volatile uint8_t queueUser
Definition: fsl_asrc_edma.h:74
uint32_t fifoThreshold
Definition: fsl_asrc_edma.h:71
volatile uint8_t queueDriver
Definition: fsl_asrc_edma.h:75
uint8_t tcd[(ASRC_XFER_OUT_QUEUE_SIZE+1U) *sizeof(edma_tcd_t)]
Definition: fsl_asrc_edma.h:68
size_t transferSize[ASRC_XFER_OUT_QUEUE_SIZE]
Definition: fsl_asrc_edma.h:73
const asrc_p2p_edma_config_t * peripheralConfig
Definition: fsl_asrc_edma.h:77
uint32_t sampleWidth
Definition: fsl_asrc_edma.h:70
destination peripheral configuration
Definition: fsl_asrc_edma.h:39
uint8_t channel
Definition: fsl_asrc_edma.h:41
uint8_t watermark
Definition: fsl_asrc_edma.h:40
asrc_start_peripheral_t startPeripheral
Definition: fsl_asrc_edma.h:42
SAI transfer structure.
Definition: fsl_asrc.h:302
eDMA transfer handle structure
Definition: fsl_edma.h:244
eDMA TCD.
Definition: fsl_edma.h:205