Browse DevX
Sign up for e-mail newsletters from DevX


EclipseME—Another IDE Option for J2ME Development : Page 2

This summer, the 1.0 release of a new plug-in, namely EclipseME, affords J2ME developers another free IDE option built on top of this very popular and powerful platform.




Building the Right Environment to Support AI, Machine Learning and Deep Learning

Prerequisites for Your Environment
Java and Eclipse, of course, are important prerequisites. JDK 1.4 or better is required. The latest version of the EclipseME (1.1.0) plug-in only works with Eclipse 3.1—the latest version of Eclipse, as of this writing. If you are starting off new in Eclipse, this probably isn't an issue. However, if you have installed older versions of Eclipse and have wrestled to get certain features of other plug-ins working in your development environment, this may prove to be a pain point. You'll either have to step back a version in EclipseME (to the 1.0.0 release) or get the new version of Eclipse 3.1 and hope all your other plug-ins still perform as expected. The EclipseME Web site suggests that it will not support Eclipse 3.0 beyond its 1.0.0 version.

Also required is a supported wireless toolkit (see Table 1). Besides those listed in Table 1, EclipseME "supports some toolkits" that meet the Unified Emulator Interface (UEI) specification. UEI provides a standard interface for Eclipse to query the emulator to understand required settings, classpaths, and additional information. So if you use another UEI standard toolkit, it might also work; according to documentation, EclipseME will identify supported toolkits automatically. If your wireless toolkit is not supported, the EclipseME project team encourages you to submit a request for support that will be considered for future release.

Table 1. Supported and Tested EclipseME Wireless Toolkits.
These J2ME wireless toolkits have been tested to work with EclipseME. Others may work if they meet the UEI specification.

Sun Wireless Toolkits
Motorola SDK for J2ME
Nokia Developer Suite 2.2 for J2ME
Siemens SMTK for Series 60
Sony Ericsson J2ME SDK
Sprint PCS Wireless Toolkit for Java 2.0.13

Optionally, if you want obfuscated code (highly recommended—see my earlier article on obfuscation), EclipseME integrates with ProGuard. ProGuard is the same obfuscator used by NetBeans and Sun's Wireless Toolkit. You have to download and configure ProGuard to work with EclipseME. The download is straightforward, and configuration amounts to telling EclipseME where it can find the ProGuard files.

Additionally, EclipseME supports automatic generation and updates for a set of Antenna build files. Antenna is an Ant extension that provides a set of Ant tasks for building and managing Java ME MIDP applications. EclipseME does many of the tasks Antenna does, but by providing a means to automatically generate and update Antenna build files, you have the ability to share your work with non-EclipseME users.

Author's Note: JDK 1.5.0, Eclipse 3.1, Sun's Wireless Toolkit 2.2, and ProGuard 3.3.1 were used for this article.

EclipseME Installation
Once you have the other tools in place, installation of EclipseME is easy. The EclipseME Web site offers a nice document with explicit instructions on two different methods for installing the plug-in. You can either use Eclipse's built in update facility to install and update the product via an electronic handshake with the EclipseME Web site or you can download the archive file and manually install the plug-in yourself. Both types of installations are fully documented. For anyone who has used a previous release of EclipseME, it is suggested that you remove any instance of the plug in numbered 0.5.0 or earlier before installing the new plug-in.

EclipseME Configuration
If you're the type who tends to download, install, and get started without reading the documentation, take heed: At a minimum, you should take a second to read the configuration instructions. If you skip this step, you will be sure to have some issues during development (trust me—I tried).

In particular, you will need to

  • Configure EclipseME to work with your favorite wireless toolkit using Eclipse's Preferences Dialog window (see Figure 1).
  • While in the Preferences Dialog, change Eclipse's default debugging settings to allow Eclipse and the EclipseME plug-in to interact with the debugging facility.
  • If you plan to obfuscate your application, provide the IDE with information on where ProGuard has been installed.
  • If you plan to use Antenna, provide the IDE with information on where the Antenna archive (JAR file) has been installed.
  • If you are going to be debugging your MIDlets in OTA mode set up Over-the-Air (OTA) options.

Figure 1.Eclipse's Preferences Dialog: The Preferences Dialog window is where most Eclipse plug-ins are configured. As shown, EclipseME adds additional configuration items to the Preferences Dialog.
Figure 2. MIDlet Suite Project Creation Error. Trying to create a J2ME MIDlet Suite without first configuring the wireless toolkit will result in a wizard window that gives the "No Platform Definitions Available" error when trying to create the project.

Configuring EclipseME to work with a supported wireless toolkit (see Table 1) is simply a matter of indicating where the toolkit is on your file system and letting EclipseME do the rest of the work. Don't try to create a new J2ME MIDlet Suite project without configuring the wireless toolkit. If you do, the wizard that allows you to create a project will indicate that a wireless toolkit needs to be configured (see Figure 2).

Also, attempting to use the Eclipse debug facility on your MIDlet without properly setting the debug options will result in all types of errors. Without the debugging configuration specified in the documentation, sometimes the application hangs and other times you get a virtual machine stack dump that is less than obvious in indicating where the problem resides.

Comment and Contribute






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



Thanks for your registration, follow us on our social networks to keep up-to-date