NOTE: The TinyVM project is no longer active. Jose Solorzano forked it into the successful leJOS project in 2000. The idea was that TinyVM would remain as a low-footprint alternative to leJOS, but users preferred features over footprint. These pages remain here as historical reference only.

RCX Java Runtime


API Reference (0.2.0+)
User's Guide
Technical Notes


Windows Ports
Languages other than Java
Thanks

Java (Sun Microsystems)
Java Tutorial
Java Developer Connection

Lego Mindstorms Internals
RCX Internals

RCX Java Forum (Lugnet)
RCXPort (Scott Lewis)
RCXLoader (Dario Laverde)

The Rossum Project


TinyVM at SourceForge
Download Area
Release Notifications
News
Mailing Lists
Bug Reports
CVS Repository

Latest Release

The latest version of TinyVM is available here: tinyvm_0_2_6.tar.gz .

For previous releases and notes, check the File Releases section in TinyVM's SourceForge Page. Windows users should check the Windows notes first.

What is TinyVM?

TinyVM is an open source JavaTM based replacement firmware for the Lego MindstormsTM RCX microcontroller. The RCX is a programmable brick that comes with Lego's Robotics Invention SystemTM.

TinyVM's footprint is about 10 Kb in the RCX. Additionally, program class files are compacted considerably (i.e. resolved) before they are downloaded to the RCX. A small program can access around 16 Kb of RAM. The overhead for each object is 4 bytes, and there is no alignment of fields (e.g. a byte field always requires one byte).

Features of TinyVM that aren't always found in other RCX programming systems are listed below.

  • Great object oriented language (Java)
  • Preemptive threads
  • Exceptions
  • Synchronization
  • Arrays, including multidimensional ones
  • Recursion
  • Access to RCX buttons
  • No need to install a cross-compiler
  • Fairly easy to install, even under CygWin
  • TinyVM's firmware allows itself to be replaced
  • Comes with an emulation tool
  • Nicely documented APIs
Since 0.2.0:
  • You can rerun a program.
  • Full object persistence across runs.
  • tinyvm.rcx.Time with sleep() and currentTimeMillis().
  • Timers (tinyvm.rcx.Timer).
  • Random numbers (java.util.Random).
  • LCD characters (tinyvm.rcx.TextLCD).
Since 0.2.2:
  • Auto power off

Limitations

Evidently, it isn't feasible to put a complete Java runtime in 32 Kb, let alone 10 Kb. The most important limitations and missing features of TinyVM are:
  • No garbage collection
  • No floating point support
  • No switch statements
  • String constants are ignored
Floating point arithmetic and string constants have already been implemented in leJOS, and it's likely that the other limitations will also be addressed there. There are a lot of interesting features that could be added to TinyVM and/or leJOS, and contributions are always welcome.

How to install it and use it?

Please read the User's Guide.

Questions? Comments?

Project founder: Jose H. Solorzano

Disclaimer

Neither Lego nor Sun Microsystems, Inc. have endorsed this page or authorized the development of the TinyVM project. In fact, this project is the result of a hobby and it has not been endorsed or authorized by any commercial entity.

Other Projects