annotate level1/modules/dwwrmess.asm @ 2940:824019cd8744

rb1773: Make 48 TPI floppy disks readonly in 96 TPI drives Deny the disk destroying write with the narrower heads of the 96 tpi drive when the user has placed a 48 tpi disk in the 96 tpi drive so he can read it. Double stepping the drive is then done automatically so as to stay in mechanical synch with the tracks on a 48 tpi disk. But that, until now, did not make the disk read-only, this patch does that. Patch by Gene Heskett and Robert Gault.
author Robert Gault <robert.gault@att.net>
date Sat, 25 Jan 2014 23:20:06 +0100
parents c92a6c65bbd9
children c505ae3120c4
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2534
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
1 *******************************************************
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
2 *
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
3 * DWWriteMESS
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
4 *
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
5 * 4/27/10 AAW - Based on John Linville's example
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
6 *
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
7 * Entry:
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
8 * X = starting address of data to send
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
9 * Y = number of bytes to send
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
10 *
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
11 * Exit:
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
12 * X = address of last byte sent + 1
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
13 * Y = 0
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
14 * All others preserved
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
15 *
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
16
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
17
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
18 DWWrite pshs u,d,cc ; preserve registers
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
19 orcc #$50 ; mask interrupts
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
20
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
21 txByte ldb ,x+ ; get a byte to transmit
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
22 stb $ffe0 ; write it to the FIFO
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
23 leay ,-y ; decrement byte counter
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
24 bne txByte ; loop if more to send
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
25
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
26 puls cc,d,u,pc ; restore registers and return
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
27
c92a6c65bbd9 dw3 MESS driver
aaronwolfe
parents:
diff changeset
28