diff --git a/src/fx/fx.hgr.1bit.fizzle.a b/src/fx/fx.hgr.1bit.fizzle.a index c2688621b..5856a128b 100755 --- a/src/fx/fx.hgr.1bit.fizzle.a +++ b/src/fx/fx.hgr.1bit.fizzle.a @@ -8,9 +8,11 @@ addrs = $6100 ; [256 bytes, page-aligned] copymasks = $6200 ; [256 bytes, page-aligned] - jsr swapzp ; copy LFSR code to zero page - - inx ; X=0 + ldx #(end-start) ; copy LFSR code to zero page +- lda start-1, x + sta $0, x + dex + bne - lda #%00000001 ; create copymask lookup table -- ldy #$20 ora #%10000000 @@ -20,7 +22,8 @@ copymasks = $6200 ; [256 bytes, page-aligned] bne - asl bne -- - ; X=0 + pha + pha clc -- ldy #$20 ; create address lookup table tya @@ -31,38 +34,23 @@ copymasks = $6200 ; [256 bytes, page-aligned] bne - txa bne -- - ; X,Y=0 - jsr $0 ; call LFSR code on zero page - - lda $4000 ; last lousy byte (because LFSR never hits 0) - sta $2000 - ; fall through to restore and exit -swapzp ldx #(end-start-1) -- ldy start, x - lda $0, x - sta start, x - sty $0, x - dex - bpl - - rts ; X=#$FF + rts ; exit via LFSR code on zero page start -!pseudopc 0 { +!pseudopc 1 { ; in: X,Y=0 loop txa -loop1 eor #$B4 ; LFSR form 0xB400 for period 65535 +loop1 eor #$B4 ; LFSR form 0xB400 with period 65535 tax ; X is LFSR high byte, Y is LFSR low byte loop2 lda addrs, x ; which means X is the index into the base address lookup table sta