annotate level1/modules/boot_1773.asm @ 1296:fe008d68f79b

Added comment from Robert Gault, changed $FF4X to DPort
author boisy
date Mon, 01 Sep 2003 12:08:12 +0000
parents cbe5b5313422
children 66b40fd73c53
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
1 ********************************************************************
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
2 * Boot - WD1773 Boot module
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
3 *
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
4 * $Id$
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
5 *
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
6 * Edt/Rev YYYY/MM/DD Modified by
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
7 * Comment
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
8 * ------------------------------------------------------------------
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
9 * 4 1985/??/??
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
10 * Original Tandy distribution version.
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
11 *
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
12 * 6 1998/10/12 Boisy G. Pitre
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
13 * Obtained from L2 Upgrade archive, has 6ms step rate and disk timeout
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
14 * changes.
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
15 *
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
16 * 6r2 2003/05/18 Boisy G. Pitre
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
17 * Added '.' output for each sector for OS-9 L2 and NitrOS9 for
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
18 * Mark Marlette (a special request :).
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
19 *
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
20 * 6r3 2003/08/31 Robert Gault
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
21 * Put BLOB-stop code in place, changed orb #$30 to orb #$28
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
22
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
23 nam Boot
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
24 ttl WD1773 Boot module
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
25
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
26 IFP1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
27 use defsfile
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
28 use rbfdefs
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
29 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
30
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
31 * Step Rate:
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
32 * $00 = 6ms
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
33 * $01 =
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
34 * $02 =
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
35 * $03 = 30ms
1213
4e235f213651 Lots of changes: bootscripts and bootlists added, sources massaged...
boisy
parents: 1166
diff changeset
36 STEP set $00
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
37
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
38 tylg set Systm+Objct
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
39 atrv set ReEnt+rev
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
40 rev set $03
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
41 edition set 6
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
42
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
43 mod eom,name,tylg,atrv,start,size
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
44
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
45 u0000 rmb 2
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
46 u0002 rmb 2
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
47 u0004 rmb 1
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
48 u0005 rmb 1
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
49 u0006 rmb 1
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
50 u0007 rmb 1
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
51 u0008 rmb 1
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
52 u0009 rmb 1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
53 size equ .
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
54
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
55 name fcs /Boot/
230
3d2fa54fe8fb Source changes
boisy
parents: 210
diff changeset
56 fcb edition
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
57
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
58 start clra clear A
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
59 ldb #size get our 'stack' size
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
60 MakeStak pshs a save 0 on stack
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
61 decb and continue...
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
62 bne MakeStak until we've created our stack
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
63
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
64 tfr s,u put 'stack statics' in U
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
65 ldx #DPort+8
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
66 lda #$D0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
67 sta ,x
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
68 lbsr L01AA
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
69 lda ,x
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
70 lda #$FF
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
71 sta u0004,u
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
72 leax >NMIRtn,pcr
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
73 IFGT Level-1
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
74 stx <D.NMI
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
75 lda #$09
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
76 ELSE
1213
4e235f213651 Lots of changes: bootscripts and bootlists added, sources massaged...
boisy
parents: 1166
diff changeset
77 stx >D.XNMI+1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
78 lda #$7E
1213
4e235f213651 Lots of changes: bootscripts and bootlists added, sources massaged...
boisy
parents: 1166
diff changeset
79 sta >D.XNMI
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
80 lda #$08
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
81 ENDC
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
82 sta >DPort
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
83
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
84 * delay loop
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
85 IFGT Level-1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
86 ldd #$C350
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
87 ELSE
249
30655a7845f7 Cut delay in half
boisy
parents: 230
diff changeset
88 ldd #$61A8
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
89 ENDC
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
90 IFNE NitrOS9
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
91 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
92 ENDC
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
93 L003A nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
94 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
95 IFNE NitrOS9
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
96 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
97 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
98 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
99 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
100 subd #$0001
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
101 bne L003A
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
102
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
103 * search for a free page (to use as a 256 byte disk buffer)
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
104 pshs u,y,x,b,a
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
105 ldd #$0001
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
106 os9 F$SRqMem
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
107 bcs L00AA
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
108 tfr u,d
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
109 ldu $06,s
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
110 std u0002,u
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
111 clrb
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
112
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
113 * go get LSN0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
114 ldx #$0000
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
115 bsr ReadSect
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
116 bcs L00AA
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
117
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
118 * get bootfile size from LSN0 and allocate memory for it
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
119 ldd DD.TOT+1,y
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
120 std u0007,u
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
121 lda <DD.FMT,y
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
122 sta u0005,u
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
123 anda #$01
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
124 sta u0008,u
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
125 lda DD.TKS,y
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
126 sta u0006,u
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
127 ldd <DD.BSZ,y
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
128 std ,s
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
129 ldx <DD.BT+1,y
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
130 pshs x
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
131 ldd #256
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
132 ldu u0002,u
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
133 os9 F$SRtMem
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
134 ldd $02,s
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
135 IFGT Level-1
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
136 os9 F$BtMem
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
137 ELSE
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
138 os9 F$SRqMem
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
139 ENDC
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
140 puls x
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
141 bcs L00AA
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
142 stu $02,s
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
143 ldu $06,s
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
144 ldd $02,s
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
145 std u0002,u
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
146 ldd ,s
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
147 beq L00A3
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
148
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
149 * this loop reads a sector at a time from the bootfile
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
150 L0091 pshs x,b,a
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
151 clrb
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
152 bsr ReadSect
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
153 bcs L00A8
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
154 IFGT Level-1
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
155 lda #'. dump out a period for boot debugging
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
156 jsr <D.BtBug do the debug stuff
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
157 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
158 puls x,b,a
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
159 inc u0002,u
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
160 leax 1,x
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
161 subd #256
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
162 bhi L0091
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
163 L00A3 clrb
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
164 puls b,a
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
165 bra L00AC
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
166 L00A8 leas $04,s
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
167 L00AA leas $02,s
1295
cbe5b5313422 Removed poke to FFD9 for CoCo 3 since this is done by rel
boisy
parents: 1291
diff changeset
168 L00AC puls u,y,x
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
169 leas size,s clean up stack
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
170 clr >DPort shut off floppy disk
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
171 rts
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
172
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
173 L00B7 lda #$29
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
174 sta ,u
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
175 clr u0004,u
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
176 lda #$05
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
177 lbsr L0170
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
178 ldb #STEP
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
179 lbra L0195
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
180
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
181 * Read a sector from the 1773
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
182 * Entry: X = LSN to read
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
183 ReadSect lda #$91
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
184 cmpx #$0000 LSN0?
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
185 bne L00DF
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
186 bsr L00DF
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
187 bcs L00D6
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
188 ldy u0002,u
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
189 clrb
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
190 L00D6 rts
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
191
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
192 L00D7 bcc L00DF
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
193 pshs x,b,a
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
194 bsr L00B7
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
195 puls x,b,a
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
196 L00DF pshs x,b,a
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
197 bsr L00EA
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
198 puls x,b,a
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
199 bcc L00D6
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
200 lsra
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
201 bne L00D7
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
202 L00EA bsr L013C
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
203 bcs L00D6
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
204 ldx u0002,u
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
205 orcc #IntMasks
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
206 pshs y
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
207 ldy #$FFFF
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
208 ldb #$80
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
209 stb >DPort+8
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
210 ldb ,u
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
211 * Notes on the next line:
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
212 * The byte in question comes after telling the controller that it should
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
213 * read a sector. RegB is then loaded (ldb ,u) which means it is set to $29
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
214 * (%00101001) or the default boot drive if sub L00B7 has been run. At this
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
215 * point an orb #$30 or orb #%00110000 means that write precomp and double
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
216 * density flags are or'd in. This does not make any sense at all for a
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
217 * read command. I suppose the command may not even be needed but $28 just
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
218 * ensures that motor on and double density are set.
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
219 orb #$28 was $30 which RG thinks is an error
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
220 tst u0009,u
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
221 beq L0107
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
222 orb #$40
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
223 L0107 stb >DPort
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
224 lbsr L01AA
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
225 orb #$80
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
226 * lda #$02
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
227 *L0111 bita >DPort+8
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
228 * bne L0123
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
229 * leay -$01,y
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
230 * bne L0111
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
231 * lda ,u
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
232 * sta >DPort
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
233 * puls y
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
234 * bra L0138
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
235 stb >DPort
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
236 nop
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
237 nop
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
238 bra L0123
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
239 L0123 lda >DPort+$0B
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
240 sta ,x+
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
241 * stb >DPort
1291
92e9f7416fc9 Added BLOB-stop fix, changed one line as per Robert Gault's suggestion
boisy
parents: 1287
diff changeset
242 nop
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
243 bra L0123
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
244
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
245 NMIRtn leas R$Size,s
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
246 puls y
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
247 ldb >DPort+8
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
248 bitb #$04
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
249 beq L018F
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
250 L0138 comb
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
251 ldb #E$Read
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
252 rts
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
253
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
254 L013C lda #$09
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
255 sta ,u
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
256 clr u0009,u
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
257 tfr x,d
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
258 cmpd #$0000
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
259 beq L016C
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
260 clr ,-s
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
261 tst u0008,u
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
262 beq L0162
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
263 bra L0158
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
264 L0152 com u0009,u
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
265 bne L0158
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
266 inc ,s
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
267 L0158 subb u0006,u
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
268 sbca #$00
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
269 bcc L0152
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
270 bra L0168
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
271 L0160 inc ,s
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
272 L0162 subb u0006,u
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
273 sbca #$00
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
274 bcc L0160
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
275 L0168 addb #$12
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
276 puls a
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
277 L016C incb
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
278 stb >DPort+$0A
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
279 L0170 ldb u0004,u
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
280 stb >DPort+$09
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
281 cmpa u0004,u
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
282 beq L018D
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
283 sta u0004,u
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
284 sta >DPort+$0B
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
285 ldb #$10+STEP
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
286 bsr L0195
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
287 pshs x
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
288 ldx #$222E
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
289 L0187 leax -$01,x
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
290 bne L0187
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
291 puls x
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
292 L018D clrb
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
293 rts
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
294 L018F bitb #$98
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
295 bne L0138
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
296 clrb
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
297 rts
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
298 L0195 bsr L01A8
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
299 L0197 ldb >DPort+8
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
300 bitb #$01
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
301 bne L0197
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
302 rts
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
303 L019F lda ,u
1296
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
304 sta >DPort
fe008d68f79b Added comment from Robert Gault, changed $FF4X to DPort
boisy
parents: 1295
diff changeset
305 stb >DPort+$08
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
306 rts
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
307 L01A8
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
308 IFNE NitrOS9
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
309 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
310 ENDC
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
311 bsr L019F
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
312 L01AA
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
313 IFNE NitrOS9
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
314 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
315 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
316 ENDC
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
317 lbsr L01AD
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
318 L01AD
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
319 IFNE NitrOS9
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
320 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
321 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
322 ENDC
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
323 lbsr L01B0
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
324 L01B0
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
325 IFNE NitrOS9
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
326 nop
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
327 ENDC
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
328 rts
210
6bf55704c623 Boot is adapted from OS-9 Level Two boot module, now boots from
boisy
parents: 201
diff changeset
329
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
330 IFGT Level-1
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
331 * Filler to get $1D0
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
332 Filler fill $39,$1D0-3-*
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 249
diff changeset
333 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
334
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
335 emod
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
336 eom equ *
48
cdfe69117a2f Cleaned up source
boisy
parents: 0
diff changeset
337 end
1287
10957d54bf16 Made all modules rev 0
boisy
parents: 1213
diff changeset
338