| usbpsu Vitis Drivers API Documentation

- Overview
- Data Structures
- APIs
- File List
- Examples

Functions
xusb_class_audio_dfu.h File Reference

## Overview

This file contains definitions used in the AUDIO-DFU composite class code.

    MODIFICATION HISTORY:

    Ver   Who  Date     Changes

    1.0   rb   22/02/18 First release

## Functions
s32 | Usb_DfuSetState (struct dfu_if *DFU, u8 dfu_state)
| This function handles setting of DFU state. More...
void | USB_DfuSetDwloadState (struct dfu_if *DFU, u8 *status)
| This function updates the current state while downloading a file. More...
void | USB_DfuGetStatus (struct dfu_if *DFU, u8 *status)
| This function handles getting of DFU status. More...
void | Usb_DisconnectHandler (struct Usb_DevData *InstancePtr)
| This function handles USB disconnect, called from driver. More...
void | Usb_ResetHandler (struct Usb_DevData *InstancePtr)
| This function handles USB reset, called from driver. More...
void | Usb_SetIntf (struct Usb_DevData *InstancePtr, SetupPacket *SetupData)
| This function handles set interface request. More...
void | Usb_ClassReq (struct Usb_DevData *InstancePtr, SetupPacket *SetupData)
| This function is class request handler for composite device Setup packet received is for Class request(not a Standard Device request) More...

## Function Documentation

void Usb_ClassReq | ( | struct Usb_DevData * | InstancePtr,
|  | SetupPacket * | SetupData
| ) |  |

This function is class request handler for composite device Setup packet received is for Class request(not a Standard Device request)

Parameters

  InstancePtr | is pointer to Usb_DevData instance.
  SetupData | is pointer to SetupPacket received.

Returns
  None

Note
  None.

This function is class request handler for composite device Setup packet received is for Class request(not a Standard Device request)

Parameters

  InstancePtr | is pointer to Usb_DevData instance.
  SetupData | is the setup packet received from Host.

Note
  None.

void USB_DfuGetStatus | ( | struct dfu_if * | DFU,
|  | u8 * | status
| ) |  |

This function handles getting of DFU status.

Parameters

  DFU | is a pointer to DFU instance of the controller
  status | is the pointer of the DFU status

Returns
  None

Note
  None.

Parameters

  DFU | is a pointer to DFU instance of the controller
  status | is the pointer of the DFU status

Returns
  - XST_SUCCESS if the function is successful.

Note
  None.

void USB_DfuSetDwloadState | ( | struct dfu_if * | DFU,
|  | u8 * | status
| ) |  |

This function updates the current state while downloading a file.

Parameters

  DFU | is a pointer to DFU instance of the controller
  status | is a pointer of the DFU status

Note
  None.

s32 Usb_DfuSetState | ( | struct dfu_if * | DFU,
|  | u8 | dfu_state
| ) |  |

This function handles setting of DFU state.

Parameters

  DFU | is a pointer to DFU instance of the controller
  dfu_state | is a value of the DFU state to be set

Returns
  - XST_SUCCESS if the function is successful.
  - XST_FAILURE if an Error occurred.

Note
  None.

void Usb_DisconnectHandler | ( | struct Usb_DevData * | InstancePtr | ) |

This function handles USB disconnect, called from driver.

Parameters

  InstancePtr | is a pointer to Usb_DevData instance of the controller

Returns
  None.

Note
  None.

void Usb_ResetHandler | ( | struct Usb_DevData * | InstancePtr | ) |

This function handles USB reset, called from driver.

Parameters

  InstancePtr | is a pointer to Usb_DevData instance of the controller

Returns
  None.

Note
  None.

void Usb_SetIntf | ( | struct Usb_DevData * | InstancePtr,
|  | SetupPacket * | SetupData
| ) |  |

This function handles set interface request.

Parameters

  InstancePtr | is a pointer to Usb_DevData instance of the controller
  SetupData | is a pointer to setup token of control transfer

Returns
  None.

Note
  None.