GetDescriptor
This function sends a GET_DESCRIPTOR request to a USB device.
USB_TRANSFER GetDescriptor(
USB_HANDLE hDevice,
LPTRANSFER_NOTIFY_ROUTINE lpStartAddress,
LPVOID lpvNotifyParameter,
DWORD dwFlags,
UCHAR bType,
UCHAR bIndex,
WORD wLanguage,
WORD wLength,
LPVOID lpvBuffer
);
Parameters
- hDevice
[in] Handle to a USB device. - lpStartAddress
[in] Pointer to the address of a callback routine, or NULL if no callback routine is necessary. - lpvNotifyParameter
[in] Pointer to the parameter to pass to a callback routine. - dwFlags
[in] Value of USB_NO_WAIT or zero (0). - bType
[in] Descriptor type. Set to USB_DEVICE_DESCRIPTOR_TYPE, USB_CONFIGURATION_DESCRIPTOR_TYPE, USB_STRING_DESCRIPTOR_TYPE, or a vendor-specific value. - bIndex
[in] Index within a descriptor. - wLanguage
[in] Language IDENTIFIER for string descriptors, zero (0) for others. - wLength
[in] Size of the buffer. - lpvBuffer
[in] Pointer to a buffer for descriptor data.
Return Values
A USB_TRANSFER handle indicates success. NULL indicates failure.
Remarks
This function initiates a control transfer to a USB device requesting device descriptor information. The device returns the contents of the device descriptor, starting at the index specified.
Requirements
OS Versions: Windows CE 2.10 and later.
Header: Usbd.hpp.
See Also
AbortTransfer | GetTransferStatus | IsTransferComplete | SetDescriptor | USB Drivers
Last updated on Tuesday, May 18, 2004
© 1992-2003 Microsoft Corporation. All rights reserved.