jsr
clrchn ; send eoi
bit serial
; check speed
of
drive
bvc
error
sei
Ida
#clkin
sta ol<lclk ; clock starts high
Idy
#0
; even page
Idx
cm<lbuf+5
; get #
of
sectors
wriLit
jsr
spout ; serial port out
topwr Ida d2pra ; check clock
cmp d2pra
; debounce
bne topwr
eor ol<lclk
and
#clkin
beq topwr
Ida ol<lclk ; change status
of
old clock
eor
#clkin
sta ol<lclk
Ida
(buffer),y
; send data
sta dlsdr
OPTIONAL
; put code here or before spinp
Ida
#8
wait 1 bit dlicr
; wait for transmission time
beq wait 1
END OPTIONAL
iny
bne topwr
; continue for buffer size
; talker tum around
jsr
spinp
; serial port input
bit dlicr
; clear pending
jsr
clklo
; set clk low, tell him we are ready
Ida
#8
wait 2 bit dlicr
; wait for status byte
beq wait 2
95