• If you are citizen of an European Union member nation, you may not use this service unless you are at least 16 years old.

  • You already know Dokkio is an AI-powered assistant to organize & manage your digital files & messages. Very soon, Dokkio will support Outlook as well as One Drive. Check it out today!



Page history last edited by Josh Burker 4 years, 8 months ago


LightLogo is a microworld created by Brian Silverman in an attempt to "get back to text programming." You can make beautiful patterns of light emerge in fewer than ten lines of code.


Installing the Software


If you have never used an Arduino on your computer before, please start by installing the FTDI driver for your operating system.


Next, download and install LightLogo-V02e. The Arduino that we will use already have the virtual machine loaded on them, but if you are curious about the process please read the Installation instructions included in the archive.


Getting Started


Plug the USB cable into the Arduino. Plug the other end of the cable into your computer.



Open the LightLogo application. The test procedure will probably start running on the Arduino and neopixel ring. You can click the stop button to stop the program.


Type the following commands. Press return on the keyboard at the end of each line.

setc red

fd 8

setc green

fd 8

setc blue

fd 8



To clear the neopixel ring, type reset.


Planning Your Procedure


You can use this "graphic organizer" to plan how you are going to move the turtle (and lights) around the ring.



Use crayons to plan your procedure on the neopixel ring.


Writing Your Procedure


You can interact directly with the neopixel ring and program it through the console, like above. However, once you start programming more complex procedures, or procedures you want to revisit, you should write them in a text editor like TextEdit or Notepad. You need to make sure TextEdit is configured to save .txt files, not .rtfd files



LightLogo only knows how to run a procedure called startup. Here is how I format the procedure we started with.


Startup can also call other procedures, like shown below.


Uploaded Your Procedure


Save the procedure or procedures you wrote in the text editor. You can upload your procedure(s) from the LightLogo console. Open LightLogo.


Click the ... button to select your file:


Navigate to the Downloads folder and select the file you downloaded. Once selected, click the download button:


The lights on the Arduino will flash and your procedure will be downloaded. To run the procedure you can type startup in the console and press the Return key on the keyboard. Alternately, press the physical RESET button on the Arduino to run the procedure.



Using the Reference


LightLogo has a small vocabulary of commands that you can use to program designs in light.


reset -- Same as 'clean' and also shows the turtle and resets the brightness to the default value.

clean -- Turns off all the lights, sets the position to 0, sets the heading to 1 (clockwise), sets the color to 0 and puts the pen down.

fd, bk -- Forward, back. Moves the turtle a number of steps (lights).

setc -- Sets the pen color. The colors are numbered between 0 and 100.

stamp -- Sets the color of the light under the turtle to the current pen color.

all -- Turns all the lights to the color specified by "all"s input.

pu, pd -- Pen up, pen down.

pe -- Pen erase. The turtle turns lights off as it moves.

ht, st -- Hides, shows the turtle.

setpos -- Sets the turtle's position. 0 is the top.

pos -- Outputs the current turtle's position.

seth -- Sets the turtle's direction clockwise (1) or counterclockwise (-1).

flip -- Flips the turtle's direction from clockwise to counterclockwise and vice-versa.

setbrightness -- Sets the brightness of the current pen color. The default is 20. 99 is the maximum.

wait -- Waits for a specified amount of time. 1 is 1/1000th of a second.

+ - * / % -- Performs and operation on two numbers. % is modulo.

random -- Outputs a random number between a minimum and a maximum value inclusive.

repeat -- Repeats a command a number of times.

loop -- Repeats a command indefinitely.

if, ifelse -- Conditionally runs commands based on a condition.

> < = != -- Compares two numbers. != is not equals.

and, or, not -- Combines conditions.

resett, timer -- Resets, outputs the milliseconds timer.

resets, seconds -- Resets, outputs the seconds timer.

resetm, minutes -- Resets, outputs the minutes timer.

print -- Prints a number in the command center on the host computer.

stop -- Stops the current procedure.

output -- Outputs a value from the current procedure.

make -- Changes the value of a local variable.

let -- Creates a local variable and gives it a value.


More Information


A downloadable version of the LightLogo Language Reference with examples is available here.

A printable planner to help you design your LightLogo procedures is available here.

Here are different projects that I have worked on in LightLogo.

You can see some excellent student examples of programming narrative in LightLogo here.

Erik Nauman programmed a story that includes a sheet of paper that diffuses the light and includes illustrations.

Comments (0)

You don't have permission to comment on this page.