home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Nibble Magazine
/
nib39b.dsk
/
MACRO.INIT.bas
< prev
next >
Wrap
BASIC Source File
|
2023-02-26
|
3KB
|
66 lines
10 REM *******************************
20 REM * AppleMate *
30 REM * The Complete Keyboard *
40 REM * Macro System *
50 REM * *
60 REM * By Chris Chapman *
70 REM * Copyright 1990 by *
80 REM * MindCraft Publ. Corp. *
90 REM *******************************
120 REM ------- Set-Up Section
150 HOME : ONERR GOTO 860
160 D$ = CHR$(4):LA = 16384: REM $4000
170 FOR L = 1 TO 27: READ D: POKE 767 +L,D: NEXT
180 DATA 169,4,32,245,190,133,7,96,162,2,160,0,177,8,145,6,200,208,249,230,9,230,7,202,16,242,96
190 IF PEEK(64435) < >6 THEN 890: REM ][+
200 IF PEEK(977) THEN 390: REM DOS 3.3
230 REM ------- Installer for ProDOS
260 REM Make sure prefix is the same as the one where MACRO.INIT lives.
270 IF PEEK(640) THEN FOR I = 1 TO PEEK(640):P$ = P$ + CHR$( PEEK(640 +I)): NEXT : FOR N = I TO 2 STEP -1: IF MID$ (P$,N,1) < >"/" THEN NEXT
280 IF PEEK(640) AND N >3 THEN P$ = LEFT$(P$,N -1): PRINT D$"PREFIX"P$
290 GOSUB 610: REM BLOAD AppleMate
300 CALL 768:BF = PEEK(7): REM Allocate buffer
310 GOSUB 690: REM Poke in Ampersand vectors
320 GOSUB 710: REM Poke in relocated address
330 GOSUB 720: CALL 776: REM Set up for relocate, do it
340 GOSUB 670: REM BLOAD Macro Table
350 GOSUB 720: POKE 7,BF +1: CALL 776: REM Relocate table
360 GOTO 790: REM All set; exit
390 REM ------- Installer for DOS 3.3
420 IF PEEK(40193) < >149 THEN PRINT : PRINT CHR$(4)"MAXFILES4": POKE 40192,218: POKE 40193,149: PRINT : PRINT CHR$(4)"MAXFILES3"
430 D$ = CHR$(13) + CHR$(4):LA = 16384:BF = 150: POKE 7,BF
440 GOSUB 610: REM BLOAD AppleMate
450 GOSUB 690: REM Poke in Ampersand vectors
460 GOSUB 710: REM Poke in relocated address
470 REM Patch for DOS 3.3
480 POKE LA +55,85: POKE LA +56,170: POKE LA +71,85: POKE LA +72,170
490 POKE LA +77,86: POKE LA +78,170: POKE LA +84,56: POKE LA +85,0
500 POKE LA +89,57: POKE LA +90,0
510 POKE LA +98,32: POKE LA +99,234: POKE LA +100,3
520 GOSUB 720: CALL 776: REM Set up for relocate, do it
530 GOSUB 670: REM BLOAD Macro Table
540 GOSUB 720: POKE 7,BF +1: CALL 776: REM Relocate table
550 GOTO 790: REM All set; exit
580 REM ------- Subroutines
610 PRINT D$"BLOAD APPLEMATE,A"LA: RETURN
620 REM Replace F$ below
630 REM with the name of the
640 REM file you wish to load
650 REM when MACRO.INIT is run.
660 REM
670 F$ = "DEMO.MACROS"
680 PRINT D$"BLOAD "F$",A"LA: RETURN
690 POKE LA +48, PEEK(1014): POKE LA +49, PEEK(1015)
700 POKE 1014,0: POKE 1015,BF: RETURN
710 POKE LA +51,BF: RETURN
720 POKE 9,LA/256: POKE 8,LA -( PEEK(9) *256): POKE 6,0: RETURN
760 REM ------- Exit Routine
790 & MAC
800 HOME : PRINT "AppleMate Installed": PRINT : PRINT "By Chris Chapman"
810 PRINT "Copyright (c) 1990 MindCraft Publ. Corp."
820 PRINT "Concord, MA 01742": NEW
830 REM ------- Error Trap routine
860 VTAB 15: PRINT "Error in setup section. Check to see"
870 PRINT "That all files have been correctly"
880 PRINT "saved and all lines correctly keyed in.": END
890 VTAB 15: POKE 36,13: PRINT "HARDWARE ERROR": POKE 36,3: PRINT "THIS COMPUTER WILL NOT RUN APPLEMATE": END