Merge pull request #2110 from gohai/serial-new

Trivial cleanups to the Serial library
This commit is contained in:
Ben Fry
2013-10-06 12:23:52 -07:00
6 changed files with 5 additions and 99 deletions

View File

@@ -1 +0,0 @@
serial.jar

View File

@@ -1 +1,4 @@
This is using a modified version of Java Simple Serial Connector by Alexey Sokolov. See https://github.com/gohai/java-simple-serial-connector for details on the modifications.
To compile the C++ portion of the library on OS X:
g++ -shared [or: -dynamiclib?] -arch i386 -arch x86_64 -I/System/Library/Frameworks/IOKit.framework/Versions/A/Headers -I$JAVA_HOME/include -I$JAVA_HOME/include/darwin -framework IOKit -framework CoreFoundation -o libjSSC-2.6.jnilib jssc.cpp

View File

@@ -186,8 +186,6 @@ public class Serial implements SerialPortEventListener {
public static Map<String, String> getProperties(String portName) {
//SerialPortList list = new SerialPortList();
//return list.getPortProperties(portName);
return SerialPortList.getPortProperties(portName);
}
@@ -214,8 +212,6 @@ public class Serial implements SerialPortEventListener {
public static String[] list() {
// returns list sorted alphabetically, thus cu.* comes before tty.*
// this was different with RXTX
//SerialPortList list = new SerialPortList();
//return list.getPortNames();
return SerialPortList.getPortNames();
}
@@ -457,4 +453,4 @@ public class Serial implements SerialPortEventListener {
throw new RuntimeException("Error writing to serial port " + e.getPortName() + ": " + e.getExceptionType());
}
}
}
}