Ioctl_usbio_set_configuration – Motorola USB08 User Manual

Page 159

Advertising
background image

Universal USB Device Driver (USBIO)

Programming Interface

USB08 Evaluation Board

Designer Reference Manual

MOTOROLA

Universal USB Device Driver (USBIO)

159

IOCTL_USBIO_SET_CONFIGURATION

The IOCTL_USBIO_SET_CONFIGURATION operation is used to set
the device configuration.

lpInBuffer

Pointer to a buffer that contains an USBIO_SET_CONFIGURATION
(

page 195

) data structure. This data structure has to be filled completely

by the caller.

nInBufferSize

Specifies the size, in bytes, of the buffer pointed to by

lpInBuffer

,

which has to be sizeof(USBIO_SET_CONFIGURATION) for this
operation.

lpOutBuffer

Not used with this operation. Set to NULL.

nOutBufferSize

Not used with this operation. Set to zero.

Comments

A SET_CONFIGURATION request appears on the bus. The USBD
generates additional SET_INTERFACE requests on the bus if
necessary.

All available interfaces have to be configured, or the request will fail. The
number of interfaces and the alternate setting for each interface have to
be specified in the structure USBIO_SET_CONFIGURATION
(

page 195

).

All pipe handles associated with the device will be unbound and all
pending requests will be cancelled. If this request returns with success,
new pipe objects are available. The operation
IOCTL_USBIO_GET_CONFIGURATION_INFO (

page 166

) may be

used to query all available pipes and interfaces.

By default, the configuration descriptor that is reported by the device is
passed to the USBD. If an user-defined configuration descriptor is stored
with IOCTL_USBIO_STORE_CONFIG_DESCRIPTOR (

page 158

), this

descriptor is used.

Advertising