Mercurial > hg > Members > kono > nitros9-code
annotate level1/cmds/verify.asm @ 474:31ce96b2dc9d
entered: chdir chmod qsort strass toupper tsleep wait
author | roug |
---|---|
date | Sun, 06 Oct 2002 09:10:36 +0000 |
parents | e9ce43cc215e |
children | 00afdd6aeb1f |
rev | line source |
---|---|
0 | 1 ******************************************************************** |
2 * Verify - Verify a module's CRC | |
3 * | |
4 * $Id$ | |
5 * | |
6 * Ed. Comments Who YY/MM/DD | |
7 * ------------------------------------------------------------------ | |
200
e9ce43cc215e
Made major changes to headers for consistency and identification
boisy
parents:
161
diff
changeset
|
8 * 5 From Tandy OS-9 Level One VR 02.00.00 |
0 | 9 |
10 nam Verify | |
11 ttl Verify a module's CRC | |
12 | |
13 * Disassembled 98/09/15 00:03:43 by Disasm v1.6 (C) 1988 by RML | |
14 | |
15 ifp1 | |
16 use defsfile | |
17 endc | |
18 | |
19 tylg set Prgrm+Objct | |
20 atrv set ReEnt+rev | |
21 rev set $01 | |
22 edition set 5 | |
23 | |
24 mod eom,name,tylg,atrv,start,size | |
25 | |
26 u0000 rmb 1 | |
27 u0001 rmb 1 | |
28 u0002 rmb 1 | |
29 u0003 rmb 2 | |
30 u0005 rmb 1 | |
31 u0006 rmb 2 | |
32 u0008 rmb 2 | |
33 u000A rmb 57 | |
34 u0043 rmb 195 | |
35 u0106 rmb 1000 | |
36 size equ . | |
37 | |
38 name fcs /Verify/ | |
39 fcb edition | |
40 | |
41 start leas >u0106,u | |
42 sts <u0006 | |
43 tfr y,d | |
44 subd <u0006 | |
45 std <u0008 | |
46 clr <u0005 | |
47 L0023 lda ,x+ | |
161
fed96c42e0b4
The files that are the same between level2 and level2v3 have been
roug
parents:
0
diff
changeset
|
48 cmpa #C$SPAC |
0 | 49 beq L0023 |
50 anda #$5F | |
51 cmpa #$55 | |
52 bne L0031 | |
53 inc <u0005 | |
54 L0031 ldd #$0009 | |
55 std <u0003 | |
56 lbsr L00F6 | |
57 bcs L004D | |
58 cmpy #$0009 | |
59 bne L0055 | |
60 ldd ,x | |
161
fed96c42e0b4
The files that are the same between level2 and level2v3 have been
roug
parents:
0
diff
changeset
|
61 cmpd #M$ID12 |
0 | 62 bne L0055 |
63 bsr L0059 | |
64 bra L0031 | |
161
fed96c42e0b4
The files that are the same between level2 and level2v3 have been
roug
parents:
0
diff
changeset
|
65 L004D cmpb #E$EOF |
0 | 66 bne L0052 |
67 clrb | |
68 L0052 os9 F$Exit | |
161
fed96c42e0b4
The files that are the same between level2 and level2v3 have been
roug
parents:
0
diff
changeset
|
69 L0055 ldb #M$ID2 |
0 | 70 bra L0052 |
71 L0059 clrb | |
72 lda #$08 | |
73 L005C eorb ,x+ | |
74 deca | |
75 bne L005C | |
76 lda <u0005 | |
77 bne L0079 | |
78 eorb ,x | |
79 incb | |
80 beq L0070 | |
81 leax >L012F,pcr | |
82 bra L0074 | |
83 L0070 leax >L0115,pcr | |
84 L0074 lbsr L010B | |
85 bra L007C | |
86 L0079 comb | |
87 stb ,x | |
88 L007C ldx <u0006 | |
89 ldy $02,x | |
90 leay -$03,y | |
91 sty <u0003 | |
92 ldd #$FFFF | |
93 std <u0000 | |
94 stb <u0002 | |
95 bsr L00D6 | |
96 lda <u0005 | |
97 bne L00B6 | |
98 ldd #$0003 | |
99 std <u0003 | |
100 bsr L00D6 | |
101 lda <u0000 | |
102 cmpa #$80 | |
103 bne L00A8 | |
104 ldd <u0001 | |
105 cmpd #$0FE3 | |
106 beq L00AE | |
107 L00A8 leax >L015C,pcr | |
108 bra L00B2 | |
109 L00AE leax >L014C,pcr | |
110 L00B2 bsr L010B | |
111 bra L00CF | |
112 L00B6 com <u0000 | |
113 com <u0001 | |
114 com <u0002 | |
115 lda #$01 | |
116 leax ,u | |
117 ldy #$0003 | |
118 os9 I$Write | |
119 bcs L0052 | |
120 clra | |
121 os9 I$Read | |
122 bcs L0052 | |
123 L00CF rts | |
124 L00D0 bsr L00F6 | |
125 lbcs L0052 | |
126 L00D6 ldy <u000A | |
127 beq L00D0 | |
128 os9 F$CRC | |
129 lda <u0005 | |
130 beq L00EB | |
131 lda #$01 | |
132 os9 I$Write | |
133 lbcs L0052 | |
134 L00EB ldd <u0003 | |
135 subd <u000A | |
136 std <u0003 | |
137 bne L00D0 | |
138 std <u000A | |
139 rts | |
140 L00F6 clra | |
141 ldx <u0006 | |
142 ldy <u0008 | |
143 cmpy <u0003 | |
144 bls L0104 | |
145 ldy <u0003 | |
146 L0104 os9 I$Read | |
147 sty <u000A | |
148 rts | |
149 L010B lda #$02 | |
150 ldy #$0050 | |
151 os9 I$WritLn | |
152 rts | |
153 L0115 fcc "Header parity is correct." | |
154 fcb C$CR | |
155 L012F fcc "Header parity is INCORRECT !" | |
156 fcb C$CR | |
157 L014C fcc "CRC is correct." | |
158 fcb C$CR | |
159 L015C fcc "CRC is INCORRECT !" | |
160 fcb C$CR | |
161 | |
162 emod | |
163 eom equ * | |
164 end |