some minor tweaks and comments

This commit is contained in:
4am 2020-09-04 23:44:38 -04:00
parent 3dfc71a25a
commit 86d3dc4b72
3 changed files with 17 additions and 16 deletions

View File

@ -5,22 +5,22 @@
!to "build/FX/BIT.FIZZLE",plain
*=$6000
copymasks = $6100 ; [256 bytes, page-aligned]
addrs = $6200 ; [256 bytes, page-aligned]
addrs = $6100 ; [256 bytes, page-aligned]
copymasks = $6200 ; [256 bytes, page-aligned]
jsr swapzp ; copy LFSR code to zero page
inx
lda #1 ; create copymask lookup table
inx ; X=0
lda #%00000001 ; create copymask lookup table
-- ldy #$20
ora #$80
ora #%10000000
- sta copymasks, x
inx
dey
bne -
asl
bne --
; X=0
clc
-- ldy #$20 ; create address lookup table
tya
@ -31,7 +31,7 @@ addrs = $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)
@ -44,7 +44,7 @@ swapzp ldx #(end-start-1)
sty $0, x
dex
bpl -
rts
rts ; X=#$FF
start
!pseudopc 0 {

View File

@ -10,7 +10,7 @@ copymasks = $6200 ; [128 bytes, should not cross page boundar
jsr swapzp ; copy LFSR code to zero page
ldx #0
inx ; X=0
lda #%00000011 ; create copymask lookup table
-- ldy #$20
ora #%10000000
@ -21,8 +21,9 @@ copymasks = $6200 ; [128 bytes, should not cross page boundar
asl
asl
bne --
tax ; X=0
clc
ldx #0
-- ldy #$20 ; create address lookup table
tya
- sta addrs, x
@ -32,7 +33,7 @@ copymasks = $6200 ; [128 bytes, should not cross page boundar
bne -
txa
bne --
; X,Y=0
jsr $0 ; call LFSR code on zero page
lda $4000 ; last lousy byte (because LFSR never hits 0)
@ -45,7 +46,7 @@ swapzp ldx #(end-start-1)
sty $0, x
dex
bpl -
rts
rts ; X=#$FF
start
!pseudopc 0 {

View File

@ -16,7 +16,7 @@ addrs=$A100 ; [128 bytes, can be anywhere in main memor
sbc #1
dex
bpl -
inx
inx ; X=0
sta $C005 ; pre-copy SHR SCB and palette
ldy #0
@ -28,13 +28,13 @@ addrs=$A100 ; [128 bytes, can be anywhere in main memor
sta $9F00, y
iny
bne -
; X,Y=0
jsr $0 ; call LFSR code on zero page
lda $2000 ; last lousy byte (because LFSR never hits 0)
sta $2000
sta $C004 ; restore and exit
sta $C004
; fall through to restore and exit
swapzp ldx #(end-start-1)
- ldy start, x
lda $0, x