BowlerKernel
|
Classes | |
class | PingCommand |
class | QueueManager |
Public Member Functions | |
abstract boolean | connect () |
abstract boolean | waitingForConnection () |
void | setThreadedUpstreamPackets (boolean up) |
BowlerDatagram | sendSynchronusly (BowlerDatagram sendable) |
synchronized BowlerDatagram | sendSynchronusly (BowlerDatagram sendable, boolean switchParser) |
void | sendAsync (BowlerDatagram sendable) throws IOException |
void | disconnect () |
void | setSynchronusPacketTimeoutTime (int sleepTime) |
int | getSleepTime () |
long | msSinceLastSend () |
synchronized void | setConnected (boolean c) |
boolean | isConnected () |
void | clearLastSyncronousResponse () |
BowlerDatagram | getLastSyncronousResponse () |
void | onDataReceived (BowlerDatagram data) |
void | addDatagramListener (IBowlerDatagramListener listener) |
void | removeDatagramListener (IBowlerDatagramListener listener) |
void | setDataIns (DataInputStream dataIns) |
DataInputStream | getDataIns () throws NullPointerException |
void | setDataOuts (DataOutputStream dataOuts) |
DataOutputStream | getDataOuts () throws NullPointerException |
void | setChunkSize (int chunkSize) |
int | getChunkSize () |
void | setAsyncQueue (QueueManager asyncQueue) |
void | setSyncQueue (QueueManager syncQueue) |
QueueManager | getAsyncQueue () |
QueueManager | getSyncQueue () |
void | addConnectionEventListener (IConnectionEventListener l) |
void | removeConnectionEventListener (IConnectionEventListener l) |
void | setSynchronousDatagramListener (ISynchronousDatagramListener l) |
void | removeSynchronousDatagramListener (ISynchronousDatagramListener l) |
RpcEncapsulation | locateRpc (String namespace, BowlerMethod method, String rpcString) |
Object[] | parseResponse (String namespace, BowlerMethod method, String rpcString, BowlerDatagram dg) |
Object[] | send (MACAddress addr, String namespace, BowlerMethod method, String rpcString, Object[] arguments, int retry) throws DeviceConnectionException |
boolean | isInitializedNamespaces () |
ArrayList< String > | getNamespaces (MACAddress addr) |
boolean | hasNamespace (String string, MACAddress addr) |
ArrayList< RpcEncapsulation > | getRpcList (String namespace, MACAddress addr) |
BowlerDatagram | send (BowlerAbstractCommand command, MACAddress addr, int retry) throws NoConnectionAvailableException, InvalidResponseException |
BowlerDatagram | send (BowlerAbstractCommand command, MACAddress addr, int retry, boolean switchParser) throws NoConnectionAvailableException, InvalidResponseException |
BowlerDatagram | send (BowlerAbstractCommand command, MACAddress addr) throws NoConnectionAvailableException, InvalidResponseException |
BowlerDatagram | send (BowlerAbstractCommand command, MACAddress addr, boolean switchParser) throws NoConnectionAvailableException, InvalidResponseException |
boolean | ping (MACAddress mac) |
boolean | ping (MACAddress mac, boolean switchParser) |
void | startHeartBeat () |
void | startHeartBeat (long msHeartBeatTime) |
void | stopHeartBeat () |
double | getPercentagePrint () |
void | setPercentagePrint (double percentagePrint) |
long | getLastWrite () |
void | setLastWrite (long lastWrite) |
boolean | isUseThreadedStack () |
void | setUseThreadedStack (boolean useThreadedStack) |
boolean | isBeater () |
void | setBeater (boolean beater) |
BowlerDatagram | loadPacketFromPhy (ByteList bytesToPacketBuffer) throws NullPointerException, IOException |
void | write (byte[] data) throws IOException |
Static Public Member Functions | |
static BowlerAbstractCommand | getCommand (String namespace, BowlerMethod method, String rpcString, Object[] arguments, RpcEncapsulation rpc) |
Protected Member Functions | |
BowlerDatagram | fireSyncOnReceive (BowlerDatagram datagram) |
void | fireAsyncOnResponse (BowlerDatagram datagram) |
void | waitForConnectioToBeReady () |
Private Member Functions | |
void | pushUp (BowlerDatagram b) throws IOException |
void | fireDisconnectEvent () |
void | fireConnectEvent () |
void | runHeartBeat () |
Private Attributes | |
boolean | useThreadedStack =true |
int | sleepTime = 1000 |
long | lastWrite = -1 |
long | heartBeatTime =1000 |
int | chunkSize = 64 |
BowlerDatagram | response = null |
ArrayList< IBowlerDatagramListener > | listeners = new ArrayList<IBowlerDatagramListener>() |
ISynchronousDatagramListener | syncListen = null |
QueueManager | syncQueue = null |
QueueManager | asyncQueue =null |
boolean | connected = false |
DataInputStream | dataIns |
DataOutputStream | dataOuts |
ArrayList< NamespaceEncapsulation > | namespaceList =null |
ArrayList< String > | nameSpaceStrings = null |
boolean | beater = false |
boolean | namespacesFinishedInitializing = false |
double | percentagePrint =75.0 |
Connections create a bridge between a device and the SDK. Each connection is encapsulated to allow maximum reuse and system changes without the need to restart / reconfigure.
Definition at line 57 of file BowlerAbstractConnection.java.
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.addConnectionEventListener | ( | IConnectionEventListener | l | ) |
Adds the connection event listener.
l | the l |
Definition at line 670 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractDevice.addConnectionEventListener(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractServer.addServer(), com.neuronrobotics.sdk.dyio.DyIO.connect(), and com.neuronrobotics.sdk.common.BowlerAbstractDevice.setConnection().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.addDatagramListener | ( | IBowlerDatagramListener | listener | ) |
Add a listener that will be notified whenever an asyncronous packet arrives.
listener | the listener |
Definition at line 479 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.listeners.
Referenced by com.neuronrobotics.sdk.common.device.server.BowlerDeviceReServerNamespace.BowlerDeviceReServerNamespace(), and com.neuronrobotics.sdk.common.BowlerAbstractDevice.setConnection().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.clearLastSyncronousResponse | ( | ) |
This should be done before sending.
Definition at line 393 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.response.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
|
abstract |
Attempt to establish a connection. Return if the attempt was successful.
Reimplemented in com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection, com.neuronrobotics.sdk.serial.SerialConnection, com.neuronrobotics.sdk.pid.VirtualGenericPidDeviceConnection, com.neuronrobotics.sdk.network.UDPBowlerConnection, com.neuronrobotics.sdk.network.BowlerUDPServer, com.neuronrobotics.sdk.network.BowlerTCPServer, com.neuronrobotics.sdk.network.BowlerTCPClient, and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.
Referenced by com.neuronrobotics.sdk.common.device.server.BowlerAbstractServer.addServer(), and com.neuronrobotics.sdk.common.BowlerAbstractDevice.connect().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect | ( | ) |
Disconnect and deactive the current connection.
Reimplemented in com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection, com.neuronrobotics.sdk.serial.SerialConnection, com.neuronrobotics.sdk.network.UDPBowlerConnection, com.neuronrobotics.sdk.network.BowlerUDPServer, com.neuronrobotics.sdk.network.BowlerTCPServer, com.neuronrobotics.sdk.network.BowlerTCPClient, and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.
Definition at line 252 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataIns, com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataIns(), com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isConnected(), com.neuronrobotics.sdk.common.ThreadedTimeout.isTimedOut(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected(), and com.neuronrobotics.sdk.common.ThreadedTimeout.setStartTime().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractDevice.disconnect(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractServer.pushAsyncPacket(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.runHeartBeat(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.runPacketUpdate(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
|
protected |
Fire async on response.
datagram | the datagram |
Definition at line 451 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isInitializedNamespaces(), com.neuronrobotics.sdk.common.BowlerDatagram.isSyncronous(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.listeners, and com.neuronrobotics.sdk.common.IBowlerDatagramListener.onAsyncResponse().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.pushUp().
|
private |
Fire connect event.
Definition at line 699 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
|
private |
Fire disconnect event.
Definition at line 690 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
|
protected |
Fire On Response.
datagram | the datagram |
Definition at line 436 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerDatagram.isSyncronous(), com.neuronrobotics.sdk.common.ISynchronousDatagramListener.onSyncReceive(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncListen.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.pushUp().
QueueManager com.neuronrobotics.sdk.common.BowlerAbstractConnection.getAsyncQueue | ( | ) |
Gets the async queue.
Definition at line 626 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.asyncQueue.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.onDataReceived(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
int com.neuronrobotics.sdk.common.BowlerAbstractConnection.getChunkSize | ( | ) |
Gets the chunk size.
Definition at line 590 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.chunkSize.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.write().
|
static |
Gets the command.
namespace | the namespace |
method | the method |
rpcString | the rpc string |
arguments | the arguments |
rpc | the rpc |
Definition at line 768 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.RpcEncapsulation.getCommand().
Referenced by com.neuronrobotics.sdk.common.device.server.BowlerAbstractServer.pushAsyncPacket(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
DataInputStream com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataIns | ( | ) | throws NullPointerException |
Gets the data ins.
NullPointerException | the null pointer exception |
Reimplemented in com.neuronrobotics.sdk.network.UDPBowlerConnection, and com.neuronrobotics.sdk.network.BowlerUDPServer.
Definition at line 524 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataIns.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect(), com.neuronrobotics.sdk.network.BowlerTCPClient.disconnect(), com.neuronrobotics.sdk.network.BowlerTCPServer.disconnect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.loadPacketFromPhy(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
DataOutputStream com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataOuts | ( | ) | throws NullPointerException |
Gets the data outs.
NullPointerException | the null pointer exception |
Reimplemented in com.neuronrobotics.sdk.network.UDPBowlerConnection, and com.neuronrobotics.sdk.network.BowlerUDPServer.
Definition at line 546 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataOuts.
Referenced by com.neuronrobotics.sdk.bootloader.NRBootLoader.reset(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractDeviceServer.sendAsync(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractDeviceServer.sendPacketWithNoResponse(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractDeviceServer.sendSyncResponse(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.write().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.getLastSyncronousResponse | ( | ) |
Return the synchronous response buffer.
Definition at line 402 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.response.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
long com.neuronrobotics.sdk.common.BowlerAbstractConnection.getLastWrite | ( | ) |
Gets the last write.
Definition at line 1288 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.lastWrite.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.msSinceLastSend(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run().
ArrayList<String> com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces | ( | MACAddress | addr | ) |
Get all the namespaces.
addr | the addr |
Definition at line 855 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.ByteList.asString(), com.neuronrobotics.sdk.common.Log.debug(), com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.ByteList.getByte(), com.neuronrobotics.sdk.common.BowlerDatagram.getData(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getRpcList(), com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespaceList, com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespacesFinishedInitializing, com.neuronrobotics.sdk.common.BowlerAbstractConnection.nameSpaceStrings, com.neuronrobotics.sdk.common.BowlerAbstractConnection.send(), com.neuronrobotics.sdk.common.ByteList.size(), and com.neuronrobotics.sdk.common.Log.warning().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractDevice.getNamespaces(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.hasNamespace(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
double com.neuronrobotics.sdk.common.BowlerAbstractConnection.getPercentagePrint | ( | ) |
Gets the percentage print.
Definition at line 1270 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.percentagePrint.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
ArrayList<RpcEncapsulation> com.neuronrobotics.sdk.common.BowlerAbstractConnection.getRpcList | ( | String | namespace, |
MACAddress | addr | ||
) |
Requests all of the RPC's from a namespace.
namespace | the namespace |
addr | the addr |
Definition at line 971 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.debug(), com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerDataType.get(), com.neuronrobotics.sdk.common.BowlerMethod.get(), com.neuronrobotics.sdk.common.ByteList.getByte(), com.neuronrobotics.sdk.common.ByteList.getBytes(), com.neuronrobotics.sdk.common.BowlerDatagram.getData(), com.neuronrobotics.sdk.common.BowlerDatagram.getRPC(), com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespaceList, com.neuronrobotics.sdk.common.BowlerAbstractConnection.send(), and com.neuronrobotics.sdk.common.RpcEncapsulation.toString().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces(), and com.neuronrobotics.sdk.common.BowlerAbstractDevice.getRpcList().
int com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSleepTime | ( | ) |
Gets the sleep time.
Definition at line 294 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.sleepTime.
Referenced by com.neuronrobotics.sdk.network.BowlerTCPClient.reconnect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
QueueManager com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSyncQueue | ( | ) |
Gets the sync queue.
Definition at line 635 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncQueue.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.onDataReceived(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.hasNamespace | ( | String | string, |
MACAddress | addr | ||
) |
Check the device to see if it has the requested namespace.
string | the string |
addr | the addr |
Definition at line 954 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespaceList.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractDevice.hasNamespace().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.isBeater | ( | ) |
Checks if is beater.
Definition at line 1466 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.beater.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.isConnected | ( | ) |
Checks if is connected.
Reimplemented in com.neuronrobotics.sdk.network.BowlerTCPServer.
Definition at line 386 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.connected.
Referenced by com.neuronrobotics.sdk.network.BowlerTCPClient.BowlerTCPClient(), com.neuronrobotics.sdk.common.BowlerAbstractDevice.connect(), com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.connect(), com.neuronrobotics.sdk.network.BowlerTCPClient.connect(), com.neuronrobotics.sdk.network.BowlerUDPServer.connect(), com.neuronrobotics.sdk.network.UDPBowlerConnection.connect(), com.neuronrobotics.sdk.serial.SerialConnection.connect(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.connect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect(), com.neuronrobotics.sdk.common.BowlerAbstractDevice.disconnect(), com.neuronrobotics.sdk.serial.SerialConnection.disconnect(), com.neuronrobotics.sdk.common.BowlerAbstractDevice.isAvailable(), com.neuronrobotics.sdk.dyio.DyIO.isAvailable(), com.neuronrobotics.sdk.genericdevice.GenericDevice.isAvailable(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.recon(), com.neuronrobotics.sdk.network.BowlerTCPClient.reconnect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.runPacketUpdate(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendAsync(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected(), com.neuronrobotics.sdk.pid.GenericPIDDevice.setConnection(), com.neuronrobotics.sdk.network.BowlerTCPClient.setTCPPort(), com.neuronrobotics.sdk.network.BowlerTCPClient.setTCPSocket(), and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.write().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.isInitializedNamespaces | ( | ) |
Checks if is initialized namespaces.
Definition at line 845 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespaceList, and com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespacesFinishedInitializing.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireAsyncOnResponse().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.isUseThreadedStack | ( | ) |
Checks if is use threaded stack.
Definition at line 1448 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.useThreadedStack.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setAsyncQueue(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSyncQueue().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.loadPacketFromPhy | ( | ByteList | bytesToPacketBuffer | ) | throws NullPointerException, IOException |
Load packet from phy.
bytesToPacketBuffer | the bytes to packet buffer |
NullPointerException | the null pointer exception |
IOException | Signals that an I/O exception has occurred. |
Reimplemented in com.neuronrobotics.sdk.network.UDPBowlerConnection, com.neuronrobotics.sdk.network.BowlerUDPServer, and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.
Definition at line 1487 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataIns, com.neuronrobotics.sdk.common.Log.error(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataIns().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.runPacketUpdate().
RpcEncapsulation com.neuronrobotics.sdk.common.BowlerAbstractConnection.locateRpc | ( | String | namespace, |
BowlerMethod | method, | ||
String | rpcString | ||
) |
Locate rpc.
namespace | the namespace |
method | the method |
rpcString | the rpc string |
Definition at line 742 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespaceList.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.parseResponse(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
long com.neuronrobotics.sdk.common.BowlerAbstractConnection.msSinceLastSend | ( | ) |
Ms since last send.
Definition at line 304 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.getLastWrite().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.runHeartBeat().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.onDataReceived | ( | BowlerDatagram | data | ) |
Whenever a connection has received a full datagram from its "physical" connection, it should then call onDataReceived with the datagram. This will set it to the last received data if it is synchronous and will add it to the appropriate queues to be picked up and send to the listeners.
data | the data |
Definition at line 413 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.addDatagram(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getAsyncQueue(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSyncQueue(), com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerDatagram.isSyncronous(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.response, and com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncListen.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.runPacketUpdate().
Object [] com.neuronrobotics.sdk.common.BowlerAbstractConnection.parseResponse | ( | String | namespace, |
BowlerMethod | method, | ||
String | rpcString, | ||
BowlerDatagram | dg | ||
) |
Parses the response.
namespace | the namespace |
method | the method |
rpcString | the rpc string |
dg | the dg |
Definition at line 786 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.locateRpc(), and com.neuronrobotics.sdk.common.RpcEncapsulation.parseResponse().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.ping | ( | MACAddress | mac | ) |
Implementation of the Bowler ping ("_png") command Sends a ping to the device returns the device's MAC address.
mac | the mac |
Definition at line 1188 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.network.UDPBowlerConnection.getAllAddresses(), com.neuronrobotics.sdk.common.BowlerAbstractDevice.ping(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.runHeartBeat().
boolean com.neuronrobotics.sdk.common.BowlerAbstractConnection.ping | ( | MACAddress | mac, |
boolean | switchParser | ||
) |
Implementation of the Bowler ping ("_png") command Sends a ping to the device returns the device's MAC address.
mac | the mac |
switchParser | the switch parser |
Definition at line 1201 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.send(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat().
|
private |
Push up.
b | the b |
IOException | Signals that an I/O exception has occurred. |
Definition at line 648 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireAsyncOnResponse(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireSyncOnReceive(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendAsync().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.removeConnectionEventListener | ( | IConnectionEventListener | l | ) |
Removes the connection event listener.
l | the l |
Definition at line 681 of file BowlerAbstractConnection.java.
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.removeDatagramListener | ( | IBowlerDatagramListener | listener | ) |
Remove a listener from new packet notifications.
listener | the listener |
Definition at line 493 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.listeners.
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.removeSynchronousDatagramListener | ( | ISynchronousDatagramListener | l | ) |
Removes the synchronous datagram listener.
l | the l |
Definition at line 725 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncListen.
|
private |
Run heart beat.
Definition at line 1250 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.debug(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.heartBeatTime, com.neuronrobotics.sdk.common.BowlerAbstractConnection.msSinceLastSend(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.ping().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.run().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.send | ( | BowlerAbstractCommand | command, |
MACAddress | addr | ||
) | throws NoConnectionAvailableException, InvalidResponseException |
Send a command to the connection.
command | the command |
addr | the addr |
NoConnectionAvailableException | the no connection available exception |
InvalidResponseException | the invalid response exception |
Definition at line 1136 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.send | ( | BowlerAbstractCommand | command, |
MACAddress | addr, | ||
boolean | switchParser | ||
) | throws NoConnectionAvailableException, InvalidResponseException |
Send a command to the connection.
command | the command |
addr | the addr |
switchParser | the switch parser |
NoConnectionAvailableException | the no connection available exception |
InvalidResponseException | the invalid response exception |
Definition at line 1150 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerDatagram.getAddress(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.send | ( | BowlerAbstractCommand | command, |
MACAddress | addr, | ||
int | retry | ||
) | throws NoConnectionAvailableException, InvalidResponseException |
Send a command to the connection.
command | the command |
addr | the addr |
retry | the retry |
NoConnectionAvailableException | the no connection available exception |
InvalidResponseException | the invalid response exception |
Definition at line 1077 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.send | ( | BowlerAbstractCommand | command, |
MACAddress | addr, | ||
int | retry, | ||
boolean | switchParser | ||
) | throws NoConnectionAvailableException, InvalidResponseException |
Send a command to the connection.
command | the command |
addr | the addr |
retry | the retry |
switchParser | the switch parser |
NoConnectionAvailableException | the no connection available exception |
InvalidResponseException | the invalid response exception |
Definition at line 1092 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerDatagram.getAddress(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.send(), and com.neuronrobotics.sdk.util.ThreadUtil.wait().
Object [] com.neuronrobotics.sdk.common.BowlerAbstractConnection.send | ( | MACAddress | addr, |
String | namespace, | ||
BowlerMethod | method, | ||
String | rpcString, | ||
Object[] | arguments, | ||
int | retry | ||
) | throws DeviceConnectionException |
This is the scripting interface to Bowler devices. THis allows a user to describe a namespace, rpc, and array or arguments to be paced into the packet based on the data types of the argument. The response in likewise unpacked into an array of objects.
addr | the addr |
namespace | The string of the desired namespace |
method | the method |
rpcString | The string of the desired RPC |
arguments | An array of objects corresponding to the data to be stuffed into the packet. |
retry | the retry |
DeviceConnectionException | If the desired RPC's are not available then this will be thrown |
Definition at line 808 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerDatagram.getAddress(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getCommand(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.locateRpc(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.namespaceList, and com.neuronrobotics.sdk.common.BowlerAbstractConnection.parseResponse().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getRpcList(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.ping(), com.neuronrobotics.sdk.common.BowlerAbstractDevice.send(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.send(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendAsync | ( | BowlerDatagram | sendable | ) | throws IOException |
Sends any "universal" data to the connection and returns either the syncronous response or null in the event that the connection has determined a timeout. Before sending, use clearLastSyncronousResponse() and use getLastSyncronousResponse() to get the last response since clearing.
sendable | the sendable |
IOException | Signals that an I/O exception has occurred. |
Definition at line 234 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isConnected(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.write().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.pushUp(), com.neuronrobotics.sdk.bootloader.NRBootLoader.reset(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractDeviceServer.sendAsync(), com.neuronrobotics.sdk.common.device.server.BowlerAbstractDeviceServer.sendPacketWithNoResponse(), and com.neuronrobotics.sdk.common.device.server.BowlerAbstractDeviceServer.sendSyncResponse().
BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly | ( | BowlerDatagram | sendable | ) |
Sends any "universal" data to the connection and returns either the syncronous response or null in the event that the connection has determined a timeout. Before sending, use clearLastSyncronousResponse() and use getLastSyncronousResponse() to get the last response since clearing.
sendable | the sendable |
Definition at line 156 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.device.server.BowlerDeviceReServerNamespace.process(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
synchronized BowlerDatagram com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly | ( | BowlerDatagram | sendable, |
boolean | switchParser | ||
) |
Sends any "universal" data to the connection and returns either the syncronous response or null in the event that the connection has determined a timeout. Before sending, use clearLastSyncronousResponse() and use getLastSyncronousResponse() to get the last response since clearing.
sendable | the sendable |
switchParser | the switch parser |
Definition at line 169 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.clearLastSyncronousResponse(), com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerDatagram.getBytes(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getLastSyncronousResponse(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getPercentagePrint(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSleepTime(), com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isConnected(), com.neuronrobotics.sdk.common.BowlerDatagram.isUseBowlerV4(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isUseThreadedStack(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.runPacketUpdate(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.send(), com.neuronrobotics.sdk.common.BowlerDatagram.setUpstream(), com.neuronrobotics.sdk.common.BowlerDatagram.setUseBowlerV4(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncQueue, com.neuronrobotics.sdk.util.ThreadUtil.wait(), com.neuronrobotics.sdk.common.Log.warning(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.write().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setAsyncQueue | ( | QueueManager | asyncQueue | ) |
Sets the async queue.
asyncQueue | the new async queue |
Definition at line 599 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.asyncQueue, and com.neuronrobotics.sdk.common.BowlerAbstractConnection.isUseThreadedStack().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setBeater | ( | boolean | beater | ) |
Sets the beater.
beater | the new beater |
Definition at line 1475 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.beater.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.stopHeartBeat().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setChunkSize | ( | int | chunkSize | ) |
Sets the chunk size.
chunkSize | the new chunk size |
Definition at line 581 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.chunkSize.
Referenced by com.neuronrobotics.sdk.network.BowlerTCPServer.BowlerTCPServer(), com.neuronrobotics.sdk.network.BowlerUDPServer.BowlerUDPServer(), and com.neuronrobotics.sdk.network.UDPBowlerConnection.init().
synchronized void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected | ( | boolean | c | ) |
Sets the connected.
c | the new connected |
Definition at line 317 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.connected, com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataIns, com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataOuts, com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireConnectEvent(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireDisconnectEvent(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getAsyncQueue(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataIns(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataOuts(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSyncQueue(), com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isConnected(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.QueueManager.kill(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setAsyncQueue(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setDataIns(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setDataOuts(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSyncQueue().
Referenced by com.neuronrobotics.sdk.network.BowlerTCPServer.BowlerTCPServer(), com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.connect(), com.neuronrobotics.sdk.network.BowlerTCPClient.connect(), com.neuronrobotics.sdk.network.BowlerUDPServer.connect(), com.neuronrobotics.sdk.network.UDPBowlerConnection.connect(), com.neuronrobotics.sdk.serial.SerialConnection.connect(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.connect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect(), com.neuronrobotics.sdk.network.BowlerUDPServer.disconnect(), com.neuronrobotics.sdk.network.UDPBowlerConnection.disconnect(), com.neuronrobotics.sdk.serial.SerialConnection.disconnect(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.disconnect(), and com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.recon().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setDataIns | ( | DataInputStream | dataIns | ) |
Start builder.
dataIns | the new data ins Sets the data ins. |
dataIns | the new data ins |
Definition at line 514 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataIns.
Referenced by com.neuronrobotics.sdk.network.BowlerTCPServer.BowlerTCPServer(), com.neuronrobotics.sdk.network.BowlerTCPClient.connect(), com.neuronrobotics.sdk.serial.SerialConnection.connect(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.connect(), com.neuronrobotics.sdk.network.BowlerTCPClient.disconnect(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setDataOuts | ( | DataOutputStream | dataOuts | ) |
Sets the data outs.
dataOuts | the new data outs |
Definition at line 535 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataOuts.
Referenced by com.neuronrobotics.sdk.network.BowlerTCPServer.BowlerTCPServer(), com.neuronrobotics.sdk.network.BowlerTCPClient.connect(), com.neuronrobotics.sdk.serial.SerialConnection.connect(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.connect(), com.neuronrobotics.sdk.network.BowlerTCPClient.disconnect(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setLastWrite | ( | long | lastWrite | ) |
Sets the last write.
lastWrite | the new last write |
Definition at line 1297 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.lastWrite.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.write(), com.neuronrobotics.sdk.network.BowlerUDPServer.write(), com.neuronrobotics.sdk.network.UDPBowlerConnection.write(), and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.write().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setPercentagePrint | ( | double | percentagePrint | ) |
Sets the percentage print.
percentagePrint | the new percentage print |
Definition at line 1279 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.percentagePrint.
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSynchronousDatagramListener | ( | ISynchronousDatagramListener | l | ) |
Sets the synchronous datagram listener.
l | the new synchronous datagram listener |
Definition at line 710 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncListen.
Referenced by com.neuronrobotics.sdk.common.device.server.BowlerAbstractServer.addServer().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSynchronusPacketTimeoutTime | ( | int | sleepTime | ) |
Sets the sleep time.
sleepTime | the new sleep time |
Definition at line 281 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.sleepTime, and com.neuronrobotics.sdk.common.Log.warning().
Referenced by com.neuronrobotics.sdk.network.BowlerTCPClient.BowlerTCPClient(), com.neuronrobotics.sdk.network.BowlerTCPServer.BowlerTCPServer(), com.neuronrobotics.sdk.network.BowlerUDPServer.BowlerUDPServer(), com.neuronrobotics.sdk.bootloader.NRBootLoader.connect(), com.neuronrobotics.sdk.dyio.DyIO.connect(), com.neuronrobotics.sdk.network.UDPBowlerConnection.init(), com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection.init(), com.neuronrobotics.sdk.namespace.bcs.pid.LegacyPidNamespaceImp.killAllPidGroups(), and com.neuronrobotics.sdk.serial.SerialConnection.SerialConnection().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSyncQueue | ( | QueueManager | syncQueue | ) |
Sets the sync queue.
syncQueue | the new sync queue |
Definition at line 612 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.isUseThreadedStack(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.syncQueue.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setThreadedUpstreamPackets | ( | boolean | up | ) |
Tells the connection to use asynchronous packets as threads or not.
up | the new threaded upstream packets |
Definition at line 143 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractDevice.setThreadedUpstreamPackets().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.setUseThreadedStack | ( | boolean | useThreadedStack | ) |
Sets the use threaded stack.
useThreadedStack | the new use threaded stack |
Definition at line 1457 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.useThreadedStack.
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat | ( | ) |
Start heart beat.
Definition at line 1224 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.setBeater().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.ping(), com.neuronrobotics.sdk.common.BowlerAbstractDevice.startHeartBeat(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat | ( | long | msHeartBeatTime | ) |
Start heart beat.
msHeartBeatTime | the ms heart beat time |
Definition at line 1233 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.heartBeatTime, and com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.stopHeartBeat | ( | ) |
Stop heart beat.
Definition at line 1243 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.setBeater().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractDevice.stopHeartBeat().
|
protected |
Wait for connectio to be ready.
Definition at line 555 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.Log.info(), com.neuronrobotics.sdk.util.ThreadUtil.wait(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.waitingForConnection().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.write(), com.neuronrobotics.sdk.network.BowlerUDPServer.write(), and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.write().
|
abstract |
Attempt to re-establish a connection. Return if the attempt was successful.
Reimplemented in com.neuronrobotics.sdk.wireless.bluetooth.BluetoothSerialConnection, com.neuronrobotics.sdk.serial.SerialConnection, com.neuronrobotics.sdk.pid.VirtualGenericPidDeviceConnection, com.neuronrobotics.sdk.network.UDPBowlerConnection, com.neuronrobotics.sdk.network.BowlerUDPServer, com.neuronrobotics.sdk.network.BowlerTCPServer, com.neuronrobotics.sdk.network.BowlerTCPClient, and com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.waitForConnectioToBeReady().
void com.neuronrobotics.sdk.common.BowlerAbstractConnection.write | ( | byte[] | data | ) | throws IOException |
Write.
data | the data |
IOException | Signals that an I/O exception has occurred. |
Reimplemented in com.neuronrobotics.sdk.javaxusb.UsbCDCSerialConnection, com.neuronrobotics.sdk.network.UDPBowlerConnection, and com.neuronrobotics.sdk.network.BowlerUDPServer.
Definition at line 1542 of file BowlerAbstractConnection.java.
References com.neuronrobotics.sdk.common.BowlerAbstractConnection.dataOuts, com.neuronrobotics.sdk.common.Log.error(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getChunkSize(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataOuts(), com.neuronrobotics.sdk.common.ByteList.popList(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setLastWrite(), com.neuronrobotics.sdk.common.ByteList.size(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.waitForConnectioToBeReady().
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendAsync(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly().
|
private |
The async queue.
Definition at line 92 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getAsyncQueue(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setAsyncQueue().
|
private |
The beater.
Definition at line 113 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.isBeater(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setBeater().
|
private |
The chunk size.
Definition at line 73 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getChunkSize(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setChunkSize().
|
private |
The connected.
Definition at line 95 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.isConnected(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected().
|
private |
The data ins.
Definition at line 98 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.disconnect(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataIns(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.loadPacketFromPhy(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setDataIns().
|
private |
The data outs.
Definition at line 101 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getDataOuts(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setConnected(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.setDataOuts(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.write().
|
private |
The heart beat time.
Definition at line 70 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.runHeartBeat(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.startHeartBeat().
|
private |
The last write.
Definition at line 67 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getLastWrite(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setLastWrite().
|
private |
The listeners.
Definition at line 80 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.addDatagramListener(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireAsyncOnResponse(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.removeDatagramListener().
|
private |
The namespace list.
Definition at line 107 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getRpcList(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.hasNamespace(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.isInitializedNamespaces(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.locateRpc(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.send().
|
private |
The namespaces finished initializing.
Definition at line 835 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.isInitializedNamespaces().
|
private |
The name space strings.
Definition at line 110 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getNamespaces().
|
private |
The percentage print.
Definition at line 838 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getPercentagePrint(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setPercentagePrint().
|
private |
The response.
Definition at line 77 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.clearLastSyncronousResponse(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.getLastSyncronousResponse(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.onDataReceived().
|
private |
The sleep time.
Definition at line 64 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSleepTime(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSynchronusPacketTimeoutTime().
|
private |
The sync listen.
Definition at line 86 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.fireSyncOnReceive(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.onDataReceived(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.removeSynchronousDatagramListener(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSynchronousDatagramListener().
|
private |
The queue.
Definition at line 89 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.getSyncQueue(), com.neuronrobotics.sdk.common.BowlerAbstractConnection.sendSynchronusly(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setSyncQueue().
|
private |
The use threaded stack.
Definition at line 61 of file BowlerAbstractConnection.java.
Referenced by com.neuronrobotics.sdk.common.BowlerAbstractConnection.isUseThreadedStack(), and com.neuronrobotics.sdk.common.BowlerAbstractConnection.setUseThreadedStack().