# 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
…
- 102
- 103
- 104
- 105
- 106
…
- 311
- 312

Syntax
bool USBHostDeviceSpecificClientDriver(uint8_t deviceAddress);
Description
This function indicates if the specified device has explicit client driver support specified in the TPL. It is used in client drivers'
USB_CLIENT_INIT routines to indicate that the client driver should be used even though the class, subclass, and protocol
values may not match those normally required by the class. For example, some printing devices do not fulfill all of the
requirements of the printer class, so their class, subclass, and protocol fields indicate a custom driver rather than the printer
class. But the printer class driver can still be used, with minor limitations.
Remarks
This function is used so client drivers can allow certain devices to enumerate. For example, some printer devices indicate a
custom class rather than the printer class, even though the device has only minor limitations from the full printer class. The
printer client driver will fail to initialize the device if it does not indicate printer class support in its interface descriptor. The
printer client driver could allow any device with an interface that matches the printer class endpoint configuration, but both
printer and mass storage devices utilize one bulk IN and one bulk OUT endpoint. So a mass storage device would be
erroneously initialized as a printer device. This function allows a client driver to know that the client driver support was
specified explicitly in the TPL, so for this particular device only, the class, subclass, and protocol fields can be safely ignored.
Preconditions
None
Parameters
Parameters Description
uint8_t deviceAddress Address of device
Return Values
Return Values Description
true This device is listed in the TPL by VID andPID, and has
explicit client driver support.
false This device is not listed in the TPL by VID and PID.
Function
bool USBHostDeviceSpecificClientDriver( uint8_t deviceAddress )
1.4.2.1.1.6 USBHostDeviceStatus Function
This function returns the current status of a device.
File
usb_host.h
Syntax
uint8_t USBHostDeviceStatus(uint8_t deviceAddress);
Description
This function returns the current status of a device. If the device is in a holding state due to an error, the error is returned.
Remarks
None
Preconditions
None
1.4 Library Interface MLA - USB Library Help Embedded Host API
104

- 1
- 2
…
- 102
- 103
- 104
- 105
- 106
…
- 311
- 312