Compucolor.org – Virtual Media

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

0 REM             'REORG'  BY TOM DEVLIN 1982
1 REM     PROGRAM TO REORG 'FREDI'. REQUIRES 16K. WORKS FOR
2 REM     V3.20, MAY HAVE TO BE MODIFIED FOR OTHER VERSIONS.
3 REM     RESET TOP OF MEMORY WITH AN <ESC>-W WHEN DONE.
8
9 REM  MOVE TOP OF MEMORY DOWN
10 POKE 32940,191:POKE 32941,158:CLEAR 50
19
20 PLOT 12,6,2,15
30 INPUT "INSERT YOUR BASIC EDITING DISK AND HIT RETURN";A$
40 PRINT :PRINT "DO YOU HAVE AN <ESC> [P] JUMP TO 4000H?"
50 INPUT "     ( ALL V8.79 UNITS DO ) ";A$:PRINT
60 PRINT "THIS WILL TAKE ABOUT TWO MINUTES"
68
69 REM  GET BOTH VERSIONS INTO 16K AT THE SAME TIME
70 PLOT 27,4:PRINT "LOAD FRED16.PRG;01":PLOT 27,27
80 PLOT 27,4:PRINT "LOAD FRED32.PRG;01,9EC0":PLOT 27,27
88
89 REM  SPOT FCS ERROR VIA CCI CODE
90 IF (PEEK (33231)AND 7)= 1THEN 10
99
100 LO= 44928:REM  0AF80H, FIRST BYTE 16K VERSON
110 HI= 40640:REM  09EC0H, FIRST BYTE 32K VERSON
120 RC= 16768:REM  04180H, FIRST BYTE RAM CARD VERSION
130 SZ= 4189:REM  105DH, PROGRAM SIZE
138
139 REM  MOVE 'FREDI' DOWN, CHANGING HIGH ADDRESS BYTES
140   FOR I= 0TO SZ
150    POKE RC+ I,PEEK (LO+ I)
160     IF PEEK (HI+ I)- PEEK (LO+ I)< > 64THEN 180
170    POKE RC+ I,PEEK (LO+ I)- 110
180   NEXT
188
189 REM  SEE IF WE NEED TO USE <ESC> [^]
190 IF ASC (A$)< > 89THEN 250:"  YES
198
199 REM  DELETE USER JUMP SETUP (FILL WITH NOPS)
200   FOR M= 16847TO 16857
210    POKE M,0
220   NEXT
230 POKE 19521,80:REM  CHANGE [^] TO [P] IN SIGN-ON MESSAGE
240 GOTO 260
248
249 REM     SET USER JUMP TO 04000H IF NO <ESC> [P]
250 POKE 16848,0:POKE 16849,64
257
258 REM    SET UP JUMP AT 04000H WHEN RUN
259 REM    USING OLD TOP OF MEMORY ADJUST SPACE
260 DATA  62,195,50,0,64,33,15,66,34,1,64,0
270   FOR M= 16864TO 16875
280    READ D
290    POKE M,D
300   NEXT
308
309 REM  CHANGE THE SIGN-ON MESSAGE TO 4000H, COLOR TO CYAN
310 DATA  6,52,48,48,48,72
320   FOR M= 19468TO 19473
330    READ D
340    POKE M,D
350   NEXT
358
359 REM  SAVE 'FRED4' TO DISK AND RUN IT.( HIM? )
360 PLOT 27,4:PRINT "SAVE FRED4 4180 105D":PLOT 27,27
370 PLOT 27,4:PRINT "RUN FRED4"