annotate level1/cmds/mdir.asm @ 851:16b8c7dc0082

Made source comment improvements
author boisy
date Wed, 15 Jan 2003 00:56:21 +0000
parents 19ac91c8dbcf
children 54ebe88fdc10
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
1 ********************************************************************
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
2 * Mdir - Show module directory
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
3 *
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
4 * $Id$
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
5 *
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
6 * Ed. Comments Who YY/MM/DD
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
7 * ------------------------------------------------------------------
200
e9ce43cc215e Made major changes to headers for consistency and identification
boisy
parents: 92
diff changeset
8 * 5 From Tandy OS-9 Level One VR 02.00.00
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
9 * 6 Changed option to -e, optimized slightly BGP 03/01/14
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
10
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
11 nam Mdir
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
12 ttl Show module directory
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
13
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
14 * Disassembled 02/04/05 12:49:18 by Disasm v1.6 (C) 1988 by RML
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
15
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
16 ifp1
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
17 use defsfile
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
18 endc
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
19
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
20 tylg set Prgrm+Objct
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
21 atrv set ReEnt+rev
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
22 rev set $01
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
23 edition set 6
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
24 stdout set 1
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
25
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
26 mod eom,name,tylg,atrv,start,size
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
27
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
28 org 0
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
29 mdstart rmb 2
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
30 mdend rmb 2
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
31 parmptr rmb 2
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
32 u0006 rmb 1
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
33 bufptr rmb 1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
34 u0008 rmb 1
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
35 datebuf rmb 3
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
36 timebuf rmb 3
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
37 u000F rmb 1
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
38 u0010 rmb 1
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
39 narrow rmb 1
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
40 buffer rmb 530
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
41 size equ .
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
42
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
43 name fcs /Mdir/
200
e9ce43cc215e Made major changes to headers for consistency and identification
boisy
parents: 92
diff changeset
44 fcb edition
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
45
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
46 tophead fcb C$LF
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
47 fcc " Module directory at "
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
48 topheadl equ *-tophead
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
49 ltitle fcb C$LF
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
50 fcc "Addr Size Typ Rev Attr Use Module name"
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
51 fcb C$LF
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
52 fcc "---- ---- --- --- ---- --- ------------"
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
53 fcb C$CR
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
54 stitle fcb C$LF
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
55 fcc "Addr Size Ty Rv At Uc Name"
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
56 fcb C$LF
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
57 fcc "---- ---- -- -- -- -- ---------"
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
58 fcb C$CR
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
59
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
60 start stx <parmptr
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
61 ldd #$0C30
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
62 std <u000F
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
63 clr <narrow assume wide output
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
64 lda #stdout standard output
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
65 ldb #SS.ScSiz we need screen size
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
66 os9 I$GetStt get it
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
67 bcc L00D2 branch if we got it
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
68 cmpb #E$UnkSvc not a known service request error?
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
69 lbne Exit if not, exit
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
70 bra L00DF
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
71 L00D2 cmpx #80 80 columns?
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
72 bge L00DF branch if greater or equal to
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
73 inc <narrow
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
74 ldd #$0A15
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
75 std <u000F
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
76 L00DF leax >tophead,pcr
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
77 ldy #topheadl
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
78 lda #stdout
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
79 os9 I$WritLn
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
80 leax datebuf,u
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
81 os9 F$Time
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
82 leax <buffer,u
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
83 stx <bufptr
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
84 leax timebuf,u
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
85 lbsr L0224
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
86 lbsr write
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
87 ldx >D.ModDir
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
88 stx <mdstart
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
89 ldd >D.ModDir+2
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
90 std <mdend
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
91 leax -$04,x
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
92 * Check for 'E' given as argument
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
93 ldy <parmptr
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
94 ldd ,y+
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
95 andb #$DF
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
96 cmpd #$2D45 -E ?
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
97 bne L0157
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
98 tst <narrow
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
99 bne L0123
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
100 leax >ltitle,pcr
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
101 bra L012B
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
102 L0123 leax >stitle,pcr
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
103 L012B ldy #80 max. length to write
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
104 lda #stdout
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
105 os9 I$WritLn
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
106 ldx <mdstart
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
107 lbra L01B9
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
108 loop ldy ,x
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
109 beq L015D
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
110 ldd $04,y
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
111 leay d,y
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
112 lbsr L0205
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
113 L0141 lbsr L01F2
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
114 ldb <u0008
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
115 subb #$12
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
116 cmpb <u0010
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
117 bhi L0154
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
118 L014C subb <u000F
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
119 bhi L014C
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
120 bne L0141
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
121 bra L015D
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
122 L0154 lbsr write
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
123 L0157 leay <buffer,u
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
124 sty <bufptr
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
125 L015D leax $04,x
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
126 cmpx <mdend
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
127 bcs loop
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
128 lbsr write
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
129 bra ExitOk
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
130 *
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
131 * A module entry is 2 two byte pointers.
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
132 * If the first pointer is $0000, then the slot is unused
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
133 L0168 leay <buffer,u
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
134 sty <bufptr
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
135 ldy ,x
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
136 beq gotonxt Is slot unused? If yes, branch
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
137 ldd ,x
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
138 bsr L01C1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
139 ldd $02,y
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
140 bsr L01C1
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
141 tst <narrow
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
142 bne L0181
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
143 bsr L01F2
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
144 L0181 lda $06,y
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
145 bsr L01C9
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
146 tst <narrow
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
147 bne L018B
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
148 bsr L01F2
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
149 L018B lda $07,y
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
150 anda #$0F
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
151 bsr L01C9
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
152 ldb $07,y
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
153 lda #$72
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
154 bsr L01FE
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
155 tst <narrow
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
156 bne L01A7
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
157 lda #$3F
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
158 bsr L01FE
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
159 lda #$3F
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
160 bsr L01FE
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
161 lda #$3F
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
162 bsr L01FE
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
163 L01A7 bsr L01F2
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
164 bsr L01F2
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
165 lda $02,x
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
166 bsr L01C9
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
167 ldd $04,y
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
168 leay d,y
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
169 bsr L0205
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
170 bsr write
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
171 gotonxt leax $04,x
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
172 L01B9 cmpx <mdend
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
173 bcs L0168
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
174
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
175 ExitOk clrb
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
176 Exit os9 F$Exit
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
177
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
178 L01C1 bsr Byt2Hex
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
179 tfr b,a
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
180 bsr L01CF
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
181 bra L01F2
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
182 L01C9 bsr Byt2Hex
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
183 bra L01F2
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
184
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
185 Byt2Hex clr <u0006
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
186 L01CF pshs a
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
187 lsra
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
188 lsra
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
189 lsra
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
190 lsra
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
191 bsr L01DB
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
192 lda ,s+
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
193 anda #$0F
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
194 L01DB tsta
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
195 beq L01E0
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
196 sta <u0006
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
197 L01E0 tst <u0006
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
198 bne L01E8
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
199 lda #C$SPAC
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
200 bra ApndA
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
201 L01E8 adda #'0
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
202 cmpa #'9
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
203 bls ApndA
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
204 adda #$07 Make it A-F
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
205 bra ApndA
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
206 L01F2 lda #$20
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
207 *
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
208 * append a char (in reg a) to buffer
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
209 *
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
210 ApndA pshs x
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
211 ldx <bufptr
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
212 sta ,x+
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
213 stx <bufptr
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
214 puls pc,x
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
215
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
216 L01FE rolb
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
217 bcs ApndA
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
218 lda #'.
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
219 bra ApndA
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
220 L0205 lda ,y
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
221 anda #$7F
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
222 bsr ApndA
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
223 lda ,y+
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
224 bpl L0205
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
225 rts
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
226 *
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
227 * Append a CR to buffer and write it
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
228 *
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
229 write pshs y,x,a
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
230 lda #C$CR
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
231 bsr ApndA
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
232 leax <buffer,u
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
233 ldy #80
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
234 lda #stdout
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
235 os9 I$WritLn
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
236 puls pc,y,x,a
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
237
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
238 L0224 bsr Byt2ASC
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
239 bsr Colon
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
240 Colon lda #':
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
241 bsr ApndA
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
242 Byt2ASC ldb ,x+
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
243 lda #$2F load A with '0 - 1
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
244 Hundreds inca
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
245 subb #100
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
246 bcc Hundreds
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
247 cmpa #'0
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
248 beq Tens no leading zeros
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
249 bsr ApndA
838
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
250 Tens lda #$3A load A with '9 + 1
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
251 TensLoop deca
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
252 addb #10
19ac91c8dbcf Changed option from e to -e, optimized slightly
boisy
parents: 200
diff changeset
253 bcc TensLoop
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
254 bsr ApndA
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
255 tfr b,a
92
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
256 adda #'0
3f67d4e039f0 Some labels changed to relevant names
roug
parents: 15
diff changeset
257 bra ApndA
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
258
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
259 emod
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
260 eom equ *
13
5a5574d54988 Touched up source comments, added mdir to Makefile
boisy
parents: 0
diff changeset
261 end