src/main/java/com/zy/core/thread/BarcodeThread.java
@@ -38,7 +38,7 @@ while (true) { try { write("T".getBytes(), "T".length()); byte[] read = read(11, 1000); byte[] read = read(11, 5); if (null != read) { barcode = new String(read); } @@ -142,7 +142,7 @@ boolean connect = barcodeThread.connect(); System.out.println(connect); barcodeThread.write("T".getBytes(), "T".length()); byte[] read = barcodeThread.read(11, 1000); byte[] read = barcodeThread.read(11, 1); System.out.println(new String(read)); } }