Running LISP On An ESP8266

LISP is a polarizing language. Either you love it or you hate it. But we’ll put aside our personal preferences to bring you a good hack. In this case a LISP environment running on an ESP8266. [Dmitry] is on the “love it” side of the fence — he’s been waiting for an excuse to code up a LISP interpreter for a while, and he found one in the ESP8266.

there-is-always-a-way-2Actually, [Dmitry] is running LISP inside JavaScript, which is itself presumably coded up in C, before it’s assembled to run on an ESP8266. (It’s turtles all the way down!) This means that he can piggy-back on JavaScript’s garbage collection and console handling and so on. After picking a suitably small LISP implementation (actually a Scheme dialect for those of you who know the difference), he went to work.

One weekend bled into the next, but he got the system running, connected to the network, and had LEDs blinking! In the end, he even managed to squeeze in some optimization for memory’s sake. Pretty cool, and because it takes advantage of an already complete system, it can even be made pretty useful. Not bad for a few weekends’ work!

And finally, if Lots of Irritating Silly Parentheses is your idea of a good time, but the wealth of computing resources available on an ESP8266 seem overkill, have a look at Microlisp, running on an AVR. Or go to the opposite extreme, and run a LISP OS on a Raspberry Pi. Whatever you do, don’t forget to close your parentheses! (We’re told that’s a traditional LISPer farewell.)