home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Set of Apple II Hard Drive Images
/
eric.hdv
/
TEST
/
MPOKETABL.bas
< prev
next >
Wrap
BASIC Source File
|
2020-08-13
|
894b
|
26 lines
1 DIM SL(25)
5 GOTO 110
10 REM
15 PRINT "CHNL: 0-15 NOTE:0-127"
17 HOME
20 FOR C = 0 TO 15: FOR N0 = 0 TO 127:N = N0: IF N >119 THEN N = 119
25 IF C <0 OR C >15 OR N <0 OR N >119 THEN PRINT "OUT OF RANGE": GOTO 15
30 O = INT(N/12)
35 R = N -(O *12)
40 LY = INT(C/4)
45 LX = C -(LY *4)
50 X = 4 *O +LX
60 Y = 45 -(R *4) -1 +LY
70 CO = C: IF C = 0 THEN CO = 15
80 B = SL( INT(Y/2)) +X
82 NI = (Y -( INT(Y/2) *2)) *16
85 BY = PEEK(B)
86 IF NI = 0 THEN PB = INT(BY/16) *16 +CO
87 IF NI = 16 THEN PB = CO *16 +BY -( INT(BY/16) *16)
88 PRINT "ADRS OF CHNL "C" NOTE "N0" = "B
89 POKE 8192 +256 *C +N0,B - INT(B/256) *256: POKE 8192 +256 *C +128 +N0, INT(B/256)
90 NEXT : NEXT
99 RETURN
100 DATA 1024,1152,1280,1408,1536,1664,1792,1920,1064,1192,1320,1448,1576,1704,1832,1960,1104,1232,1360,1488,1616,1744,1872,2000
110 FOR I = 0 TO 23: READ SL(I): NEXT
120 GOSUB 10