Wednesday May 28, 2008

Developing Java ME on Mac

As Karel already mentioned a few weeks ago, the Mobility pack can also be used on MacOS. (The mobility pack is written in Java and does run on Mac OS, but there is no current official WTK and no emulators for Mac OS, so netbeans.org never offered this download option.) Since people asked about it, I tried to install the third-party SDK and emulator and ran a sample app, and ta-daa, it worked. :) Here are a few "Doh!"s I came across, I'll write them down in case somebody else has the same questions.

  1. Installing NeBeans Mobility pack for Mac
    • There is no download explicitly labeled "Mobility pack of NetBeans for Mac OS" or so on the NetBeans Installer page. Instead you download any other Java edition for Mac OS, for instance the Java SE edition. (Or use the one you already have.)
    • Then you go to the Tools>Plugins menu, and install (at least) these two plugins: "Mobility" and "Visual Mobility Designer" (you can also install other items you need).
    • In other words, don't look for a plugin explicitly called "mpowerplayer" or so. The Mac integration is part of the normal "Mobility" plugin now.
  2. Installing mPowerPlayer
    • Next download the SDK for Mac OS -- click the "Get the SDK: Download..." link.
    • Then download the emulator for Mac OS -- click the "free download" button.
    • Remember the directory where you downloaded the stuff to. :-) The SDK is saved as mpp-sdk, the emulator is called mpowerplayer.app. I copied them into the "/Applications/" directory.
  3. Telling NetBeans where to find the JavaME platform
    • Go to the IDE's platform manager (Tools menu) and add the mpp-sdk as a "Java MIDP Platform emulator". (If needed you can get more details how to do that on the FAQ).
    • When you now create a new Mobile project, the MPowerPlayer SDK and QVGA device will show as options.
  4. Limitations?
    • You cannot use the CDC framework yet, this implementation is only meant for CLDC/MIDP.
    • You get a working emulator together with mpowerplayer, but it's only one. This is because emulators are released by phone companies, but they never released any for Mac OS. So you have to go back to a PC (e.g. on a virtual machine) to get one emulator for each type of phone if you want to do any serious crash-testing of your mobile apps.
    • Tip: Instead of using different emulators, you can test the app on actual devices that you have. Use the help menu in the IDE and search for "deploy to mobile device" to learn more, but some devices don't come with software to connect to Mac OS, so you may be out of luck.

About

NetBeans IDE, Java SE and ME, 3D Games, Linux, Mac, Cocoa, Prague, Linguistics.

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today
News

No bookmarks in folder

Blogroll