Practical
Embedded Java

Java Tools List
updated 2009 Jan 31


A practical engineering approach to using embedded Java in real-world applications.


...



 

Java Tools List

Here is a list of the main tools we like, use at Systronix, and recommend. As with many things, there is no one-size-fits-all solution, so feel free to use what works for you, and let us know if you come across anything really wonderful.

Once you've obtained all these files, then follow the installation instructions before you install the programs. In particular, if you have a choice, don't install in the Windows defaults of paths which contain whitespace such as "C:\Program Files\...". Here's why.


Java Tool list -- download links and description
Tool
Applies to
Download URL & Link
Description

Eclipse

All embedded Java systems as well as the PC. (Also has support for C/C++). Best for creating and managing Java projects.

you can also use the Java IDE of your choice, such as JBuilder, JEdit, etc.

http://www.eclipse.org/downloads/index.php

Download the JDT Eclipse installer. Source code, etc is optional.

Eclipse is a multi-platform, open source, Java-aware Integrated Development Environment. It has many terrific features which will save you time when writing and debugging code. It is open source and supports multiple platforms. Eclipse is not "Java-centric", and there are active projects which use Eclipse to develop C/C++ code.

We recommend the most recent release from the "current stable builds" list. Eclipse templates change between major versions such as 2.1 and 3.0, so be aware that once you upgrade you can't easily downgrade again. Eclipse is evolving rapidly. We will not attempt to update this area of the website for every minor Eclipse release. Please get the most recent stable build and assume that its operation will be very similar to what is shown here. At a minimum you will need the Eclipse Platform and Java Development Tools - you can get all this in one whack by downloading the Eclipse SDK, but it's a 100 MByte whack and includes source code and other items which you may never use. You can download just the "Platform Runtime Binary" and the "JDT Runtime Binary" which together are about half the size of the complete JDK.

Subclipse Adds Subversion support to Eclipse http://subclipse.tigris.org/ Java.net and many other repositories use Subversion so you will need Subclipse or other Subversion support.
CVS "Concurrent Version Systems" http://www.nongnu.org/cvs/ for documentation or other information. You don't need to download it. It comes with the core Eclipse installs. Many respositories, especially legacy ones, use CVS. It's already built into Eclipse.
NetBeans All Java users. This is an alternative to Eclipse. Get 6.5 or later. http://www.netbeans.org/ Includes an excellent GUI builer: "Matisse" which is inspiring me to take another look at NetBeans.
SunSPOT SDK SunSPOT developers, even if you don't already have SPOTs.

http://www.sunspotworld.com/SPOTManager/

If you want the beta releases, go to the Preferences tab and select that...

Also see this informative blog by a member of the SPOT team.

You can now get access to the latest SPOT SDKs including pre-releases (use at your own risk!). You don't have to already have SPOT hardware. You also must have Ant and a JDK to use the SPOT SDK.

SPOT's JVM, Squawk, is now in the final stages of being open-sourced, and it is free for non-profit use. If you want to use it commercially you must purchase a license. How much does that cost? It varies (contact Sun) but you can expect to pay in the neighborhood of $100K.

BlueJ Educators or beginning Java programmers. http://bluej.org/ BlueJ is a simplified IDE, excellent for entry level Java programmers. It's built on NetBeans. Be sure to get the excellent book which is an 'objects first' approach to teaching Java.
Greenfoot Educators, robotics enthusiasts, multi-agent researchers...

Greenfoot: http://greenfoot.org/
TrackBot scenario: https://trackbot-greenfoot.dev.java.net/

Greenfoot is a 2-D multi-agent and world simulator useful in quickly programming games, multi-agent simulations, and robotics. Coming soon: SunSPOT support. Aimed at entry level CS students or, with assistance, even grade school students.
RealTerm Use of a serial port in Windows with a lot more utility than awful HyperTerminal. Fantastic terminal program, IMHO. Get it here: http://realterm.sourceforge.net/ where you can also get the Delphi (it's almost Java!) source code. Windows only. This is what Windows users should use with TrackBot and a PC serial adapter, or a USB radio such as BlueTooth. You can easily make a text file which acts like an action script to control or test TrackBot or other serial devices from a PC, either cabled or wireless.
JEdit & plugins

