Compucolor.org – Virtual Media

Listing of file='HLPRNT.BAS;01' on disk='vmedia/hardware_utilities-sector.ccvf'

10 REM  PROGRAM TO PRINT OUT THE ROM GROUPS IN H/L FORMAT
20 REM  TO SCREEN & PRINTER, BY K.G.WINDER - JUNE 1984
30 REM
40 CLEAR 500:PLOT 14,12
50 PRINT :PRINT TAB( 22)"MEMORY DATA PRINTER"
60 PRINT TAB( 22)"eeeeeeeeeeeeeeeeeee"
70 PLOT 15,3,12,6:INPUT "DATA IN MEMORY AT AF80, OR FROM DISK? - ";C$
80 IF C$= ""THEN PLOT 28,11:GOTO 70
90 IF C$= "M"THEN 120
100 PLOT 3,12,8:INPUT "ENTER NAME OF DATA FILE (PRG) - ";D$
110 PLOT 27,4:PRINT "LOA ";D$;".PRG AF80":PLOT 27,27
120 PLOT 15,3,12,10:INPUT "ENTER TOTAL NUMBER OF ADDRESSES IN MEM ";UL
130 PLOT 3,19,12:INPUT "ENTER BIT WIDTH OF MEM  ";P
140 PLOT 3,19,14:INPUT "PRINTOUT ON PAPER? Y OR N - ";PT$
150 IF PT$< > "Y"AND PT$< > "N"THEN PLOT 28,11:GOTO 140
160 Q= 0:IF PT$= "N"THEN Q= 1:GOTO 170
165 IF C$= "M"THEN PLOT 3,12,16:INPUT "ENTER NAME OF DATA FILE FOR PRINTING - ";D$
170 PLOT 3,19,18:INPUT "PRESS RETURN WHEN READY - ";R
180 IF Q= 1THEN PRINT :POKE 33289,64:PLOT 27,18,7:GOTO 200
190 PRINT :POKE 33289,132:PLOT 27,18,7
191 N$= "        DIRECTORY NAME IS - - "+ D$+ ".PRG"
194 POKE 33265,14:PRINT N$:PRINT :POKE 33265,0
200 FOR J= 0TO UL- 1STEP 4
210 X$= "   ":IF J> 9AND J< 100THEN X$= "  "
220 IF J> 99AND J< 1000THEN X$= " "
230 IF J> 999AND J< 10000THEN X$= ""
240 PRINT "    "X$;J;
250 IF Q= 1THEN GOTO 270
260 POKE 33265,14:PRINT ""X$;J;:POKE 33265,0
270 FOR I= 1TO 4
280 Z= PEEK (44927+ I+ J)
290 IF P= 8THEN GOSUB 1000
300 IF P= 4THEN GOSUB 1050
310 IF P= 1THEN GOSUB 1080
320 PRINT "   ";Z9$;
330 IF Q= 1THEN GOTO 350
340 POKE 33265,14:PRINT "   "Z9$;:POKE 33265,0
350 NEXT I
360 IF Q= 1THEN GOTO 380
370 POKE 33265,14:PRINT :POKE 33265,0:PLOT 13:PRINT :GOTO 390
380 PRINT :NEXT J:GOTO 400
390 NEXT J
395 POKE 33265,14:PRINT :PRINT :POKE 33265,0
400 PRINT :PRINT :PLOT 7
410 INPUT "            PRESS RETURN TO REPEAT, OR M FOR MENU - ";R$
420 POKE 33289,64:IF R$= "M"THEN PLOT 1
430 GOTO 40
440 END
1000 REM  BINARY DECODE
1010 Z1$= "L":IF Z> 127AND Z< 256THEN Z1$= "H":Z= Z- 128
1020 Z2$= "L":IF Z> 63AND Z< 128THEN Z2$= "H":Z= Z- 64
1030 Z3$= "L":IF Z> 31AND Z< 64THEN Z3$= "H":Z= Z- 32
1040 Z4$= "L":IF Z> 15AND Z< 32THEN Z4$= "H":Z= Z- 16
1050 Z5$= "L":IF Z> 7AND Z< 16THEN Z5$= "H":Z= Z- 8
1060 Z6$= "L":IF Z> 3AND Z< 8THEN Z6$= "H":Z= Z- 4
1070 Z7$= "L":IF Z> 1AND Z< 4THEN Z7$= "H":Z= Z- 2
1080 Z8$= "L":IF Z= 1THEN Z8$= "H"
1090 IF P= 8THEN Z9$= Z1$+ Z2$+ Z3$+ Z4$+ Z5$+ Z6$+ Z7$+ Z8$
1100 IF P= 4THEN Z9$= Z5$+ Z6$+ Z7$+ Z8$
1110 IF P= 1THEN Z9$= Z8$
1120 RETURN