Created
October 26, 2017 10:11
-
-
Save saviour123/616cae1413ffdce7800f2e0f1c223f1e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.fazecast.jSerialComm.SerialPort; | |
public class clean { | |
public static void main(String[] args) { | |
SerialPort[] ttyPort = SerialPort.getCommPorts(); | |
for (SerialPort i: ttyPort) { | |
i.openPort(); | |
System.out.println(i.bytesAvailable()); | |
i.closePort(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment