Log in

View Full Version : Java Applications on Pocket PC Platform: Why Not?


Jonathon Watkins
01-26-2005, 11:00 AM
<div class='os_post_top_link'><a href='http://blog.vikdavid.com/2005/01/java_on_pocketp.html' target='_blank'>http://blog.vikdavid.com/2005/01/ja...on_pocketp.html</a><br /><br /></div>"<i>I've thought of 5 reasons why PocketPC is not a popular platform for Java apps. I'm asking the Java community for comments on PocketPC and PDA development in general. Why do I care? I spent a year working on a Java/PocketPC project and subsequently have put up the Java on PocketPC (unofficial FAQ) which is starting to get a decent number of search hits. I have a few thoughts that I'm just going to list out."</i><br /><br />Vik has indeed thought of several reasons why Java on the PPC has not been widely adopted yet. Suggests include the possibility that that developers may be ignoring a formidable device platform for purely 'religious' reasons and that folks just simply don't know where to begin. To fix that last point you can certainly make a good start with Val's <a href="http://www.vikdavid.com/mobile/">'Java on PocketPC' FAQ</a>. So why do you guys think that we haven't had too many tasty Java applications brewed for the Pocket PC Platform?

pajjy
01-26-2005, 03:08 PM
Well, for one thing you have to buy the JVM in addition to the application that you want to run - it's not expensive, but an extra hassle and cost to deal with. It's amazing how little patience people have when they need to put in just a little extra effort.

In addition, I've often found Java applications to be quite resource-intensive, which is probably not ideal for a PocketPC. I'm always having to keep an eye on memory usage on my own PPC as it is.

Pete

Jonathon Watkins
01-26-2005, 03:23 PM
A very harty welcome to you Pajjy. And how is Edinburgh these days? :wink:

Interesting points. I know for myself that is something is fiddly, I tend not to do it. :oops: Inertia and hassle are two great drags factors.....

egads
01-26-2005, 04:04 PM
Most Java app's I've ever used have been resource hogs and very slow at what they do. I think the PPC is slow enough already, why make it slower???

Menneisyys
01-26-2005, 04:07 PM
Cool article :)

