Home    Prev Next    
Contents
Programming For USB Device
Overview
Programmers Guide
Scenario
Data transfer
Synchronous Transfer
Asynchronous Transfer
Reading Descriptors
USB Support Routines And Structures
Common Procedures
UsbEnumerateDevices
OpenRapidUsb
IsRapidUsbOpened
CloseRapidUsb
Descriptors
UsbGetDescriptor
UsbGetDeviceDescriptor
UsbGetStringDescriptor
UsbGetConfigDescriptor
UsbFreeConfigDescriptor
UsbGetInterfaceDescriptor
UsbFreeInterfaceDescriptor
UsbGetEndpointDescriptor
Configure Device
UsbGetDeviceInfo
UsbUnconfigureDevice
UsbSelectConfig
UsbGetConfig
UsbSelectInterface
UsbGetInterface
UsbResetDevice
UsbGetBandwidthInfo
UsbCyclePort
Features and Status
UsbSetFeature
UsbClearFeature
UsbGetStatus
Vendor/Class Requests
UsbVendorRequestIn
UsbVendorRequestOut
UsbClassRequestIn
UsbClassRequestOut
Pipes
IsRapidUsbPipeOpened
UsbPipeOpen
UsbPipeClose
UsbGetPipeCount
UsbPipeGetInfo
UsbPipeDirectionIn
UsbPipeGetType
UsbTransfer
UsbTransferAsync
TRANSFER_COMPLETION_ROUTINE
UsbCancelTransfer
UsbPipeReset
UsbPipeAbort
Other
UsbGetPortStatus
UsbGetCurrentFrameNumber
USB Structures and Types
RDUSB_DEVICE_INFORMATION
RDUSB_PIPE_INFORMATION
RDUSB_PIPE_TYPE
RDUSB_BANDWIDTH_INFORMATION
UsbPipeOpen
Go to RapidDriver Main Page


Language

Description

C/C++
USB_PIPE_HANDLE UsbPipeOpen(IN USB_DEVICE_HANDLE hUsb, 
IN UCHAR PipeNum);  

Delphi
function UsbPipeOpen(hUsb : USB_DEVICE_HANDLE; 
                     PipeNum : UCHAR) : USB_PIPE_HANDLE; stdcall;
VB
Function UsbPipeOpen (ByVal hUsb As Long, _
                      ByVal PipeNumber As Byte) As Long



Parameters
 
hUsb  
Specifies device handle. This handle can be obtained with OpenRapidUsb.  
 
PipeNum  
Number of pipe to make active.  

Return Value
 
Function returns valid pipe handle if succeed. If function fails return value is INVALID_HANDLE_VALUE.  

Description
 
Function returns handle to USB pipe of specified number. Pipe is taken from active interface. All input/output operations can be performed only after successful call to this function (return value is not INVALID_HANDLE_VALUE). When all operations with pipe are finished call UsbPipeClose.