Package org.bidib.jbidibc.debug
Interface DebugInterface
-
public interface DebugInterface
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()Close the port.DebugMessageProcessorgetMessageReceiver()List<String>getPortIdentifiers()voidinitialize()Perform initialization task.booleanisOpened()voidopen(String portName, int baudRate, org.bidib.jbidibc.messages.ConnectionListener connectionListener, org.bidib.jbidibc.messages.helpers.Context context)Open connection to the specified port.voidsend(byte[] content)voidsend(String message, LineEndingEnum lineEnding)
-
-
-
Method Detail
-
initialize
void initialize()
Perform initialization task.
-
getPortIdentifiers
List<String> getPortIdentifiers()
- Returns:
- returns the list of serial port identifiers that are available in the system.
-
getMessageReceiver
DebugMessageProcessor getMessageReceiver()
- Returns:
- the message processor
-
close
void close()
Close the port.
-
isOpened
boolean isOpened()
- Returns:
- port is opened
-
open
void open(String portName, int baudRate, org.bidib.jbidibc.messages.ConnectionListener connectionListener, org.bidib.jbidibc.messages.helpers.Context context) throws org.bidib.jbidibc.messages.exception.PortNotFoundException, org.bidib.jbidibc.messages.exception.PortNotOpenedException
Open connection to the specified port.- Parameters:
portName- the port identifierbaudRate- the baud rate to useconnectionListener- the connection listenercontext- the context- Throws:
org.bidib.jbidibc.messages.exception.PortNotFoundExceptionorg.bidib.jbidibc.messages.exception.PortNotOpenedException
-
send
void send(String message, LineEndingEnum lineEnding)
- Parameters:
message- the message to send
-
send
void send(byte[] content)
- Parameters:
content- the content to send
-
-