Home » CEEFAX disks » telesoftware1.adl » Utils/NLQ\DEF
Utils/NLQ\DEF
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 » CEEFAX disks » telesoftware1.adl |
Filename: | Utils/NLQ\DEF |
Read OK: | ✔ |
File size: | 05D2 bytes |
Load address: | 1A00 |
Exec address: | 801F |
File contents
10REM ********************** 20REM NLQ printout routine 30REM Define NLQ characters 40REM (c) P.A.Crook 1986 50REM ********************** 60 70*TV255 80*FX4,1 90*FX229,1 100MODE5 110VDU23;8202;0;0;0; 120X%=OPENUP"NLQ1" 130Y%=OPENUP"NLQ2" 140Z%=OPENUP"NLQ3" 150VDU 23,128,255,128,128,128,128,128,128,128,23,129,255,255,255,255,255,255,255,255 160FOR A%=0TO768STEP32:MOVE0,A%:DRAW768,A%:NEXT 170FOR A%=0TO768STEP64:MOVEA%,0:DRAWA%,768:NEXT 180C%=0 190PRINTTAB(0,0);"CHR$ - "C%+33;" " 200FOR F%=0TO11:FOR G%=0TO23:PROCdisplay(C%,F%,G%):NEXT, 210F%=0:G%=0 220REPEATVDU5:MOVEF%*64,G%*32+32:GCOL3,1:VDU129,4 230K%=GET:VDU5:MOVEF%*64,G%*32+32:GCOL3,1:VDU129,4 240IFK%=136ANDF%>0THEN F%=F%-1 250IFK%=137ANDF%<11THEN F%=F%+1 260IFK%=138ANDG%>0THEN G%=G%-1 270IFK%=139ANDG%<23THEN G%=G%+1 280IF K%=ASC"1"THENPROCpoke(C%,F%,G%,1) 290IF K%=ASC"0"THENPROCpoke(C%,F%,G%,0) 300PROCdisplay(C%,F%,G%) 310UNTIL K%=135ORK%=127ORK%=27ORK%=ASC"I" 320IF K%=135AND C%<93 THENC%=C%+1 330IF K%=127AND C%>0 THENC%=C%-1 340IF K%<>ASC"I"THEN370 350PRINTTAB(7,0);" ":INPUTTAB(7,0)C%:C%=C%-33 360IF C%<0 OR C%>93 THEN350 370IF K%<>27THEN190 380CLOSE#0 390END 400DEFFNpeek(C%,F%,G%) 410IF G%MOD3=2THEN PTR#X%=C%*12+F%:D%=BGET#X% 420IF G%MOD3=1THEN PTR#Y%=C%*12+F%:D%=BGET#Y% 430IF G%MOD3=0THEN PTR#Z%=C%*12+F%:D%=BGET#Z% 440IF 2^(G%DIV3)ANDD% THEN=TRUE ELSE=FALSE 450DEFPROCpoke(C%,F%,G%,P%) 460IF G%MOD3=2THEN PTR#X%=C%*12+F%:D%=BGET#X% 470IF G%MOD3=1THEN PTR#Y%=C%*12+F%:D%=BGET#Y% 480IF G%MOD3=0THEN PTR#Z%=C%*12+F%:D%=BGET#Z% 490D%=(D%AND(2^(G%DIV3)EOR&FF))OR(P%*2^(G%DIV3)) 500IF G%MOD3=2THEN PTR#X%=C%*12+F%:BPUT#X%,D% 510IF G%MOD3=1THEN PTR#Y%=C%*12+F%:BPUT#Y%,D% 520IF G%MOD3=0THEN PTR#Z%=C%*12+F%:BPUT#Z%,D% 530ENDPROC 540DEFPROCdisplay(C%,F%,G%) 550VDU5:GCOL2,0:MOVEF%*64,G%*32+32:VDU129:GCOL0,3:MOVEF%*64,G%*32+32 560IF FNpeek(C%,F%,G%) THENVDU129 ELSEVDU128 570VDU4 580ENDPROC
� ********************** � NLQ printout routine � Define NLQ characters (� (c) P.A.Crook 1986 2� ********************** < F *TV255 P *FX4,1 Z*FX229,1 d�5 n�23;8202;0;0;0; xX%=�"NLQ1" �Y%=�"NLQ2" �Z%=�"NLQ3" �S� 23,128,255,128,128,128,128,128,128,128,23,129,255,255,255,255,255,255,255,255 �!� A%=0�768�32:�0,A%:�768,A%:� �!� A%=0�768�64:�A%,0:�A%,768:� �C%=0 ��0,0);"CHR$ - "C%+33;" " �-� F%=0�11:� G%=0�23:�display(C%,F%,G%):�, � F%=0:G%=0 �#��5:�F%*64,G%*32+32:�3,1:�129,4 �'K%=�:�5:�F%*64,G%*32+32:�3,1:�129,4 ��K%=136�F%>0� F%=F%-1 ��K%=137�F%<11� F%=F%+1 �K%=138�G%>0� G%=G%-1 �K%=139�G%<23� G%=G%+1 � K%=�"1"��poke(C%,F%,G%,1) "� K%=�"0"��poke(C%,F%,G%,0) ,�display(C%,F%,G%) 6!� K%=135�K%=127�K%=27�K%=�"I" @� K%=135� C%<93 �C%=C%+1 J� K%=127� C%>0 �C%=C%-1 T� K%<>�"I"��DrA ^"�7,0);" ":�7,0)C%:C%=C%-33 h� C%<0 � C%>93 ��D^A r� K%<>27��t~@ |�#0 �� �ݤpeek(C%,F%,G%) �#� G%�3=2� �#X%=C%*12+F%:D%=�#X% �#� G%�3=1� �#Y%=C%*12+F%:D%=�#Y% �#� G%�3=0� �#Z%=C%*12+F%:D%=�#Z% �� 2^(G%�3)�D% �=� �=� ���poke(C%,F%,G%,P%) �#� G%�3=2� �#X%=C%*12+F%:D%=�#X% �#� G%�3=1� �#Y%=C%*12+F%:D%=�#Y% �#� G%�3=0� �#Z%=C%*12+F%:D%=�#Z% �(D%=(D%�(2^(G%�3)�&FF))�(P%*2^(G%�3)) �#� G%�3=2� �#X%=C%*12+F%:�#X%,D% �#� G%�3=1� �#Y%=C%*12+F%:�#Y%,D% #� G%�3=0� �#Z%=C%*12+F%:�#Z%,D% � ��display(C%,F%,G%) &5�5:�2,0:�F%*64,G%*32+32:�129:�0,3:�F%*64,G%*32+32 0!� �peek(C%,F%,G%) ��129 ��128 :�4 D� �
00000000 0d 00 0a 1c f4 20 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a |..... **********| 00000010 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 0d 00 14 1b |************....| 00000020 f4 20 20 4e 4c 51 20 70 72 69 6e 74 6f 75 74 20 |. NLQ printout | 00000030 72 6f 75 74 69 6e 65 0d 00 1e 1c f4 20 44 65 66 |routine..... Def| 00000040 69 6e 65 20 20 4e 4c 51 20 63 68 61 72 61 63 74 |ine NLQ charact| 00000050 65 72 73 0d 00 28 1a f4 20 20 20 28 63 29 20 50 |ers..(.. (c) P| 00000060 2e 41 2e 43 72 6f 6f 6b 20 31 39 38 36 0d 00 32 |.A.Crook 1986..2| 00000070 1c f4 20 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a |.. *************| 00000080 2a 2a 2a 2a 2a 2a 2a 2a 2a 0d 00 3c 05 20 0d 00 |*********..<. ..| 00000090 46 0a 2a 54 56 32 35 35 0d 00 50 0a 2a 46 58 34 |F.*TV255..P.*FX4| 000000a0 2c 31 0d 00 5a 0c 2a 46 58 32 32 39 2c 31 0d 00 |,1..Z.*FX229,1..| 000000b0 64 06 eb 35 0d 00 6e 13 ef 32 33 3b 38 32 30 32 |d..5..n..23;8202| 000000c0 3b 30 3b 30 3b 30 3b 0d 00 78 0e 58 25 3d ad 22 |;0;0;0;..x.X%=."| 000000d0 4e 4c 51 31 22 0d 00 82 0e 59 25 3d ad 22 4e 4c |NLQ1"....Y%=."NL| 000000e0 51 32 22 0d 00 8c 0e 5a 25 3d ad 22 4e 4c 51 33 |Q2"....Z%=."NLQ3| 000000f0 22 0d 00 96 53 ef 20 32 33 2c 31 32 38 2c 32 35 |"...S. 23,128,25| 00000100 35 2c 31 32 38 2c 31 32 38 2c 31 32 38 2c 31 32 |5,128,128,128,12| 00000110 38 2c 31 32 38 2c 31 32 38 2c 31 32 38 2c 32 33 |8,128,128,128,23| 00000120 2c 31 32 39 2c 32 35 35 2c 32 35 35 2c 32 35 35 |,129,255,255,255| 00000130 2c 32 35 35 2c 32 35 35 2c 32 35 35 2c 32 35 35 |,255,255,255,255| 00000140 2c 32 35 35 0d 00 a0 21 e3 20 41 25 3d 30 b8 37 |,255...!. A%=0.7| 00000150 36 38 88 33 32 3a ec 30 2c 41 25 3a df 37 36 38 |68.32:.0,A%:.768| 00000160 2c 41 25 3a ed 0d 00 aa 21 e3 20 41 25 3d 30 b8 |,A%:....!. A%=0.| 00000170 37 36 38 88 36 34 3a ec 41 25 2c 30 3a df 41 25 |768.64:.A%,0:.A%| 00000180 2c 37 36 38 3a ed 0d 00 b4 08 43 25 3d 30 0d 00 |,768:.....C%=0..| 00000190 be 1e f1 8a 30 2c 30 29 3b 22 43 48 52 24 20 2d |....0,0);"CHR$ -| 000001a0 20 22 43 25 2b 33 33 3b 22 20 20 22 0d 00 c8 2d | "C%+33;" "...-| 000001b0 e3 20 46 25 3d 30 b8 31 31 3a e3 20 47 25 3d 30 |. F%=0.11:. G%=0| 000001c0 b8 32 33 3a f2 64 69 73 70 6c 61 79 28 43 25 2c |.23:.display(C%,| 000001d0 46 25 2c 47 25 29 3a ed 2c 0d 00 d2 0d 46 25 3d |F%,G%):.,....F%=| 000001e0 30 3a 47 25 3d 30 0d 00 dc 23 f5 ef 35 3a ec 46 |0:G%=0...#..5:.F| 000001f0 25 2a 36 34 2c 47 25 2a 33 32 2b 33 32 3a e6 33 |%*64,G%*32+32:.3| 00000200 2c 31 3a ef 31 32 39 2c 34 0d 00 e6 27 4b 25 3d |,1:.129,4...'K%=| 00000210 a5 3a ef 35 3a ec 46 25 2a 36 34 2c 47 25 2a 33 |.:.5:.F%*64,G%*3| 00000220 32 2b 33 32 3a e6 33 2c 31 3a ef 31 32 39 2c 34 |2+32:.3,1:.129,4| 00000230 0d 00 f0 19 e7 4b 25 3d 31 33 36 80 46 25 3e 30 |.....K%=136.F%>0| 00000240 8c 20 46 25 3d 46 25 2d 31 0d 00 fa 1a e7 4b 25 |. F%=F%-1.....K%| 00000250 3d 31 33 37 80 46 25 3c 31 31 8c 20 46 25 3d 46 |=137.F%<11. F%=F| 00000260 25 2b 31 0d 01 04 19 e7 4b 25 3d 31 33 38 80 47 |%+1.....K%=138.G| 00000270 25 3e 30 8c 20 47 25 3d 47 25 2d 31 0d 01 0e 1a |%>0. G%=G%-1....| 00000280 e7 4b 25 3d 31 33 39 80 47 25 3c 32 33 8c 20 47 |.K%=139.G%<23. G| 00000290 25 3d 47 25 2b 31 0d 01 18 1f e7 20 4b 25 3d 97 |%=G%+1..... K%=.| 000002a0 22 31 22 8c f2 70 6f 6b 65 28 43 25 2c 46 25 2c |"1"..poke(C%,F%,| 000002b0 47 25 2c 31 29 0d 01 22 1f e7 20 4b 25 3d 97 22 |G%,1)..".. K%=."| 000002c0 30 22 8c f2 70 6f 6b 65 28 43 25 2c 46 25 2c 47 |0"..poke(C%,F%,G| 000002d0 25 2c 30 29 0d 01 2c 16 f2 64 69 73 70 6c 61 79 |%,0)..,..display| 000002e0 28 43 25 2c 46 25 2c 47 25 29 0d 01 36 21 fd 20 |(C%,F%,G%)..6!. | 000002f0 4b 25 3d 31 33 35 84 4b 25 3d 31 32 37 84 4b 25 |K%=135.K%=127.K%| 00000300 3d 32 37 84 4b 25 3d 97 22 49 22 0d 01 40 1c e7 |=27.K%=."I"..@..| 00000310 20 4b 25 3d 31 33 35 80 20 43 25 3c 39 33 20 8c | K%=135. C%<93 .| 00000320 43 25 3d 43 25 2b 31 0d 01 4a 1b e7 20 4b 25 3d |C%=C%+1..J.. K%=| 00000330 31 32 37 80 20 43 25 3e 30 20 8c 43 25 3d 43 25 |127. C%>0 .C%=C%| 00000340 2d 31 0d 01 54 13 e7 20 4b 25 3c 3e 97 22 49 22 |-1..T.. K%<>."I"| 00000350 8c 8d 44 72 41 0d 01 5e 22 f1 8a 37 2c 30 29 3b |..DrA..^"..7,0);| 00000360 22 20 20 20 22 3a e8 8a 37 2c 30 29 43 25 3a 43 |" ":..7,0)C%:C| 00000370 25 3d 43 25 2d 33 33 0d 01 68 18 e7 20 43 25 3c |%=C%-33..h.. C%<| 00000380 30 20 84 20 43 25 3e 39 33 20 8c 8d 44 5e 41 0d |0 . C%>93 ..D^A.| 00000390 01 72 11 e7 20 4b 25 3c 3e 32 37 8c 8d 74 7e 40 |.r.. K%<>27..t~@| 000003a0 0d 01 7c 07 d9 23 30 0d 01 86 05 e0 0d 01 90 14 |..|..#0.........| 000003b0 dd a4 70 65 65 6b 28 43 25 2c 46 25 2c 47 25 29 |..peek(C%,F%,G%)| 000003c0 0d 01 9a 23 e7 20 47 25 83 33 3d 32 8c 20 cf 23 |...#. G%.3=2. .#| 000003d0 58 25 3d 43 25 2a 31 32 2b 46 25 3a 44 25 3d 9a |X%=C%*12+F%:D%=.| 000003e0 23 58 25 0d 01 a4 23 e7 20 47 25 83 33 3d 31 8c |#X%...#. G%.3=1.| 000003f0 20 cf 23 59 25 3d 43 25 2a 31 32 2b 46 25 3a 44 | .#Y%=C%*12+F%:D| 00000400 25 3d 9a 23 59 25 0d 01 ae 23 e7 20 47 25 83 33 |%=.#Y%...#. G%.3| 00000410 3d 30 8c 20 cf 23 5a 25 3d 43 25 2a 31 32 2b 46 |=0. .#Z%=C%*12+F| 00000420 25 3a 44 25 3d 9a 23 5a 25 0d 01 b8 19 e7 20 32 |%:D%=.#Z%..... 2| 00000430 5e 28 47 25 81 33 29 80 44 25 20 8c 3d b9 20 8b |^(G%.3).D% .=. .| 00000440 3d a3 0d 01 c2 17 dd f2 70 6f 6b 65 28 43 25 2c |=.......poke(C%,| 00000450 46 25 2c 47 25 2c 50 25 29 0d 01 cc 23 e7 20 47 |F%,G%,P%)...#. G| 00000460 25 83 33 3d 32 8c 20 cf 23 58 25 3d 43 25 2a 31 |%.3=2. .#X%=C%*1| 00000470 32 2b 46 25 3a 44 25 3d 9a 23 58 25 0d 01 d6 23 |2+F%:D%=.#X%...#| 00000480 e7 20 47 25 83 33 3d 31 8c 20 cf 23 59 25 3d 43 |. G%.3=1. .#Y%=C| 00000490 25 2a 31 32 2b 46 25 3a 44 25 3d 9a 23 59 25 0d |%*12+F%:D%=.#Y%.| 000004a0 01 e0 23 e7 20 47 25 83 33 3d 30 8c 20 cf 23 5a |..#. G%.3=0. .#Z| 000004b0 25 3d 43 25 2a 31 32 2b 46 25 3a 44 25 3d 9a 23 |%=C%*12+F%:D%=.#| 000004c0 5a 25 0d 01 ea 28 44 25 3d 28 44 25 80 28 32 5e |Z%...(D%=(D%.(2^| 000004d0 28 47 25 81 33 29 82 26 46 46 29 29 84 28 50 25 |(G%.3).&FF)).(P%| 000004e0 2a 32 5e 28 47 25 81 33 29 29 0d 01 f4 23 e7 20 |*2^(G%.3))...#. | 000004f0 47 25 83 33 3d 32 8c 20 cf 23 58 25 3d 43 25 2a |G%.3=2. .#X%=C%*| 00000500 31 32 2b 46 25 3a d5 23 58 25 2c 44 25 0d 01 fe |12+F%:.#X%,D%...| 00000510 23 e7 20 47 25 83 33 3d 31 8c 20 cf 23 59 25 3d |#. G%.3=1. .#Y%=| 00000520 43 25 2a 31 32 2b 46 25 3a d5 23 59 25 2c 44 25 |C%*12+F%:.#Y%,D%| 00000530 0d 02 08 23 e7 20 47 25 83 33 3d 30 8c 20 cf 23 |...#. G%.3=0. .#| 00000540 5a 25 3d 43 25 2a 31 32 2b 46 25 3a d5 23 5a 25 |Z%=C%*12+F%:.#Z%| 00000550 2c 44 25 0d 02 12 05 e1 0d 02 1c 17 dd f2 64 69 |,D%...........di| 00000560 73 70 6c 61 79 28 43 25 2c 46 25 2c 47 25 29 0d |splay(C%,F%,G%).| 00000570 02 26 35 ef 35 3a e6 32 2c 30 3a ec 46 25 2a 36 |.&5.5:.2,0:.F%*6| 00000580 34 2c 47 25 2a 33 32 2b 33 32 3a ef 31 32 39 3a |4,G%*32+32:.129:| 00000590 e6 30 2c 33 3a ec 46 25 2a 36 34 2c 47 25 2a 33 |.0,3:.F%*64,G%*3| 000005a0 32 2b 33 32 0d 02 30 21 e7 20 a4 70 65 65 6b 28 |2+32..0!. .peek(| 000005b0 43 25 2c 46 25 2c 47 25 29 20 8c ef 31 32 39 20 |C%,F%,G%) ..129 | 000005c0 8b ef 31 32 38 0d 02 3a 06 ef 34 0d 02 44 05 e1 |..128..:..4..D..| 000005d0 0d ff |..| 000005d2