Calendar

September 2010
S M T W T F S
« Jul    
 1234
567891011
12131415161718
19202122232425
2627282930  

Developing Java ME on Mac OS X

To install and setup Netbeans on Mac is no problem. Running a J2EE or J2SE application would then be fairly similar to Windows. But running J2ME has a little problem.

To work with mobile application, one can follow the helpful Netbeans + Mobility + Mpowerplayer Guide. However, the guide did not cover how to add optional java package such as jsr75, which I would cover below.

The complete steps to set up a mobile development environment with Netbeans + J2ME Mobility Pack + Visual Designer + Mpowerplayer emulator + optional java package:

  1. Download Netbeans for Mac OS X.
  2. Install either the Java SE or Web & Java EE version of the IDE.
  3. After installation, start the IDE and go to Tools > Plugins.
  4. Click the Available Plugins tab. Under Category go to Mobility.
  5. Check the boxes for Visual Mobility Designer, and Mobility and click Install.
  6. Download the Mpowerplayer SDK and install it.
  7. In the NetBeans IDE main menu, choose Tools > Java Platform Manager.
  8. Click Add Platform. Select the folder that contains the MPowerPlayer SDK (mpp-sdk). Click Search to locate the emulator in the folder. When the IDE finds the MPowerPlayer SDK, click Next.
  9. Click Finish. The IDE registers the MIDP platform. You can now build and run a MIDP 2.0 application. But the setup still lacks optional java packages.
  10. Download SUN WTK 2.5.2 (for Windows and Linux)
  11. Unzip the .bin. For example, run the command:
    $ unzip sun_java_wireless_toolkit-2_5_2-linux.bin
  12. Under /lib, copy the optional java package you need eg. jsr75, jsr 179 or even midpapi21.jar. Put them under /Applications/mpp-sdk/stubs/
  13. In your project, edit project.properties and add to platform.bootclasspath the optional java package. eg.
    platform.bootclasspath=${platform.home}/stubs/mmapi.jar:${platform.home}/stubs/midp-2.0.jar:${platform.home}/stubs/cldc-1.0.jar:${platform.home}/stubs/jsr75.jar
  14. Begin mobile development on Mac OS X!
Share and Enjoy:
  • Print
  • Digg
  • Sphinn
  • Facebook
  • Google Bookmarks
  • Live
  • MySpace
  • PDF
  • RSS
  • Twitter
  • Yahoo! Bookmarks
  • email

Leave a Reply

 

 

 

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="">