×

Discussion Board

Results 1 to 5 of 5
  1. #1
    Registered User
    Join Date
    Mar 2009
    Location
    Jordan
    Posts
    3

    Unhappy javax.comm package

    al salam alyikom

    I want my Mobile to be able to receive a serial data from a device,
    I have just write a program using javax.comm package but I cannt run it through wireless toolKit 2.5, it give me this error "Javax.comm package does not exist".
    I installed the package to the java program but how can I install it to j2me?or what i have to do?

    regard
    Palestine princess

  2. #2
    Regular Contributor
    Join Date
    Sep 2007
    Location
    Thirunelveli
    Posts
    115

    Re: javax.comm package

    Hi,
    You cannot use javax.comm package in MIDlet. this is not supported by MIDP profile. Please use the package Javax.microedition.io package. Using this u can have http, https, socket and UDP connection. Please use this. Please take a look into these url's
    http://www.wirelessdevnet.com/channe...2me_http.phtml
    http://developers.sun.com/mobility/m.../midp2network/

    Hope this is will help you

    Regards
    Senthil

  3. #3
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: javax.comm package

    Some devices provide access to serial ports, which might be RS232, USB, IrDA, or something else.

    The way to open a connection is by using the javax.microedition.io package:

    Code:
    CommConnection con = (CommConnection) Connector.open("comm:port-name");
    To find the port names that your device supports, use:

    Code:
    String portList = System.getProperty("microedition.commports");
    This might read like "COM0", or might be a comma-separated list like "COM0,IR0".

    Hope this helps.

    Graham.

  4. #4
    Registered User
    Join Date
    Mar 2009
    Location
    Jordan
    Posts
    3

    Re: javax.comm package

    thanx all

    I was afraid from this,
    any way;I will read the tutorial and start from s crash.

    thanx again. ^_^

  5. #5
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: javax.comm package

    Don't worry. Take a look at the javadocs for javax.microedition.io.CommConnection. Once you work out the right connection string, and get an InputStream and an OutputStream, you'll be fine! :-)

Similar Threads

  1. [moved] Where can i download from the Partnaring API package
    By dbydx_nitinv in forum Feedback - Nokia Developer Services & Infrastructure
    Replies: 2
    Last Post: 2009-03-02, 13:46
  2. Problems about maemo 4.0.1 SDK installation.
    By fgg_maemo in forum General Development Questions
    Replies: 3
    Last Post: 2008-10-07, 14:26
  3. Suggestion: Combined Python Extras package
    By tsharju in forum Symbian
    Replies: 21
    Last Post: 2007-07-03, 04:28
  4. Creting Application package fileNotFound error
    By pid0101 in forum Mobile Java General
    Replies: 0
    Last Post: 2004-01-19, 19:55
  5. javax.comm package
    By 0m4r in forum Mobile Java Networking & Messaging & Security
    Replies: 0
    Last Post: 2003-06-04, 19:36

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×