fix big seek

This commit is contained in:
Peter Ferrie 2020-05-23 12:30:30 -07:00
parent 0d25b35d8e
commit e473a430d9
3 changed files with 13 additions and 5 deletions

View File

@ -15,7 +15,7 @@ LoadFileAuxInternal
!if RELBASE != $2000 {
!ifdef PASS2 {
} else { ;PASS2
!if * != $DAF3 {
!if * != $DAFD {
!error "LoadFileDirect=",*, ", adjust !if and fix Berzap"
}
}

View File

@ -36,7 +36,7 @@ callback2
pha
lda #<berzap_mb
ldy #>berzap_mb
jsr $DAF3 ; ahem, LoadFileDirect
jsr $DAFD ; ahem, LoadFileDirect
pla
sta $D403
pla

View File

@ -214,7 +214,7 @@ ProDOS_enter
sta sizelo
jsr hddopendir
stx blkidx
beq @jmp_zp ;always
beq @link_jmpzp ;always
resetval=$f0
@imp_seek
@ -226,7 +226,14 @@ resetval=$f0
stx reqcmd
jsr @reset
ldx sizelo
beq @seek64
bne @seek64
cmp ldrhi
bcc @seek64
bne @seek32
ldx ldrlo
beq @seek32
@seek64
sta sizehi
sta sizelo
jsr @seekreset
@ -234,7 +241,7 @@ resetval=$f0
sbc #resetval
sta ldrhi
@seek64
@seek32
lda ldrhi
sta sizehi
lda ldrlo
@ -244,6 +251,7 @@ resetval=$f0
ora ldrlo
bne @jmp_zp
dec blkidx
@link_jmpzp
beq @jmp_zp ;always
@seekreset