Partager via


LPSET_FEATURE (Windows Embedded CE 6.0)

1/6/2010

This function sends a SET_FEATURE request to a universal serial bus (USB) device.

Syntax

typedef USB_TRANSFER (* LPSET_FEATURE)(
  USB_HANDLE hDevice, 
  LPTRANSFER_NOTIFY_ROUTINE lpStartAddress,
  LPVOID lpvNotifyParameter, 
  DWORD dwFlags, 
  WORD wFeature, 
  UCHAR bIndex
);

Parameters

  • hDevice
    [in] Handle to a USB device.
  • lpvNotifyParameter
    [in] Pointer to the parameter to pass to a callback routine.
  • dwFlags
    [in] Value of USB_NO_WAIT or zero (0), and one of the values from the following table.

    Value Description

    USB_SEND_TO_DEVICE

    Request for device.

    USB_SEND_TO_INTERFACE

    Request for interface.

    USB_SEND_TO_ENDPOINT

    Request for endpoint, default.

  • wFeature
    [in] Values in the following list declared in USB100.h; set to one:

    • USB_FEATURE_ENDPOINT_STALL
    • USB_FEATURE_REMOTE_WAKEUP
    • USB_FEATURE_POWER_D0
    • USB_FEATURE_POWER_D1
    • USB_FEATURE_POWER_D2
    • USB_FEATURE_POWER_D3
  • bIndex
    [in] Value of zero (0) for DEVICE, or the interface or endpoint number.

Return Value

A USB_TRANSFER handle indicates success. NULL indicates failure.

Remarks

This function initiates a control transfer to a USB device requesting that a specified feature be enabled.

Requirements

Header usbdi.h
Windows Embedded CE Windows CE 2.10 and later

See Also

Reference

USB Host Driver Functions
LPABORT_TRANSFER
LPCLEAR_FEATURE
LPGET_TRANSFER_STATUS
LPIS_TRANSFER_COMPLETE
LPTRANSFER_NOTIFY_ROUTINE