tweak
This commit is contained in:
parent
cf2a18e0d7
commit
0bae8670ba
1 changed files with 7 additions and 4 deletions
|
@ -209,6 +209,10 @@ wait_loop:
|
|||
|
||||
.macro run_frame frame_offset
|
||||
.scope
|
||||
; each scanline is 228 color clocks
|
||||
; that's 114 CPU cycles
|
||||
; minus 41-43 for DMA leaves 71-73 clock cycles per line
|
||||
|
||||
each_scanline_pair:
|
||||
sty scanline ; 3 cycles
|
||||
inner_scanline frame_offset, 0 ; 23-26 cycles before break, 12 cycles after
|
||||
|
@ -219,15 +223,14 @@ wait_loop:
|
|||
ldy scanline ; 3 cycles
|
||||
inner_scanline frame_offset, 128 ; 23-26 cycles before break, 12 cycles after
|
||||
|
||||
; save for later lookup
|
||||
; pair cleanup: 6 cycles
|
||||
ldy VCOUNT ; 4 cycles
|
||||
cpy #0 ; 2 cycles
|
||||
bne each_scanline_pair ; 2 cycles
|
||||
|
||||
; frame cleanup: 11 cycles
|
||||
lda frame_counter ; 3 cycles
|
||||
eor #1 ; 2 cycles
|
||||
sta frame_counter ; 3 cycles
|
||||
|
||||
jmp wait_start ; 3 cycles
|
||||
.endscope
|
||||
.endmacro
|
||||
|
|
Loading…
Reference in a new issue