XS: Lisp on Lego MindStorms
by Taiichi Yuasa
XS is a Lisp system which is designed to control RCX blocks of
the Lego MindStorms Robotics Invention System (RIS).
XS Lisp provides one of the most complete and powerful systems currently
available for Lego MindStorms programming.
Autonomous XS evaluator runs on the RCX and includes its own runtime
stacks and garbage-collected heap.
Communication with the front-end PC subsystem provides
an interactive programming environment that includes features
such as backtrace, function trace, and terminal interrupt.
Lisp/Scheme-based language extends functionality for interfacing with
motors, sensors and other RIS devices.
The language of XS supports mechanisms such as event waiting and asynchronous event handlers
for all RIS controlled robots.
The first version of the system has been released as an open source
software, distributed under the Mozilla Public License (MPL).
The system is currently running on the following platforms.
Windows XP for RCX 1.0, 1.5, and 2.0.
Linux (RedHat, Debian, Fedora Core) for RCX 1.0, 1.5, and 2.0.
The following materials are available:
In case you have trouble with using XS, here is
Lisp for Lego MindStorms NXT available
Developed by Tasuku Hiraishi, this system allows you to control NXT
through Allegro Common Lisp.
(in Japanese only, sorry) for details.
The front-end of XS now can fork subprocesses so that XS programs can
communicate with Linux applications.
The new top-level form "fork" creates a subprocess and
executes a specified Linux program.
The I/O functions of XS, such as "read" and "write", can now accept
port numbers to communicate with subprocesses.
See the revised reference manual for details.
Bug fix for tail-recursion optimization
The evaluator in the RCX sometimes failed to correctly
optimize tail-recursive calls of functions within let, let*, and letrec
Japanese version of the Reference Manual became available
See the Japanese page.
Support for USB tower on Linux PC (2005/03/18):
See the updated Installation Guides.
Copyright 2003, Taiichi Yuasa
The project of XS was sponsored by the Information-technology Promotion Agency (IPA) of Japan as an Exploratory Software Project.