I not able to open the connection. Every time it try it throws
purejavacomm.PortInUseException: errno() == 13
at purejavacomm.PureJavaSerialPort.(PureJavaSerialPort.java:1093)
at purejavacomm.CommPortIdentifier.open(CommPortIdentifier.java:159)
at com.company.Main.foo(Main.java:27)
at com.company.Main.main(Main.java:21)
Exception in thread "main" java.lang.NullPointerException
at com.company.Main.foo(Main.java:32)
at com.company.Main.main(Main.java:21)
Heres my code
package com.company;
import purejavacomm.*;
public class Main {
public static Logger logger = Logger.getLogger(Main.class.getName());
public static List serialPorts = new ArrayList();
public static InputStream inputStream;
public static Thread readThread;
I not able to open the connection. Every time it try it throws purejavacomm.PortInUseException: errno() == 13 at purejavacomm.PureJavaSerialPort.(PureJavaSerialPort.java:1093)
at purejavacomm.CommPortIdentifier.open(CommPortIdentifier.java:159)
at com.company.Main.foo(Main.java:27)
at com.company.Main.main(Main.java:21)
Exception in thread "main" java.lang.NullPointerException
at com.company.Main.foo(Main.java:32)
at com.company.Main.main(Main.java:21)
Heres my code
package com.company;
import purejavacomm.*;
import java.io.IOException; import java.io.InputStream; import java.util.ArrayList; import java.util.List; import java.util.TooManyListenersException; import java.util.logging.Level; import java.util.logging.Logger; import java.util.Enumeration;
public class Main { public static Logger logger = Logger.getLogger(Main.class.getName()); public static List serialPorts = new ArrayList();
public static InputStream inputStream;
public static Thread readThread;
} //Users need to be in I also added user to the lock and uucp grounds