mirror of
https://github.com/a2-4am/passport.git
synced 2024-11-01 07:07:59 +00:00
Merge pull request #13 from peterferrie/master
switch Optimum to ProDOS write method
This commit is contained in:
commit
7659056630
@ -138,6 +138,8 @@ _optimum
|
||||
;track 0, find the region with replaced page
|
||||
|
||||
.reread1
|
||||
lda #s_construct
|
||||
jsr PrintByID
|
||||
ldy #8
|
||||
jsr SearchTrack
|
||||
!byte $20,$5D,$B6 ;JSR $B65D
|
||||
@ -191,40 +193,36 @@ _optimum
|
||||
cpy #$FF
|
||||
bne -
|
||||
|
||||
;write replaced page
|
||||
;read other page in block
|
||||
|
||||
lda gRWTSParams+1
|
||||
pha
|
||||
lda gRWTSParams+2
|
||||
pha
|
||||
lda SLOT
|
||||
asl
|
||||
asl
|
||||
asl
|
||||
asl
|
||||
sta gRWTSParams+1
|
||||
sta gRWTSParams+$0F
|
||||
lda DRIVE
|
||||
and #$0F
|
||||
sta gRWTSParams+2
|
||||
lda #1
|
||||
sta gTrack
|
||||
lda #$0F
|
||||
sta gSector
|
||||
inc gRWTSParams+$0C
|
||||
dec gAddress+1
|
||||
ldy #<gRWTSParams
|
||||
lda #>gRWTSParams
|
||||
jsr $BD00
|
||||
dec gRWTSParams+$0C
|
||||
pla
|
||||
sta gRWTSParams+2
|
||||
pla
|
||||
sta gRWTSParams+$0F
|
||||
sta gRWTSParams+1
|
||||
|
||||
;restore original page
|
||||
;write replaced block
|
||||
|
||||
lda #(BASEPAGE+$0E)
|
||||
sta mliparam+3 ; hi byte of data buffer
|
||||
dec mliparam+4 ; lo byte of block number
|
||||
jsr SwapProDOS
|
||||
lda #$81 ; 'write block' command
|
||||
ldy #$03 ; parameter count
|
||||
jsr mli
|
||||
jsr SwapProDOS
|
||||
|
||||
;restore original pages
|
||||
|
||||
dec gTrack
|
||||
inc gSector
|
||||
ldy #<gRWTSParams
|
||||
lda #>gRWTSParams
|
||||
jsr $BD00
|
||||
inc gSector
|
||||
inc gAddress+1
|
||||
ldy #<gRWTSParams
|
||||
lda #>gRWTSParams
|
||||
jsr $BD00
|
||||
|
@ -89,7 +89,8 @@ s_eab0 = $46
|
||||
s_eatrk6 = $47
|
||||
s_eeef = $48
|
||||
s_poke = $49
|
||||
STRINGCOUNT = $4A
|
||||
s_construct= $4A
|
||||
STRINGCOUNT = $4B
|
||||
|
||||
!zone {
|
||||
StringTable
|
||||
@ -167,6 +168,7 @@ StringTable
|
||||
!word .eatrk6
|
||||
!word .eeef
|
||||
!word .poke
|
||||
!word .construct
|
||||
;
|
||||
; Text can contain substitution strings, which
|
||||
; are replaced by current values at runtime. Each
|
||||
@ -192,7 +194,7 @@ StringTable
|
||||
; can be set directly before calling PrintByID.
|
||||
;
|
||||
.header
|
||||
!text "Passport by 4am 2017-02-09",00
|
||||
!text "Passport by 4am 2017-02-10",00
|
||||
.mainmenu
|
||||
!text "________________________________________",$8D,$8D,$8D,$8D,$8D,$8D,$8D
|
||||
!text " "
|
||||
@ -427,4 +429,7 @@ StringTable
|
||||
.poke
|
||||
!text "T%t,S%0 BASIC program POKEs protection",$8D
|
||||
!text "check into memory and CALLs it.",$8D,$00
|
||||
.construct
|
||||
!text "Constructing complete T01S0F content.",$8D
|
||||
!text "Protected version is only partial.",$8D,$00
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user