Running applets (especially evaluating NetFront's Java support) are missing from the article, though. Also, I would have welcome some cool 'hacks', like making JDK1.1-only Personal Java JVM's run (almost full-fledged) J2SE applications. (I have played a lot with PPC JVM's and am pretty happy with their hackability.)

Also, I recommend the thread http://www.pocketpcthoughts.com/forums/viewtopic.php?t=36013 for people interested in a step-by-step tutorial of installing the IBM JVM and some games for it.

pdhenry
01-26-2005, 04:08 PM
A valid point, perhaps, but much lesser devices (I'm thinking cell phones) have the JVM in ROM and are capable of running small java apps like games.

Microsoft's disdain for Java might be an issue, but it shouldn't be too hard for a vendor to bundle a JVM into a PPC ROM image.

Menneisyys
01-26-2005, 04:15 PM
Most Java app's I've ever used have been resource hogs and very slow at what they do. I think the PPC is slow enough already, why make it slower???

Running Java applets (with Jeode's PIE plug-in or NetFront) is pretty cool though. And, the ability to run J2ME games is pretty cool too because there're tons of them at http://midlet.org/ .

And, there're quite a few apps running flawlessly under (prolly, hacked and J2SE-upgraded) Jeode. Jeode is indeed a resource hog, but, for example, generating PDF files on a PDA is only possible from inside Java apps because there's absolutely no native applications to do this.

Jimmy Dodd
01-26-2005, 04:16 PM
From a developer's standpoint, I haven't see any reason to go the Java route on a Pocket PC, especially with the .NET CF available. You have to get a JVM (which usually isn't free and takes up space) versus .NET CF which is either free to download or included in ROM with the device. Then there's the whole confusing JAVA world of Personal Java, Micro Java, CLDC, MIDP, MIDLETs, yadda yadda yadda. There's a pretty big learning curve just to get the development environment figured out. Until recently, Sun's web site was close to impossible to figure out from a newbie standpoint. IBM has put out a lot of stuff for Pocket PC but it's still hard to figure out just what you need.

I think Sun and IBM are moving to clear a lot of this up, but the whole lack of standard JVM for Pocket PC is still problematic. Sun doesn't seem to want to invest in the Pocket PC platform at all, and IBM is mainly interested in the desktop. Maybe if one or the other would acknowledge the platform and write some starter material for developers we'd see more interest.

Menneisyys
01-26-2005, 04:32 PM
You have to get a JVM (which usually isn't free and takes up space) versus .NET CF which is either free to download or included in ROM with the device. Then there's the whole confusing JAVA world of Personal Java, Micro Java, CLDC, MIDP, MIDLETs, yadda yadda yadda. There's a pretty big learning curve just to get the development environment figured out.

I disagree. I've been programming in Java since its inception (started early 1996) and had no problem in absorbing new versions. Sure, J2ME is pretty different from J2SE, but it's not very hard to learn either if you already know J2SE.

just to get the development environment figured out.

You can always code in a simple, lightweight Java editor like JCreator. I mostly don't use any kind of IDE either.

Until recently, Sun's web site was close to impossible to figure out from a newbie standpoint. IBM has put out a lot of stuff for Pocket PC but it's still hard to figure out just what you need.

That's, unfortunately, right. However, if one gets a decent Java intro book (e.g., Horstmann's Core Java - http://www.horstmann.com/corejava.html ), he/she won't have problems in absorving new info/technologies after that. Sure, a book on J2ME will also be needed if he/she wants to code for J2ME too.

I think Sun and IBM are moving to clear a lot of this up, but the whole lack of standard JVM for Pocket PC is still problematic. Sun doesn't seem to want to invest in the Pocket PC platform at all, and IBM is mainly interested in the desktop. Maybe if one or the other would acknowledge the platform and write some starter material for developers we'd see more interest.

Sun has indeed made a mistake by completely ignoring WinCE. However, as there're tons of Java code already, and a lot of them CAN be run on the PPC (think of, for example, the vast number of networking apps that won't ever be rewritten/converted to WinCE.NET!), the situation is not that bad. (Except for the lack of a REAL JVM that is not a resource hog, is up-to-date without major hacking from the user's part and has good speed.)

SteveHoward999
01-26-2005, 04:59 PM
I have been a multimedia developer for about 8 years now. I've been hearing for years about how amazing Java is and how it will take over the world and solve all our cross-platform issues.

I think I can count on the fingers of one had the number of Java applats I encounter each YEAR on the web (maybe I lead a sheltered life) and no-one has ever approached me requiring me to create a Java solution.


So while the Java community is still certain they are really important, and everywhere, I have yet to be convinced(leaving aside Mobile phones that is ...). That's the main reason I don't care about Java for PPC. Why bother when everything I need, and everything my clients need, is already there without Java?

Jimmy Dodd
01-26-2005, 05:05 PM
You have to get a JVM (which usually isn't free and takes up space) versus .NET CF which is either free to download or included in ROM with the device. Then there's the whole confusing JAVA world of Personal Java, Micro Java, CLDC, MIDP, MIDLETs, yadda yadda yadda. There's a pretty big learning curve just to get the development environment figured out.

I disagree. I've been programming in Java since its inception (started early 1996) and had no problem in absorbing new versions. Sure, J2ME is pretty different from J2SE, but it's not very hard to learn either if you already know J2SE.

I won't argue that it is hard to keep up with, I'm looking more from the point of jumping in now (or in the last couple of years). Trying to determine from the Sun website what technology to use is incredibly hard. Until recently there was as much information on their site on PersonalJava (now defunct, I think) as there was on J2ME. There was also very little help in figuring out which of the two was the newer technology. The discussion of the CDC/CLDC "profiles" didn't help much either. ;-)

I know that the article is mainly about why JAVA developers don't code for PPCs, but I was approaching it from the position of why PPC developers don't use JAVA. Sorry if I didn't make that clear from the beginning.

Menneisyys
01-26-2005, 05:21 PM
I don't debate client-side Java is pretty dead (except for some well-known, multiplatform stuff like the Oracle GUI). So are 'toy' applets. Exceptions are midlets - and being able to run midlets on the PPC (even when they are dog-slow) is a big plus.

Java as a platform, on the other hand, is very popular in middle-layer programming. I mostly coordinate middle-layer business (not "plain" Web) development and the majority of middle-layer technologies are Java-based. For example, we've just started working with ** (a well-known American firm - electricity and stuff), and most of their middle-layer stuff are Java.

Furthermore, because of the lack of native apps on the PPC, Java support (would be) welcome to run, for example, advanced HTTP proxies (the only native PPC HTTP proxy only knows the GET method...) or thousands of other tools.

I don't debate running them in a bloated/slow JVM is not a good idea. But, at least, they work, until someone rewrites/recompiles the same stuff into native .NET.

Menneisyys
01-26-2005, 05:26 PM
I'm looking more from the point of jumping in now (or in the last couple of years). Trying to determine from the Sun website what technology to use is incredibly hard. Until recently there was as much information on their site on PersonalJava (now defunct, I think) as there was on J2ME. There was also very little help in figuring out which of the two was the newer technology. The discussion of the CDC/CLDC "profiles" didn't help much either. ;-)

Sun's website has always been pretty convoluted and their own tutorial useless for teaching/learning. I've been tutoring Java on several Java courses at separate firms / my ex-University since 1998 and have never used/recommended Sun's own teaching stuff (except for their own course books - SL-111 and SL-276, for example, in courses organized by them). Third-party tutorials, books (Core Java, Just Java, Thinking in Java, Beginning Java etc.) are orders of magnitude clearer.

pajjy
01-26-2005, 05:26 PM
I've been hearing for years about how amazing Java is and how it will take over the world and solve all our cross-platform issues.

If that was going to happen it would have happened a long time ago. Java has its good points, but it's certainly not the all encompassing solution that was originally envisioned.

I think I can count on the fingers of one had the number of Java applats I encounter each YEAR on the web (maybe I lead a sheltered life) and no-one has ever approached me requiring me to create a Java solution.

I work for a company that writes quite a lot of Java solutions, but we very, very seldom have to write applets. The company have generally found that Java solutions are best run on the web server as a servlet - that way you can predict the hardware and software platform and resources that Java has available to it.

Felix Torres
01-26-2005, 07:51 PM
I'm thinking its a combination of factors:

1- The core audience of the PocketPC (and PalmOS) platforms is looking for an information appliance. They want apps that plug in and run. Java on either system is anything *but* plug-n-go.
2- Native plug-n-go apps are abundant and high quality, usually at good prices.
3- Native development tools are at least as good as anything Java has to offer and often much better. Hence there is no incentive for developers to use Java. If the developers don't use it, there is no incentive for hardware vendors to include it, which brings you back to item 1.

I've noticed that client-side Java is most successful in environments that are generally starved for applications. Usually proprietary or niche systems where if you couldn't run Java you couldn't run anything. Or, that are dominated by techies that aren't afraid of write once debug everywhere. >;-)

None of which applies to the mainstream PocketPC market.
The bottom line is PocketPC customers have no need of anything Java has to offer. And that's how MS likes it. ;-)

Kevin Daly
01-26-2005, 08:13 PM
Given the need for the person installing the application to have purchased a JVM, the question regarding Java on Pocket PC is always going to be not so much "Why not?" as "Why?", and this is only going to become more true as Microsoft fills in gaps in the Compact Framework this year and improves performance.

There's probably a much stronger case for Java on Smartphone (the base of Java games for mobile phones, which makes a difference to some people), which is why some vendors provide it as standard.

Damion Chaplin
01-26-2005, 10:44 PM
Didn't Microsoft have to be sued before they would even release a Java module for Windows? Even then, it had to be downloaded and was not included in the default install...

That seems pretty clear that Microsoft's not interested in encouraging developers to use Java. MS could easily include support for it native in the OS if they wanted to...

jneely
01-27-2005, 03:48 AM
As a Java developer with a good bit of desktop experience, I'd have to say that there are a FEW very good Java desktop applications. In fact, I'd say that Java IDEs are themselves some of the best examples of Java Desktop software in existence.

I'd even say that taken together, Eclipse, NetBeans and IntelliJ (and there are others) are some of the most incredible development tools ever written. Easily better than Visual Studio at this point (from someone who uses both).

Unfortunately, it's harder for me to find other examples outside of developer tools.

Java GUIs *CAN* be both beautiful AND highly responsive -- as the mentioned tools demonstrate. It isn't easy to acheive though, and I think that's the real problem.

The real hurdle for both Java and .NET apps is the relatively slow start-up time of larger GUI applications and the sometimes painful garbage collection that all VMs incur.

Both are getting better though, and the important thing to keep your eyes on though is that dynamic optimizers and dynamic profiling of code WILL someday be faster than the best pre-compiled code. Read this for a neat look into what the future may hold:
http://arstechnica.com/reviews/1q00/dynamo/dynamo-1.html

Menneisyys
01-27-2005, 09:36 AM
BTW, there're tons of cool and useful Java midlets released all the time (not just games), especially in Symbian-centric countries (e.g. Finland). For example, Tero Lehto's PDA BLOG ( http://lehto.net/blogi/ ) has just linked a new, very cool midlet, BusWatch, ( http://koti.mbnet.fi/~kakoskin/buswatch/ ) that contains some 6000 station data of the Helsinki area + Tampere. If you have (had) a PPC that is able to run midlets, it is of great help because there're no native PPC solutions for this (except for being connected and browsing the web).