[Back to GSN Home Page] [Back to Message Index]

Global SchoolNet - Automated Message Archive

LOGO-L> Single Key Logo




Michael Tempel (michaelt@media.mit.edu)
Mon, 8 Jan 96 16:14:44 -0500

Several recent postings have mentioned single key stroke
Logo programs. The idea is to be able to move the turtle
around by pressing single keys, like F and R rather than
typing the full commands such as

forward 10
right 15

Here's an example of such a program:

to instant
make "key readchar
if :key = "f [forward 10]
if :key = "b [back 10]
if :key = "r [right 15]
if :key = "l [left 15]
if :key = "s [stop]
instant
end


You could include additional lines like

if :key = "u [pu]
if :key = "d [pd]

to pick the turtles pen up and put it down.

To start the INSTANT program, just type INSTANT and press
the return key.


Another approach to creating a simplified introductory
turtle environment is found in the LogoWriter Primary
materials. Single letters are used as the names of
procedures:

To f
forward 10
end

to b
back 10
end

to r
right 15
end

to l
left 15
end

With these procedures you type one of the letters and then
press return.

I prefer the second approach because it's consistent with
the larger Logo interface. You press the return key as a
"do it", just like with any Logo instructions.

Also, you can mix full Logo instructions with the
abbreviations:

f
r
fd 5
r

Very often children will want a step size other than the one
provided by the single key procedure. That would be a time
to introduce a command such as fd 5.

--------------------------------------------------
Michael Tempel Tel: 212 765 4918
Logo Foundation FAX: 212 765 4789
250 West 57th Street
New York, NY 10107-2228
---------------------------------------------------------------
Please post messages to the Logo forum to logo-l@gsn.org. Mail
questions about the list administration to logofdn@gsn.org. To
unsubscribe send unsubscribe logo-l to majordomo@gsn.org.