Mercurial > hg > Members > kono > nitros9-code
annotate level1/cmds/help.asm @ 2758:e4a0f58a5f9b
Found that people who do not have the envirornment variable NITROS9DIR set before building the project get a error missing file "/rules.mak". Found this is caused do to the fact that the code to set this envirornment variable is in the rules.mak which can't get loaded.
To fix this the code needed to set the envirornment variable that is in the rules.mak is now in the makefile(s) right before the include for the rules.mak file. This should fix the problem for those who do not have the NITROS9DIR envirornment variable preset.
author | drencor-xeen |
---|---|
date | Mon, 14 Jan 2013 14:37:46 -0600 |
parents | 04b3b0436d6b |
children |
rev | line source |
---|---|
1351
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
1 ******************************************************************** |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
2 * Help - Show help |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
3 * |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
4 * $Id$ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
5 * |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
6 * Edt/Rev YYYY/MM/DD Modified by |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
7 * Comment |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
8 * ------------------------------------------------------------------ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
9 * 6 2003/01/21 Boisy G. Pitre |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
10 * |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
11 * 7 2003/05/30 Rodney V. Hamilton |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
12 * Fixed showlist partial line bug, do auto list. |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
13 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
14 nam Help |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
15 ttl Show help |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
16 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
17 ifp1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
18 use defsfile |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
19 endc |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
20 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
21 COLWIDTH set 10 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
22 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
23 tylg set Prgrm+Objct |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
24 atrv set ReEnt+rev |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
25 rev set $00 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
26 edition set 7 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
27 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
28 mod eom,name,tylg,atrv,start,size |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
29 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
30 name fcs /Help/ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
31 fcb edition |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
32 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
33 org 0 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
34 exitvec rmb 2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
35 ncols rmb 1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
36 colcopy rmb 1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
37 bufptr rmb 2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
38 path rmb 1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
39 same rmb 1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
40 prmptr rmb 2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
41 prmend rmb 2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
42 length rmb 2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
43 colbuff rmb 128 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
44 userbuf rmb 128 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
45 parbuff rmb 256 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
46 filbuff rmb 256 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
47 stack rmb 350 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
48 size equ . |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
49 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
50 * Ask user for subjects |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
51 askuser leax askusr2,pcr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
52 stx <exitvec |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
53 leax prompt1,pcr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
54 lda #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
55 ldy #128 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
56 os9 I$WritLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
57 * Show topics (if user enters nothing at prompt) |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
58 showlist lda #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
59 leax >avail,pcr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
60 ldy #128 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
61 os9 I$WritLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
62 lbsr seek0 rewind the file |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
63 bra resetcl |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
64 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
65 doeol sty <bufptr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
66 lda #C$CR |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
67 sta ,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
68 leax colbuff,u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
69 lda #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
70 ldy #128 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
71 os9 I$WritLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
72 resetcl lda <ncols |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
73 sta <colcopy |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
74 leax colbuff,u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
75 stx <bufptr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
76 readlp lbsr readlin |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
77 bcc readlp2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
78 lda <colcopy check for partial line |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
79 cmpa <ncols |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
80 blt doeol and print it |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
81 askusr2 leax prompt2,pcr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
82 lda #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
83 ldy #prompt2l |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
84 os9 I$Write |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
85 clra |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
86 ldy #127 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
87 leax userbuf,u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
88 os9 I$ReadLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
89 lbcs exiteof |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
90 lda ,x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
91 cmpa #C$CR |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
92 beq showlist |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
93 lbsr seek0 rewind the file |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
94 lbra entrya |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
95 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
96 readlp2 leax filbuff,u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
97 lda ,x+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
98 cmpa #'@ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
99 bne readlp |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
100 ldy <bufptr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
101 strcpy clra |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
102 clrb |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
103 pshs d |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
104 strc0 lda ,x+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
105 cmpa #C$SPAC |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
106 ble strc1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
107 sta ,y+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
108 ldd ,s |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
109 addd #$0001 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
110 std ,s |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
111 bra strc0 do again |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
112 strc1 puls d |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
113 dec <colcopy |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
114 beq doeol |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
115 cmpb #COLWIDTH |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
116 bge onesp |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
117 pshs b |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
118 ldb #COLWIDTH |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
119 subb ,s+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
120 fcb $8C |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
121 onesp ldb #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
122 lda #C$SPAC |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
123 spacelp sta ,y+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
124 decb |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
125 bne spacelp |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
126 sty <bufptr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
127 bra readlp |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
128 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
129 start pshs d,x,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
130 lda #8 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
131 sta <ncols assume 8 columns |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
132 lda #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
133 ldb #SS.ScSiz |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
134 os9 I$GetStt |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
135 bcs start2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
136 cmpx #9 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
137 ble start1 A = 1 here |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
138 tfr x,d |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
139 clra |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
140 * Divide screen X by COLWIDTH to determine number of columns |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
141 Div10 subb #COLWIDTH |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
142 bcs start1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
143 inca |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
144 bra Div10 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
145 start1 sta <ncols |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
146 start2 leax exit,pcr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
147 stx <exitvec |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
148 puls d,x,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
149 tfr d,y length of parameters |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
150 open pshs x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
151 leax helpfile,pcr point to file name |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
152 lda #READ. read mode |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
153 os9 I$Open |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
154 puls x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
155 bcs exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
156 sta <path store path number |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
157 cmpy #$0001 no parameters? |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
158 lbeq askuser |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
159 entrya pshs u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
160 leau parbuff,u point to buffer |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
161 entry0 lda ,x+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
162 cmpa #C$SPAC is it a space (between parameters?) |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
163 beq entry1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
164 cmpa #C$CR |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
165 bne nocr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
166 entry1 clra yes, null it |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
167 nocr sta ,u+ store in buffer |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
168 leay -1,y decrement length counter |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
169 bne entry0 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
170 clr ,u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
171 tfr u,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
172 puls u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
173 sty <prmend store end of all parameters |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
174 leax parbuff,u load address of parbuff into X |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
175 stx <prmptr save parameter pointer |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
176 entry2 lda ,x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
177 bne strlen |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
178 leax 1,x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
179 bra rered2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
180 strlen pshs x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
181 ldy #0 initialise count |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
182 strl0 lda ,x+ is it a char > null |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
183 cmpa #C$SPAC |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
184 ble strl1 nope, exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
185 leay 1,y yep, increment count |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
186 bra strl0 do again |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
187 strl1 puls x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
188 sty <length store it |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
189 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
190 reread bsr readlin read line from helpfile file |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
191 bcc rered0 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
192 cmpb #E$EOF did we find end-of-file? |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
193 lbeq unknown yep, tell user we don't know his command |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
194 rered0 bsr compare compare user number with 1st 3 chars of line |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
195 beq reread compare returns 0 if failed |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
196 bsr print else go print the helpfile line |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
197 bcc rered1 exit if I$WritLn problem |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
198 cmpb #E$EOF |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
199 bcs exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
200 rered1 ldd <length get length |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
201 ldx prmptr get parameter pointer |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
202 leax d,x add length to it |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
203 leax 1,x increment past null byte |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
204 rered2 clrb |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
205 cmpx <prmend |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
206 blt rered25 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
207 jmp [exitvec,u] |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
208 rered25 stx <prmptr store it |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
209 rered3 lbsr seek0 rewind the file |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
210 bra entry2 loop around again |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
211 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
212 exiteof cmpb #E$EOF |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
213 bne exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
214 exitok clrb |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
215 exit os9 F$Exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
216 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
217 readlin pshs x,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
218 lda <path get file path number |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
219 ldy #256 read max 256 bytes |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
220 leax filbuff,u into memory pointed to by filbuff |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
221 os9 I$ReadLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
222 puls x,y,pc |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
223 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
224 print pshs x,y,a |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
225 print2 bsr readlin |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
226 bcs printout |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
227 print3 lda ,x |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
228 cmpa #'@ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
229 beq printout |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
230 lda #1 STDOUT |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
231 leax filbuff,u into memory pointed to by filbuff |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
232 ldy #256 max of 256 chars |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
233 os9 I$WritLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
234 bra print2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
235 printout lda #1 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
236 leax return,pcr |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
237 ldy #256 max of 256 chars |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
238 os9 I$WritLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
239 puls x,y,a,pc |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
240 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
241 compare pshs x,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
242 clr <same comparison indicator |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
243 leay filbuff,u point to file buffer |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
244 lda ,y+ get first char |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
245 cmpa #'@ @ sign? |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
246 bne comp2 branch if not |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
247 ldx prmptr get address of next cmd line param |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
248 comp0 lda ,x+ get char from cmd line |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
249 beq comp1 is it null (end of param) |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
250 ldb ,y+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
251 anda #$DF |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
252 andb #$DF |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
253 pshs a |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
254 cmpb ,s+ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
255 bne comp2 not same, exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
256 inc <same yep, in comparison counter |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
257 bra comp0 'round again |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
258 comp1 lda ,y |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
259 cmpa #C$CR was it end of string in helpfile file? |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
260 bne comp2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
261 tst <same test indicator |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
262 puls x,y,pc |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
263 comp2 clr <same clear the counter |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
264 puls x,y,pc |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
265 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
266 unknown ldx prmptr put pointer into parameter buffer in X |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
267 lda #1 STDOUT |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
268 ldy <length get length of user's param |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
269 os9 I$Write |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
270 bcs exit |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
271 leax unkmsg,pcr point to message |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
272 ldy #unkmsgl num of chars to print |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
273 lda #1 to STDOUT |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
274 os9 I$WritLn |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
275 lbcs exit exit if problem with I$Write |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
276 ldx prmptr put point into parameter buffer in X |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
277 ldd <length get length of user's param |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
278 leax d,x add to X |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
279 leax 1,x increment past null byte |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
280 clrb |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
281 cmpx prmend |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
282 blt unk2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
283 jmp [exitvec,u] |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
284 unk2 stx <prmptr store X |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
285 bsr seek0 rewind file |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
286 lbra entry2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
287 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
288 seek0 pshs x,u |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
289 lda <path |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
290 ldx #0 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
291 ldu #0 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
292 os9 I$Seek |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
293 puls x,u,pc |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
294 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
295 helpfile fcc "/DD/SYS/helpmsg" |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
296 fcb 0 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
297 unkmsg fcc /: no help available/ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
298 return fcb C$CR |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
299 unkmsgl equ *-unkmsg |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
300 prompt1 fcc /Hit [ESC] to exit/ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
301 fcb C$CR |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
302 prompt2 fcc /What Subject(s)? / |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
303 prompt2l equ *-prompt2 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
304 avail fcc /Help available on:/ |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
305 fcb C$CR |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
306 |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
307 emod |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
308 eom equ * |
04b3b0436d6b
Fixed line-ending issue in help.asm, added new style header
boisy
parents:
1325
diff
changeset
|
309 end |