public class UsbTransceiver extends Transceiver
Modifier and Type | Class and Description |
---|---|
class |
UsbTransceiver.ReceiveRunnable |
Modifier and Type | Field and Description |
---|---|
static int |
INPUT_ENDPOINT_INDEX |
static int |
OUTPUT_ENDPOINT_INDEX |
static int |
SEND_THREAD_POOL_SIZE |
mOnConnectionUpdatedListener, mOnTransceivedListener
Constructor and Description |
---|
UsbTransceiver(android.content.Context context,
android.hardware.usb.UsbDevice usbDevice) |
Modifier and Type | Method and Description |
---|---|
void |
connect() |
void |
destroy() |
void |
disconnect() |
boolean |
equals(java.lang.Object obj) |
CommunicationType |
getCommunicationType() |
ConnectionState |
getConnectionState() |
java.lang.String |
getDefaultChannelId() |
java.lang.String |
getDeviceId() |
java.lang.String |
getDeviceName() |
void |
send(byte[] writeData) |
void |
send(byte[] data,
java.lang.String channelId) |
setOnConnectionUpdatedListener, setOnTransceivedListener
public static final int SEND_THREAD_POOL_SIZE
public static final int INPUT_ENDPOINT_INDEX
public static final int OUTPUT_ENDPOINT_INDEX
public UsbTransceiver(android.content.Context context, android.hardware.usb.UsbDevice usbDevice)
public void connect()
connect
in class Transceiver
public void disconnect()
disconnect
in class Transceiver
public void send(byte[] writeData)
send
in class Transceiver
public void send(byte[] data, java.lang.String channelId)
send
in class Transceiver
public void destroy()
destroy
in class Transceiver
public java.lang.String getDeviceId()
getDeviceId
in class Transceiver
public ConnectionState getConnectionState()
getConnectionState
in class Transceiver
public CommunicationType getCommunicationType()
getCommunicationType
in class Transceiver
public java.lang.String getDefaultChannelId()
getDefaultChannelId
in class Transceiver
public java.lang.String getDeviceName()
getDeviceName
in class Transceiver
public boolean equals(java.lang.Object obj)
equals
in class Transceiver