Microchip® Advanced Software Framework

common/services/usb/class/cdc/host/example/ui.h File Reference

Common User Interface for USB host MSC application.

Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries.

#include "uhc.h"

Functions

void ui_com_error (void)
 Called when a communication error occur. More...
 
void ui_com_overflow (void)
 Called when an overflow occur. More...
 
void ui_com_rx_start (void)
 Called when a data is received on CDC. More...
 
void ui_com_rx_stop (void)
 Called when all pending data are sent on com port. More...
 
void ui_com_tx_start (void)
 Called when a data is received on com port. More...
 
void ui_com_tx_stop (void)
 Called when all pending data are sent on CDC. More...
 
void ui_init (void)
 Initializes the user interface. More...
 
void ui_usb_connection_event (uhc_device_t *dev, bool b_present)
 Notify that a USB device has been connected or disconnected. More...
 
void ui_usb_enum_event (uhc_device_t *dev, uhc_enum_status_t status)
 Notify the end of a USB device enumeration. More...
 
void ui_usb_mode_change (bool b_host_mode)
 Notify that the USB mode has automatically switched. This is only possible when the ID pin is available. More...
 
void ui_usb_sof_event (void)
 Notify that a SOF has been sent (each 1 ms) More...
 
void ui_usb_vbus_change (bool b_vbus_present)
 Notify that a new Vbus transition has been detected. Available only in USB hardware with Vbus monitoring. More...
 
void ui_usb_vbus_error (void)
 Notify that a Vbus error has occurred Available only in USB hardware with Vbus monitoring. More...
 
void ui_usb_wakeup_event (void)
 Notify that a USB device or the host has woken up the USB line. More...
 

void ui_com_error ( void  )

Called when a communication error occur.

void ui_com_overflow ( void  )

Called when an overflow occur.

Called when an overflow occur.

void ui_com_rx_start ( void  )

Called when a data is received on CDC.

void ui_com_rx_stop ( void  )

Called when all pending data are sent on com port.

Called when all pending data are sent on com port.

void ui_com_tx_start ( void  )

Called when a data is received on com port.

Called when a data is received on com port.

void ui_com_tx_stop ( void  )

Called when all pending data are sent on CDC.

Called when all pending data are sent on CDC.

void ui_init ( void  )

Initializes the user interface.

void ui_usb_connection_event ( uhc_device_t dev,
bool  b_present 
)

Notify that a USB device has been connected or disconnected.

Parameters
devPointer on USB device information
b_presenttrue, if the device has been connected
void ui_usb_enum_event ( uhc_device_t dev,
uhc_enum_status_t  status 
)

Notify the end of a USB device enumeration.

Parameters
devPointer on USB device information
statusStatus of the USB enumeration
void ui_usb_mode_change ( bool  b_host_mode)

Notify that the USB mode has automatically switched. This is only possible when the ID pin is available.

Parameters
b_host_modetrue, if the host mode has been selected
void ui_usb_sof_event ( void  )

Notify that a SOF has been sent (each 1 ms)

void ui_usb_vbus_change ( bool  b_vbus_present)

Notify that a new Vbus transition has been detected. Available only in USB hardware with Vbus monitoring.

Parameters
b_vbus_presenttrue, if Vbus is high.
void ui_usb_vbus_error ( void  )

Notify that a Vbus error has occurred Available only in USB hardware with Vbus monitoring.

void ui_usb_wakeup_event ( void  )

Notify that a USB device or the host has woken up the USB line.