Part 2 - J2ME Development: Eclipse Pulsar & other Wireless Dev Kits
This part of series will go into the setup and basic run through of Eclipse Pulsar. If haven't already download Eclipse Pulsar from http://www.eclipse.org/pulsar/. In addition, you will need to download and install at least one of the following wireless dev kits:
Java Platform Micro Edition Software Development Kit 3.0 http://java.sun.com/javame/downloads/index.jsp Sony Ericsson SDK for Java ME Plaftorm http://developer.sonyericsson.com MotoDev Studio http://developer.motorola.com/platforms/java/ Nokia Series 60 and/or Nokia Seris 60 SDK http://www.forum.nokia.com/Tools_Docs_and_Code/Tools/ LG SDK 1.3 for the Java ME Platform http://developer.lgmobile.com/
Well its assume you know how to download and install Eclipse, nothing fancy here basically looks like your regular Eclipse but of course the J2ME flavour. Now create new project, select a New MIDlet Project. I've named the project My Mobile Project. You won't be able to finish creating the project without configuring at least one of the other dev kits to Eclipse Pulsar. This is to provide Eclipse Pulsar the mobile emulators. Press Add. After that press Manage Devices, then press Import, the familiar Windows browse will appear. Navigate to a wireless dev kit and import the emulators. What I did was install all 3rd party dev kits under one folder and imported from there. For example c:\mobiledev\, under that I installed the LGMobile, Motorola and the rest of the kits. The import will take a few minutes if you downloaded and installed all the other wireless dev kits. Ok now lets get something really basic up and running. We can use the built in templates, right-click the src folder and select New Java MIDlet. I named the usual HelloWorld; as well, I created package call com.jasonlam604 and placed the HelloWorld MIDlet there. You select any one of the templates (don't forget to check of the checkbox to enable the template selection). For this article I used the one that generates 3 Forms. After that all you need to do is run it! righ-click the project and select Run As and then select Emulated Java ME MIDlet Depending on which emulator you selected as your default an emulator with your HelloWorld will popup. Essentially thats it! You can now go about your J2ME coding under the Eclipse environment and assuming you've imported all the mobile emulators it makes it very easy to test the application in various emulators without the hassle of starting each of them up and re-deploying the application. Application Descriptor is your main source for the J2ME configuration: signing, midlet icon, build properties...etc. You may want to to ensure the right class files are generated for CLDC 1.1 by going under Properties and configuring the right options under the Java Compiler section.
Other Mobile Dev Kits
At the time of this writing other dev kits like Palm, Andorid or BlackBerry is supported. I did attempt to install the BlackBerry Eclipse Plugin from BlackBerry Developer site; however, it would install due to the fact its looking for Eclipse version 3.4 and Eclipse Pulsar is based on version 3.5.
Ok before we go any further we should hook in source control in this case Subversion Part 3 - Eclipse Pulsar with Subclipse keeping mind Maven2 layout standards