uLisp now available for the ESP8266


#1

uLisp is now available for the popular ESP8266.

As well as supporting all the existing commands, uLisp for the ESP8266 includes wi-fi networking commands to allow you to take advantage of the ESP8266’s wi-fi capabilities with the convenience of uLisp’s compact syntax.

For more information, examples, and recommended boards, see Lisp for the ESP8266.


#2

Cool – thank you! Do you plan to include spiffs (instead of an sd-card)?

I found some strange behaviour:
(defun down (n) (< n 1) 1 (down (- n 1)))
(down 0) blocks for ever
(down 5) seems to do nothing
Same for:
(defun fac (n) (< n 2) 1 (* n (fac (- n 1))))
2527> (fac 5)

Panic /homes/common/arduino-1.8.5/portable/packages/esp8266/hardware/esp8266/2.4.0/cores/esp8266/core_esp8266_main.cpp:99 __yield

ctx: sys
sp: 3fff54c0 end: 3fffffb0 offset: 01b0

stack>>>
3fff5670: 00000000 3fff03a0 3fff03a0 40208c78
3fff5680: 3fff6690 00000000 3fff03a0 40209411


#3

Thanks! I’ll investigate the problems.

Yes, spiffs looks like a good solution to saving images - I need to do some more research.


#4

What you’ve written is valid Lisp, but I’m not sure it’s what you intended. Do you mean:

(defun down (n) (if (< n 1) 1 (down (- n 1))))

This gives:

> (down 0)
1

Also you probably meant:

> (defun fac (n) (if (< n 2) 1 (* n (fac (- n 1)))))
fac

> (fac 5)
120

Your version of fac keeps calling itself until it runs out of stack - hence the crash.


#5

Hi, you’re right in both cases. It was my poor lisp experience that lead to the examples. Thank you very much, Kaef