- 浏览: 799142 次
- 性别:
- 来自: 北京
文章分类
最新评论
-
yuhanwm910731:
我现在需要实现复选(非级联选择)的树形下拉菜单,麻烦发给我一份 ...
extjs3.X支持树型的下拉控件 -
shine1200:
“所以咱们现在设置的虚拟路径“/message/upload/ ...
weblogic虚拟路径的配置和使用(2) -
icefireforest:
Fangrn 写道jx_dream 写道楼主,我最近在做树形下 ...
extjs3.X支持树型的下拉控件 -
cloudfile:
谢谢分享!
c++库c#调用开发时需要注意的一点 -
xuweilinbegin:
我也要一份哦:xuweilin15353@163.com,谢谢 ...
extjs3.X支持树型的下拉控件
From Rxtx
<!-- start content -->This page is for general content regarding the use of rxtx. Feel free to add your own content.
I wrote an app several months ago using javax.comm on windows. Sun has left me high and dry. rxtx help!
- download ftp://ftp.qbang.org/pub/rxtx/rxtx-2.1-7-bins-r2.zip
- unzip it
- copy rxtxSerial.dll into your c:\program files\java\jre-version\bin dir
- copy RXTXcomm.jar into your c:\program files\java\jre-version\lib\ext dir
- change all references from 'javax.comm' to 'gnu.io'
- recompile
- test
Dido Sun left me Hi and dry. After 30+ hours wasting my life on javax.comm it is the RXTXcomm 2.1.7 that really worked the first time
REMEMBER !! for the newbies Change the all occurences of the import javax.comm.*; in MyApps.java TO import gnu.io.*; I did not even have to recompile as suggested the rxtxSerial.dll
a job well done for the rxtx.org team.
Even after following the above instructions, under Netbeans 5.5 on Windows, I needed to right-click Libraries under Projects on the left hand side of the screen, and select Add JAR/Folder, picking the RXTXcomm.jar file. Only then did my "import gnu.io.*;" become a valid command. Also, I got a run-time error where it failed to load the rxtxSerial.DLL library because it couldn't find it. I needed to right-click the project name, select properties, select Run under categories, and ...
add a VM Options: entry of -Djava.library.path="C:/where-ever-you-stuck-rxtxSerial.DLL-file;%PATH%" While I'm sure there is more than one way of adding the directory to your path, this worked for me. Note I did the default NetBeans 5.5/JDK 1.6.0 isntall accepting all the default options(ie clicking next until I got to finish), so I haven't modified my java paths or anything.
Using RXTX In Eclipse
From Rxtx
<!-- start content -->This is how I add and use RXTX in Eclipse for Win32 Projects, there are probably other ways but it works for me. mailto:seaton@gateway.net.au
- Copy RXTXcomm.jar file and dll files to the lib directory of your project
- Under Project | Properties | Java Build Path | Libraries
- click Add JARs... Button
- Select the RXTXComm.jar from lib directory
- Jar should now be in the Build Path
- expand the RXTXComm.jar entry in the list and select "Native Library Location"
- Select the project lib directory and apply
Be careful when using System.in.read() and rxtx in win32; It can trip across a known JRE deadlock (http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4809647 ) bug
Deploying JAVA with RXTX
From Rxtx
<!-- start content -->Saving the RXTX jar-file and DLL in the JRE is not optimal if you indend to distribute your JAVA application and do not want to bundle it with a customized JRE.
Windows
For Windows, the Janel (http://sourceforge.net/projects/janel ) JAVA launcher can be used.
- create a directory for your application, and save the Janel executable and lap-file to it;
- create a subfolder named "classes" and save the jar-file of your application as well as the RXTXcomm.jar in it;
- create a subfolder named "lib" and save the rxtxSerial.dll to it;
- make the following entries in the lap-file:
- "-Djava.class.path=;${SELF_HOME}\classes\YourApp.jar;${SELF_HOME}\classes\RXTXcomm.jar;"
- "janel.main.class=YourAppMainClass"
- "janel.library.path.dir=${SELF_HOME}\lib"
unjar
It should be possible to unjar the RXTXcomm.jar and then add the .classes into YourApp.jar. This should eliminate the secon .jar and the need to modify java.class.path. Please clarify the steps if you pursue this.
I was successful in doing this on my Mac. First, unzip the RXTX.jar file. I didn't try unjar, as unzip worked fine. Then, place the gnu folder in the same folder as your application jar file. Execute the following command from the command line:
jar uvf Your_Apps_Name_here.jar gnu
to update the jar with the contents of the classes in the gnu folder. Your app will now run by double clicking on it, provided the .dll or .jnilib library is in the same folder. I would love to include the OS specific libraries in the jar for a single, monolithic package, but after researching this on the web, it is apparently very difficult at best and probably impossible.
Other Platforms
It would be great if someone with access to Linux boxes could provide us with similar recipes for their operating system.
The above unjar instructions and subsequent jars worked fine for my app on both Mac and Windows machines.
<!-- Saved in parser cache with key rxtxdb:pcache:idhash:945-1!1!0!1!0!1!0!!en and timestamp 20070424145924 -->两个库都可以在Eclipse下随项目跑,相信在纯项目中也可以做到。
发表评论
-
提供IT系统运维支持、系统优化方案
2012-10-26 14:46 6提供IT系统运维支持、系统优化方案,有多个运维实施经验。 ... -
Java指定编码读写文件(UTF-8)
2010-11-30 14:00 3097有时我们需要程序动态生成jsp文件,采取系统默认的编码操作的文 ... -
was6.0发布struts2项目异常
2010-11-18 18:39 1974[10-11-18 18:31:33:609 CST] 000 ... -
利用spring提供的字符编码过滤器
2010-11-14 11:55 1960<!-- spring的字符集过滤器 --> ... -
简单的几句CSS布局口诀
2010-11-10 16:41 954简单的几句CSS布局口诀,就可以写出精简,标准的样式。 ... -
commons-email笔记
2010-11-10 14:38 1364import java.io.UnsupportedE ... -
如何解决 调用jar程序时出现 outofMemory的问题
2010-10-29 12:02 1192我们在调用 打包好的java程序时,如果程序要加载大量数据的话 ... -
GC策略的调优
2010-09-30 22:30 1613GC 策略在 G1 还没成熟的情况下,目前主要有串行、并 ... -
关于Spring和WebLogic版本兼容的一点小提示
2010-09-30 16:31 2056首先 WebLogic 的各个版本和 JDK 绑定的很紧, 或 ... -
删除WebLogic 10的缓存
2010-09-30 16:07 4631在WebLogic 10上部署了一个应用,最近作了更新并重新部 ... -
weblogic如何强制先加载web-inf/lib下的jar
2010-09-30 16:05 4775方法1: 修改WEB-INF\weblogic.xml (如 ... -
用Log4j自动生成日志
2010-09-27 13:28 1629Log4j是Apache基金会的一 ... -
java smslib发送短信
2010-09-10 10:02 1623public class SendMessage { ... -
Spring定时器的两种实现方式
2010-09-01 21:07 1450有两种流行Spring定时 ... -
使用 Commons-Email 在邮件内容中直接嵌入图片
2010-08-31 20:25 1317我们在发送邮件的时候,如果使用HTML在邮件内容中嵌入图片,& ... -
Struts2中转换Date类型的问题
2010-08-29 09:43 1329Web开发会涉及到很多类型转换的情况。我们知道,页面中的一切值 ... -
java smslib 发送短信错误信息
2010-08-25 15:02 4238org.smslib.GatewayException: GS ... -
javascript汉字转拼音代码
2010-08-22 08:21 4568使用方法(1):pinyin.go('汉字'); //例:张家 ... -
关于IE等浏览器在下载JAR文件时的,将后缀更改为zip等问题及解决方案
2010-08-03 12:19 1199httpd.conf这个文件中的mime.types上面,打开 ... -
一句代码解决IE8兼容问题
2010-07-24 15:46 1572这篇文章就是寻求最简单的方法解决ie8兼容问题,当然这只是最简 ...
相关推荐
用于java进行串口读取操作,尤其RXTX.jar找了好久才找到。。。。你值得拥有
这是我使用的开发JAVA串口通讯的文件,里面含有小例程,希望对各位有用!
RXTX 2.0 for use WITH Sun's CommAPI (namespace javax.comm) win32
标签:netty、transport、rxtx、中文文档、jar包、java; 使用方法:解压翻译后的API文档,用浏览器打开“index.html”文件,即可纵览文档内容。 人性化翻译,文档中的代码和结构保持不变,注释和说明精准翻译,请...
标签:transport、netty、rxtx、jar包、java、中文文档; 使用方法:解压翻译后的API文档,用浏览器打开“index.html”文件,即可纵览文档内容。 人性化翻译,文档中的代码和结构保持不变,注释和说明精准翻译,请...
标签:transport、netty、rxtx、jar包、java、中英对照文档; 使用方法:解压翻译后的API文档,用浏览器打开“index.html”文件,即可纵览文档内容。 人性化翻译,文档中的代码和结构保持不变,注释和说明精准翻译,...
java操作串口rxtx的dll.win32下面的最新版
标签:netty、transport、rxtx、中英对照文档、jar包、java; 使用方法:解压翻译后的API文档,用浏览器打开“index.html”文件,即可纵览文档内容。 人性化翻译,文档中的代码和结构保持不变,注释和说明精准翻译,...
RXTX项目提供了Windows,Linux,Mac OS X,Solaris操作系统下的兼容性,javax.comm 串口通讯包API的实现,为其他研发人员在此类系统下研发串口应用提供了相当的方便。
串口通讯部分包,如果需要可以再找资源win7 64 java 8 RXTXcomm(mfz-rxtx-2.2) IntelliJ IDEA 2019.1.1 x64
RXTX.jar,内含所有RXTX2.2版本jar包及安装方法,32位和64的都有
rxtx的编程文档 英文版 不是很好用,相信的可用看官网的实例
串口通信gnu.io包不存在,这里提供jar包,下载导入即可,亲测可用
串口通讯需要的jar包,gnu.io.SerialPort; gnu.io.CommPortIdentifier; gnu.io.SerialPort; gnu.io.SerialPortEvent; gnu.io.SerialPortEventListener; gnu.io.... <JAVA_HOME>\jre\bin
http://fizzed.com/oss/rxtx-for-java 官方地址不能正常下载,将我收藏的分享给需要的人
java串口通信jar包rxtx-2.2
支持读取linux系统下目录为ttyr的串口
1.下载系统相应的RXTXcomm。 2.将rxtxSerial.dll、rxtxParallel.dll复制到\jre\bin目录下。包含所有版本,win/ linux
我将它移植回 javax.comm 命名空间,因为我们没有源代码的遗留软件需要这样。RXTX 2.2 上游最新更新: 2012-01-08 RXTX 的这个分支修补了上游源以引入以下修复: 支持 linux ttyACM* 设备减少延迟(感谢 ) 在具有...
保含java串口编程的所有文件 ...1.java 串口通信编程所需要的类库:RXTXCommon 和 comm jar包以及所需要的其他文件,以及使用说明。comm包里有demo和API 2.java串口模拟助手 VSPD(绿色版) 3.java 串口调试助手