Software Drivers

xosd_intr.c File Reference


Detailed Description

This code contains interrupt related functions of Xilinx MVI Video On-Screen-Display device driver. Please see xosd.h for more details of the driver.

 MODIFICATION HISTORY:

 Ver	Who  Date     Changes
 ----- ---- -------- -------------------------------------------------------
 1.00a xd   08/18/08 First release
 2.00a cjm  12/18/12 Converted from xio.h to xil_io.h, translating
                     basic types, MB cache functions, exceptions and
                     assertions to xil_io format. 
 

#include "xosd.h"

Functions

void XOSD_IntrHandler (void *InstancePtr)
int XOSD_SetCallBack (XOSD *InstancePtr, u32 HandlerType, void *CallBackFunc, void *CallBackRef)


Function Documentation

void XOSD_IntrHandler void *  InstancePtr  ) 
 

This function is the interrupt handler for the On-Screen-Display driver.

This handler reads the pending interrupt from the IER/ISR, determines the source of the interrupts, calls according callbacks, and finally clears the interrupts.

The application is responsible for connecting this function to the interrupt system. Application beyond this driver is also responsible for providing callbacks to handle interrupts and installing the callbacks using XOSD_SetCallBack() during initialization phase. An example delivered with this driver demonstrates how this could be done.

Parameters:
InstancePtr is a pointer to the XOSD instance that just interrupted.
Returns:
None.
Note:
None.

int XOSD_SetCallBack XOSD InstancePtr,
u32  HandlerType,
void *  CallBackFunc,
void *  CallBackRef
 

This routine installs an asynchronous callback function for the given HandlerType:

 HandlerType		   Callback Function Type
 -----------------------  ---------------------------
 XOSD_HANDLER_VBISTART	   XOSD_CallBack
 XOSD_HANDLER_VBIEND	   XOSD_CallBack
 XOSD_HANDLER_FRAMEDONE   XOSD_CallBack
 XOSD_HANDLER_ERROR	   XOSD_ErrCallBack

 HandlerType		   Invoked by this driver when:
 -----------------------  --------------------------------------------------
 XOSD_HANDLER_VBISTART	   A Vertical Blank Interval Start Interrupt happens
 XOSD_HANDLER_VBIEND	   A Vertical Blank Interval End Interrupt happens
 XOSD_HANDLER_FRAMEDONE   A Frame Done Interrupt happens
 XOSD_HANDLER_ERROR	   An error condition happens

 

Parameters:
InstancePtr is a pointer to the XOSD instance to be worked on.
HandlerType specifies which callback is to be attached.
CallbackFunc is the address of the callback function.
CallbackRef is a user data item that will be passed to the callback function when it is invoked.
Returns:
  • XST_SUCCESS when handler is installed.
  • XST_INVALID_PARAM when HandlerType is invalid.
Note:
Invoking this function for a handler that already has been installed replaces it with the new handler.
Copyright @ 1995-2014 Xilinx, Inc. All rights reserved.