Skip to main content

UsbClientControllerApiWrapper Class

Namespace: GHIElectronics.TinyCLR.Devices.UsbClient.Provider · Assembly: GHIElectronics.TinyCLR.Devices.UsbClient

No description available.

public class UsbClientControllerApiWrapper : IUsbClientControllerProvider

Constructors

UsbClientControllerApiWrapper(NativeApi api)

public UsbClientControllerApiWrapper(NativeApi api)

No description available.

ParameterTypeDescription
apiNativeApi

Properties

Api

public NativeApi Api { get; }

The underlying native API descriptor. (inherited)

DeviceState

public DeviceState DeviceState { get; }

No description available.

WriteBufferSize

public extern int WriteBufferSize { get; set; }

Size in bytes of the transmit buffer. (inherited)

ReadBufferSize

public extern int ReadBufferSize { get; set; }

Size in bytes of the receive buffer. (inherited)

Methods

Dispose()

public void Dispose()

Releases buffered memory (the unmanaged firmware/application buffers). (inherited)

Dispose(bool disposing)

protected virtual void Dispose(bool disposing)

Closes a response stream, if present. (inherited)

ParameterTypeDescription
disposingboolNot used.

BytesToRead(int streamIndex)

public int BytesToRead(int streamIndex)

No description available.

ParameterTypeDescription
streamIndexint

Returns int

BytesToWrite(int streamIndex)

public int BytesToWrite(int streamIndex)

No description available.

ParameterTypeDescription
streamIndexint

Returns int

Enable()

public extern void Enable()

Re-enables interrupts after a matching Disable. (inherited)

Disable()

public extern void Disable()

Disables interrupts on the current core. Always pair with Enable. (inherited)

SetActiveSetting(UsbClientSetting setting)

public extern void SetActiveSetting(UsbClientSetting setting)

No description available.

ParameterTypeDescription
settingUsbClientSetting

Read(int streamIndex, byte[] data, int offset, int count)

public extern int Read(int streamIndex, byte[] data, int offset, int count)

Captures a slice of inter-edge intervals after waiting for waitForState. (inherited)

ParameterTypeDescription
streamIndexint
databyte[]
offsetint
countint

Returns int

Write(int streamIndex, byte[] data, int offset, int count)

public extern int Write(int streamIndex, byte[] data, int offset, int count)

Writes length bytes; optional trailing break of breakDuration. (inherited)

ParameterTypeDescription
streamIndexint
databyte[]
offsetint
countint

Returns int

Flush(int streamIndex)

public extern void Flush(int streamIndex)

No description available.

ParameterTypeDescription
streamIndexint

ClearReadBuffer(int streamIndex)

public extern void ClearReadBuffer(int streamIndex)

No description available.

ParameterTypeDescription
streamIndexint

ClearWriteBuffer(int streamIndex)

public extern void ClearWriteBuffer(int streamIndex)

No description available.

ParameterTypeDescription
streamIndexint

GetControlPacketSize()

public extern int GetControlPacketSize()

No description available.

Returns int

GetEndpointMap()

public extern ushort GetEndpointMap()

No description available.

Returns ushort

SetDeviceDescriptor(Configuration.DeviceDescriptor[] deviceDescriptor)

public extern void SetDeviceDescriptor(Configuration.DeviceDescriptor[] deviceDescriptor)

No description available.

ParameterTypeDescription
deviceDescriptorConfiguration.DeviceDescriptor[]

SetConfigurationDescriptor(Configuration.ConfigurationDescriptor[] configurationDescriptor)

public extern void SetConfigurationDescriptor(Configuration.ConfigurationDescriptor[] configurationDescriptor)

No description available.

ParameterTypeDescription
configurationDescriptorConfiguration.ConfigurationDescriptor[]

SetStringDescriptor(Configuration.StringDescriptor[] stringDescriptor, uint index)

public extern void SetStringDescriptor(Configuration.StringDescriptor[] stringDescriptor, uint index)

No description available.

ParameterTypeDescription
stringDescriptorConfiguration.StringDescriptor[]
indexuint

SetGenericDescriptor(Configuration.GenericDescriptor[] genericDescriptor)

public extern void SetGenericDescriptor(Configuration.GenericDescriptor[] genericDescriptor)

No description available.

ParameterTypeDescription
genericDescriptorConfiguration.GenericDescriptor[]

Events

DataReceived

public event DataReceivedEventHandler DataReceived

Raised when receive data becomes available. (inherited)

DeviceStateChanged

public event DeviceStateChangedEventHandler DeviceStateChanged

No description available.