-
Notifications
You must be signed in to change notification settings - Fork 85
/
Copy pathmon.pars
88 lines (88 loc) · 1.15 KB
/
mon.pars
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
.PAGE 'MON.PARS'
;
;
;
; PARSER FOR THE MONITOR
;
PARMS LDA #0 ; DEFAULT ERROR RECOVERY ATTEMPTS OF 0
STA RECOV
;
PAR002 JSR BASIN ;GET NEXT CHAR
CMP #SPC ; IGNORE SPACE
BEQ PAR002
CMP #', ; IGNORE ,
BEQ PAR002
CMP #CR ; END OF LINE
BNE PAR005
RTS
;
PAR005 LDX #NUMPRM-1 ; PARM LOOKUP INDEX
PAR003 CMP PRMTBL,X ; TEST IF PARM LETTER
BNE PAR004 ; NOPE
;
TXA ; YES GET VAR. ADDRESS
ASL A
TAX
;
LDA PRMADR,X
STA PRMPTR
LDA PRMADR+1,X
STA PRMPTR+1
;
JSR RDOB ; GET THE VALUE
;
LDY #0 ; STORE TWO BYTE VALUE
STA (PRMPTR),Y
JMP PAR002
;
PAR004 DEX
BPL PAR003 ; TEST IF DONE
;
JMP ERROR ; BAD COMMAND
;
;
; *GETADR
;
; CHECK FOR ' ' OR ','
;
; THEN READ HEX ADDRESS
;
;
GETADR JSR SYNCHK ; TEST FOR SPC OR ,
JMP RDOA ;GET ADR
;
;
SYNCHK JSR RDOC ; GET CHAR
CMP #SPC
BEQ SYNC10 ; OK
;
CMP #',
BEQ SYNC10 ; OK
;
JMP ERROR ; BAD SYNTAXXX
;
SYNC10 RTS
;
;
;
;
;
;
;
;
PRMTBL .BYTE 'TSDJR'
;
; T: TRACK
; S: SECTOR
; D: DRIVE
; J: JOB #
; R: ROCOVERY
;
PRMADR .WORD TRACK
.WORD SECTOR
.WORD DRIVE
.WORD JOBNUM
.WORD RECOV
;
;
.END