iomodule
Vitis Drivers API Documentation
xiomodule.h File Reference

Data Structures

struct  XIOModule_Config
 This typedef contains configuration information for the device. More...
 
struct  XIOModule_Uart_Stats
 Statistics for the UART. More...
 
struct  XIOModule_Buffer
 The following data type is used to manage the buffers that are handled when sending and receiving UART data in the interrupt mode. More...
 
struct  XIOModule_Timer_Stats
 Programmable Interval Timer statistics. More...
 
struct  XIOModule
 The XIOModule driver instance data. More...
 

Typedefs

typedef void(* XIOModule_Handler )(void *CallBackRef, unsigned int ByteCount)
 Callback function. More...
 
typedef void(* XIOModule_Timer_Handler )(void *CallBackRef, u8 TimerNumber)
 Signature for the timer callback function. More...
 

Functions

s32 XIOModule_Initialize (XIOModule *InstancePtr, u16 DeviceId)
 Initialize a specific interrupt controller instance/driver. More...
 
s32 XIOModule_Timer_Initialize (XIOModule *InstancePtr, u16 DeviceId)
 Initializes a specific timer instance/driver. More...
 
s32 XIOModule_Start (XIOModule *InstancePtr)
 Starts the IO Module. More...
 
void XIOModule_Stop (XIOModule *InstancePtr)
 Stops the interrupt controller by disabling the output from the controller so that no interrupts will be caused by the interrupt controller. More...
 
s32 XIOModule_Connect (XIOModule *InstancePtr, u8 Id, XInterruptHandler Handler, void *CallBackRef)
 Makes the connection between the Id of the interrupt source and the associated handler that is to run when the interrupt is recognized. More...
 
void XIOModule_Disconnect (XIOModule *InstancePtr, u8 Id)
 Updates the interrupt table with the Null Handler and NULL arguments at the location pointed at by the Id. More...
 
void XIOModule_Enable (XIOModule *InstancePtr, u8 Id)
 Enables the interrupt source provided as the argument Id. More...
 
void XIOModule_Disable (XIOModule *InstancePtr, u8 Id)
 Disables the interrupt source provided as the argument Id such that the interrupt controller will not cause interrupts for the specified Id. More...
 
void XIOModule_Acknowledge (XIOModule *InstancePtr, u8 Id)
 Acknowledges the interrupt source provided as the argument Id. More...
 
XIOModule_ConfigXIOModule_LookupConfig (u16 DeviceId)
 Looks up the device configuration based on the unique device ID. More...
 
s32 XIOModule_ConnectFastHandler (XIOModule *InstancePtr, u8 Id, XFastInterruptHandler Handler)
 Makes the connection between the Id of the interrupt source and the associated handler that is to run when the interrupt is recognized. More...
 
void XIOModule_SetNormalIntrMode (XIOModule *InstancePtr, u8 Id)
 Sets the normal interrupt mode for the specified interrupt in the Interrupt Mode Register, by resetting the vector to (BaseVector & 0xFFFFFF80) | 0x10 and selecting normal mode. More...
 
u32 XIOModule_DiscreteRead (XIOModule *InstancePtr, u32 Channel)
 Read state of discretes for the specified GPI channel. More...
 
void XIOModule_DiscreteWrite (XIOModule *InstancePtr, u32 Channel, u32 Data)
 Write to discretes register for the specified GPO channel. More...
 
void XIOModule_DiscreteSet (XIOModule *InstancePtr, u32 Channel, u32 Mask)
 Set output discrete(s) to logic 1 for the specified GPO channel. More...
 
void XIOModule_DiscreteClear (XIOModule *InstancePtr, u32 Channel, u32 Mask)
 Set output discrete(s) to logic 0 for the specified GPO channel. More...
 
s32 XIOModule_CfgInitialize (XIOModule *InstancePtr, XIOModule_Config *Config, u32 EffectiveAddr)
 Initialize a XIOModule instance. More...
 
void XIOModule_ResetFifos (XIOModule *InstancePtr)
 This function does nothing, since the UART doesn't have any FIFOs. More...
 
u32 XIOModule_Send (XIOModule *InstancePtr, u8 *DataBufferPtr, u32 NumBytes)
 This functions sends the specified buffer of data using the UART in either polled or interrupt driven modes. More...
 
u32 XIOModule_Recv (XIOModule *InstancePtr, u8 *DataBufferPtr, u32 NumBytes)
 This function will attempt to receive a specified number of bytes of data from the UART and store it into the specified buffer. More...
 
s32 XIOModule_IsSending (XIOModule *InstancePtr)
 This function determines if the specified UART is sending data. More...
 
s32 XIOModule_SetBaudRate (XIOModule *InstancePtr, u32 BaudRate)
 Sets the baud rate for the specified UART. More...
 
