Login | Register   
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


advertisement
 

Running J2ME Applications on Palm-powered Devices : Page 3

Learn how to migrate your Enterprise J2ME applications to Palm-Powered devices including the Treo 650 and Palm LifeDrive.


advertisement
Running Your Application on a Palm-powered Handheld
To run your application on your Palm-powered device, you must deliver the JAD and JAR files to the WEME runtime. There are two ways to do this: via a network connection and by creating a Palm PRC file containing the JAD and JAR files.

My personal preference is to simply use the WEME runtime to download the JAD and JAR files over the network. If you're installing a third-party application, you can use the device's built-in Web browser to select a link to the application, or follow these steps:

  • From the application launcher, run the IBM WEME application manager by touching "IBM Java VM."
  • Press the Install Button.
  • Enter the URL to your jad file in the URL field (for example, http://www.myhost.com/j2me/helloworld.jad). You can use the various shortcuts available from the triangle menu to speed input of common URL components such as the protocol and domain bits of the URL.
  • Touch "OK."
  • The application manager may prompt you to confirm that you wish to install an application from an untrusted source. Confirm the installation if you feel you've entered the URL correctly.
  • The application manager will inform you that the application has been installed successfully.
The other way to install your application is to create a Palm PRC database from the class file and JAD file using the JarToPrc file included with the IBM WEME from IBM. This tool, described in the documentation that accompanies the IBM WEME, takes either the URL to a JAD file on the Internet or can have a JAD file dropped on its main window, and will download the associated JAR file and create a Palm PRC database you can HotSync to your Palm device. (It can also be run from the command line, letting you automate the process of creating a Palm PRC in your build environment.) It's probably best to create a Palm PRC file for your application if you're going to be distributing the J2ME file exclusively to Palm-powered handheld users, or if you want to include it as part of a larger installation package.

Regardless of how you install the J2ME applications, you will be able to execute them in two ways: either from the list of applications in the IBM Java VM's list of applications, or as icons in the Palm application launcher. Simply tapping the icon for the J2ME application in the Palm application launcher will start up the IBM WEME Java virtual machine and seamlessly launch your J2ME application just as if it were a native Palm application.



An Excellent Bridge
The IBM WEME is the most mature and stable Java runtime for Palm Powered devices, and compares favorably with the Java MIDP 2.0 runtimes available on commercially available wireless handsets from Nokia, Motorola, Samsung, and other major vendors. Whether you're a Java developer looking to bring your enterprise or consumer application to Palm Powered handhelds, or simply an owner of a Palm Powered device looking to run a specific J2ME application, it's an excellent bridge between Palm OS and Java applications.



Ray Rischpater is the chief architect at Rocket Mobile, Inc., specializing in the design and development of messaging and information access applications for today's wireless devices. Ray is the author of several books on software development including "eBay Application Development" and "Software Development for the QUALCOMM BREW Platform," both available from Apress, and is an active amateur radio operator.
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap