AN050
GD32 USBFS&USBHS Firmware Library User Guide
61
Device class
File name
Function name
Description
si.c
device
usbh_msc_test_unitready
send 'Test unit ready' command
to the device
usbh_msc_read_capacity10
send the read capacity
command to the device
usbh_msc_mode_sense6
send the mode sense6
command to the device
usbh_msc_request_sense
send the Request Sense
command to the device
usbh_msc_write10
send the write10 command to
the device
usbh_msc_read10
send the read10 command to
the device
usbh_msc_fat
fs.c
disk_initialize
initialize disk driver
disk_status
get disk status
disk_read
read sectors
disk_write
write sectors
disk_ioctl
I/O control function
get_fattime
get fat time
6.7.
USB Host Library Routine
6.7.1.
HID HOST
HID host rountine could be used to identify the keyboard and mouse, enumeration course
and data transfer phase is displayed in display screen.
Firstly, insert cable into USB connector, and then download HID_Host program file to EVAL
board and run the application.
If one mouse is connected, mouse enumeration information could be displayed on the display
screen. Depending on the tips of display screen, firstly, the inserted device could be viewed
as mouse, and then move mouse, the mouse position and key pressing state could be
displayed on the display screen.
If one keyboard is connected, keyboard enumeration information could be displayed on the
display screen. Depending on the tips of display screen, firstly, the inserted device could be
viewed as keyboard, and then press keyboard, the corresponding character could be
displayed on the display screen.