2824
|
1 * Disassembly by Os9disasm of putc.r
|
|
2
|
|
3 section code
|
|
4
|
|
5 putc: pshs u
|
|
6 ldu 6,s
|
|
7 ldd 6,u
|
|
8 anda #$80
|
|
9 andb #$22
|
|
10 cmpb #2
|
|
11 bne L0046
|
|
12 cmpa #$80
|
|
13 beq L0019
|
|
14 pshs u
|
|
15 lbsr _setbase
|
|
16 leas 2,s
|
|
17 L0019 ldd 6,u
|
|
18 andb #4
|
|
19 beq L004b
|
|
20 ldd #1
|
|
21 pshs d
|
|
22 leax 7,s
|
|
23 ldd 8,u
|
|
24 pshs d,x
|
|
25 ldb 7,u
|
|
26 andb #$40
|
|
27 beq L0035
|
|
28 lbsr writeln
|
|
29 bra L0038
|
|
30 L0035 lbsr write
|
|
31 L0038 leas 6,s
|
|
32 cmpd #-1
|
|
33 bne L0079
|
|
34 ldb 7,u
|
|
35 orb #$20
|
|
36 stb 7,u
|
|
37 L0046 ldd #-1
|
|
38 puls u,pc
|
|
39 L004b anda #1
|
|
40 bne L0058
|
|
41 pshs u
|
|
42 lbsr L00fd
|
|
43 std ,s++
|
|
44 bne L0046
|
|
45 L0058 ldx ,u
|
|
46 ldb 5,s
|
|
47 stb ,x+
|
|
48 stx ,u
|
|
49 cmpx 4,u
|
|
50 bcc L0070
|
|
51 ldb 7,u
|
|
52 andb #$40
|
|
53 beq L0079
|
|
54 ldb 5,s
|
|
55 cmpb #$0d
|
|
56 bne L0079
|
|
57 L0070 pshs u
|
|
58 lbsr L00fd
|
|
59 std ,s++
|
|
60 bne L0046
|
|
61 L0079 ldd 4,s
|
|
62 puls u,pc
|
|
63 putw: pshs u
|
|
64 ldu 6,s
|
|
65 ldb 4,s
|
|
66 pshs d,u
|
|
67 lbsr putc
|
|
68 ldb 9,s
|
|
69 stb 1,s
|
|
70 lbsr putc
|
|
71 leas 4,s
|
|
72 puls u,pc
|
|
73 _tidyup: pshs u
|
|
74 leax _iob,y
|
|
75 ldb #$10
|
|
76 pshs b
|
|
77 L009d pshs x
|
|
78 bsr fclose
|
|
79 puls x
|
|
80 leax 13,x
|
|
81 dec ,s
|
|
82 bne L009d
|
|
83 puls b,u,pc
|
|
84 fclose: pshs u
|
|
85 ldu 4,s
|
|
86 lbeq L0046
|
|
87 ldd 6,u
|
|
88 lbeq L0046
|
|
89 andb #2
|
|
90 beq L00c5
|
|
91 pshs u
|
|
92 bsr fflush
|
|
93 leas 2,s
|
|
94 bra L00c7
|
|
95 L00c5 clra
|
|
96 clrb
|
|
97 L00c7 pshs d
|
|
98 ldd 8,u
|
|
99 pshs d
|
|
100 lbsr close
|
|
101 leas 2,s
|
|
102 clra
|
|
103 clrb
|
|
104 std 6,u
|
|
105 puls d,u,pc
|
|
106 fflush: pshs u
|
|
107 ldu 4,s
|
|
108 lbeq L0046
|
|
109 ldd 6,u
|
|
110 andb #$22
|
|
111 cmpb #2
|
|
112 lbne L0046
|
|
113 anda #$80
|
|
114 bne L00f5
|
|
115 pshs u
|
|
116 lbsr _setbase
|
|
117 leas 2,s
|
|
118 L00f5 pshs u
|
|
119 bsr L00fd
|
|
120 leas 2,s
|
|
121 puls u,pc
|
|
122 L00fd pshs u
|
|
123 ldu 4,s
|
|
124 leas -4,s
|
|
125 lda 6,u
|
|
126 anda #1
|
|
127 bne L012c
|
|
128 ldd ,u
|
|
129 cmpd 4,u
|
|
130 beq L012c
|
|
131 clra
|
|
132 clrb
|
|
133 pshs d
|
|
134 pshs u
|
|
135 lbsr ftell
|
|
136 leas 2,s
|
|
137 ldd 2,x
|
|
138 pshs d
|
|
139 ldd ,x
|
|
140 pshs d
|
|
141 ldd 8,u
|
|
142 pshs d
|
|
143 lbsr lseek
|
|
144 leas 8,s
|
|
145 L012c ldd ,u
|
|
146 subd 2,u
|
|
147 std 2,s
|
|
148 lbeq L0194
|
|
149 ldd 6,u
|
|
150 anda #1
|
|
151 lbeq L0194
|
|
152 andb #$40
|
|
153 beq L016f
|
|
154 ldd 2,u
|
|
155 bra L0167
|
|
156 L0146 pshs d
|
|
157 ldd ,u
|
|
158 pshs d
|
|
159 ldd 8,u
|
|
160 pshs d
|
|
161 lbsr writeln
|
|
162 leas 6,s
|
|
163 std ,s
|
|
164 cmpd #-1
|
|
165 beq L0185
|
|
166 ldd 2,s
|
|
167 subd ,s
|
|
168 std 2,s
|
|
169 ldd ,u
|
|
170 addd ,s
|
|
171 L0167 std ,u
|
|
172 ldd 2,s
|
|
173 bne L0146
|
|
174 bra L0194
|
|
175 L016f ldd 2,s
|
|
176 pshs d
|
|
177 ldd 2,u
|
|
178 pshs d
|
|
179 ldd 8,u
|
|
180 pshs d
|
|
181 lbsr write
|
|
182 leas 6,s
|
|
183 cmpd 2,s
|
|
184 beq L0194
|
|
185 L0185 ldb 7,u
|
|
186 orb #$20
|
|
187 stb 7,u
|
|
188 ldd 4,u
|
|
189 std ,u
|
|
190 ldd #-1
|
|
191 bra L01a4
|
|
192 L0194 lda 6,u
|
|
193 ora #1
|
|
194 sta 6,u
|
|
195 ldd 2,u
|
|
196 std ,u
|
|
197 addd 11,u
|
|
198 std 4,u
|
|
199 clra
|
|
200 clrb
|
|
201 L01a4 leas 4,s
|
|
202 puls u,pc
|
|
203
|
|
204 endsect
|
|
205
|