Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

Version 1 Current »

Description

Get the current alternate setting for the specified interface.

Files

usbdev_api.c

Prototype

Arguments

dev

General handle to device.

if_nbr

Interface number.

p_err

Pointer to variable that will receive the return error code from this function:

ERROR_SUCCESS
ERROR_INVALID_HANDLE
ERROR_INVALID_PARAMETER

Returned Value

Current alternate setting number, if NO error(s).

0, otherwise.

Callers

Application.

Notes / Warnings

This function gets the current alternate setting number used internally by WinUSB and gets the one from the device by sending a GET_INTERFACE request. Both alternate setting numbers are compared. If they match, the current  alternate setting is returned.

  • No labels