Javax comm 2.0 API

Hello everyone.
Do anyone of you know why the new version of comm api (version 3.0) does not support Windows? It is only available for Solaris SPARC, Solaris x86, and Linux x86.
Therefore, I can only use comm 2.0. But my problem is that although I have managed to connect a GPS device with my desktop, I can not do that with my laptop or a different desktop pc that I have tried.
The problem is that the application that I have developed can not find the COM port that I describe.
Any thoughts?
Thanks a lot
Pavlos

http://www.rxtx.org/
RXTX is an open source javax.comm 2.x compatible package with multi platform support. I use it on all of WinXP/CE, Linux, FreeBSD, OSX and it works like a charm for parallel, serial and serial to USB devices (for GPRS modems and GPS devices specifically). RXTX is nicely abstracted also so you don't specifically need to use anything but the javax.comm interface unless you want to use one of the API extensions (for example clearCommInput() which is a very obvious omission in the javax.comm api - skip() just does not cut it).
The code itself is not well documented - for the most part you can use the javax.comm documentation or just read the source - but it works, and works very well. Even if the heuristics in the RXTXCommDriver don't automatically find the device (you can check the sources as to why) you can add devices at runtime with CommPortIdentifier.addPortName() if needed.

Similar Messages

  • Trying to use javax comm api in Windows Environment

    I am working on developing a module to dial a phone number in a Windows environment. This is to test a voicemail connection so it isn't, necessarily, calling a modem.
    A couple of questions:
    1) I found the javax comm api but it appears Sun has only provided a Solaris and Linux version - where would I find a Windows version?
    2) I was planning on dialing a modem with the voicemail phone number (programmatically, of course). I, then, want to recognize response and react to it - possibly stopping only with seeing that the phone number answered (since I don't want to write voice recognition software). Am I on the right track?
    Ed

    I don't know of any devices named "/dev/term/a" - and that's both Linux and Solaris.

  • Javax Comm API on linux

    Hi,
    I am using javax comm API on linux. I am using RXTX comm API release 1.4 that uses gnu.io.RXTXCommDriver on J2ME Personal Profile Runtime Environment for x86 Linux Version 1.0.
    When I try to open a serial port, I get javax.comm.NoSuchPortException. What could be the problem? Does the cvm not support comm API. Is there any alternate way?

    I am looking for one too.. i figured better would be to use JNI classes... but i havent yet implemented it.. mebbe that will cause even more problemos..
    please post here if you find smthing

  • Javax comm api

    hi all,
    I tend to install the javax comm api on my windows98 se but it seem that I cant find the win32com.dll in the unzipped file.
    I downloaded the javax.comm 3.0, update 1 for Linux plateform, since there is no version for the windows.
    I have tried to enable the view every folder in my view tool but cant seem to work, I still cant see the win32com.dll file.
    Regards,
    Rejina Choi

    hi , I having problem downloading this file ""Comm3.0_u1_linux.zip""" and I need it urgently could someone give me a link where I can download it. Sun say that "Product Not Found The product you requested is not available at this time".

  • Javax comm problems

    Hi,
    I am trying to communicate with the communication ports using javax comm API through an applet.
    I am using Java 1.3.1.
    It gives me the exception:
    java.lang.ClassNotFoundException:javax.comm.commPortIdentifier
    I run the same program not using the applet , it runs fine.(i.e.recognises the ports etc)
    i tried to using a signed applet for the communication and still the exception is raised.
    All the files like comm.jar and properties file and also windriver are located in the reqd locations.else my program would not have run without using the applet.
    Can someone suggest what could be causing this problem
    Thanks
    Sai

    I am having the same problems with this javax.comm package. I am using Java 1.3.1_01 under WIN2K. I checked the hardware profile, and it listed my serial ports. I also have a palmpilot which communicates with this serial port, and it works fine as well.
    I tryed installing it two different ways:
    1.)
    installed it as if I was using jdk1.1.x
    putting the comm.jar package in the <jdkroot>/lib dir
    putting the properties file in the <jdkroot>/lib dir
    putting the dll in the <jdkroot>/bin dir
    adding <jdkroot>/lib/comm.jar to the classpath.
    While this did not give me a runtime error, it would not recognize any of my serial ports.
    2.)
    installed it according to the jdk1.2 documentation
    comm.jar -> <jdkroot>/jre/lib/ext/ dir
    properties -> <jdkroot>/jre/lib
    dll -> <jdkroot>/jre/bin
    not altering the path
    This gave me the following runtime error:
    java.lang.NoClassDefFoundError: javax/comm/CommPortIdentifier
         at VirtualGPSConsoleApp.main(VirtualGPSConsoleApp.java:27)
    Exception in thread "main"
    Process VirtualGPSConsoleApp exited abnormally with code 1
    Please let me know if you make any headway.
    Thank you,
    [email protected]

  • Missing artifact javax.servlet.jsp:jsp.api:jar:2.1 Eclipse error

    When I try to UPDATE my Maven project ( Chapter 8 - Using JSP with AEM 6.0 ) after I updated my main pom.xml with the javax.servlet.jsp dependancy, I get the following error :Missing artifact javax.servlet.jsp:jsp.api:jar:2.1
    I even tried to compile from command line using mvn compile and get the same error :
    [ERROR] Failed to execute goal on project company-training-project-bundle: Could  not resolve dependencies for project com.adobe.training:company-training-project-bundle:bundle:1.0-SNAPSHOT:
    Could not find artifact javax.servlet.jsp:jsp.api:jar:2.1 in adobe (http://repo.adobe.com/nexus/content/groups/public/) -> [Help 1]
    If I look at my .m2 dir, I can see that it attempted to get the jar, but it wasn't able to grab it :

    Hi Billy,
    Try changing the URL from (http://repo.adobe.com/nexus/content/groups/public/) to (https://repo.adobe.com/nexus/content/groups/public/), i.e. add the https.
    That should do it. Let us know if it doesn't work.

  • Javax comm package

    Do I need to download the javax comm package or what. If yes , what is url for downloading

    What platform are you using, javax.comm is easy on Windows and Solaris http://java.sun.com/products/javacomm/downloads/index.html. On Linux you will need a third party driver from http://www.rxtx.org/.

  • Javax Comm

    Could anyone please explain the exact use of JAVAX COMM ? (ie what it does ?)

    A blackbox is a piece of hardware normally. With this box one can monitor communication lines.
    In this case it is a Java application that monitors the hardware (see the readme in the source directory).

  • Javax comm api tutorial

    Hi!
    I've gone through sun's examples on how to use comm api.
    Are there any detailed tutorials anywhere which one can use to learn the intricacies of the comm api? This is because one can go through the code or even the javadoc and get already written code to run, but a good detailed tutorial somewhere always helps a great deal to really plunge into the essence of the technology in use.
    I'm an undergrad student and my aim is to send AT commands to a cell phone using a JAVA applet as well as receive responses from it through the JAVA applet.
    Thanks alot for all your help.

    This is a very well commented piece of code and is a good tutorial for the javx.comm api!
    http://discussion.forum.nokia.com/forum/showthread.php?s=ffbe2f2bf1e0d951ec1a0867c9470bd0&threadid=27929&highlight=%2Ajavax.comm%2A

  • OCF and Reader

    i want to used OCF but my reader is not a PCSC reader...please tell me how should i communicate with the card using non pcsc reader and OCF.
    Thanks
    Gopal

    please tell me how should i communicate with the card using non pcsc reader and OCF.From what I remember, you need to have an implementation of a CardTerminal for your reader, i.e., a class that is a driver, written in Java, for this type of reader; and then to tell OCF to use this implementation when a reader of that type is used (in an opencard.properties file). When I was working with OCF, we developped such drivers for the Gemplus readers that were connected to the serial port (GCR400, GCR410, GCR500, GCR700, etc.) and using the javax.comm generic communication API. The code is open source so if your reader is serial based, you could try to tweak your own implementation.. If it's usb-based, you would need to have the specs and develop your own driver on top of the Java USB communication API (javax.usb) but I do not know the state of this API and in any case it might be a very painful work to do.. In case it helps, you can find the source of our implementation with a compiled jar here: http://www.gemalto.com/techno/opencard/download/gemplus-terminals-4.1.zip
    Hope it'll help.
    Cheers,
    Christophe.
    = Any sufficiently advanced technology is indistinguishable from magic. =
    = -- Arthur C. Clarke (Clarke's third law) =

  • Serial port doesn't close properly

    I'm working with the RXTX comm APi to connect a java application (jdk 1.5) with a mikrocontroller via a virtual serial port (using WinXP). I'm only jumping to certain addresses of the controller and then write into or read from them.
    After some tricky problems that were already discussed in this forum I now encountered a new one:
    After I finished my communication with the controller, I want to make a clean shutdown by closing the input- and outputStream, removing the SerialEventListener and finally closing the serialPort.
    When I'm doing the latter, the program suddenly hangs totally. No exception is thrown and I have to terminate the application through the ide.
    I monitor all the port traffic with "portmon" from sysinternals and it tells me that around 5 minutes after I tried to close the port, the javaw-process finally sends "IRP_MJ_CLEANUP" and "IRP_MJ_CLOSE".
    Sometimes only the first one is sent, what makes it impossible to connect to the port again without a restart of windows (port in use by unkown application).
    I don't have the sourcecode right with me now, so I can't post some examples. However I'm basically doing nothing else then most of the other sourcecodes concerning serial port connections posted in this forum. Anyway I will post some code later.
    But for now, has anybody some ideas what could be the problem?
    ********* EDIT **********
    Seems that it's not necessary to post my sourcecode because the same problem occures when I'm running the SerialDemo from the javax.comm 2.0 API.

    Here's an update.  The serial port works fine, as long as I don't have any I/O pci cards in the machine.  Both my Adaptec SCSI controller and a Pinnacle AV card cause the same malfunction with the serial port.  When those cards are removed, it works!  No conflicts with IRQ or anything that I can see.....no errors reported by windows device manager.
    P

  • How to use the COMM API in a JAR file

    I have developed an application, using the NetBeans IDE, to communicate with a modem over the COM1 serial port using the Java Comm API. The application works fine within the IDE, but when a JAR file is created and "double-clicked", the application launches correctly, but when the code is executed to "talk" over the COM1 serial port - nothing happens. No exceptions and no warnings are thrown. My environment is XP, SP1.
    The manifest file is as follows:
    Manifest-Version: 1.0
    Class-Path: ../j2sdk1.4.2/jre/lib/ext/TimerBean.jar ../j2sdk1.4.2/jre/
    lib/ext/AbsoluteLayout.jar ../j2sdk1.4.2/jre/lib/ext/comm.jar
    Created-By: NetBeans IDE
    Specified-By: Projects/TheApp/Files/TheApp.jarContent
    Main-Class: Main
    According to the Comm API installation instructions, the following files are copied:
    copy comm.jar \j2sdk1.4.2\jre\lib\ext
    copy wind32com.dll \j2sdk1.4.2\bin
    copy javax.comm.properties \j2sdk1.4.2\jre\lib
    I suspect it has something to do with the paths.
    Any help would be greatly appreciated. Thanks.

    Thanks for your input, but after trying what you suggested the problem still exists. I think your right to be suspicous of the javax.comm.properties file. The application, that worked in the IDE, exhibits the same behavoir as the JAR file if the javax.comm.properties file is removed from the ../jre/lib directory. In other words it compiles correctly in the IDE, but when executed, nothing happens when the code that "talks" to the serial port is run.
    I've tried moving the javax.comm.properties file into the working directory. Also, the CLASSPATH and PATH system variables were modified to include the path to javax.comm.properties.
    If you have anymore ideas, please let me know.
    Thanks.

  • My last chance...for comm api with applet

    Hi to u great valued developers,
    Did anybody on earth the same as I do:
    Create and deploy a signed applet including the java comm api lib.
    The applet is deployed on an Apache Server and should run under IE6
    Easy? sure but something is certainly missing in the cab 'cause altough no error is return in console, I either do not receive any info from the ports.
    Same app compiled as application is ok.
    Thanks very much for any help.
    Cedric ([email protected])

    Hello Enrique,
    tx for ur answer.
    As said, the application (reading serial ports) works fine.
    The problem come possibly from javax.comm.property.
    Should I package it with the cab?

  • Error in the latest Java comm api for Linux

    installed latest Java comm api for Linux, tried test application for the Sun package:
    $ java SimpleRead
    Exception in thread "main" java.lang.ExceptionInInitializerError
    at SimpleRead.main(SimpleRead.java:67)
    Caused by: java.lang.NullPointerException
    at javax.comm.CommPortIdentifier.findConfFile(CommPortIdentifier.java:199)
    at javax.comm.CommPortIdentifier.<clinit>(CommPortIdentifier.java:117)
    ... 1 more
    What deis this message mean? How to make you serial port support work?

    and what does this error message mean??
    The package was installed accordingly to "Java(tm) Communications API Linux Installation Instructions":
    $ls /usr/lib/libLinuxSerialParallel.so
    /usr/lib/libLinuxSerialParallel.so
    $env|grep CLASS
    CLASSPATH=<..skipped..>:/opt/commapi/jar/comm.jar:/opt/commapi/jar/commtest.jar
    $ ls /opt/jdk1.5.0_04/jre/lib/javax.comm.properties
    /opt/jdk1.5.0_04/jre/lib/javax.comm.properties
    What else does it need?

  • Identifying a comm port using java communication API

    HI ALL,
    i'm using the communication API to detect the comm port to which my modem is attached.
    i say CommPortIdentifier c = CommPortIdentifier.getPortIdentifier("COM3");
    then i SOP(c.getName())
    i get an exception saying noSuchPortException
    i've put the javax.comm.properties file in jdk/lib but to no avail.
    i also have a win32com.dll file that is there inside lib.
    but this hasn't helped. Now the properties file has a driver mentioned. do i have 2 download that driver or does it come with the OS (i've no idea)
    i would be helpful if anybody could help me out with this problem.

    Try putting tha javax.comm.properties file in you <java>/jre/lib folder as well... It worked for me !

Maybe you are looking for