...
usbd_msc.h / usbd_msc.c
Prototype
| Code Block | ||
|---|---|---|
| ||
CPU_BOOLEAN USBD_MSC_CfgAdd (CPU_INT08U class_nbr,
CPU_INT08U dev_nbr,
CPU_INT08U cfg_nbr,
USBD_ERR *p_err); |
Arguments
class_nbr
MSC instance number.
...
|-- Endpoint Descriptor (Bulk IN) If USBD_MSC_CfgAdd() is called several times from the application, it allows to create multiple instances and multiple configurations. For instance, the following architecture could be created for an high-speed device:
...
|-- Interface 0 (MSC 0)
|-- Interface 1 (MSC 1) In that example, there are two instances of MSC: 'MSC 0' and 'MSC 1', and two possible configurations for the device: 'Configuration 0' and 'Configuration 1'. 'Configuration 1' is composed of two interfaces. Each class instance has an association with one of the interfaces. If 'Configuration 1' is activated by the host, it allows the host to access two different functionalities offered by the device.