<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>ITworks &#187; J2ME</title>
	<atom:link href="http://itworks.hu/tag/j2me/feed/" rel="self" type="application/rss+xml" />
	<link>http://itworks.hu</link>
	<description>Random musings in IT</description>
	<lastBuildDate>Mon, 09 Jan 2012 08:01:21 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Developing J2ME application on Linux</title>
		<link>http://itworks.hu/2007/06/08/developing-j2me-application-on-linux/</link>
		<comments>http://itworks.hu/2007/06/08/developing-j2me-application-on-linux/#comments</comments>
		<pubDate>Thu, 07 Jun 2007 23:27:49 +0000</pubDate>
		<dc:creator>csak</dc:creator>
				<category><![CDATA[IT]]></category>
		<category><![CDATA[]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[J2ME]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[SWT]]></category>

		<guid isPermaLink="false">http://itworks.hu/?p=15</guid>
		<description><![CDATA[We are starting up prototyping on a new project I&#8217;ve mentioned in this article. Our aim is to provide a proof-of-concept implementation of a simple off-line application running on the PDA&#8217;s we have. The PDA&#8217;s of today are quite well &#8230; <a href="http://itworks.hu/2007/06/08/developing-j2me-application-on-linux/">Read more <span class="meta-nav">&#187;</span></a>]]></description>
			<content:encoded><![CDATA[<p>We are starting up prototyping on a new project I&#8217;ve mentioned in <a href="http://itworks.hu/?p=8">this article</a>. Our aim is to provide a proof-of-concept implementation of a simple off-line application running on the PDA&#8217;s we have.<br />
<span id="more-15"></span><br />
The PDA&#8217;s of today are quite well equipped, they come with ample processor power and enough RAM for running medium sized applications. We&#8217;re supplied with some rugged Symbol PDAs, running Windows CE 2003 (I might be wrong there, as I haven&#8217;t laid my hand on one for longer than 5 minutes)<br />
Just to make things clear, I never done any J2ME development and I&#8217;m not very familiar with the concept of configurations or profiles either.<br />
Going through the Net and checking the scene I&#8217;ve found that there are only few options for J2ME development other than vi. The most favored recommendation seemed to be the <a href="http://www.netbeans.org/kb/articles/mobility.html">Netbeans Mobility Pack</a>, but I said I&#8217;m not touching that with a six foot pig-teaser pole. For the first run I&#8217;ve opted for using EclipseME instead.<br />
EclipseME 1.6.8 is a pretty simple solution, and can use <a href="http://java.sun.com/products/sjwtoolkit/">Sun&#8217;s Java Wireless toolkit 2.5.1</a> seamlessly under Linux.<br />
In a couple of minutes I was able to bang together a simple HelloWorld midlet, being pleased with myself. This was going better than I thought, so I went on with extending the application. I banged together a simple form display using SAX based xml parser and the lcdui controls. After I had my first form with a couple of controls displayed I went out to the Net to see which embedded language I could use to store and evaluate the logic parsed from the XML. I went to see the usual suspects, <a href="http://jakarta.apache.org/bsf/">BSF</a>, <a href="http://http://groovy.codehaus.org/">Groovy</a>, <a href="http://www.jython.org/">Jython</a>, <a href="http://www.mozilla.org/rhino/">JavaScript</a> and my favorite <a href="http://www.beanshell.org/">BeanShell</a>. There were traces on the forums that some people have already struggled with this out there, this didn&#8217;t make me feel more secure, but at least I knew I was not alone. After hours of reading it turned out that BSH has the smallest footprint of this all (cca. 145Kb) but whatever I do the language will use reflection to access the host objects. This was hardly a surprise, but the surprise came when I realized MIDP and CLDC do <strong>NOT</strong> support reflection. This was the time when I realized that I was using the wrong environment all along.<br />
No problem! &#8211; I thought &#8211; I just switch over to <a href="http://jcp.org/en/jsr/detail?id=218">CDC</a> and <a href="http://jcp.org/en/jsr/detail?id=219">Foundation</a> or <a href="http://jcp.org/en/jsr/detail?id=217">Personal Basis </a> Profile and I&#8217;m all set!<br />
This was when my hair started graying, I went through the Internet to find a single CDC implementation that can run on Linux, but no luck. Sun, Nokia, Motorola, Sony just to name a few, even though all strongly support Linux don&#8217;t provide any development environment for any OS other than Windows. This basically means that once you want to develop for any PDA in J2ME you are resorted to use a Windows based machine.<br />
There seems to be a touch of light on the end of the tunnel though, IBM does provide a solution even if it&#8217;s quite dated, that is Linux compatible. See the <a href="http://www-306.ibm.com/software/wireless/wctme_fam/index.html">Websphere Studio Device Developer</a> site to get a trial version. I thought Eclipse 2.0 is something I&#8217;ll never see in my life, but this is something I give a hearty welcome to! For our current project this is a reasonable alternative to use, but buying this for any other project seems unreasonable. As far as I can see this product is already discontinued, so I don&#8217;t expect to have it around for much longer.</p>
]]></content:encoded>
			<wfw:commentRss>http://itworks.hu/2007/06/08/developing-j2me-application-on-linux/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

