annotate level1/cmds/verify.asm @ 0:6641a883d6b0

Initial revision
author boisy
date Thu, 04 Apr 2002 16:34:12 +0000
parents
children fed96c42e0b4
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
1 ********************************************************************
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
2 * Verify - Verify a module's CRC
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 * ------------------------------------------------------------------
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
8 * 5 Original Tandy distribution version
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
9
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
10 nam Verify
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
11 ttl Verify a module's CRC
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
12
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
13 * Disassembled 98/09/15 00:03:43 by Disasm v1.6 (C) 1988 by RML
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
14
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
15 ifp1
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
16 use defsfile
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
17 endc
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
18
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
19 tylg set Prgrm+Objct
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
20 atrv set ReEnt+rev
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
21 rev set $01
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
22 edition set 5
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
23
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
24 mod eom,name,tylg,atrv,start,size
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
25
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
26 u0000 rmb 1
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
27 u0001 rmb 1
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
28 u0002 rmb 1
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
29 u0003 rmb 2
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
30 u0005 rmb 1
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
31 u0006 rmb 2
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
32 u0008 rmb 2
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
33 u000A rmb 57
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
34 u0043 rmb 195
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
35 u0106 rmb 1000
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
36 size equ .
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
37
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
38 name fcs /Verify/
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
39 fcb edition
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
40
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
41 start leas >u0106,u
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
42 sts <u0006
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
43 tfr y,d
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
44 subd <u0006
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
45 std <u0008
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
46 clr <u0005
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
47 L0023 lda ,x+
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
48 cmpa #$20
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
49 beq L0023
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
50 anda #$5F
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
51 cmpa #$55
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
52 bne L0031
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
53 inc <u0005
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
54 L0031 ldd #$0009
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
55 std <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
56 lbsr L00F6
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
57 bcs L004D
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
58 cmpy #$0009
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
59 bne L0055
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
60 ldd ,x
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
61 cmpd #$87CD
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
62 bne L0055
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
63 bsr L0059
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
64 bra L0031
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
65 L004D cmpb #$D3
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
66 bne L0052
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
67 clrb
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
68 L0052 os9 F$Exit
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
69 L0055 ldb #$CD
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
70 bra L0052
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
71 L0059 clrb
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
72 lda #$08
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
73 L005C eorb ,x+
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
74 deca
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
75 bne L005C
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
76 lda <u0005
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
77 bne L0079
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
78 eorb ,x
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
79 incb
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
80 beq L0070
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
81 leax >L012F,pcr
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
82 bra L0074
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
83 L0070 leax >L0115,pcr
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
84 L0074 lbsr L010B
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
85 bra L007C
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
86 L0079 comb
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
87 stb ,x
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
88 L007C ldx <u0006
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
89 ldy $02,x
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
90 leay -$03,y
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
91 sty <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
92 ldd #$FFFF
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
93 std <u0000
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
94 stb <u0002
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
95 bsr L00D6
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
96 lda <u0005
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
97 bne L00B6
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
98 ldd #$0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
99 std <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
100 bsr L00D6
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
101 lda <u0000
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
102 cmpa #$80
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
103 bne L00A8
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
104 ldd <u0001
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
105 cmpd #$0FE3
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
106 beq L00AE
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
107 L00A8 leax >L015C,pcr
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
108 bra L00B2
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
109 L00AE leax >L014C,pcr
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
110 L00B2 bsr L010B
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
111 bra L00CF
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
112 L00B6 com <u0000
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
113 com <u0001
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
114 com <u0002
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
115 lda #$01
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
116 leax ,u
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
117 ldy #$0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
118 os9 I$Write
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
119 bcs L0052
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
120 clra
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
121 os9 I$Read
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
122 bcs L0052
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
123 L00CF rts
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
124 L00D0 bsr L00F6
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
125 lbcs L0052
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
126 L00D6 ldy <u000A
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
127 beq L00D0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
128 os9 F$CRC
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
129 lda <u0005
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
130 beq L00EB
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
131 lda #$01
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
132 os9 I$Write
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
133 lbcs L0052
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
134 L00EB ldd <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
135 subd <u000A
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
136 std <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
137 bne L00D0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
138 std <u000A
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
139 rts
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
140 L00F6 clra
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
141 ldx <u0006
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
142 ldy <u0008
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
143 cmpy <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
144 bls L0104
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
145 ldy <u0003
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
146 L0104 os9 I$Read
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
147 sty <u000A
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
148 rts
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
149 L010B lda #$02
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
150 ldy #$0050
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
151 os9 I$WritLn
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
152 rts
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
153 L0115 fcc "Header parity is correct."
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
154 fcb C$CR
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
155 L012F fcc "Header parity is INCORRECT !"
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
156 fcb C$CR
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
157 L014C fcc "CRC is correct."
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
158 fcb C$CR
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
159 L015C fcc "CRC is INCORRECT !"
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
160 fcb C$CR
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
161
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
162 emod
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
163 eom equ *
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
164 end