RUsbDevice Class Reference
Use restricted to the Function Driver Framework, enforced by SID. Provides a means to examine the configuration descriptor, and so load appropriate Function Drivers.
Nested Classes and Structures
Public Member Enumerations |
---|
enum | TDeviceState { EDeviceActive, EDeviceSuspended, EDeviceTriState } |
enum | TUsbDeviceControl { EDeviceControl = 0x4000000, EOpen, EClose, EGetDeviceDescriptor, EGetConfigurationDescriptorSize, EGetConfigurationDescriptor, EGetStringDescriptor, EGetInterfaceToken, ESuspend, EResume, ECancelDeviceStateChange } |
enum | TUsbDeviceRequest { EDeviceRequest = 0x4000000, EDeviceStateChange } |
Constructor & Destructor Documentation
Member Functions Documentation
CancelDeviceStateChangeNotification()
void | CancelDeviceStateChangeNotification | ( | ) | [inline] |
Close()
Close a handle to a device.
GetConfigurationDescriptor(TUsbConfigurationDescriptor &)
Return the USB Configuration Descriptor for this device.
Note: the supplied TUsbConfigurationDescriptor is owned by the caller, but any descriptor objects linked to it remain the property of the RUsbDevice object. Memory leaks will result if the head pointer is not cleaned up, but the pointed to objects should not be destroyed.
Parameters
TUsbConfigurationDescriptor & aDescriptor | The supplied TUsbConfigurationDescriptor object will be populated from the data retrieved from the device. Note that the caller owns the head of the list, but not any children or peers. |
GetConfigurationDescriptor(TDes8 &)
TInt
| GetConfigurationDescriptor | ( | TDes8 & | aConfigDesc | ) | [private, inline] |
GetConfigurationDescriptorSize(TInt &)
TInt
| GetConfigurationDescriptorSize | ( | TInt & | aConfigDescSize | ) | [private, inline] |
GetDeviceDescriptor(TUsbDeviceDescriptor &)
Return the USB Device Descriptor for this device.
Note: the supplied TUsbDeviceDescriptor is owned by the caller, but any descriptor objects linked to it remain the property of the RUsbDevice object. Memory leaks will result if the head pointer is not cleaned up, but the pointed to objects should not be destroyed.
Parameters
TUsbDeviceDescriptor & aDescriptor | The supplied TUsbDeviceDescriptor object will be populated from the data retrieved from the device. |
GetDeviceDescriptor(TDes8 &)
TInt
| GetDeviceDescriptor | ( | TDes8 & | aDeviceDesc | ) | [private, inline] |
GetLocalDescriptorsL()
void | GetLocalDescriptorsL | ( | ) | [private, inline] |
GetStringDescriptor(TUsbStringDescriptor *&, TDes8 &, TInt)
GetStringDescriptor(TUsbStringDescriptor *&, TDes8 &, TInt, TInt)
GetStringDescriptor(TDes8 &, TInt, TInt)
TInt
| GetStringDescriptor | ( | TDes8 & | aStringDescriptor, |
| TInt | aIndex, |
| TInt | aLangId = 0 |
| ) | [private, inline] |
GetTokenForInterface(TInt, TUint32 &)
Return a token which may be used to uniquely identify the supplied interface on this device. The returned token may then be passed to a function driver, to allow it to open the required interface.
Parameters
TInt aInterfaceNumber | Interface to return a token for. |
TUint32 & aToken | The token assigned to the interface. |
Handle()
TUint
| Handle | ( | ) | const [inline] |
Return the handle to a device
Open(RUsbHubDriver &, TUint)
Open a handle to a device.
ParseStringDescriptor(TUsbStringDescriptor *&, const TDesC8 &)
QueueDeviceStateChangeNotification(TDeviceState &, TRequestStatus &)
Queues an asynchronous request for changes in the state of the device represented by this handle.
Parameters
TDeviceState & aCurrentState | The new state of the device |
TRequestStatus & aRequest | The request status completed when a state change has occured. |
Resume()
Resumes the device from a suspended state.
Suspend()
Places the device into a suspended state.
Member Enumerations Documentation
Enum TDeviceState
Enumerators
EDeviceActive | |
EDeviceSuspended | |
EDeviceTriState | |
Enum TUsbDeviceControl
Enumerators
EDeviceControl = 0x4000000 | |
EOpen | |
EClose | |
EGetDeviceDescriptor | |
EGetConfigurationDescriptorSize | |
EGetConfigurationDescriptor | |
EGetStringDescriptor | |
EGetInterfaceToken | |
ESuspend | |
EResume | |
ECancelDeviceStateChange | |
Enum TUsbDeviceRequest
Enumerators
EDeviceRequest = 0x4000000 | |
EDeviceStateChange | |
Member Data Documentation
const TUint KDeviceDescriptorSize
const TUint | KDeviceDescriptorSize | [private, static] |
HBufC8 * iConfigurationDescriptorData
HBufC8 * | iConfigurationDescriptorData | [private] |
TBuf8< KDeviceDescriptorSize > iDeviceDescriptorData
TUsbConfigurationDescriptor * iHeadConfDescriptor
TUsbDeviceDescriptor * iHeadDeviceDescriptor
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.