The Background

For this Lego Robotics Project, we used the LejOS software that installs a firmware in the Lego Brick NCX 1.0 and lets us create applications that the robot understands with a simple-to-use API. LejOS uses the Java SDK 1.3 and compiles source files into bytecode for a minimal virtual machine inside of the block's memory.

There have been 3 AI classes that have worked on this project: Fall 2000, Fall 2002, and Fall 2004 (with three groups). The idea of the project is to build upon the previous generation and improve some of the things groups in the past couldn't or didn't implement. The source for those assignments is shown below along with other useful links.

The most remarkable modifications to the code are the integration in the line follower code of the following elements: (1) battery voltage independent actions that replace previous attempts to use sleep threads to turn on intersections/corners and letting while loops control the execution of the actions to get to a better state. (2) Improvement over challenge 2 & 3, where the robot interacts with intersections and acute angles very robustly. (3) The robot has the capacity of orienting itself when it finds the end of the line, turning around and going back to where it came from.

Useful links

Provided by Professor Todd Neller

Source Files

You can download the source files for our project by clicking here. The source code package contains both the source files and the documentation. Also we can take you directly to the documentation we produced for our code.