void XIOModule_GetStats (XIOModule *InstancePtr, XIOModule_Uart_Stats *StatsPtr)
 Returns a snapshot of the current statistics in the structure specified. More...
 
void XIOModule_ClearStats (XIOModule *InstancePtr)
 This function zeros the statistics for the given instance. More...
 
void XIOModule_InterruptHandler (XIOModule *InstancePtr)
 The interrupt handler for the driver. More...
 
void XIOModule_Uart_EnableInterrupt (XIOModule *InstancePtr)
 This function enables the UART interrupts such that an interrupt will occur when data is received or data has been transmitted. More...
 
void XIOModule_Uart_DisableInterrupt (XIOModule *InstancePtr)
 This function disables the UART interrupt. More...
 
void XIOModule_SetRecvHandler (XIOModule *InstancePtr, XIOModule_Handler FuncPtr, void *CallBackRef)
 This function sets the handler that will be called when an event (interrupt) occurs in the driver for the UART. More...
 
void XIOModule_SetSendHandler (XIOModule *InstancePtr, XIOModule_Handler FuncPtr, void *CallBackRef)
 This function sets the handler that will be called when an event (interrupt) occurs in the driver for the UART. More...
 
void XIOModule_Uart_InterruptHandler (XIOModule *InstancePtr)
 This function is the interrupt handler for the UART. More...
 
s32 XIOModule_SetOptions (XIOModule *InstancePtr, u32 Options)
 Set the options for the interrupt controller driver. More...
 
u32 XIOModule_GetOptions (XIOModule *InstancePtr)
 Return the currently set options. More...
 
s32 XIOModule_SelfTest (XIOModule *InstancePtr)
 Runs a self-test on the timer and interrupt controller driver/device. More...
 
void XIOModule_Timer_Start (XIOModule *InstancePtr, u8 TimerNumber)
 Starts the specified timer counter of the device such that it starts running. More...
 
void XIOModule_Timer_Stop (XIOModule *InstancePtr, u8 TimerNumber)
 Stops the timer by disabling it. More...
 
u32 XIOModule_GetValue (XIOModule *InstancePtr, u8 TimerNumber)
 Get the current value of the specified timer counter. More...
 
void XIOModule_SetResetValue (XIOModule *InstancePtr, u8 TimerNumber, u32 ResetValue)
 Set the reset value for the specified timer counter. More...
 
u32 XIOModule_GetCaptureValue (XIOModule *InstancePtr, u8 TimerNumber)
 Returns the timer counter value that was captured the last time the external capture input was asserted. More...
 
s32 XIOModule_IsExpired (XIOModule *InstancePtr, u8 TimerNumber)
 Checks if the specified timer counter of the device has expired. More...
 
void XIOModule_Reset (XIOModule *InstancePtr, u8 TimerNumber)
 Resets the specified timer counter of the device. More...
 
void XIOModule_Timer_SetOptions (XIOModule *InstancePtr, u8 TimerNumber, u32 Options)
 Enables the specified options for the specified timer . More...
 
u32 XIOModel_Timer_GetOptions (XIOModule *InstancePtr, u8 TimerNumber)
 Get the options for the specified timer. More...
 
s32 XIOModule_Timer_SelfTest (XIOModule *InstancePtr, u8 TimerNumber)
 Runs a self-test on the timer driver/device. More...
 
int XIOModule_Intc_SelfTest (XIOModule *InstancePtr)
 Run a self-test on the interrupt controller driver/device. More...
 
void XIOModule_SetHandler (XIOModule *InstancePtr, XIOModule_Timer_Handler FuncPtr, void *CallBackRef)
 Sets the timer callback function, which the driver calls when the specified timer times out. More...
 
void XIOModule_Timer_InterruptHandler (void *InstancePtr)
 Interrupt Service Routine (ISR) for the driver. More...
 
u32 XIOModule_IoReadWord (XIOModule *InstancePtr, u32 ByteOffset)
 Read 32-bit word from the IO Bus memory mapped IO. More...
 
u16 XIOModule_IoReadHalfword (XIOModule *InstancePtr, u32 ByteOffset)
 Read 16-bit halfword from the IO Bus memory mapped IO. More...
 
u8 XIOModule_IoReadByte (XIOModule *InstancePtr, u32 ByteOffset)
 Read byte from the IO Bus memory mapped IO. More...
 
void XIOModule_IoWriteWord (XIOModule *InstancePtr, u32 ByteOffset, u32 Data)
 Write 32-bit word to the IO Bus memory mapped IO. More...
 
void XIOModule_IoWriteHalfword (XIOModule *InstancePtr, u32 ByteOffset, u16 Data)
 Write 16-bit word to the IO Bus memory mapped IO. More...
 
void XIOModule_IoWriteByte (XIOModule *InstancePtr, u32 ByteOffset, u8 Data)
 Write 8-bit word to the IO Bus memory mapped IO. More...