![]() |
i2srx
Xilinx SDK Drivers API Documentation
|
This file contains a example for using the I2S receiver hardware device and I2S receiver driver using interrupt mode.This example assumes that the interrupt controller is also present as a part of the system.
MODIFICATION HISTORY:
Ver Who Date Changes
1.0 kar 01/25/18 First release
Functions | |
int | I2sRxIntrExample (INTC *IntcInstancePtr, XI2s_Rx *I2sRxInstancePtr, u16 DeviceId, u16 IntrId) |
This function does a minimal test on the I2S receiver device and driver as a design example. More... | |
void | I2sRxDisableIntr (INTC *IntcInstancePtr, u16 IntrId) |
This function disables the interrupts for the I2S receiver. More... | |
void | I2sRxAesBlockCmplIntrHandler (void *CallBackRef) |
This function is the handler which performs processing for the I2S receiver. More... | |
void | I2sRxOvrflwIntrHandler (void *CallBackRef) |
This function is the handler which performs processing for the I2S receiver. More... | |
int | main (void) |
This function is the main function of the I2S receiver example using Interrupts. More... | |
void I2sRxAesBlockCmplIntrHandler | ( | void * | CallBackRef | ) |
This function is the handler which performs processing for the I2S receiver.
It is called from an interrupt context when the I2S receiver receives a AES Block Complete Interrupt.
This handler provides an example of how to handle I2S receiver interrupts but is application specific.
CallBackRef | is a pointer to the callback function |
Referenced by I2sRxIntrExample().
void I2sRxDisableIntr | ( | INTC * | IntcInstancePtr, |
u16 | IntrId | ||
) |
This function disables the interrupts for the I2S receiver.
IntcInstancePtr | is a reference to the Interrupt Controller driver Instance. |
IntrId | is XPAR_<INTC_instance>_<i2s_rx_instance>_VEC_ID value from xparameters.h. |
int I2sRxIntrExample | ( | INTC * | IntcInstancePtr, |
XI2s_Rx * | I2sRxInstancePtr, | ||
u16 | DeviceId, | ||
u16 | IntrId | ||
) |
This function does a minimal test on the I2S receiver device and driver as a design example.
The purpose of this function is to illustrate how to use the XI2s_Rx component. It initializes a I2S receiver and then sets it up such that a periodic interrupt is generated.
This function uses interrupt driven mode of the I2S receiver.
IntcInstancePtr | is a pointer to the Interrupt Controller driver Instance |
I2sRxInstancePtr | is a pointer to the XI2s_Rx driver Instance |
DeviceId | is the XPAR_<i2s_rx_instance>_DEVICE_ID value from xparameters.h |
IntrId | is XPAR_<INTC_instance>_<i2s_rx_instance>_INTERRUPT_INTR value from xparameters.h |
References I2sRxAesBlockCmplIntrHandler(), I2sRxOvrflwIntrHandler(), XI2s_Rx_CfgInitialize(), XI2S_RX_CHMUX_XI2S_01, XI2s_Rx_Enable(), XI2S_RX_GINTR_EN_MASK, XI2S_RX_HANDLER_AES_BLKCMPLT, XI2S_RX_HANDLER_AUD_OVRFLW, XI2S_RX_INTR_AES_BLKCMPLT_MASK, XI2S_RX_INTR_AUDOVRFLW_MASK, XI2s_Rx_IntrEnable(), XI2s_Rx_LookupConfig(), XI2s_Rx_SetChMux(), XI2s_Rx_SetHandler(), and XI2s_Rx_SetSclkOutDiv().
Referenced by main().
void I2sRxOvrflwIntrHandler | ( | void * | CallBackRef | ) |
This function is the handler which performs processing for the I2S receiver.
It is called from an interrupt context when the I2S receiver receives a Underflow Interrupt.
This handler provides an example of how to handle I2S receiver interrupts but is application specific.
CallBackRef | is a pointer to the callback function |
Referenced by I2sRxIntrExample().
int main | ( | void | ) |
This function is the main function of the I2S receiver example using Interrupts.
None. |
References I2sRxIntrExample().