All embedded Java systems as well as the PC. Much smaller and leaner than Eclipse, so loads much faster. Excellent and preferred for quick editing of code files, code snippets, etc where you don't want to hassle with an Eclipse project.

http://www.jedit.org

JEdit is almost unbelieveably slick and elegant. It's a very responsive Java application itself. The whole JEdit runtime download is under 1.5 MBytes, and full source code is available. The plugin manager is a thing of beauty, but recently Eclipse and other IDEs now also handle plugs very well.

JEdit is suitable for all your Java development, but doesn't handle large projects as nicely as Eclipse.

JEdit is lean and simple and relies on plugins for many of the features you will consider essential, such as class browsing.

HTML Editor Amulet LCD screens, HTTP Server pages, servlet pages, advanced javadocs

http://www.macromedia.com/software/dreamweaver/
(free trial, or you can purchase the product for about $400)

... or use your favorite free HTML editor (it doesn't need to be fancy)

I use and recommend Macromedia Studio MX, which is about $900. Dreamweaver MX ($400) is the HTML development portion of Studio MX. Much lower cost educational versions are available. We also use Dreamweaver to maintain all our websites (including this one). But any HTML editor you like will do, and there are plenty of free or low-cost HTML environments available.
HTML Browser You need a browser to view javadocs, which are simply hyperlinked HTML pages You probably already have Microsoft IE (you can't install XP without it) but I still prefer Opera: http://www.opera.com I like to use the Opera browser (it's much more nimble than IE or NS). I set up a bookmark folder called "Java Docs" and keep links there to all the API docs I use frequently. Opera is also much better for searching on the 'net and grabbing files. I use an IE "skin" which makes it very easy to switch back and forth between Opera and IE.

Java SE SDK

more details

all embedded Java systems as well as the PC

Java SE SDK:
http://java.sun.com/javase/downloads/index.jsp

This is the Java Standard Edition. You want the J2SE SDK 1.4.1 or later. You may also want examples. Do not use the older JDK1.4 which has known problems when cross-compiling. While you are there you may want to download relevant white papers. With Java 1.5 the numbering system has changed - it's became "Java SE 5.0".

If you're new to embedded Java, and to cross-compiling (i.e. running a program on hardware different from that used to compile it) it may seem odd that the version of this JDK has almost nothing to do with the version of Java you will be running on your embedded system. Don't worry about this for now, it will be explained in the tools installation details.

all embedded Java systems as well as the PC

http://java.sun.com/products/javacomm/

download javacomm20-win32.zip (300 KBytes), or whatever is the latest version for your platform. Or, if you have the option, use rxtx instead.

In order to use serial communications on your PC, and use the standard Java communication API on embedded systems, you need the Sun COMMAPI. Javaxcomm is the standard Java serial and parallel I/O support package. All true Java systems support javaxcomm serial I/O. Embedded systems don't support the parallel port since it's PC-specific.

Sun has not maintained the windows version of javaxcomm very well,, and has not released the code so that others can maintain it. However there suddenly appear to be new releases especially for Solaris and Linux. But you don't get the source code, so... you may be happier with RXTX.

RXTX all popular operating systems We use RXTX for the PC and javaxcomm (vendor implementation) on embedded systems. Get rxtx at http://www.rxtx.org/ RXTX works very well but documentation is lacking: it mostly refers you to the Sun COMMAPI documentation which is not exactly a model of completeness itself. Earlier versions of Windows javaxcomm contains numerous bugs (google "javaxcomm bugs" if you are interested), so several other versions of serial communications have been developed to address these shortcomings.
J2ME/CLDC 1.0
API Javadocs

JStamp, JStik, SaJe, other aJile systems using aJIle runtime 3.16.09, as well as SNAP

http://wwws.sun.com/software/communitysource/j2me/cldc/download.html JStamp, SaJe, JStik, SNAP, and other systems use this. Although they may include the runtime support in their own development kits, you will probably find that you need the Sun files in order to get all the Javadocs for all the J2ME/CLDC base classes. You need to register (it's free) at before you can download the file. The current version is 1.0.4 and includes source code which you may find instructive. These Java systems now (2007) support CLDC 1.1.
J2ME/CLDC 1.1
API Javadocs
JStamp, JStik, SaJe, other aJile systems using aJile 4.X (starting 2007) http://www.sun.com/software/communitysource/j2me/cldc/download.xml CLDC 1.1 upgrade for aJile-based systems.
Java 2 JDK 1.1.8 API Javadocs
TINI390 and TINI400 only
http://java.sun.com/apis.html This is the edition of Java upon which TINI is based. However, TINI has had numerous other packages added to it, so JDK1.1.8 javadocs just give you the base class documentation. Note that you only need the Javadocs, not the whole JDK. The Dallas TINI development tools include all the runtime support for TINI, and platform-specific documentation. But documentation for the JDK 1.1.8 base classes is not included in the TINI development kits.
J2ME/CDC javadocs possible JStik future use http://java.sun.com/products/cdc/ SaJe and JStik will eventually use the Connected Device Configuration, and other embedded Java devices use it now.
Apache Ant
all Java projects. Can also be used with other languages.
http://ant.apache.org/

Apache Ant is a Java-based build tool. In theory, it is kind of like Make, but without Make's wrinkles.

Why another build tool when there is already make, gnumake, nmake, jam, and others? Because all those tools have limitations that Ant's original author couldn't live with when developing software across multiple platforms. Make-like tools are inherently shell-based -- they evaluate a set of dependencies, then execute commands not unlike what you would issue in a shell. This means that you can easily extend these tools by using or writing any program for the OS that you are working on. However, this also means that you limit yourself to the OS, or at least the OS type such as Unix, that you are working on.

Makefiles are inherently evil as well. Anybody who has worked on them for any time has run into the dreaded tab problem. "Is my command not executing because I have a space in front of my tab!!!" said the original author of Ant way too many times. Tools like Jam took care of this to a great degree, but still have yet another format to use and remember.

Ant is different. Instead of a model where it is extended with shell-based commands, Ant is extended using Java classes. Instead of writing shell commands, the configuration files are XML-based, calling out a target tree where various tasks get executed. Each task is run by an object that implements a particular Task interface.

Tini Ant
optional Ant task for TINI only
http://tiniant.sourceforge.net/ Much easier than writing command line scripts or entering huge command lines to invoke BuildDependency manually. It's an Ant plug-in.
Netcomponents
now
Jakarta Commons Net
optional FTP Ant task for all systems
http://www.savarese.org/oro/downloads/index.html#NetComponents
this has now been replaced by
Jakarta Commons Net at http://jakarta.apache.org/site/downloads/downloads_commons-net.cgi
You send new applications to TINI and SNAP using FTP. This Ant plug-in helps automate that process, so that it can occur automatically as part of a build. Plus lots of other useful utilities.
aJile tools 4.X JStamp, JStik, SaJe http://www.practicalembeddedjava.com/tutorials/aJile4XUpgrade.html
You get free upgrades for a time after purchase of a development kit. Both free (using a coupon code) and purchased upgrades are in the online store in the software updates area.
New in 2007, CLDC 1.1 upgrade for all Systronix hardware using aJile controllers. Don't use the generic aJile tools - you need the Systronix configurations for Systronix products SaJe, JStik, and JStamp.
aJile Development Tools 3.16.09
aJile based systems such as JStamp, JStik and SaJe
http://jstampu.systronix.com/ajile_docs.htm If you have not purchased a development kit from aJile, Systronix, or other aJile vendor, you do not have a development tools license and cannot legally use these files. These tools include the JemBuilder linker and configuration tool, and the Charade program downloading and deugging tool.
aJile configurations for 3.16.09 Systronix systems (not other, non-Systronix aJile systems) such as JStamp, JStik and SaJe http://jstampu.systronix.com/ajile_docs.htm You must have the JemBuilder configuration files for your specific hardware. These configurations include such information as the hardware memory map, interrupt assignments, and other hardware-specific parameters. Using other configurations will not work. For example, you need the JStik configuration files to build JStik programs. You cannot use the aJ100-EVB configurations, or any others. Only the JStik configurations have the correct memory map, interrupt assignments, and other parameters.
TINI Development Tools
TINI systems including TStik from Systronix as well as modules from Dallas
http://www.maxim-ic.com/products/tini/software/downloads.cfm Get the latest version, currently 1.17. Don't use 1.16 - it has some serial server issues. 1.15 is also stable.
Dallas 1-Wire API for J2ME Use with JStamp, JStik, SaJe, SNAP, and other J2ME systems. ftp://ftp.dalsemi.com/pub/auto_id/public/owapi_1_00B_J2ME.tgz Supports iButtons and 1-Wire devices on J2ME/CLDC platforms. Check for a newer version, although there is no expectation for frequent updates. SNAP includes its own implementation of 1-Wire classes.
Optional components or tools which are not part of the Java tool chain
TweakAll utilities

Windows NT/2000/XP systems only

optional but very handy

http://www.codeforge.co.uk/mainframes.htm Adds "Command Prompt Here" and improved "Send To" to your right-click menu when browsing files and folders using Windows Explorer. This lets you instantly get to a command prompt in any folder on any Windows PC. Saves a lot of annoying typing. The link takes you to http://www.codeforge.co.uk/mainframes.htm where you can download the TweakAll package.
Bug Tracking System
(not discussed here)
any project (hardware, software, whatever) Java.net and other public repositories have bug tracking and issue resolution built in, using mail lists and browser-based interfaces, and you don't need anything special to use them. Bug tracking systems help you log alleged problems and track how they are resolved. Some enable customers to enter a problem themselves. Essential if more than one person will respond to the bugs. Can also handle requested features and other non-bug issues (updating documentation for example). We use Bugzilla. It's pretty easy to set up.
Two physical hard drives For best performance and easier file management.  

Windows XP and some applications (Adobe Photoshop is one) want to have a swap file located on a different physical drive from the one containing the application. Having a swap file on a different physical disk apparently offers better performance, since each drive will have its own RAM buffers. Ideally each drive would also use a different IDE controller.

I like to keep my system files and non-development apps on drive C and all my developer files on drive D. That way I can mess with drive D all I want and run no risk of scrambling the operating system.


How can I create Java code for, say, J2ME/CLDC, with a J2SE JDK?

The base Java class files are identical regardless of the platform on which they will be executed. This is the "write once, run anywhere" feature of Java (some would say that "write once, debug anywhere is more accurate"). Java platform-specifc support is contained in optional packages which you reference in your program and at compile time. You will be using a PC-based Java compiler in "cross compiling" mode.

"Cross-compiling" means that you will use a compiler executing on a given hardware platform (A Windows PC for example) to create code which will be executed on a different platform (JStamp for example). Most embedded systems require cross-compilers, so this is a concept familiar to anyone who has done embedded system development. You cross compile by using the javac "bootclasspath" and "classpath" options, but more on that later.

When cross compiling be sure you:
  1. Do not build with default J2SE runtime libraries, use only the appropriate embedded runtime libraries. Including J2SE libraries will lead to puzzling errors in JemBuilder or runtime exceptions.
  2. Use the javac "target 1.1" option
  3. Use the javac "source 1.3" option if you are using J2SE 5.0 or later
  4. Use Ant build files, or some other way to "clean" your output folders (delete .class and other compiler output) at the start of each build. This saves you from ever getting a build which is a mix of old and new class files.

Which JDK version do I need?
You can use any JDK you wish, except JDK1.4 which has known problems when cross-compiling. You might be able to use an older JDK 1.2 but why? Use the most up to date version which is available for your hardware.

What's up with the miter saw?
The image is a Ryobi 12-inch laser miter saw. It's a very impressive tool for $200 (Home Depot). Add a $60 100-tooth blade (Costco) and you're really ready to rock. The laser guide is actually part of the blade clamp and contains its own battery and a centrifugal switch which turns on above 500 rpm.

 
Systronix® 939 Edison St, Salt Lake City, Utah, USA 84111
Tel +1-801-534-1017, Fax +1-801-534-1019
contact us     Time Zone: MDT (UTC-6)
 

Java and all Java-based marks are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. and other countries.
Systronix is independent of Sun Microsystems, Inc.
TStik, JStik, JCX, JStamp, JSimm, JDroid, and JRealTime are trademarks of Systronix, Inc.
1-Wire, iButton and TINI are trademarks of Dallas Semiconductor
Simmstick is a trademark of Dontronics
LEGO® is a trademark of Lego A/S, Denmark