usb
Vitis Drivers API Documentation
xusb_mouse.h File Reference

Overview

This file contains the constants, type definitions, variables and function prototypes used in the mouse application.

Note
None.
MODIFICATION HISTORY:
Ver   Who  Date     Changes


1.00a hvm 3/30/07 First release 3.02a hvm 08/16/10 Updated with the little endian support changes.

 

Functions

void InitUsbInterface (XUsb *InstancePtr)
 This is the USB initialization function. More...
 
void UsbIfIntrHandler (void *CallBackRef, u32 IntrStatus)
 This function is the interrupt handler for the USB mass storage device application. More...
 
void Ep0IntrHandler (void *CallBackRef, u8 EpNum, u32 IntrStatus)
 This function is the interrupt handler for the USB End point Zero events. More...
 
void Ep1IntrHandler (void *CallBackRef, u8 EpNum, u32 IntrStatus)
 This function is the interrupt handler for the USB End point one events. More...
 

Function Documentation

void Ep0IntrHandler ( void *  CallBackRef,
u8  EpNum,
u32  IntrStatus 
)

This function is the interrupt handler for the USB End point Zero events.

Parameters
CallBackRefis the callback reference passed from the interrupt. handler, which in our case is a pointer to the driver instance.
EpNumis the end point number.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
EpNum is not used in this function as the handler is attached specific to end point zero. This parameter is useful when a single handler is used for processing all end point interrupts.

This function is the interrupt handler for the USB End point Zero events.

Parameters
CallBackRefis the callback reference passed from the caller function, which in our case is a pointer to the driver instance.
EpNumis the end point number.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
EpNum is not used in this function as the handler is attached specific to end point zero. This parameter is useful when a single handler is used for processing all end point interrupts.
void Ep1IntrHandler ( void *  CallBackRef,
u8  EpNum,
u32  IntrStatus 
)

This function is the interrupt handler for the USB End point one events.

Parameters
CallBackRefis the callback reference passed from the interrupt handler, which in our case is a pointer to the driver instance.
EpNumis the end point number.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
EpNum is not used in this function as the handler is attached specific to end point one. This parameter is useful when a single handler is used for processing all end point interrupts.

This function is the interrupt handler for the USB End point one events.

Parameters
CallBackRefis the callback reference passed from the caller function, which in our case is a pointer to the driver instance.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
EpNum is not used in this function as the handler is attached specific to end point one. This parameter is useful when a single handler is used for processing all end point interrupts.
void InitUsbInterface ( XUsb InstancePtr)

This is the USB initialization function.

This example initializes the device for Mass Storage Application. The following configuration is done.

  • EP0 : CONTROL end point, Bidirectional, Packet size 64 bytes.
  • EP1 : NON_ISOCHRONOUS, BULK_IN, packet size 512 bytes.
  • EP2 : NON_ISOCHRONOUS, BULK_OUT, packet size 512 bytes
Parameters
InstancePtris a pointer to the XUsb instance.
Returns
None.
Note
None.

This is the USB initialization function.

The following is the configuration.

  • EP0 : CONTROL end point, Bidirectional, Packet size 64 bytes.
  • EP1 : NON_ISOCHRONOUS, INTERRUPT_IN, packet size of 16 bytes.
Parameters
InstancePtris a pointer to the XUsb instance.
Returns
None.
Note
None.

This example initializes the device for Microphone Application. The following configuration is done.

  • EP0 : CONTROL end point, Bidirectional, Packet size 64 bytes.
  • EP1 : ISOCHRONOUS, BULK_IN, packet size 1024 bytes.
Parameters
InstancePtris a pointer to the XUsb instance.
Returns
None.
Note
None.

This example initializes the USB device for USB mouse example. The following configuration is done.

  • EP0 : CONTROL end point, Bidirectional, Packet size 64 bytes.
  • EP1 : NON_ISOCHRONOUS, INTERRUPT_IN, packet size of 16 bytes.
Parameters
InstancePtris a pointer to the XUsb instance.
Returns
None.
Note
None.
void UsbIfIntrHandler ( void *  CallBackRef,
u32  IntrStatus 
)

This function is the interrupt handler for the USB mass storage device application.

Parameters
CallBackRefis the callback reference passed from the interrupt handler, which in our case is a pointer to the driver instance.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
None.

This function is the interrupt handler for the USB mass storage device application.

Parameters
CallBackRefis the callback reference passed from the interrupt handler, which in our case is a pointer to the driver instance.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
Each interrupt source is disabled upon reception. This is to avoid the repetitive occurrence of the same event. This is done because these event conditions exist for few milliseconds.

This function is the interrupt handler for the USB mass storage device application.

Parameters
CallBackRefis the callback reference passed from the interrupt handler, which in our case is a pointer to the driver instance.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
None.

This function is the interrupt handler for the USB mass storage device application.

Parameters
CallBackRefis the callback reference passed from to the function, which in our case is a pointer to the driver instance.
IntrStatusis a bit mask indicating pending interrupts.
Returns
None.
Note
None.