Sets up a timer identified by
id (a number from 1-31) to call the instructions in
delay milliseconds of time.
It continues to "fire" every
delay milliseconds until you invoke CLEARTIMER with the same
You can clear the timer at any time with CLEARTIMER.
In particular, you can clear the timer in the
callback instructions to create a one-shot timer event.
You can also create a timer at any time, including in the
Halting clears all timers.
id values from 1-16 run their callbacks in NOYIELD mode, which means they are not interrupted by user interaction and the screen isn't repainted if it becomes occulded when the
callback is running.
id values from 17-31 run their callbacks in the normal, interruptable mode.
id can have different values for
SETTIMER 17 200 [SETPENCOLOR (LIST RANDOM 256 RANDOM 256 RANDOM 256)]
FMSLogo is ready to run more instructions and the timer changes the pen color randomly every 200 milliseconds.
REPEAT 72 [REPEAT 4 [FORWARD 100 RIGHT 90] RIGHT 5] CLEARTIMER 17