diff --git a/src/apicode.a b/src/apicode.a index 98bac7f..0155e08 100644 --- a/src/apicode.a +++ b/src/apicode.a @@ -64,6 +64,10 @@ ; set in IDBootloader() after reading T00,S00 FIRSTFILTER +;gIsDiversi + !byte FALSE ; 0=true, 1=false + ; reset before each operation + ; set in IDBootloader() after reading T00,S00 ;gIsPhoenix !byte FALSE ; 0=true, 1=false ; reset before each operation diff --git a/src/apidefs.a b/src/apidefs.a index 679ef74..deee067 100644 --- a/src/apidefs.a +++ b/src/apidefs.a @@ -101,9 +101,10 @@ gIsRDOS13 = gIsDavidson-$01 ; byte gIsMUSERWTS = gIsRDOS13-$01 ; byte gIsHolle = gIsMUSERWTS-$01 ; byte gIsPhoenix = gIsHolle-$01 ; byte +gIsDiversi = gIsPhoenix-$01 ; byte ;LASTFILTER ; add new gIs* above this line ;gIsInfocom18 is a special case whose ID is not in the regular inspection path -gIsInfocom18 = gIsPhoenix-$01 ; byte +gIsInfocom18 = gIsDiversi-$01 ; byte ;gIs13Sector is a special case whose ID is not in the regular inspection path gIs13Sector = gIsInfocom18-$01 ; byte ;gMECCFastloadType is a special case integer whose default value cannot be #FALSE @@ -177,6 +178,7 @@ ConstructStandardDelivery = jConstructStandardDelivery !warn "gIsMUSERWTS=",gIsMUSERWTS !warn "gIsHolle=",gIsHolle !warn "gIsPhoenix=",gIsPhoenix +!warn "gIsDiversi=",gIsDiversi !warn "gIsRDOS13=",gIsRDOS13 !warn "gIsInfocom18=",gIsInfocom18 !warn "gIs13Sector=",gIs13Sector diff --git a/src/id/diversidos.a b/src/id/diversidos.a index 56fa6d7..5b861c5 100644 --- a/src/id/diversidos.a +++ b/src/id/diversidos.a @@ -17,5 +17,10 @@ IDDiversi ldy #$0B jsr compare ; if T00,S00,$F1 == !byte $B3,$A3,$A0,$D2,$CF,$D2,$D2,$C5,$8D,$87,$8D + bcs .no + lda #TRUE + sta gIsDiversi + +.no rts ; passport-test-suite/Moon Bingo.woz [C=0] matches } diff --git a/src/passport.a b/src/passport.a index d4e6ed7..2cea79c 100755 --- a/src/passport.a +++ b/src/passport.a @@ -802,6 +802,7 @@ _applyToAll !source "patchers/zoomgrafix.a" ; gIsPhoenix only !source "patchers/e7everywhere.a" ; gIsBoot0 || gIsProDOS only !source "patchers/choplifter.a" ; gIsChoplifter only + !source "patchers/basham.a" ; gIsDiversi only lda gPatchCount beq .nopatches diff --git a/src/patchers/basham.a b/src/patchers/basham.a new file mode 100644 index 0000000..3816b5a --- /dev/null +++ b/src/patchers/basham.a @@ -0,0 +1,38 @@ +;------------------------------- +; #BASHAM +; obfuscated nibble check +; used by Passport Systems +; +; tested on +; - Korg-800 4 Track Midi Sequencer +; - MIDI-8 Plus +; - Polywriter +;------------------------------- +!zone { + bit gMode ; nothing to do here in verify-only mode + bpl .exit + lda gIsDiversi ; only if we found Diversi-DOS boot sector earlier + bne .exit + ldy #14 + jsr SearchTrack + !byte $A0,$0F ; LDY #$0F + !byte $B9,$00,$00 ; LDA $0000,Y + !byte $99,$E4,$95 ; STA $95E4,Y + !byte $88 ; DEY + !byte $10,$F7 ; BPL *-9 + !byte $4C,$E3,$93 ; JMP $93E3 + bcs .exit + sta gDisplayBytes + pha + lda #s_basham + jsr PrintByID + txa + clc + adc #12 + tax + pla + ldy #$02 + jsr modify + !byte $99,$8E ; jmp directly to decoder +.exit +} diff --git a/src/patchers/choplifter.a b/src/patchers/choplifter.a index 287f5b8..c30d339 100644 --- a/src/patchers/choplifter.a +++ b/src/patchers/choplifter.a @@ -22,7 +22,7 @@ ; - Star Blazer (Broderbund) ;------------------------------- !zone { - rts ; reachable only via inspect + jmp .exit2 ; reachable only via inspect Choplifter lda #$00 @@ -496,4 +496,6 @@ ReadChoplifter rts } ;$5xx } ;$Bxxx + +.exit2 } diff --git a/src/strings/en.a b/src/strings/en.a index ae3dc2e..59705dd 100755 --- a/src/strings/en.a +++ b/src/strings/en.a @@ -134,6 +134,7 @@ StringTableLow !byte <.diskvol0 !byte <.e7everywhere !byte <.choplifter + !byte <.basham StringTableHigh !byte >.header @@ -254,6 +255,7 @@ StringTableHigh !byte >.diskvol0 !byte >.e7everywhere !byte >.choplifter + !byte >.basham ; ; Text can contain substitution strings, which @@ -280,7 +282,7 @@ StringTableHigh ; can be set directly before calling PrintByID. ; .header - !text "Passport by 4am 2019-08-28",$00 + !text "Passport by 4am 2019-10-10",$00 .mainmenu !text "________________________________________",$8D,$8D,$8D,$8D,$8D,$8D,$8D,$8D !text " " @@ -607,4 +609,6 @@ StringTableHigh !text "T%t,S%0 Found E7 Everywhere protection",$8D,$00 .choplifter !text "Roland was here, but he left...",$8D,$00 +.basham + !text "T%t,S%0 Found Basham protection",$8D,$00 } diff --git a/src/strings/enid.a b/src/strings/enid.a index 899f190..4abb353 100644 --- a/src/strings/enid.a +++ b/src/strings/enid.a @@ -120,4 +120,5 @@ s_hoffman = $72 s_diskvol0 = $73 s_e7everywhere=$74 s_choplifter = $75 -STRINGCOUNT = $76 +s_basham = $76 +STRINGCOUNT = $77