首先根據自己系統下載相應開發lib跟配置文件
32位系統
- Windows系統:放置
win32com.dll
在<jdk>\jre\bin
目錄中。 - Solaris系統:把
libSolarisSerialParallel.so
中LD_LIBRARY_PATH
。 - 放置
comm.jar
在<jdk>\jre\lib\ext
。 - 放置
javax.comm.properties
在<jdk>\jre\lib
。 - 不要改變
CLASSPATH
。
官方包,包含開發文檔、文件
鏈接:https://pan.baidu.com/s/1b8Wm7VbVepw_9Eh2Y84DIw
提取碼:ir4j
64位系統
配置文件、開發包,文檔說明等
Windows
----------------------------------------------------
Choose your binary build - x64 or x86 (based on which version of
the JVM you are installing to)
NOTE: You MUST match your architecture. You can't install the i386
version on a 64-bit version of the JDK and vice-versa.
For a JDK installation:
Copy RXTXcomm.jar ---> <JAVA_HOME>\jre\lib\ext
Copy rxtxSerial.dll ---> <JAVA_HOME>\jre\bin
Copy rxtxParallel.dll ---> <JAVA_HOME>\jre\bin
Linux
----------------------------------------------------
Choose your binary build - x86_64 or i386 (based on which version of
the JVM you are installing to)
NOTE: You MUST match your architecture. You can't install the i386
version on a 64-bit version of the JDK and vice-versa.
For a JDK installation on architecture=i386
Copy RXTXcomm.jar ---> <JAVA_HOME>/jre/lib/ext
Copy librxtxSerial.so ---> <JAVA_HOME>/jre/lib/i386/
Copy librxtxParallel.so ---> <JAVA_HOME>/jre/lib/i386/
NOTE: For a JDK installation on architecture=x86_64, just change the
i386 to x86_64 above.
鏈接:https://pan.baidu.com/s/1ppNBLjFoqQ7Juow3SkhDqw
提取碼:y3ae
接下來就是寫代碼:
...