View Full Version : Will the BS2 Work with LISP?
09-18-2006, 11:13 AM
·I am working on a project robot that I wanted to run using a BS2, however the program has quickly taken a life of its own and is being created in LISP. Is there a way to get the BS2 and LISP to work with each other?
09-18-2006, 11:23 AM
·· If your LISP program can communicate serially, it would be possible to exchange some information back and forth that way.
Parallax Tech Support
09-18-2006, 11:33 AM
That depends on what you want to do. Keep in mind that the BS2 is somewhat limited in program size and very limited in the data that can be kept (other than in EEPROM which is limited in how often it can change). Lisp, on the other hand, is particularly powerful in that it can store lots of data in very complex structures and the data itself can sometimes be executed. The construction of programs and program fragments is an important part of the use of Lisp.
1) You can use Lisp for the development of the "higher level" functions and either
a) Run those functions on a processor that supports Lisp and have that and the BS2 communicate.
Consider something like a GumStix or similar embedded processor that can run Linux. Scheme is a
dialect of Lisp that is available on a variety of platforms (Windows, Mac, Linux) and is particularly well
suited for running in a relatively limited environment. It has been ported to the Palm OS for example.
b) See if you can translate the finished Lisp functions into some kind of simple interpretive code or tables
that can be "executed" on the BS2. Truthfully, a BS2 is probably too small for this. You'd need something
like a BS2p or BS2px to get a little more speed and a lot more memory (as EEPROM).