;------------------------------- ; IDDavid ; identify David-DOS bootloader ; ; in: $0800..$08FF contains T00,S00 ; first page of track buffer also contains T00,S00 ; A = 0 ; X = 0 ; out: C clear if David-DOS bootloader found ; C set otherwise ; A = 0 ; X = 0 ; all other registers & flags clobbered ;------------------------------- !macro IDDavid { ldy #$07 jsr compare ; if T00,S00,$00 == !byte $01 !byte $A5,$27 ; LDA $27 !byte $C9,$09 ; CMP #$09 !byte $D0,$17 ; BNE +$17 bcs @notDavid ldx #$4A dey jsr compare ; and T00,S00,$4A == !byte $A2,WILDCARD ; LDX #$** !byte $BD,WILDCARD,$08; LDA $08**,X !byte $9D ; passport-test-suite/Horses.woz [C=0] matches tax @notDavid }