|Surveyor Robotics Journal|
Wed, 02 Apr 2008
Just added a small Lisp interpreter to SRV-1 Blackfin firmware
I have been exploring some alternatives to the C interpreter currently built into the SRV-1 Blackfin firmware as our onboard behavior scripting engine, and came across a very compact LISP interpreter called Lithp, written by Scott Anderson. Tucked into the SRV-1 firmware, the code takes just a bit more the 6 kbytes of program space, and while it hosts only a fairly limited subset of Common Lisp, the code is very clean and easy to extend, and it already has a lot of capability.
The code is described here -
and full documentation is found here -
The interpreter runs a program that has been transferred to the onboard flash buffer either from flash memory, via XMODEM transfer, or directly entered through the onboard line editor. The 'P' command launches code execution. The SRV-1 firmware has now been split in to separate versions to support either the C interpreter or Lisp interpreter, but not both in the same image. The download link for the test version of firmware is found in this forum thread -
To get this to run, some new memory management functions were added and the processor stack was moved. We are just at the beginning of the testing cycle, so some revisions should be expected. Also, none of the core motor, sensor or vision functions have been linked to Lisp calls, though that should follow shortly. One of the goals is to link Lisp functions to the neural net library now built into the firmware - some interesting possibilities for SRV-1 behavior development should emerge once we figure out how to tie those pieces together.