Home » Personal collection » Acorn tapes » Own_Work » box02_tape04a_c15_acorn_school_progs.wav » VDU
VDU
This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.
Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.
Tape/disk: | Home » Personal collection » Acorn tapes » Own_Work » box02_tape04a_c15_acorn_school_progs.wav |
Filename: | VDU |
Read OK: | ✔ |
File size: | 03B6 bytes |
Load address: | FFFF0E00 |
Exec address: | FFFF802B |
File contents
10 *FX 4,1 20 DIM N(8,8) 30 DIM P(8) 40 *TV 0,1 50 MODE 4 60 VDU 23,244,127,127,127,127,0,0,127,127 70 FOR X =100 TO 900 STEP 100 80 MOVE X,100:DRAW X,900 90 MOVE 100,X:DRAW 900,X 100 NEXT 110 Y=8:X=1:Z=7 120 GCOL 0,Z 130 A$=GET$ 140 A=ASC(A$) 150 IF A=136 THEN X=X-1 160 IF A=137 THEN X=X+1 170 IF A=138 THEN Y=Y-1 180 IF A=139 THEN Y=Y+1 190 IF X=9 THEN X=1 200 IF X=0 THEN X=8 210 IF Y=9 THEN Y=1 220 IF Y=0 THEN Y=8 230 IF A<>32 THEN GOTO 130 240 MOVE X*100,Y*100 250 DRAW X*100,(Y+1)*100 260 PLOT 85,(X+1)*100,Y*100 270 PLOT 85,(X+1)*100,(Y+1)*100 280 IF Z=0 THEN N(X,Y)=0 ELSE N(X,Y)=1 290 IF Z=0 THEN GCOL 0,7:MOVE X*100,Y*100:DRAW X*100,(Y+1)*100:DRAW (X+1)*100,(Y+1)*100:DRAW (X+1)*100,Y*100:DRAW X*100,Y*100 300 S$="VDU 23,244," 310 FOR R=8 TO 1 STEP -1 320 SUM=0 330 FOR S=1 TO 8 340 SUM=SUM+N(S,R)*2^(8-S) 350 NEXT 360 S$=S$+STR$(SUM) 370 P(9-R)=SUM 380 IF R<>1 THEN S$=S$+"," 390 NEXT 400 PRINT TAB(0,0);S$;" " 410 VDU23,224,P(1),P(2),P(3),P(4),P(5),P(6),P(7),P(8) 420 PRINT TAB(35,12),CHR$(224) 430 IF Z=7 THEN Z=0 ELSE Z=7 440 GOTO 120
*FX 4,1 � N(8,8) � P(8) ( *TV 0,1 2 � 4 <) � 23,244,127,127,127,127,0,0,127,127 F � X =100 � 900 � 100 P � X,100:� X,900 Z � 100,X:� 900,X d � n Y=8:X=1:Z=7 x � 0,Z � A$=� � A=�(A$) � � A=136 � X=X-1 � � A=137 � X=X+1 � � A=138 � Y=Y-1 � � A=139 � Y=Y+1 � � X=9 � X=1 � � X=0 � X=8 � � Y=9 � Y=1 � � Y=0 � Y=8 � � A<>32 � � �tB@ � � X*100,Y*100 � � X*100,(Y+1)*100 � 85,(X+1)*100,Y*100 � 85,(X+1)*100,(Y+1)*100 � Z=0 � N(X,Y)=0 � N(X,Y)=1 "h � Z=0 � � 0,7:� X*100,Y*100:� X*100,(Y+1)*100:� (X+1)*100,(Y+1)*100:� (X+1)*100,Y*100:� X*100,Y*100 , S$="VDU 23,244," 6 � R=8 � 1 � -1 @ SUM=0 J � S=1 � 8 T SUM=SUM+N(S,R)*2^(8-S) ^ � h S$=S$+�(SUM) r P(9-R)=SUM | � R<>1 � S$=S$+"," � � �; � �0,0);S$;" " �4 �23,224,P(1),P(2),P(3),P(4),P(5),P(6),P(7),P(8) � � �35,12),�(224) � � Z=7 � Z=0 � Z=7 � � �Dx@ �
00000000 0d 00 0a 0c 20 2a 46 58 20 34 2c 31 0d 00 14 0d |.... *FX 4,1....| 00000010 20 de 20 4e 28 38 2c 38 29 0d 00 1e 0b 20 de 20 | . N(8,8).... . | 00000020 50 28 38 29 0d 00 28 0c 20 2a 54 56 20 30 2c 31 |P(8)..(. *TV 0,1| 00000030 0d 00 32 08 20 eb 20 34 0d 00 3c 29 20 ef 20 32 |..2. . 4..<) . 2| 00000040 33 2c 32 34 34 2c 31 32 37 2c 31 32 37 2c 31 32 |3,244,127,127,12| 00000050 37 2c 31 32 37 2c 30 2c 30 2c 31 32 37 2c 31 32 |7,127,0,0,127,12| 00000060 37 0d 00 46 19 20 e3 20 58 20 3d 31 30 30 20 b8 |7..F. . X =100 .| 00000070 20 39 30 30 20 88 20 31 30 30 0d 00 50 15 20 ec | 900 . 100..P. .| 00000080 20 58 2c 31 30 30 3a df 20 58 2c 39 30 30 20 0d | X,100:. X,900 .| 00000090 00 5a 16 20 ec 20 31 30 30 2c 58 3a df 20 39 30 |.Z. . 100,X:. 90| 000000a0 30 2c 58 20 20 0d 00 64 06 20 ed 0d 00 6e 10 20 |0,X ..d. ...n. | 000000b0 59 3d 38 3a 58 3d 31 3a 5a 3d 37 0d 00 78 0a 20 |Y=8:X=1:Z=7..x. | 000000c0 e6 20 30 2c 5a 0d 00 82 09 20 41 24 3d be 0d 00 |. 0,Z.... A$=...| 000000d0 8c 0c 20 41 3d 97 28 41 24 29 0d 00 96 14 20 e7 |.. A=.(A$).... .| 000000e0 20 41 3d 31 33 36 20 8c 20 58 3d 58 2d 31 0d 00 | A=136 . X=X-1..| 000000f0 a0 14 20 e7 20 41 3d 31 33 37 20 8c 20 58 3d 58 |.. . A=137 . X=X| 00000100 2b 31 0d 00 aa 14 20 e7 20 41 3d 31 33 38 20 8c |+1.... . A=138 .| 00000110 20 59 3d 59 2d 31 0d 00 b4 14 20 e7 20 41 3d 31 | Y=Y-1.... . A=1| 00000120 33 39 20 8c 20 59 3d 59 2b 31 0d 00 be 10 20 e7 |39 . Y=Y+1.... .| 00000130 20 58 3d 39 20 8c 20 58 3d 31 0d 00 c8 10 20 e7 | X=9 . X=1.... .| 00000140 20 58 3d 30 20 8c 20 58 3d 38 0d 00 d2 10 20 e7 | X=0 . X=8.... .| 00000150 20 59 3d 39 20 8c 20 59 3d 31 0d 00 dc 10 20 e7 | Y=9 . Y=1.... .| 00000160 20 59 3d 30 20 8c 20 59 3d 38 0d 00 e6 15 20 e7 | Y=0 . Y=8.... .| 00000170 20 41 3c 3e 33 32 20 8c 20 e5 20 8d 74 42 40 0d | A<>32 . . .tB@.| 00000180 00 f0 14 20 ec 20 58 2a 31 30 30 2c 59 2a 31 30 |... . X*100,Y*10| 00000190 30 20 20 0d 00 fa 18 20 df 20 58 2a 31 30 30 2c |0 .... . X*100,| 000001a0 28 59 2b 31 29 2a 31 30 30 20 20 0d 01 04 1c 20 |(Y+1)*100 .... | 000001b0 f0 20 38 35 2c 28 58 2b 31 29 2a 31 30 30 2c 59 |. 85,(X+1)*100,Y| 000001c0 2a 31 30 30 20 20 20 0d 01 0e 1d 20 f0 20 38 35 |*100 .... . 85| 000001d0 2c 28 58 2b 31 29 2a 31 30 30 2c 28 59 2b 31 29 |,(X+1)*100,(Y+1)| 000001e0 2a 31 30 30 0d 01 18 20 20 e7 20 5a 3d 30 20 8c |*100... . Z=0 .| 000001f0 20 4e 28 58 2c 59 29 3d 30 20 8b 20 4e 28 58 2c | N(X,Y)=0 . N(X,| 00000200 59 29 3d 31 0d 01 22 68 20 e7 20 5a 3d 30 20 8c |Y)=1.."h . Z=0 .| 00000210 20 e6 20 30 2c 37 3a ec 20 58 2a 31 30 30 2c 59 | . 0,7:. X*100,Y| 00000220 2a 31 30 30 3a df 20 58 2a 31 30 30 2c 28 59 2b |*100:. X*100,(Y+| 00000230 31 29 2a 31 30 30 3a df 20 28 58 2b 31 29 2a 31 |1)*100:. (X+1)*1| 00000240 30 30 2c 28 59 2b 31 29 2a 31 30 30 3a df 20 28 |00,(Y+1)*100:. (| 00000250 58 2b 31 29 2a 31 30 30 2c 59 2a 31 30 30 3a df |X+1)*100,Y*100:.| 00000260 20 58 2a 31 30 30 2c 59 2a 31 30 30 0d 01 2c 15 | X*100,Y*100..,.| 00000270 20 53 24 3d 22 56 44 55 20 32 33 2c 32 34 34 2c | S$="VDU 23,244,| 00000280 22 0d 01 36 13 20 e3 20 52 3d 38 20 b8 20 31 20 |"..6. . R=8 . 1 | 00000290 88 20 2d 31 0d 01 40 0a 20 53 55 4d 3d 30 0d 01 |. -1..@. SUM=0..| 000002a0 4a 11 20 e3 20 53 3d 31 20 b8 20 38 20 20 20 0d |J. . S=1 . 8 .| 000002b0 01 54 1b 20 53 55 4d 3d 53 55 4d 2b 4e 28 53 2c |.T. SUM=SUM+N(S,| 000002c0 52 29 2a 32 5e 28 38 2d 53 29 0d 01 5e 06 20 ed |R)*2^(8-S)..^. .| 000002d0 0d 01 68 11 20 53 24 3d 53 24 2b c3 28 53 55 4d |..h. S$=S$+.(SUM| 000002e0 29 0d 01 72 0f 20 50 28 39 2d 52 29 3d 53 55 4d |)..r. P(9-R)=SUM| 000002f0 0d 01 7c 17 20 e7 20 52 3c 3e 31 20 8c 20 53 24 |..|. . R<>1 . S$| 00000300 3d 53 24 2b 22 2c 22 0d 01 86 06 20 ed 0d 01 90 |=S$+",".... ....| 00000310 3b 20 f1 20 8a 30 2c 30 29 3b 53 24 3b 22 20 20 |; . .0,0);S$;" | 00000320 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | | * 00000340 20 20 20 20 20 20 20 22 0d 01 9a 34 20 ef 32 33 | "...4 .23| 00000350 2c 32 32 34 2c 50 28 31 29 2c 50 28 32 29 2c 50 |,224,P(1),P(2),P| 00000360 28 33 29 2c 50 28 34 29 2c 50 28 35 29 2c 50 28 |(3),P(4),P(5),P(| 00000370 36 29 2c 50 28 37 29 2c 50 28 38 29 0d 01 a4 16 |6),P(7),P(8)....| 00000380 20 f1 20 8a 33 35 2c 31 32 29 2c bd 28 32 32 34 | . .35,12),.(224| 00000390 29 20 0d 01 ae 17 20 e7 20 5a 3d 37 20 8c 20 5a |) .... . Z=7 . Z| 000003a0 3d 30 20 8b 20 5a 3d 37 20 0d 01 b8 0b 20 e5 20 |=0 . Z=7 .... . | 000003b0 8d 44 78 40 0d ff |.Dx@..| 000003b6