public class SerialPortControl
extends java.lang.Object
implements gnu.io.SerialPortEventListener
Klasse zum Senden und Empfangen von TC57-Telegrammen via serieller Schnittstelle.
Constructor and Description |
---|
SerialPortControl() |
Modifier and Type | Method and Description |
---|---|
byte[] |
query(int waitTimeSinceLastReceive,
byte[] sendBytes,
int receiveTimeout) |
byte[] |
readBytes(long timeout) |
void |
serialEvent(gnu.io.SerialPortEvent serialPortEvent) |
void |
shutdown() |
void |
start(PropertyQueryInterface propertyQueryInterface,
java.lang.String applicationName) |
public void start(PropertyQueryInterface propertyQueryInterface, java.lang.String applicationName) throws java.lang.Exception
java.lang.Exception
public void shutdown()
public void serialEvent(gnu.io.SerialPortEvent serialPortEvent)
serialEvent
in interface gnu.io.SerialPortEventListener
public byte[] query(int waitTimeSinceLastReceive, byte[] sendBytes, int receiveTimeout) throws java.lang.InterruptedException, java.io.IOException
java.lang.InterruptedException
java.io.IOException
public byte[] readBytes(long timeout) throws java.lang.InterruptedException
java.lang.InterruptedException