Articles
Index
Program JavaTM Devices An Overview
Get up to speed on JavaTM technology for small devices
by Bill Day; Reprinted from JavaWorld
Not so many years ago, computers were huge boxes requiring tremendous quantities
of air conditioning and protection. They were hidden away within special rooms
located within large corporations and research centers. There weren't very many
of them, and each had many users. CPU time was extremely expensive, and access
and availability were often quite limited. Oh, how the world has changed!
Today, we can see three distinct but overlapping eras of computing:
-
Mainframe era: one computer, many people
-
PC era: one person, one computer
-
Ubiquitous-computing era: one person, many computers
Most of us use more computers embedded in devices and appliances than we do
PCs, workstations, and mainframes combined. For instance, a quick inventory of
my average workday shows that I use a laptop, a couple of servers, and a
workstation. But the car I use to commute to work each day has many more CPUs
than all of those traditional computers put together! When we include the
computer chips in mobile phones, Palm handhelds, microwave ovens, Ethernet hubs
and the communication equipment we use at work (the phone system, and so on),
you can see that we're already firmly planted in the era of ubiquitous computing.
Not only are CPUs everywhere, but almost all of our interactions with CPUs
involve (or very soon will involve) interactions with networks. How can you as
a programmer take advantage of computers and networks embedded everywhere in
heterogeneous devices and environments?
Java technology enables ubiquitous network computing
Many articles on the history of the JavaTM programming language describe its early days as having been
device-oriented. It was originally designed for nontraditional computing
devices; over time, it moved up into desktops and servers. From the beginning,
the language's small bytecode size, ability to move objects around networks, and
cross-platform portability were engineered to enable programming for small,
mobile, heterogeneous devices. It luckily turned out that these features were
also quite useful in an interconnected, net-based world on bigger computers.
Java technology has come full circle, and programming devices with the Java language is
once again on the rise. In this column, I will examine the various APIs, tools,
and products available for Java programming for various consumer devices, such
as personal digital assistants (PDAs), mobile phones, pagers, and similar
embedded computers.
As these articles unfold, I hope you will gain a greater appreciation of both
what Java technology can do for these devices and how you can take advantage of them in
future projects.
Major Java device APIs and initiatives
Sun and its partners are building a number of Java device
environments and APIs:
|
API's and Environments |
Description |
|
PersonalJavaTM |
Including numerous implementations from RTOS
(Realtime Operating System) vendors. It supports consumer devices with a GUI
and network connection. |
|
EmbeddedJavaTM |
For devices with intermittent or
no network connection and often no GUI. It is highly
configurable to include only those classes and VM
features needed for a particular device. |
|
JavaCardTM |
Including Dallas Semiconductor's iButton
implementation (the ever popular Java ring being
one form factor for its delivery). |
Java 2 Platform, Micro Edition (J2ME)
K Virtual Machine* (KVM) |
For consumer devices these are the latest
additions. Early preview versions were demonstrated
at JavaOneSM (June 1999) running on
Motorola PageWriter 2000x, Palm III and V
hand-held devices, Bull point-of-sale
(POS) terminals, and next generation mobile phones
from Matsushita/Panasonic and other manufacturers
targeting NTT DoCoMo's i-mode service. They will enable
JiniTM Technology support for small devices, as well as enable splitting
up computing functionality between device and server,
so that device footprint can be minimized. |
|
Symbian |
A partnership between Nokia, Ericsson, Motorola,
and Matsushita/Panasonic, providing Java technology support for the EPOC32
mobile phone and wireless communicator operating system. |
In addition, several other companies have independent clean-room Java technology for
consumer and embedded device initiatives. Among these, the most talked about
technologies include:
-
Various independent Palm VMs, such as the Ghost VM
and WabaVM; Java conduit and related technologies
are also available from third parties
-
Transvirtual Technologies's Kaffe JVM,
compliant with the PersonalJava 1.1.1 specification
-
Cygnus Solutions's GCJ static compiler front end
for embedded Java development
-
Hewlett-Packard's Chai, Chai VM, and
related tools
-
NewMonics's clean-room realtime Java technology efforts
There are also some emerging sets of consumer-oriented APIs. These API groupings,
known as profiles in Sun parlance, are meant to sit on top of
underlying Java runtimes and provide a certain level of portability and
interoperability within classes of devices targeted at specific markets or
vertical industries. Note that profiles may include other profilesthat
is, profiles can be nested.
Profiles are currently under development by working groups within the consumer
device and embedded device community. Some possible profiles to watch for include:
-
Wireless profile (mobile phones and communicators), similar to Symbian's
smart phone and wireless information device profiles. May include JavaPhoneTM
API.
-
POS profile.
-
Hand-held PDA profile.
-
Automotive profile (may include Java platform for Automotive API).
-
Set-top box/interactive television profile (may include
Java TVTM API).
-
PersonalJava profile, a repackaging of PersonalJava specifications
to more clearly differentiate how the APIs may be provided on
top of various J2ME implementations.
The profiles are still under development, but most of the platforms and tools
are already available in some form. Please refer to the
Resources at the end of this column for more information
on each of the platforms, profiles, and other embedded Java technologies
mentioned above.
The states of the major consumer and embedded Java APIs and technologies as of
June 23, 1999 are revealed in the following table.
|
Technology |
Type |
API specification (version) |
FAQ |
Reference implementation (version) |
Discussion e-mail list |
|
PersonalJava |
Application environment (likely profile in future) |
Yes (1.1.1) |
Yes |
Yes (3.0, corresponds to 1.1.1 API) |
No |
|
JavaPhone |
Extension API (likely part of one or more profiles) |
Yes (0.91) |
Yes |
No |
No |
|
JavaTV |
Extension API (likely part of one or more profiles) |
Yes (0.90) |
Yes |
No |
No |
|
EmbeddedJava |
Application environment |
Yes (1.1) |
No |
Yes (Based upon JDK 1.1.6) |
No |
|
JavaCard |
Platform |
Yes (2.1) |
Yes |
Yes (early access) |
No |
|
K Virtual Machine |
Runtime environment |
No (expected by end of July 1999) |
No (does have datasheet and whitepaper) |
Yes (early preview to JavaOne attendees only) |
Yes (refer to KVM site for subscription info) |
|
Java 2 Platform, Micro Edition |
Java 2 Platform, for devices |
No |
No |
No (except for KVM preview at JavaOne) |
No (except for KVM mailing list) |
Note that the above refers to publicly available information from Sun and other
companies and does not include licensee-only releases or
nonreference implementations. Most of this information came from links available
from Sun's java.sun.com home page, from the home pages of other companies, or from
public announcements and demonstrations at the 1999 JavaOne Developer Conference.
Be sure to review the URLs provided in the Resources
at the end of this article for more information. The JavaOne Today
article on device developments, in particular, contains a lot of useful resources
and information.
Please also be sure to review the material on the J2ME Web site, as Sun's
repackaging of Java 2 technology into an Enterprise Edition (J2EE), Standard
Edition (J2SE), and Micro Edition (J2ME) will likely have many subtle but
important consequences in the coming months.
We will explore the details of these technologies in later articles. Taken as a
whole, they give developers a lot of options and opportunities for targeting
devices in the Java programming language.
Device programming roadmap
I had a fair amount of success with my Media Programming column
roadmap, so why not issue another? Over the course of this column, I will track
the various Java device programming technologies and give as many concrete
examples as possible so that you can learn about them and use them yourself. I
will always provide information on any emulators and related tools that will
let you get started programming devices as early as possible, sometimes even
before the actual device hardware is available. (This should also keep your
costs down as you follow the column and learn about programming devices.) I
strongly encourage you to get your hands dirty with the code as the columns roll
out.
Ideas for upcoming columns include:
-
Programming Palm devices in the Java programming language. This will include information
on how to program Java-based conduits as well as compiling
Java code to native instructions and interpreting Java
code on the Palm itself. It will also discuss Sun and Palm runtimes
and SDKs, as well as independent tools.
-
A tutorial on programming PersonalJava-compliant devices.
Learn how to target PersonalJava to ensure that your applets
run on set-tops and Web phones, as well as desktops and
workstations. We will use the PersonalJava emulator
so that you can start programming now, even
if you do not yet have any PersonalJava-compliant
devices.
-
The emergence of mobile phones capable of running the Java platform and
accessing Internet content. Learn about Wireless Access
Protocol (WAP), Wireless Markup Language (WML), and
how Java brings it all together. We will look at the
publicly available EPOC Java SDK from Symbian, and
at Nokia and Ericsson WAP development tools.
-
Open source and community source in the Java consumer-
and embedded-technology marketplace. What are your
alternatives?
-
Jini technology for consumer devices. What is available now and
what will be available in the near future, including
a discussion of some of the third-party development
projects underway in the Jini technology community. We will also
discuss the Jini technology's Java runtime requirements
and how J2ME will address them.
As always, please let me know about topics you want covered. I appreciate any
ideas or comments you care to share. I hope this column will provide you with
useful information and ideas that allow you to develop networked Java technology
applications for use throughout the ubiquitous computing infrastructure.
Conclusions
Thousands of JavaOne attendees have already started writing Java programming language code for their
Palm devices. In the next few months we will see the deployment of the Java platform on Palms,
mobile phones, and other devices increase rapidly. Millions of Palm handhelds
are in widespread use today, and Symbian's partners plan to deploy 40 to 60
million Javatechnology-enabled wireless phones within the next three years. The moral of
the story: Java device programming is real today, and will be extremely
widespread in very short order.
Next month, I will kick off a series on Java programming for Palm devices. The
time to start developing for these Java technology-enabled devices is now, so let's get busy!
RESOURCES:
-
Bill's Media Programming articles are archived in the
JavaWorld
Topical Index
- Ubiquitous computing
describes
the third era of computing. Learn why the father of ubiquitous computing,
Mark Weiser, calls ubiquitous computing the era of calm technology
- "Java
device developments at the 1999 JavaOne Developer Conference," Bill
Day (JavaOne Today, June 1999). More information on the device
development demos and announcements from JavaOne 1999. The article contains
specific information on the KVM and its demonstration on Palm handhelds,
Motorola two-way pagers, and NTT DoCoMo i-mode capable mobile phones, including
photos of the devices
- Ziff-Davis's
assessment
of J2ME, KVM, HP's Chai, and related JavaOne consumer and embedded
technology announcements
- The main Sun Java site
provides links to more information on PersonalJava, EmbeddedJava, JavaCard,
J2ME, and the KVM API's
- The
Spotless
System is a KVM predecessor, an experimental Java system for Palm Connected
Organizers developed by SunLabs. The Spotless site contains some interesting
technical reports and related links
- Symbian's EPOC
World developer site provides more information on EPOC Release 5's Java
implementation. It includes links to the EPOC Java SDK
- Sean
McDermid makes the Ghost VM freely available from his University of Utah
site. The Ghost Machine separates some processing functionality from the
Palm-hosted client VM into a desktop-hosted server VM, akin to the model
espoused as a part of the new J2ME
- Learn more about WabaVM,
Wabasoft's Palm and
WinCE VM environment. Site includes information on how to install and develop
for WabaVM
- Transvirtual
Technologies makes its PersonalJava-1.1.1 technology-compliant Kaffe JVM available on
a number of CPU and OS platforms. Open source implementation available for
desktop computers
- Read
Salon's
discussion of the consumer and embedded Java marketplace and Transvirtual's
place within it
- Cygnus
Solutions is developing a free software toolkit for compiling Java code
into native code linked against a
libgcj library. Part of the
toolkit is GCJ, a Java front-end compiler that works with various GNU back-end
compilers to enable Java-to-native compilation
- Hewlett-Packard's embedded
software site provides information on the Chai VM and its new ChaiFreezeDry
bytecode compression technology
- NewMonics was an
early entrant to the realtime Java technology arena. It is helping to lead the J
Consortium, a group working on realtime Java technology somewhat in opposition to the
Sun-supported realtime experts group (which is itself working within the Java
Community Process documented on Sun's Web site). Time will tell which realtime
Java standard will succeed
- Download the
complete
Device and Media Programming code archive from the Resources section of
Bill's Web site. Also contains links to previous columns and related materials
- Watch for the new
Device
Programming FAQ for answers to your nagging questions. Not in the FAQ?
E-mail Bill your questions
* As used on this web site, the terms "Java virtual machine" or "JVM" mean a virtual
machine for the Java platform.
About the Author
Bill Day is a
technology evangelist at Sun Microsystems and an Association for Computing
Machinery (ACM) distinguished lecturer. In addition to Java Device
Programming, Bill also writes a weekly Q&A column for
JavaWorld's career newsletter. Bill has contributed
SunWorld, Gamasutra, and JavaSoft feature articles
and speaks frequently on Java-based multimedia and consumer device programming.
Reader Feedback
Tell us what you think of this article.
[TOP]