Class UsbInterface

Definition

Namespace:
Tizen.System.Usb
Assembly:
Tizen.System.Usb.dll
API Level:
4

A class to manage the USB interfaces.

C#
Copy
public class UsbInterface
Inheritance
UsbInterface

Properties

View Source

AlternateSetting

Sets an alternative setting. Use the index of a new alternative setting for a given interface.

Declaration
C#
Copy
public int AlternateSetting { set; }
Property Value
Type Description
System.Int32
API Level: 4
View Source

Endpoints

A dictionary for mapping the endpoint IDs to endpoint instances for a given interface.

Declaration
C#
Copy
public IReadOnlyDictionary<int, UsbEndpoint> Endpoints { get; }
Property Value
Type Description
IReadOnlyDictionary<System.Int32, UsbEndpoint>
API Level: 4
View Source

Id

Gets the number of a given interface.

Declaration
C#
Copy
public int Id { get; }
Property Value
Type Description
System.Int32
API Level: 4

Methods

View Source

Claim(Boolean)

Claims the interface on a device. The interface must be claimed first to perform I/O operations.

Declaration
C#
Copy
public void Claim(bool force)
Parameters
Type Name Description
Boolean force

Set to true to auto detach the kernel driver, false otherwise.

Exceptions
Type Condition
System.InvalidOperationException

Throws an exception if the device is disconnected, or not opened for an operation, or another program or driver has claimed the interface.

API Level: 4
View Source

InterfaceString()

Gets the string describing an interface.

Declaration
C#
Copy
public string InterfaceString()
Returns
Type Description
System.String
API Level: 4
View Source

Release()

Releases the previously claimed interface.

Declaration
C#
Copy
public void Release()
Exceptions
Type Condition
System.InvalidOperationException

Throws an exception if the device is disconnected or not opened for an operation.

UnauthorizedAccessException

Throws an exception if the user has insufficient permission on the device.

API Level: 4