From 741d4168443b80ae5d7b282e4b2f2b0a6e319a9c Mon Sep 17 00:00:00 2001 From: gac-S_Changer Date: Thu, 31 Aug 2017 17:23:54 +0200 Subject: [PATCH] Closedown --- plugins/LaserUE.java | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/plugins/LaserUE.java b/plugins/LaserUE.java index 588a853..f88628c 100644 --- a/plugins/LaserUE.java +++ b/plugins/LaserUE.java @@ -2,6 +2,7 @@ import ch.psi.pshell.serial.SerialPortDevice; import ch.psi.pshell.serial.SerialPortDeviceConfig; import static ch.psi.utils.BitMask.*; +import java.io.IOException; /* * @@ -14,15 +15,23 @@ public class LaserUE extends SerialPortDevice{ public LaserUE(String name, String port) { super(name, port, 921600, SerialPortDeviceConfig.DataBits.DB_8, SerialPortDeviceConfig.StopBits.SB_1, SerialPortDeviceConfig.Parity.None); - //this.setMode(Mode.FullDuplex); + this.setMode(Mode.FullDuplex); + System.out.print("XXX"); } int value = 0; int count = 0; - //@Override - protected void onBytee(int rx) { - System.out.print(rx); + @Override + protected int readByte() throws IOException { + int ret = super.readByte(); + System.out.print(ret); + return ret; + } + + @Override + protected void onByte(int rx) { + //System.out.print(rx); if (rx < 0) { count = 0; } else {