#include <buffer.h>


Go to the source code of this file.
Data Structures | |
| struct | usb_func_iface_ops |
| USB device interface driver operations. More... | |
| struct | usb_func_iface_setting |
| An alternate setting of an interface. More... | |
| struct | usb_func_iface |
| A USB device interface. More... | |
| struct | usb_func_config |
| A USB device configuration. More... | |
Functions | |
| void | usb_func_add_interface (struct usb_func_config *config, struct usb_func_iface *iface) |
| Add an interface to a configuration. | |
| struct usb_func_config * | usb_func_add_config (struct usb_configuration_descriptor *desc) |
| Add a device configuration. | |
Definition in file function_core.h.
| struct usb_func_config* usb_func_add_config | ( | struct usb_configuration_descriptor * | desc | ) | [read] |
Add a device configuration.
This function will add a new configuration of the device.
| desc | The configuration descriptor of the new configuration. |
Definition at line 185 of file usb_function_core.c.
References assert, usb_configuration_descriptor::bConfigurationValue, usb_configuration_descriptor::bNumInterfaces, dbg_printf, usb_func_config::desc, usb_func_config::interface, and memset().

| void usb_func_add_interface | ( | struct usb_func_config * | config, | |
| struct usb_func_iface * | iface | |||
| ) |
Add an interface to a configuration.
This function will associate an interface with an existing configuration so that it will be automatically enabled when the configuration is selected, and the interface descriptor(s) will be included in the configuration descriptor for this configuration.
If no high-speed descriptors are provided, they will be assumed to be the same as the full-speed descriptors.
| config | The USB function configuration. | |
| iface | The interface to be added to config. |
Definition at line 137 of file usb_function_core.c.
References assert, usb_interface_descriptor::bInterfaceNumber, dbg_printf, usb_func_iface_setting::fs_desc, usb_func_iface_setting::fs_desc_size, usb_func_iface_setting::hs_desc, usb_func_iface_setting::hs_desc_size, usb_func_config::interface, usb_func_iface::nr_settings, usb_func_iface_setting::ops, and usb_func_iface::setting.
1.5.8