USBDev_PipeAddrGet

Description

Get pipe address.

Files

usbdev_api.c

Prototype

UCHAR  USBDev_PipeAddrGet (HANDLE   pipe,
                           DWORD   *p_err);


Arguments

pipe

Pipe handle.

p_err

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

ERROR_SUCCESS
ERROR_INVALID_HANDLE

Returned Value

Pipe address, if NO error(s).

0, otherwise.

Callers

Application.

Notes / Warnings

The pipe address is composed of the pipe direction and the pipe logical address. The pipe direction is located at bit 7. A value of '1' indicates an IN pipe and '0' an OUT pipe. The pipe logical address sits in bit 3 to bit 0.