RTEMS 6.1-rc4
Loading...
Searching...
No Matches
Data Structures
Spdif_edma

Data Structures

struct  _spdif_edma_transfer
 SPDIF transfer structure. More...
 
struct  _spdif_edma_handle
 SPDIF DMA transfer handle, users should not touch the content of the handle. More...
 

Driver version

typedef struct _spdif_edma_handle spdif_edma_handle_t
 
typedef void(* spdif_edma_callback_t) (SPDIF_Type *base, spdif_edma_handle_t *handle, status_t status, void *userData)
 SPDIF eDMA transfer callback function for finish and error.
 
typedef struct _spdif_edma_transfer spdif_edma_transfer_t
 SPDIF transfer structure.
 
#define FSL_SPDIF_EDMA_DRIVER_VERSION   (MAKE_VERSION(2, 0, 5))
 

eDMA Transactional

void SPDIF_TransferTxCreateHandleEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle, spdif_edma_callback_t callback, void *userData, edma_handle_t *dmaLeftHandle, edma_handle_t *dmaRightHandle)
 Initializes the SPDIF eDMA handle.
 
void SPDIF_TransferRxCreateHandleEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle, spdif_edma_callback_t callback, void *userData, edma_handle_t *dmaLeftHandle, edma_handle_t *dmaRightHandle)
 Initializes the SPDIF Rx eDMA handle.
 
status_t SPDIF_TransferSendEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle, spdif_edma_transfer_t *xfer)
 Performs a non-blocking SPDIF transfer using DMA.
 
status_t SPDIF_TransferReceiveEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle, spdif_edma_transfer_t *xfer)
 Performs a non-blocking SPDIF receive using eDMA.
 
void SPDIF_TransferAbortSendEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle)
 Aborts a SPDIF transfer using eDMA.
 
void SPDIF_TransferAbortReceiveEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle)
 Aborts a SPDIF receive using eDMA.
 
status_t SPDIF_TransferGetSendCountEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle, size_t *count)
 Gets byte count sent by SPDIF.
 
status_t SPDIF_TransferGetReceiveCountEDMA (SPDIF_Type *base, spdif_edma_handle_t *handle, size_t *count)
 Gets byte count received by SPDIF.
 

Detailed Description

Macro Definition Documentation

◆ FSL_SPDIF_EDMA_DRIVER_VERSION

#define FSL_SPDIF_EDMA_DRIVER_VERSION   (MAKE_VERSION(2, 0, 5))

Version 2.0.5

Function Documentation

◆ SPDIF_TransferAbortReceiveEDMA()

void SPDIF_TransferAbortReceiveEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle 
)

Aborts a SPDIF receive using eDMA.

Parameters
baseSPDIF base pointer
handleSPDIF eDMA handle pointer.

brief Aborts a SPDIF receive using eDMA.

param base SPDIF base pointer param handle SPDIF eDMA handle pointer.

◆ SPDIF_TransferAbortSendEDMA()

void SPDIF_TransferAbortSendEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle 
)

Aborts a SPDIF transfer using eDMA.

Parameters
baseSPDIF base pointer.
handleSPDIF eDMA handle pointer.

brief Aborts a SPDIF transfer using eDMA.

param base SPDIF base pointer. param handle SPDIF eDMA handle pointer.

◆ SPDIF_TransferGetReceiveCountEDMA()

status_t SPDIF_TransferGetReceiveCountEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle,
size_t *  count 
)

Gets byte count received by SPDIF.

Parameters
baseSPDIF base pointer
handleSPDIF eDMA handle pointer.
countBytes count received by SPDIF.
Return values
kStatus_SuccessSucceed get the transfer count.
kStatus_NoTransferInProgressThere is no non-blocking transaction in progress.

brief Gets byte count received by SPDIF.

param base SPDIF base pointer param handle SPDIF eDMA handle pointer. param count Bytes count received by SPDIF. retval kStatus_Success Succeed get the transfer count. retval kStatus_NoTransferInProgress There is no non-blocking transaction in progress.

◆ SPDIF_TransferGetSendCountEDMA()

status_t SPDIF_TransferGetSendCountEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle,
size_t *  count 
)

Gets byte count sent by SPDIF.

Parameters
baseSPDIF base pointer.
handleSPDIF eDMA handle pointer.
countBytes count sent by SPDIF.
Return values
kStatus_SuccessSucceed get the transfer count.
kStatus_NoTransferInProgressThere is no non-blocking transaction in progress.

brief Gets byte count sent by SPDIF.

param base SPDIF base pointer. param handle SPDIF eDMA handle pointer. param count Bytes count sent by SPDIF. retval kStatus_Success Succeed get the transfer count. retval kStatus_NoTransferInProgress There is no non-blocking transaction in progress.

◆ SPDIF_TransferReceiveEDMA()

status_t SPDIF_TransferReceiveEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle,
spdif_edma_transfer_t xfer 
)

Performs a non-blocking SPDIF receive using eDMA.

