Merged most of Etienne's improvements from last year, including
[picobit/chj.git] / red-green.scm
blobe615e576da449636439cda098034d18a546d7dd6
1 ; File: "red-green.scm"
3 (define loop
4   (lambda ()
6     (led 'green)  ; set LED to green
7     (putchar #\G) ; send a "G" to the console
8     (led 'off)    ; turn off LED
9     (sleep 100)   ; wait 1 second
11     (led 'red)    ; set LED to red
12     (putchar #\R) ; send an "R" to the console
13     (led 'off)    ; turn off LED
14     (sleep 100)   ; wait 1 second
16     (loop)))      ; repeat
18 (loop)