Class UsbControlEndpoint
Definition
- Assembly:
- Tizen.System.Usb.dll
The USB Control Endpoint class.
public class UsbControlEndpoint : UsbEndpoint
- Inheritance
Properties
View SourceDirection
Gets the direction of this endpoint.
Declaration
public EndpointDirection Direction { get; }
Property Value
Type | Description |
---|---|
EndpointDirection |
Exceptions
Type | Condition |
---|---|
System.NotSupportedException | The required feature is not supported. |
Id
Gets the number of this endpoint.
Declaration
public int Id { get; }
Property Value
Type | Description |
---|---|
int |
Exceptions
Type | Condition |
---|---|
System.NotSupportedException | The required feature is not supported. |
MaxPacketSize
Gets the maximum packet size of a given endpoint.
Declaration
public int MaxPacketSize { get; }
Property Value
Type | Description |
---|---|
int |
Exceptions
Type | Condition |
---|---|
System.NotSupportedException | The required feature is not supported. |
Methods
View SourceTransfer(byte, byte, ushort, ushort, byte[], ushort, uint)
Performs a control transaction on the endpoint, zero for this device.
Declaration
public int Transfer(byte requestType, byte request, ushort value, ushort index, byte[] data, ushort length, uint timeout)
Parameters
Type | Name | Description |
---|---|---|
byte | requestType | bmRequestType type field for the setup packet. |
byte | request | bRequest field for the setup packet. |
ushort | value | wValue field for the setup packet. |
ushort | index | wIndex field for the setup packet. |
byte[] | data | Suitably-sized data buffer for either an input or output (depending on the direction bits within a bmRequestType). |
ushort | length | wLength field for the setup packet. The data buffer should be at least this size. |
uint | timeout | The time (in milliseconds) that this function should wait for, before giving up due to no response being received (for an unlimited timeout, 0 value should be used). |
Returns
Type | Description |
---|---|
int | Transferred number of the transferred bytes. |
Exceptions
Type | Condition |
---|---|
System.NotSupportedException | The required feature is not supported. |
System.InvalidOperationException | Throws an exception if the device is disconnected or not opened for an operation. |
System.TimeoutException | Throws an exception if the transfer is timed out. |