# Vault 7: Projects

This publication series is about specific projects related to the Vault 7 main publication.

### Protego

# MLA -- USB Library

20 December, 2013

- 1
- 2
…
- 163
- 164
- 165
- 166
- 167
…
- 311
- 312

Module
CDC Client Driver
Description
This is file usb_host_cdc_interface.h.
1.4.2.3 HID Client Driver
This client driver provides USB Embedded Host support for HID devices.
Files
Name Description
usb_host_hid.h This is file usb_host_hid.h.
usb_host_hid_parser.h This is file usb_host_hid_parser.h.
Description
This client driver provides USB Embedded Host support for HID devices. Common HID devices include mice, keyboards,
and bar code scanners. Many other USB peripherals also use the HID class to transfer data, since it provides a simple,
flexible interface and does not require a custom Windows driver when used with a PC.
See AN1144 - USB HID Class on an Embedded Host and AN1212 - Using USB Keyboard with an Embedded Host for more
information.
1.4.2.3.1 Functions
Functions
Name Description
USBHostHID_ApiFindBit This function is used to locate a specific button or indicator. Once
the report descriptor is parsed by the HID layer without any error,
data from the report descriptor is stored in pre defined dat
structures. This function traverses these data structure and exract
data required by application
USBHostHID_ApiFindValue Find a specific Usage Value. Once the report descriptor is parsed
by the HID layer without any error, data from the report descriptor is
stored in pre defined dat structures. This function traverses these
data structure and exract data required by application.
USBHostHID_ApiGetCurrentInterfaceNum This function reurns the interface number of the cuurent report
descriptor parsed. This function must be called to fill data interface
detail data structure and passed as parameter when requesinf for
report transfers.
USBHostHID_ApiImportData This function can be used by application to extract data from the
input reports. On receiving the input report from the device
application can call the function with required inputs
'HID_DATA_DETAILS'.
USBHostHID_HasUsage This function is used to locate the usage in a report descriptor.
Function will look into the data structures created by the HID parser
and return the appropriate location.
USBHostHIDDeviceDetect This function determines if a HID device is attached and ready to
use.
USBHostHIDDeviceStatus
USBHostHIDEventHandler This function is the event handler for this client driver.
USBHostHIDInitialize This function is the initialization routine for this client driver.
USBHostHIDResetDevice This function starts a HID reset.
1.4 Library Interface MLA - USB Library Help Embedded Host API
165

- 1
- 2
…
- 163
- 164
- 165
- 166
- 167
…
- 311
- 312