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
UsbGetStatus
Go to RapidDriver Main Page


Language

Description

C/C++
BOOL UsbGetStatus(IN  USB_DEVICE_HANDLE hUsb, 
IN  RDUSB_REQUEST_RECIPIENT RequestRecipient,   
IN  USHORT Index,   
OUT PUSHORT Status);  

Delphi
function UsbGetStatus(hUsb : USB_DEVICE_HANDLE;
                      RequestRecipient : RDUSB_Request_Recipient;
                      Index : USHORT;
                      var Status : USHORT): BOOL; stdcall;

VB
Function UsbGetStatus (ByVal hUsb As Long, _
                       ByVal Recepient As Byte, _
                       ByVal FeatIndex As Byte, _
                       ByRef Status As Integer) As Boolean



Parameters
 
hUsb  
Device handle. This handle can be obtained with OpenRapidUsb.  
 
RequestRecipient  
Specifies recipient of feature request.  
 
FeatureSelector  
Specifies the USB-defined feature code that should be cleared on the target specified by RequestRecipient.  
 
Index  
Specifies the device-defined index, returned by a successful configuration request, if the request is for an endpoint or interface. Otherwise, Index must be zero.  
 
Status  
Output parameter. If function succeeds, Status contains RequestRecipient status data.  

Return Value
 
If function fails it return FALSE. To detect error call GetLastError function.  
 
Description
   
UsbGetStatus is used to obtain state of RequestRecipient features.