*/
private static final Logger log = Logger.getLogger(SerialPortTest.class);
public static void main(String[] args) {
try {
final SerialPortAPI api = (SerialPortAPI)
(DeviceUtils.getAPI("serial0", SerialPortAPI.class));
final ByteChannel channel = api.getChannel(null);
System.out.println("Writing a test string to the serial port.");
PrintWriter w = new PrintWriter(new OutputStreamWriter(
new ChannelOutputStream(channel, 1000)));
w.print("Hello World!\r\n");