Note
This interface returns immediately after the transfer initiates. Call the SPDIF_GetReceiveRemainingBytes to poll the transfer status and check whether the SPDIF transfer is finished.
Parameters
baseSPDIF base pointer
handleSPDIF eDMA handle pointer.
xferPointer to DMA transfer structure.
Return values
kStatus_SuccessStart a SPDIF eDMA receive successfully.
kStatus_InvalidArgumentThe input argument is invalid.
kStatus_RxBusySPDIF is busy receiving data.

brief Performs a non-blocking SPDIF receive using eDMA.

note This interface returns immediately after the transfer initiates. Call the SPDIF_GetReceiveRemainingBytes to poll the transfer status and check whether the SPDIF transfer is finished.

param base SPDIF base pointer param handle SPDIF eDMA handle pointer. param xfer Pointer to DMA transfer structure. retval kStatus_Success Start a SPDIF eDMA receive successfully. retval kStatus_InvalidArgument The input argument is invalid. retval kStatus_RxBusy SPDIF is busy receiving data.

◆ SPDIF_TransferRxCreateHandleEDMA()

void SPDIF_TransferRxCreateHandleEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle,
spdif_edma_callback_t  callback,
void *  userData,
edma_handle_t dmaLeftHandle,
edma_handle_t dmaRightHandle 
)

Initializes the SPDIF Rx eDMA handle.

This function initializes the SPDIF slave DMA handle, which can be used for other SPDIF master transactional APIs. Usually, for a specified SPDIF instance, call this API once to get the initialized handle.

Parameters
baseSPDIF base pointer.
handleSPDIF eDMA handle pointer.
baseSPDIF peripheral base address.
callbackPointer to user callback function.
userDataUser parameter passed to the callback function.
dmaLeftHandleeDMA handle pointer for left channel, this handle shall be static allocated by users.
dmaRightHandleeDMA handle pointer for right channel, this handle shall be static allocated by users.

brief Initializes the SPDIF Rx eDMA handle.

This function initializes the SPDIF slave DMA handle, which can be used for other SPDIF master transactional APIs. Usually, for a specified SPDIF instance, call this API once to get the initialized handle.

param base SPDIF base pointer. param handle SPDIF eDMA handle pointer. param base SPDIF peripheral base address. param callback Pointer to user callback function. param userData User parameter passed to the callback function. param dmaLeftHandle eDMA handle pointer for left channel, this handle shall be static allocated by users. param dmaRightHandle eDMA handle pointer for right channel, this handle shall be static allocated by users.

◆ SPDIF_TransferSendEDMA()

status_t SPDIF_TransferSendEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle,
spdif_edma_transfer_t xfer 
)

Performs a non-blocking SPDIF transfer using DMA.

Note
This interface returns immediately after the transfer initiates. Call SPDIF_GetTransferStatus to poll the transfer status and check whether the SPDIF transfer is finished.
Parameters
baseSPDIF base pointer.
handleSPDIF eDMA handle pointer.
xferPointer to the DMA transfer structure.
Return values
kStatus_SuccessStart a SPDIF eDMA send successfully.
kStatus_InvalidArgumentThe input argument is invalid.
kStatus_TxBusySPDIF is busy sending data.

brief Performs a non-blocking SPDIF transfer using DMA.

note This interface returns immediately after the transfer initiates. Call SPDIF_GetTransferStatus to poll the transfer status and check whether the SPDIF transfer is finished.

param base SPDIF base pointer. param handle SPDIF eDMA handle pointer. param xfer Pointer to the DMA transfer structure. retval kStatus_Success Start a SPDIF eDMA send successfully. retval kStatus_InvalidArgument The input argument is invalid. retval kStatus_TxBusy SPDIF is busy sending data.

◆ SPDIF_TransferTxCreateHandleEDMA()

void SPDIF_TransferTxCreateHandleEDMA ( SPDIF_Type base,
spdif_edma_handle_t handle,
spdif_edma_callback_t  callback,
void *  userData,
edma_handle_t dmaLeftHandle,
edma_handle_t dmaRightHandle 
)

Initializes the SPDIF eDMA handle.

This function initializes the SPDIF master DMA handle, which can be used for other SPDIF master transactional APIs. Usually, for a specified SPDIF instance, call this API once to get the initialized handle.

Parameters
baseSPDIF base pointer.
handleSPDIF eDMA handle pointer.
baseSPDIF peripheral base address.
callbackPointer to user callback function.
userDataUser parameter passed to the callback function.
dmaLeftHandleeDMA handle pointer for left channel, this handle shall be static allocated by users.
dmaRightHandleeDMA handle pointer for right channel, this handle shall be static allocated by users.

brief Initializes the SPDIF eDMA handle.

This function initializes the SPDIF master DMA handle, which can be used for other SPDIF master transactional APIs. Usually, for a specified SPDIF instance, call this API once to get the initialized handle.

param base SPDIF base pointer. param handle SPDIF eDMA handle pointer. param base SPDIF peripheral base address. param callback Pointer to user callback function. param userData User parameter passed to the callback function. param dmaLeftHandle eDMA handle pointer for left channel, this handle shall be static allocated by users. param dmaRightHandle eDMA handle pointer for right channel, this handle shall be static allocated by users.