mirror of https://github.com/A2osX/A2osX.git
Kernel 0.94+
This commit is contained in:
parent
f73e38b2d0
commit
41ca317460
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,10 +1,10 @@
|
|||
NEW
|
||||
AUTO 3,1
|
||||
*--------------------------------------
|
||||
IO.D2.SeekTimeR .EQ 55 LIBBLKDEV Recalibration
|
||||
IO.D2.SeekTimeF .EQ 55 LIBBLKDEV Track Formatter
|
||||
IO.D2.SeekTimeB .EQ 45 LIBBLKDEV Boot Block
|
||||
IO.D2.SeekTimeP .EQ 28 ProDOS.FX initial
|
||||
IO.D2.SeekTimeR .EQ 45 LIBBLKDEV Recalibration
|
||||
IO.D2.SeekTimeF .EQ 65 LIBBLKDEV Track Formatter
|
||||
IO.D2.SeekTimeB .EQ 55 LIBBLKDEV Boot Block
|
||||
IO.D2.SeekTimeP .EQ 15 ProDOS.FX initial
|
||||
IO.D2.SeekTimeI .EQ 5 ProDOS.FX increment -> until > 128
|
||||
*--------------------------------------
|
||||
IO.D2.Ph0Off .EQ $C080
|
||||
|
|
|
@ -271,7 +271,7 @@ BB.ReadBlock lda blok figure out track & sector.
|
|||
lsr
|
||||
lsr
|
||||
sta BB.TargetTrk
|
||||
|
||||
*--------------------------------------
|
||||
lda buff+1
|
||||
sta dbuf+1
|
||||
|
||||
|
@ -337,10 +337,10 @@ BB.Seek lda BB.HdrTrk get track we're on
|
|||
tay
|
||||
lda IO.D2.Ph0On,y we are on 0/4 or 2/4 track
|
||||
|
||||
* lda #1
|
||||
* bra .9 no wait, next operation will be phy/plx/Ph0On,y
|
||||
lda #1
|
||||
bra .9 no wait, next operation will be phy/plx/Ph0On,y
|
||||
|
||||
bra .90
|
||||
* bra .90
|
||||
|
||||
.1
|
||||
* cmp BB.TargetQTrack we are on 1/4 or 3/4
|
||||
|
|
|
@ -83,10 +83,10 @@ D2.MoveHead.SEI lda D2.CurrentQTrack
|
|||
|
||||
jsr .10 we are on 0/4 or 2/4 track
|
||||
|
||||
* lda #1
|
||||
* bra .9 no wait, next operation will be phy/plx/Ph0On,y
|
||||
lda #1
|
||||
bra .9 no wait, next operation will be phy/plx/Ph0On,y
|
||||
|
||||
bra .90
|
||||
* bra .90
|
||||
|
||||
.1 cmp D2.TargetQTrack we are on 1/4 or 3/4
|
||||
|
||||
|
@ -100,7 +100,7 @@ D2.MoveHead.SEI lda D2.CurrentQTrack
|
|||
|
||||
sta D2.CurrentQTrack
|
||||
|
||||
bra .7 Ph ON to go to 0/4 or 2/4, then wait
|
||||
bra .6 Ph ON to go to 0/4 or 2/4, then wait
|
||||
*--------------------------------------
|
||||
.3 bcs .4 if CS, C > T, must move out
|
||||
|
||||
|
@ -116,6 +116,7 @@ D2.MoveHead.SEI lda D2.CurrentQTrack
|
|||
bne .5 we must go to 1/4 or 3/4
|
||||
|
||||
lda IO.D2.Ph0Off,x we must go to 0/4 or 2/4 : Off Prev Ph
|
||||
* lda $C0EC
|
||||
bra .8 go wait....
|
||||
|
||||
.5 phy we must go on 1/4 or 3/4
|
||||
|
@ -125,13 +126,7 @@ D2.MoveHead.SEI lda D2.CurrentQTrack
|
|||
|
||||
inc CC: C < T, ON next PH
|
||||
|
||||
* .HS B0 BCS
|
||||
|
||||
*.6 dec CS: C > T, ON prev PH
|
||||
|
||||
.6
|
||||
|
||||
.7 jsr .10 now X and Y on
|
||||
.6 jsr .10 now X and Y on
|
||||
|
||||
.8 lda #IO.D2.SeekTimeF
|
||||
|
||||
|
@ -144,13 +139,16 @@ D2.MoveHead.SEI lda D2.CurrentQTrack
|
|||
jsr D2.Wait25600usec
|
||||
|
||||
lda IO.D2.Ph0Off,x
|
||||
* lda $C0EC
|
||||
lda IO.D2.Ph0Off,y
|
||||
* lda $C0EC
|
||||
rts
|
||||
|
||||
.10 and #6
|
||||
ora D2.Slotn0
|
||||
tay
|
||||
lda IO.D2.Ph0On,y
|
||||
* lda $C0EC
|
||||
rts
|
||||
*/--------------------------------------
|
||||
* # D2TrkRead16s
|
||||
|
|
|
@ -34,7 +34,7 @@ XRW.START cld $D8 to flag language card bank 1 (main)
|
|||
|
||||
eor XRW.LastUnitUsed same slot as last ?
|
||||
asl
|
||||
beq L59BD
|
||||
beq XRW.Blk2TS
|
||||
|
||||
lda #$01
|
||||
sta XRW.montimeh
|
||||
|
@ -42,37 +42,59 @@ XRW.START cld $D8 to flag language card bank 1 (main)
|
|||
.1 lda XRW.LastUnitUsed
|
||||
and #$70
|
||||
tax
|
||||
beq L59BD branch if no previous ever (boot only).
|
||||
beq XRW.Blk2TS branch if no previous ever (boot only).
|
||||
|
||||
jsr XRW.CheckMotorOnX check if previous drive running.
|
||||
beq L59BD branch if stopped.
|
||||
beq XRW.Blk2TS branch if stopped.
|
||||
|
||||
jsr XRW.Wait100usec
|
||||
|
||||
lda XRW.montimeh
|
||||
bne .1
|
||||
*--------------------------------------
|
||||
L59BD lda bloknml
|
||||
ldx bloknml+1
|
||||
stx XRW.ReqTrack calculate block's track and sector.
|
||||
XRW.Blk2TS
|
||||
lda bloknml
|
||||
sta XRW.ReqTrack
|
||||
|
||||
and #7
|
||||
cmp #4
|
||||
php
|
||||
and #3
|
||||
asl
|
||||
plp
|
||||
rol
|
||||
sta XRW.ReqSector
|
||||
|
||||
lda bloknml+1
|
||||
|
||||
ldx #3
|
||||
|
||||
ldy #$05
|
||||
|
||||
.1 asl
|
||||
rol XRW.ReqTrack
|
||||
dey
|
||||
.1 lsr
|
||||
ror XRW.ReqTrack
|
||||
dex
|
||||
bne .1
|
||||
|
||||
asl
|
||||
bcc .2
|
||||
* lda bloknml
|
||||
* ldx bloknml+1
|
||||
* stx XRW.ReqTrack calculate block's track and sector.
|
||||
|
||||
ora #$10 adjust for upper 4 bits of track
|
||||
* ldy #$05
|
||||
|
||||
.2 lsr
|
||||
lsr
|
||||
lsr
|
||||
lsr
|
||||
sta XRW.ReqSector
|
||||
*.1 asl
|
||||
* rol XRW.ReqTrack
|
||||
* dey
|
||||
* bne .1
|
||||
|
||||
* asl
|
||||
* bcc .2
|
||||
|
||||
* ora #$10 adjust for upper 4 bits of track
|
||||
|
||||
*.2 lsr
|
||||
* lsr
|
||||
* lsr
|
||||
* lsr
|
||||
* sta XRW.ReqSector
|
||||
*--------------------------------------
|
||||
ldx A2L
|
||||
jsr XRW.ReadMode
|
||||
|
@ -115,7 +137,7 @@ L59BD lda bloknml
|
|||
php Z set
|
||||
|
||||
.5 plp was motor on ?
|
||||
bne L538E if so, don't wait.
|
||||
bne XRW.Cmd if so, don't wait.
|
||||
|
||||
* motor was off, wait for it to speed up
|
||||
|
||||
|
@ -130,7 +152,7 @@ L59BD lda bloknml
|
|||
jsr XRW.CheckMotorOn is drive present ?
|
||||
beq XRW.E.ND
|
||||
*--------------------------------------
|
||||
L538E lda A4L get command #
|
||||
XRW.Cmd lda A4L get command #
|
||||
bne .1
|
||||
|
||||
jsr XRW.TestWP 0 = status
|
||||
|
@ -737,9 +759,6 @@ XRW.TrackSelect lda #2
|
|||
cmp XRW.ReqTrack2
|
||||
beq .8
|
||||
|
||||
* lda #"S"
|
||||
* sta $722
|
||||
|
||||
lda XRW.BadSeekCnt
|
||||
beq .6 2 bad seeks, already
|
||||
|
||||
|
@ -785,15 +804,15 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
|
|||
jsr XRW.Trk2Qtrk
|
||||
sta XRW.CurrentQTrack
|
||||
|
||||
bit #1 A = Current QT
|
||||
bne .1
|
||||
|
||||
* cmp XRW.TargetQTrack
|
||||
* bcc .88
|
||||
* bcs .88
|
||||
* >DEBUG
|
||||
*.88
|
||||
|
||||
jsr .10 we are on 0/4 or 2/4 track
|
||||
bit #1 A = Current QT
|
||||
bne .1
|
||||
|
||||
jsr .10 we are on 0/4 or 2/4 track : PhY on
|
||||
|
||||
* lda #1
|
||||
* bra .9 no wait, next operation will be phy/plx/Ph0On,y
|
||||
|
@ -812,7 +831,7 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
|
|||
|
||||
sta XRW.CurrentQTrack
|
||||
|
||||
bra .7 Ph ON to go to 0/4 or 2/4, then wait
|
||||
bra .6 PhY ON to go to 0/4 or 2/4, then wait
|
||||
*--------------------------------------
|
||||
.3 bcs .4 if CS, C > T, must move out
|
||||
|
||||
|
@ -827,8 +846,8 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
|
|||
bit #1
|
||||
bne .5 we must go to 1/4 or 3/4
|
||||
|
||||
lda IO.D2.Ph0Off,x we must go to 0/4 or 2/4 : Off Prev Ph
|
||||
|
||||
lda IO.D2.Ph0Off,x we must go to 0/4 or 2/4 : PhX Off
|
||||
* lda $C0EC
|
||||
bra .8 go wait....
|
||||
|
||||
.5 phy we must go on 1/4 or 3/4
|
||||
|
@ -838,15 +857,7 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
|
|||
|
||||
inc CC: C < T, ON next PH
|
||||
|
||||
* useless, AND #6 will do it
|
||||
|
||||
* .HS B0 BCS
|
||||
|
||||
*.6 dec CS: C > T, ON prev PH
|
||||
|
||||
.6
|
||||
|
||||
.7 jsr .10 now X and Y on
|
||||
.6 jsr .10 now X and Y on
|
||||
|
||||
.8 lda XRW.SeekTime
|
||||
|
||||
|
@ -859,7 +870,9 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
|
|||
jsr XRW.Wait25600usec
|
||||
|
||||
lda IO.D2.Ph0Off,x
|
||||
* lda $C0EC
|
||||
lda IO.D2.Ph0Off,y
|
||||
* lda $C0EC
|
||||
clc Exit wit CC (recalibrate)
|
||||
rts
|
||||
|
||||
|
@ -867,27 +880,33 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
|
|||
ora A2L
|
||||
tay
|
||||
lda IO.D2.Ph0On,y
|
||||
* lda $C0EC
|
||||
rts
|
||||
*--------------------------------------
|
||||
* A = 0 -> 79, X = XRW.UnitIndex
|
||||
* A = 0 -> 159, X = XRW.UnitIndex
|
||||
*--------------------------------------
|
||||
XRW.Trk2Qtrk asl x2, CC
|
||||
sta pch
|
||||
XRW.Trk2Qtrk sta pch
|
||||
|
||||
bit XRW.D2VolNum-1,x
|
||||
bpl .1 < $80 : x4
|
||||
|
||||
bvs .2
|
||||
|
||||
lsr $80 < v < $BF : x3
|
||||
|
||||
.1 adc pch
|
||||
asl $80 < v < $BF : x3
|
||||
adc pch
|
||||
rts
|
||||
|
||||
.2 lda XRW.D2VolNum-1,x > $C0 : 2 heads
|
||||
lsr CS if 80trk
|
||||
.1 asl
|
||||
asl
|
||||
rts
|
||||
|
||||
* 2 sides :
|
||||
|
||||
.2 lda XRW.D2VolNum-1,x > $C0 : 2 heads
|
||||
lsr CS : $C1 = 80, 2 heads
|
||||
|
||||
lda pch
|
||||
and #$FE
|
||||
bcs .8 x2 for 80trk (ELITE III)
|
||||
|
||||
asl x4 for 40trk (ELITE II)
|
||||
|
|
Loading…
Reference in New Issue