public final class LocalSerialPortRaw extends LocalSerialPort implements IBytesCommand
LocalSerialPort.FlowControl, LocalSerialPort.ParitydefaultPort, inStream, outStream, verbose| Constructor and Description |
|---|
LocalSerialPortRaw(String portName,
int baud,
int length,
int stopBits,
LocalSerialPort.Parity parity,
LocalSerialPort.FlowControl flowControl,
int timeout,
boolean verbose) |
| Modifier and Type | Method and Description |
|---|---|
static void |
main(String[] args) |
int |
readByte() |
int |
readBytes(byte[] buf) |
byte[] |
readBytes(int size) |
void |
sendByte(byte b) |
void |
sendBytes(byte[] data) |
void |
sendBytes(byte[] data,
int offset,
int length) |
void |
setDebug(int debug)
Sets a debug parameter.
|
close, dropDTR, flush, flushInput, getPortName, getSerialPortName, getSerialPortNames, getVersion, isValid, open, setDTR, setTimeout, setVerbosepublic LocalSerialPortRaw(String portName, int baud, int length, int stopBits, LocalSerialPort.Parity parity, LocalSerialPort.FlowControl flowControl, int timeout, boolean verbose) throws gnu.io.NoSuchPortException, gnu.io.PortInUseException, gnu.io.UnsupportedCommOperationException, IOException
gnu.io.NoSuchPortExceptiongnu.io.PortInUseExceptiongnu.io.UnsupportedCommOperationExceptionIOExceptionpublic static void main(String[] args)
public byte[] readBytes(int size)
throws IOException
readBytes in interface IBytesCommandIOExceptionpublic int readBytes(byte[] buf)
throws IOException
IOExceptionpublic int readByte()
throws IOException
IOExceptionpublic void sendBytes(byte[] data)
throws IOException
sendBytes in interface IBytesCommandIOExceptionpublic void sendBytes(byte[] data,
int offset,
int length)
throws IOException
IOExceptionpublic void sendByte(byte b)
throws IOException
IOExceptionpublic void setDebug(int debug)
IHarcHardwaresetDebug in interface IHarcHardwareCopyright © 2020. All rights reserved.