HttpConnection and CLDC 1.0

Hi there,
I'm having some troubles with CLDC 1.0, my Midlet is communicating with the server over HTTP, but if I make some 4 to 6 HttpConnections without restarting the Midlet, it shows me an Exception. I was testing it in a Motorola V3 Black and a Samsung SGH-C200 both CLDC 1.0, but in any CLDC 1.1 device this exception is never thrown, anyone knows why?
Obs.: In Motorola's devices we get the size of the bytes transferred, and it is always something near 6000 bytes, than the Exception occurs.
Are there any limitations?

U need a virtual machine such as java on the pda and unless u can install that first u will not be able to run this stuff. The alternative would be to find out how to get only the runtime libs and install them in an applet.
You can see an applet demo of a motorola emulator on a web page applet at this page.
http://www.yospace.com/midpemu.html
Hope this helps...
Prashant

Similar Messages

  • Converting from MIDP 2.0 and CLDC 1.1 to MIDP 1.0 and CLDC 1.0

    Hello
    I have a Midlet that I set initially to use MIDP 2.0 and CLDC 1.1. I changed the platforms to MIDP 1.0, after i changed to MIDP 1.0 i get an Obfuscation failed with error code 1. error. I am using the NetBeans Progaurd obfuscator.
    When I change to CLDC 1.0 i get a Preverification failed with error code 1 Floating point result not allowed error.
    Can someone please help.

    When I change to CLDC 1.0 i get a Preverification failed with error code 1 Floating point result not allowed error.
    I am using bouncy castle cryptographic classes, i assume these use floating points. This is probably the reason why i cannot convert to CLDC 1.0.
    How about converting to MIDP 2.0?
    null
    null

  • Is MIDP 2.0 and CLDC  inluded in Sun Java Wireless Toolkit 2.5 for CLDC?

    I downloaded the "Sun Java Wireless Toolkit 2.5 for CLDC" and "Sun Java Toolkit 1.0 for CDC" and I have JDK 6.
    do I need to download anything else or is this all I need to make applications for cdc and cldc devices??
    please help.
    thank you.

    Most devices used today support MIDP 2.0, but not all of them support CLDC 1.1. If you can do without floats, it's better to restrict yourself to CLDC 1.0 & MIDP 2.0. Devices which only support MIDP 1.0 aren't suitable for today's game development anyway (performance, resolution...) so personally I'd suggest not bothering with them if you don't have to.
    Here are some lists you can use to help you decide what to use, based on how many devices you want to target:
    http://www.j2mepolish.org/devices/platform.html
    These lists aren't complete, so please let me know if you find better ones.

  • (MIDP) and (CLDC)

    I want to download (MIDP) and (CLDC) here;
    http://java.sun.com/javame/downloads/index.jsp
    but i can not, what I do wrong?

    ...what I do wrong?you do wrong by stopping too early.
    What you look for is about 4-5 clicks away from [index.jsp|http://java.sun.com/javame/downloads/index.jsp], not one. // More clicks seems to be the price for getting it for free
    - When you get to page shown after pressing "Download" button, don't stop but
    - - find and follow the link to "Sun's Free and Open Source Projects",
    - - - at page displayed, find and follow the link to (surprise surprise) "Mobile & Embedded"
    - - - - at the mobile section follow the link to project site
    - - - - - at the project site main page, you'll find the explanations and download links

  • Antenna and CLDC 1.1

    Hi All,
    I've been using float points in my application (CLDC 1.1) and my application is preverified and runs fine on Eclipse, but I am having few problems when I am deploying it.
    I've used the antenna plug-in and I set in my build.xml file:
    <property name="MicroEdition-Configuration_version" value="CLDC-1.1" />
    <property name="wtk.cldc.version" value="1.1" />
    <wtkpackage basedir="${classes.dir}" jarfile="${build.dir}/${MIDletSuite}.jar" jadfile="${build.dir}/${MIDletSuite}.jad" config="${MicroEdition-Configuration_version}" profile="${MicroEdition-Profile_version}" obfuscate="false" preverify="true">
    I see that it is adding the cldc11.jar instead of the cldc10.jar successfully in my application, but it still invoking the preverify1.0 instead of the preverify1.1 and I am getting the error:
    [wtkbuild] Error preverifying class myPackage.MyClass
    [wtkbuild] VERIFIER ERROR mypackage/MyClass.myMethod(I)V:
    [wtkbuild] Floating point result not allowed
    I really would appreciate any help here.
    Kind Regards,
    Marcelo
    Message was edited by:
    marcelo.dantas

    i have encounter a similar problem, the cross-compiled kvm1.1 quits as soon as a java program goes to a floating-point operation. but kvm1.1 with native-compile runs well on my pc.
    the kvm1.1 both with cross-compile and native-compile can not prints its version.
    is there anyone know how to solve this bug? please help me to settle this problem. thank you very much.

  • Save as swf file using httpconnection and file io

    I have one application which is fatch the swf file from web and i want to save as in same to swf file format.
    when i have fatch the swf file and save as .swf format i have unable to view as flash animation in browser and micromedia.
    Anyone suggest me ?
    URL url = new URL("http://nileshpatel.com/abc.swf");
    HttpURLConnection con = (HttpURLConnection) url.openConnection();
    con.setRequestProperty( "User-Agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" );
    BufferedReader rd;
    rd = new BufferedReader(new InputStreamReader(con.getInputStream()));
    String line="";
    String content="";
    File f = new File("users/nileshpatel/neo.swf");
    FileWriter fw = new FileWriter(f);
    while ((line = rd.readLine()) != null) {
    content += line;
    rd.close();
    fw.write(content);
    fw.close();
    ############################################################

    BTW sometimes flash uses communication with server to obtain some information before/during running. In such case you'll need to provide kind of your own HTTP server, pass swf to browser using HTTP protocol (not directly from HDD) then pass all additional data.
    Hope this is not your case :)

  • MDIP ,MIDLet and CLDC

    hi all,
    I am a newbie in J2ME.I would like to develop a mobile app,but i am confusing with the MDIP, MIDLet and CDLC.Dose anyone tell me or give me a guide what is the connection between them?
    Then,what should i use to develop a mobile app(applet?servlet?or others?).
    Thanks in advance
    wls

    No, wouldn't know why I sould do that without knowing what you need. I really isn't that hard.

  • J2me wireless toolkit and MIDP,CLDC

    Hi,
    does the j2me wireless toolkit ship the cldc and midp with it ?

    why email, thats a forum because there are more people interested in problems and their solution than you.
    The 2.2beta also ships with the CLDC 1.1 and MIDP 2.0. Its a must because without it, you wouldnt be able to execute anything. And you cant put the JVM, MIDP and CLDC on your phone. The only thing you need is your application. The rest is implemented in hardware (or firmware of the phone). If not, theres no way to ''manually'' put in there (this includes upgrading).
    hth
    Kay

  • Any Embeded database for CLDC ?

    Hi to all
    Is there any standard embeded database for mobile phone application development. That embeded database can store in mobile itself. We can access this database using standard sql quires from MIDP. And also we cannot use HttpConnection and RMS Concept. We can write pure jdbc connection concept in CLDC application itself.
    1. Embeded MySql support for this concept? If it support please provide the link for download and sampels codes.
    2. Or suggess me can i use any other database for mobile without using a httpserver connection.
    Thanks in advance,
    Saravanan.K

    Hi,
    We are a startup mobile technology company. We have developed a complete relational database with SQL and JDBC support for J2ME platform. The CLDC 1.0 version is in beta testing and supports standard SQL including triggers. It is a small footprint database only 115 KB in size. It runs on any mobile which supports J2ME CLDC 1.0 / MIDP 1.0 or above. We also have a CLDC 1.1 database under development which will support support constraints like foreign key and check constraints. If you are interested in receiving a evaluation copy please email at [email protected]
    Thanks

  • User-Agent property is doubled in HttpConnection

    Hi,
    I have midlet which makes an HttpConnection to the server.
    If i deploy it in my device MDA compact III, and try to connect to server I get 400 Bad Request (Invalid Header Name).
    I searched around and found the reason that my device sends two User-Agent headers. One is "Untrusted/1.0" other is "intent JTE Profile/MIDP-2.0 Configuration/CLDC-1.1"
    And the server just rejects that request without doing anything.
    I dont add any User-Agent headers in my code, it is added by default. Is there any workaround for this. Please help me.
    Message was edited by:
    gerekbolsa

    The implementation of HttpConnection and HttpsConnection must include
    a separate User-Agent header with the Product-Token �UNTRUSTED/1.0�.
    (This is supplied by the kvm in order to refer to the fact that this MIDlet is unsigned.)
    User-Agent headers supplied by the application must not be deleted.
    So to remove it, u must have to sign it. And regarding why u are getting BadRequest in the server, this must be because of some illegal assignment of headers. u have to watch the request u are sending to the server and its headers as they are reaching there.
    Regds,
    SD
    Message was edited by:
    find_suvro@SDN

  • HttpConnection & TCP Sockets

    I wish to receive an httprequest on a tcpsocket. That is one midlet opens an httpconnection and the other midlet opens a tcp socket. Is it posiible for two way communication between them.
    If so how can the tcp socket read the data.

    Hi Briggsd!
    I'm playing with some sockets.
    can you please help me?!
    J2ME uses only HTTP connections?
    and what are the sockets? what is the difference between CLDC socket and J2SE Socket?
    is there any other way to communicate with a Servlet?
    and very important..
    is there a difference if it's using GPRS or 3G?
    would the http connection work for all? and just the connection speed would change?
    help me!!

  • How to make a pause between an Alert and a plateformRequest ?

    Hello,
    I' programming a class which realize a download from an URL called downloadURL. An overview of my code is :
    public class SoundDownloader implements CommandListener{
                 private Alert downloadAlert2;
                 private String downloadURL;
                       private MIDlet midlet;
                 public SoundDownloader(String downloadURL, MIDlet midlet){
                   this.downloadURL = downloadURL;
                            this.midlet = midlet;
                       try {                       
                   //download code using HttpConnection and openInputStream()                       
                       } catch (Exception e) {
                            downloadAlert2 = new Alert("Download error !");
                            downloadAlert2.setType(AlertType.ERROR);
                            downloadAlert2.setString("Download error : "+e.toString());
                            downloadAlert2.setTimeout(Alert.FOREVER);                      
                            display.setCurrent(downloadAlert2);//show the Alert  
                            downloadAlert2=null;
                   //I'd like to stay here until the user dismisses the Alert     
                            this.midlet.platformRequest(downloadURL);
                            this.midlet.notifyDestroyed();
    }When an exception is caught, I display an error alert and I'd like to make the user wait until he dismisses the alert before launching a download by the mobile browser (platformRequest).
    I don't get this result now! The alert is displayed, but just after (without any delay), the platformRequest method is automatically launched!
    Could someone help me please?
    Thanks in advance!
    /arkienou

    I would try catch block code with [Alert.setCommandListener|http://java.sun.com/javame/reference/apis/jsr118/javax/microedition/lcdui/Alert.html#setCommandListener(javax.microedition.lcdui.CommandListener)], roughly like below:
      downloadAlert2 = new Alert("Download error !");
      downloadAlert2.setType(AlertType.ERROR);
      downloadAlert2.setString("Download error : "+e.toString())
      downloadAlert2.setTimeout(Alert.FOREVER);
      downloadAlert2.setCommandListener(new CommandListener() {
        public void commandAction(Command c, Displayable d) {
          if (c == Alert.DISMISS_COMMAND) {
            midlet.platformRequest(downloadURL);
            midlet.notifyDestroyed();
      display.setCurrent(downloadAlert2);//show the Alert  
    }

  • Bluetooth and j2me, a frustrating scenario...

    Hello all,
    I don't want to use propeitory sdk's so I need to get a bluetooth stack working with the wireless toolkit but I am not going to pay for it so I downloaded the stack from javabluetooth.org, but when trying to compile a program which uses the javax.bluetooth package I get an error...
    Error preverifying class org.javabluetooth.distributed.BluetoothTCPServer
        VERIFIER ERROR org/javabluetooth/distributed/BluetoothTCPServer.run()V:
    Cannot find class java/net/SocketI guess j2me api does not include the package socket at all?
    Does anyone have any ideas how to get a bluetooth stack working with j2me?
    Thanks for your time
    poncenby

    the WTK 2.2b is available since June 26 or so.
    To the JSR-82 API: the classes from sun (javax.bluetooth.* and javax.obex.*) are part of the WTK 2.2b and can be used. But remember: to use a bt app on a phone, the phone must support JSR82, not only MIDP and CLDC.
    I am too good for this world. You should check http://java.sun.com/j2me . There can at least 2 articles be found regarding the development of J2ME and Bluetooth, as well as the WTK downloads and many other interesting things ;-)
    here is the link to the WTK 2.2b
    http://java.sun.com/products/j2mewtoolkit/download-2_2.html
    good luck and have fun
    Killer_2001

  • Floating Point # in MIDP & CLDC...

    What is way of using the floating point numbers in MIDP & CLDC?
    MIDP and CLDC has no built in support for it.
    Plz help me...

    simple.... Don't :P
    you've got fixed point libs available, but theyre not exactly fast.
    It is possible to recompile the KVM and enable floating point support, but none of the embedded implementations have this support, so its a pointless excercise.
    What do you need floating point for?

  • MIDP and floating-point numbers

    Hiya,
    I need to use floating numbers in a few occasions in a MIDP app that I'm programming at the moment. Whenever I do so though I get a nervous-breaking error at the pre-verification stage of the build. I am working with Wireless Toolkit 2.0 and the rror I get is:
    Building "MyMIDlet"
    Error preverifying class <ClassName>
    ERROR: floating-point constants should not appear
    com.sun.kvem.ktools.ExecutionException: Preverifier returned 1
    Build failedI get this error whenever I use a floating-point varible or even whenever I compare something to a floating-point value.
    It's got me really puzzled and I can't think of any way around the problem. Any help would be very much appreciated...
    Thanks!

    also WTK 2.1 (and CLDC 1.1I think ) does support FP. You think right, CLDC 1.1, that's when they added the floats (in theory a device could be MIDP 1.0 on top of CLDC 1.1, and it would also have floats). There's only one CLDC 1.1 device I've heard of: Nokia 6320.
    shmoove

Maybe you are looking for

  • Pc no longer works on airport extreme

    Airport extreme was working for mac and older PC. Now it isn't. Can anyone help?

  • No external display signal

    I recently purchased a miniDisplayPort to HDMI so I could have an external display. I am getting no signal from my Samsung 32in TV. Is it not possible to use this cable? Unfortunately, I've looked around on the Internet and couldn't find anything so

  • Quick question which I'm sure has already been answer..

    So unlike a lot of people I'm not completely upset with the release of the new iPhone, technology changes all the time and there really isn't anything that you can do. That is unless you have extremely deep pockets. Anyway, with the release of the iP

  • CAN I USE A PROGRESSBAR WITH A SERVICE DOWNLOAD?

    I know that I can, just not sure if I can do it the way that I want.  In an AIR app, I have three dropdownlists that are populated by a service call that then displays media associated with the dropdownlists.  I do not want the user to have to wait a

  • Get SPRY to start at 0%

    I hae spent a few hours now on the internet trying to find the answer to the Grow/Shrink delema of having it start off with a the image at it's min. setting instead of it's larger setting. I can not find anything on this that is clear. Looking at cod