FRIENDS OF THE TURTLE
David D. Thornburg, Associate Editor
Turtle Graphics For The VIC
Judging from the amount of mail I have received on this topic, there are thousands of VIC owners who are waiting for the chance to see turtle graphics on their computer. It was thus with excitement that I viewed the chance to try the Turtle Graphics program cartridge from HES.
This cartridge comes nicely packaged with a thorough manual that contains both a tutorial and a reference section. The cartridge contains an 8K byte program that loaded immediately when the VIC was turned on. Since the program worked on my vintage VIC from Japan, I'm sure it works on every VIC ever made.
I have used this program for a month and am quite ambivalent about it. As someone who uses turtle graphics packages of all sizes and vintages for a host of computers, I confess to having a pre-defined set of expectations. In order to help you assess my review, it is only fair that I list what I feel are the important aspects of WSFN, Atari PILOT, Apple SuperPILOT, Logo, and the Big Track toy with a felt-tip pen attached to the back:
- Turtle graphics is just that – a graphics environment. It is capable of drawing continuous lines on a screen (or a sheet of paper).
- Turtle graphics is richly endowed with commands that allow the incremental movement along a heading and the incremental rotation of the heading by amounts whose values can be stored in variables.
- The highly interactive and experimental nature of those who use turtle graphics most effectively requires that graphics commands and user-defined procedures be capable of execution directly from the keyboard. A true immediate mode is present in all my favorite turtle systems – including the $40 Big Trak.
Unfortunately, the Turtle Graphics package from HES fails all these tests – and I could have made the list longer with the same result. My biggest complaint is that this program does not use the VIC graphics mode at all, but builds pictures by printing trails of characters on the 22 column by 23 row display screen. This restricts one to very primitive pictures.
This does not mean that the program isn't useful. I feel that, under a new name, this program can find tremendous application in another field, but more on that later.
Structurally, the program is quite nice. It contains its own line editor that performs some error checking before accepting each line. The language itself uses English language commands that, in most cases, are instantly understood by the user. For example, TURTLE COLOR RED changes the turtle's color to red.
When the system is turned on, the user is presented with a menu that allows the addition, insertion, deletion and replacement of program lines, the listing and printing of programs, and the execution and tracing of programs. All aspects of this menu driven system work well.
To get a feel for the language's syntax, let's examine a simple program from the manual:
SCREEN COLOR YELLOW BORDER COLOR PURPLE TURTLE COLOR BLUE PEN DOWN TEXT HI THERE PEN UP CHARACTER TO + TURTLE COLOR GREEN MOVE TO 6-3 PEN DOWN RIGHT 5 DOWN 5 LEFT 5 UP 5 STOP
The first three commands set colors. Any of the standard VIC colors can be used. The turtle starts with the pen up (unlike all the other turtle systems with which I am familiar), so if you want to see something, you must remember to put the pen down first. The TEXT command functions somewhat like the PILOT T: command in that it prints whatever follows the command. It does not, however, allow you to print out the contents of variables, so it can't be used to print out the results of calculations. Also, unfortunately, there is no INPUT command to allow data to be entered interactively during the execution of a program.
The command CHARACTER TO + tells the turtle to leave a trail of + marks as it moves. It is better to think of the turtle as carrying a rubber stamp rather than a pen. As it moves, it stamps images of characters on the screen. The command MOVE TO 6-3 moves the turtle to the sixth column and third row of the screen. The commands RIGHT, DOWN, LEFT, UP move the turtle the indicated number of spaces in the indicated direction. Note that RIGHT and LEFT are not turn commands. They shift the turtle to the right or left. Movement is allowed to take place only along columns or rows, and there is no command that lets the turtle move incrementally along a diagonal.
The user can create labeled procedures with this system and can then invoke the procedures with the USE command. Among other valuable features, the user can have the program check to see if a particular symbol is underneath the turtle. This allows the creation of simple maze-following programs, and is quite valuable.
The conditional branching command, IF, is quite non-standard in its use. Consider this example from the manual:
IF(X>2) SCREEN COLOR BLUE JUMP DONE LABEL FALSE SCREEN COLOR RED LABEL DONE
If the value of X is greater than 2, then the commands immediately following the IF command will be executed. If it is false, execution branches to the next label. I would guess that the reason this was done was to make sure that each program line did only one thing. The IF command then starts to look like the Logo TEST command. I would have been happier if HES had used TEST, IFT and IFF, as does TI Logo. The present construction is quite convoluted and cumbersome, in my opinion.
While no fault of HES, the aspect ratio of the display screen makes any accurate correspondence between a procedure and a drawn figure hard to detect. Suppose, for example, that a child draws a square on a sheet of paper and then translates this square to the procedure:
LABEL SQUARE RIGHT 10 DOWN 10 LEFT 10 UP 10 ROUTINE END
When this procedure is executed, a wide rectangle will be drawn on the screen. The procedure should give a square, but the aspect ratio of the VIC's character screen will never let you plot a square with this procedure. Does this adversely affect the child's understanding of programming? I think so. This hunch has been reinforced by my limited testing of this package with an eight-year-old boy who certainly knew what a square looked like. This might seem like a minor point to some, unless they are expecting to use this program in an educational environment.
On the positive side, I think that Turtle Graphics is an excellent program for the creation of animated titles and text displays. The user can create musical sounds and can adjust the rate at which characters are placed on the screen. Any VIC owner who makes home video tapes or who needs an inexpensive, eye-catching attraction for a retail display can benefit from this package. In fact, the cost of the VIC plus the $39.95 Turtle Graphics program is far less expensive than the titling systems presently being sold to VCR owners. The VIC's video output connects easily to all VCR's, making this a natural application for the system.
My recommendation is for HES to market this program to the massive number of home video users who can use it to title their recordings. HES should use the proceeds from these sales to develop a true turtle graphics package for the VIC.
It is sorely needed.
[See manufacturer's statement, p. 112.]
Microworlds For Atari PILOT
I recently heard from Martin Suey, an elementary school teacher in Tulare, California who has been making good use of Atari's turtle graphics in his second grade classroom. After reading about the creation of microworlds – user-controlled environments which one can change at will – he decided to see if he could implement such an environment with Atari PILOT. His program, Day and Night, is designed for primary-aged children. The computer displays a scene showing a house with a movable pet (dog or cat) that can be made to walk in front of or behind the house. Pressing the button on the joystick changes the scene slowly from day to night (or from night to day).
Of technical interest to those of you who use this language, Martin's program uses player graphics, priority data registers, and color registers. The program is controlled with a joystick in port #1. Holding the joystick to the left or right moves the player in the indicated direction (with wraparound).
Pushing the joystick up moves the player "behind" the playfield image (behind the house, for example), and pulling the joystick down moves the player to the front of the image. Pressing the button causes the scene to change from day to night or vice versa. Michael is interested in hearing from those of you interested in these types of educational applications. I will gladly forward any comments to him.
Manufacturer's Reply In the interests of providing readers with a fair and balanced report on the features of a product, we asked the manufacturer of VIC Turtle Graphics to reply to David Thornburg's remarks. The following comments are from the author of VIC Turtle Graphics, David Malmberg, and from Human Engineered Software. While I was developing VIC Turtle Graphics, I had a number of design objectives in mind. Specifically, I wanted TURTLE to be:
On the whole, I believe these objectives have been met or exceeded in the final TURTLE product. Specifically, at $39.95 for a cartridge-based system with a 72-page tutorial instruction manual, TURTLE is an economical and highly effective means of introducing programming concepts. However, several of the above design objectives are clearly incompatible with Mr. Thornburg's "predefined set of expectations." The most significant incompatibility is obviously TURTLE'S lack of high-resolution graphics. This omission was a conscious decision on my part. Hi-res graphics would have required that approximately 4K of the 3.5K available to the user in a standard VIC be set aside for a bit-mapped video display area. This would mean that it would take extra memory and a cartridge slot expander for it to work. None of the Atari or Apple Logo or PILOT systems that Mr. Thornburg cites as his standards of comparison had to deal with the VIC's limited memory – all have at least 16K of usable memory and several are 64K with a required system disk drive. As a result, such a comparison is quite unfair. Had the developers of these systems had only 3.5K to work with, they probably would not have opted for hi-res either. Furthermore, it is not clear that hi-res is as important to the child who is being introduced to programming concepts as it is to Mr. Thornburg. Does the novice programmer learn more and/or have more fun if his turtle draws a line in hi-res than if it draws a "line" made of VIC graphic characters, such as red hearts or green diamonds? I think not. The acts of planning and debugging the drawing seem to me to be much more important to developing skills in the child than the aesthetics or resolution of the lines used. Let me correct a few possible misunderstandings that might result from reading the review:
Even though I disagree with the overall tenor and conclusions of the review, Mr. Thornburg did make several good observations. His identification of the need for INPUT and PRINT statements that can handle variables is quite valid. His suggestions on ways to improve the IF statement are good. These and other improvements are currently being incorporated into a version of Turtle Graphics for the Commodore 64. |
10 GR: QUIT 20 R: WRITTEN SEPTEMBER 11, 1982 30 C: @B1373 = 16 40 C: @B1374 = 2 50 WRITE : S ; 60 WRITE : S ; 70 WRITE : S ; 80 WRITE : S ; {4 SPACES} Day and Night 90 WRITE : S ; 100 WRITE : S ; {9 SPACES} by 110 WRITE : S ; 120 WRITE : S ; {5 SPACES} Martin Suey 130 * COUNT 140 C : # C = # C + 1 150 J(# C = 500) : * CLEAR 160 J : * COUNT 170 * CLEAR 180 GR : CLEAR 190 * TURTLE 200 C : @B708 = 20 210 C : @B709 = 196 220 C : @710 = 16 230 C : # L = 126 240 * LITE 250 C : # P = 0 260 C : # L = # L + 2 270 C : @B712 = # L 280 J (# L = 134) : * DAY 290 * KNT 300 C : # P = # P + 1 310 J (# P = 100) : * LITE 320 J : * KNT 330 * DAY 340 GR : PEN ERASE 350 GR : GOTO -74, 10 ; 5(DRAW 4 ; TURN 144) 360 GR : GOTO -50, 30 ; 5(DRAW 8 ; TURN 144) 370 GR : GOTO -30, 15 ; 5(DRAW 8 ; TURN 144) 380 GR : GOTO 0, 40 ; 5(DRAW 6 ; TURN 144) 390 GR : GOTO 50, 25 ; 5(DRAW 8 ; TURN 144) 400 GR : GOTO 74, 42 ; 5(DRAW 4 ; TURN 144) 410 GR : PEN RED 420 GR : GOTO 10, -20 ; TURNTO 0 430 GR : 2(DRAW 30 ; TURN 90 ; DRAW 40 ; TURN 90) 440 GR : PEN BLUE 450 GR : GO 30 ; TURN 30 460 GR : 3(DRAW 40 ; TURN 120) 470 GR : FILL 39 480 GR : PEN YELLOW 490 GR : GOTO 26, -20 ; TURNTO 0 500 GR : 2(DRAW 10 ; TURN 90 ; DRAW 10 ; TURN 90) 510 GR : GOTO -79, -32 ; FILL 11 520 GR : GOTO 26, -20 ; FILL 10 530 GR : PEN RED 540 GR : GOTO 10, -20 ; FILL 30 550 GR : GOTO 36, -20 ; FILL 10 560 GR : GOTO -30, -20 ; TURNTO 0 570 GR : 10(DRAW 5 ; TURN 90 ; GO 2 ; TURN 90 ; DRAW 5 ; TURN -90 ; GO 2 ; TURN -90) 580 GR : GOTO 51, -20 ; TURNTO 0 590 GR : 8(DRAW 5 ; TURN 90 ; GO 2 ; TURN 90 ; DRAW 5 ; TURN -90 ; GO 2 ; TURN -90) 600 C : @B559 = 62 610 C : # I = @B106 - 32 620 C : @B54279 = # I 630 C : @B53277 = 3 640 C : @B704 = 208 650 C : @B53256 = 0 660 C : @B53248 = 125 670 C : # J = # I * 256 + 1024 680 C : # Y = # J + 160 690 C : @B # Y = 3 700 C : # Y = # J + 161 710 C : @B # Y = 5 720 C : # Y = # J + 162 730 C : @B # Y = 6 740 C : # Y = # J + 163 750 C : @B # Y = 58 760 C : # Y = # J + 164 770 C : @B # Y = 100 780 C : # Y = # J + 165 790 C : @B # Y = 212 800 C : # Y = # J + 166 810 C : @B # Y = 76 820 C : # Y = # J + 167 830 C : @B # Y = 126 840 C : # Y = # J + 168 850 C : @B # Y = 202 860 C : # X = 125 870 * MOVET 880 J (%T8 = 1) : * CAT 890 J (%J0 = 2) : * PLAYERT 900 J (%J0 = 1) : * PFT 910 J (%J0 = 4) : * LEFT T 920 J (%J0 = 8) : *RIGHTT 930 J : * MOVET 940 * LEFTT 950 C : # X = # X - 1 960 C : @B53248 = #X 970 J : * MOVET 980 * RIGHTT 990 C : # X = # X + 1 1000 C : @B53248 = #X 1010 J : * MOVET 1020 * PLAYERT 1030 C : @B623 = 1 1040 J : * MOVET 1050 * PFT 1060 C : @B623 = 8 1070 J : * MOVET 1080 * CAT 1090 C : @B708 = 228 1100 C : @B709 = 192 1110 C : @B710 = 16 1120 C : # D = 134 1130 * DARK 1140 C : # P = 0 1150 C : # D = # D - 2 1160 C : @B712 = # D 1170 J(# D = 128) : * NITE 1180 * KOUNT 1190 C : # P = # P + 1 1200 J (# P = 100) : * DARK 1210 J : * KOUNT 1220 * NITE 1230 C : # B = 4 1240 * BLACK 1250 C : # P = 0 1260 C : # B = # B - 2 1270 C : @B712 = # B 1280 J(# B = 0) : * SCENE 1290 * CNT1300 C : # P = # P + 1 1310 J(#P = 100) : * BLACK 1320 J : * CNT 1330 * SCENE 1340 GR : PEN RED 1350 GR : GOTO -74, 10 ; 5(DRAW 4 ; TURN 144) 1360 GR : GOTO -50, 30 ; 5(DRAW 8 ; TURN 144) 1370 GR : GOTO -30, 15 ; 5 (DRAW 8 ; TURN 144) 1380 GR : GOTO 0, 40 ; 5(DRAW 6 ; TURN 144) 1390 GR : GOTO 50, 25 ; 5(DRAW 8 ; TURN 144) 1400 GR : GOTO 74, 42 ; 5(DRAW 4 ; TURN 144) 1410 GR : GOTO 10, -20 ; TURNTO 0 1420 GR : 2(DRAW 30 ; TURN 90 ; DRAW 40 ; TURN 90) 1430 GR : PEN ERASE 1440 GR : GOTO -30, -20 ; TURNTO 0 1450 GR : 10(DRAW 5 ; TURN 90 ; GO 2 ; TURN 90 ; DRAW 5 ; TURN -90 ; GO 2 ; TURN -90) 1460 GR : GOTO 51, -20 ; TURNTO 0 1470 GR : 8 (DRAW 5 ; TURN 90 ; GO 2 ; TURN 90 ; DRAW 5 ; TURN -90 ; GO 2 ; TURN -90) 1480 GR : PEN BLUE 1490 GR : GO 30 ; TURN 30 1500 GR : 3 (DRAW 40 ; TURN 120) 1510 GR : FILL 39 1520 GR : PEN YELLOW 1530 GR : GOTO 26, -20 ; TURNTO 0 1540 GR : 2 (DRAW 10 ; TURN 90 ; DRAW 10 ; TURN 90) 1550 GR : GOTO -79, -32 ; FILL 11 1560 GR : GOTO 26, -20 ; FILL 10 1570 GR : PEN RED 1580 GR : GOTO 10, -20 ; FILL 30 1590 GR : GOTO 36, -20 ; FILL 10 1600 C : @B559 = 62 1610 C : # I = @B106 - 32 1620 C : @B54279 = # I 1630 C : @B53277 = 3 1640 C : @B704 = 6 1650 C : @B53256 = 0 1660 C : @B53248 = 125 1670 C : # J = # I * 256 + 1024 1680 C : # Y = # J + 160 1690 C : @B # Y = 10 1700 C : # Y = # J + 161 1710 C : @B # Y = 14 1720 C : # Y = # J + 162 1730 C : @B # Y = 21 1740 C : # Y = # J + 163 1750 C : @B # Y = 219 1760 C : # Y = # J + 164 1770 C : @B # Y = 68 1780 C : # Y = # J + 165 1790 C : @B # Y = 124 1800 C : # Y = # J + 166 1810 C : @B # Y = 124 1820 C : # Y = # J + 167 1830 C : @B # Y = 68 1840 C : # Y = # J + 169 1850 C : @B # Y = 170 1860 C : # Y = # J + 168 1870 C : @B # Y = 202 1880 C : # X = 125 1890 * MOVE 1900 J(%T8 = 1) : * TURTLE 1910 J(%J0 = 2) : * PLAYER 1920 J(%J0 = 1) : * PF 1930 J(%J0 = 4) : * LEFT 1940 J(%J0 = 8) : * RIGHT 1950 J : * MOVE 1960 * LEFT 1970 C : # X = # X - 1 1980 C : @B53248 = # X 1990 J : * MOVE 2000 * RIGHT 2010 C : # X = # X + 1 2020 C : @B53248 = # X 2030 J : * MOVE 2040 * PLAYER 2050 C : @B623 = 1 2060 J : * MOVE 2070 * PF 2080 C : @B623 = 8 2090 J : * MOVE