ds: more tracking down the issue

did find two more uninitialized variables, but not sure if they
were the issue
This commit is contained in:
Vince Weaver 2019-11-16 17:39:27 -05:00
parent b558a8fa3a
commit 7b263360a6
4 changed files with 94 additions and 16 deletions

View File

@ -10,7 +10,8 @@ demosplash2019:
; clear zp
; shouldn't have to do this, but uninit memory bugs
;==================================================
lda #0
lda #$38
ldy #$20
zp_clear_loop:
sta $0,y
@ -26,6 +27,7 @@ zp_clear_loop:
sta FRAME_PLAY_PAGE
sta FRAME_OFFSET
sta FRAME_PAGE
sta SOUND_WHILE_DECODE
jsr update_pt3_play
jsr pt3_set_pages
@ -35,6 +37,8 @@ zp_clear_loop:
jsr clear_ay_both
jsr pt3_init_song
;====================================
; turn on language card
; enable read/write, use 1st 4k bank

View File

@ -13,19 +13,21 @@ escape:
; we are roughly at the beginning of pattern 0x18
; pattern $18, line $00
lda #$18
sta current_pattern_smc+1
lda #0
sta current_line_smc+1
; lda #$18
; sta current_pattern_smc+1
; lda #0
; sta current_line_smc+1
; lda #1
; sta current_subframe_smc+1
lda #0
sta FRAME_PLAY_PAGE
sta FRAME_OFFSET
sta FRAME_PAGE
sta FRAME_PLAY_PAGE
sta FRAME_PLAY_OFFSET
jsr update_pt3_play
lda #$0 ; assume on line $15, speed=3
sta FRAME_PLAY_OFFSET
; lda #$0 ; assume on line $15, speed=3
lda #1
sta SOUND_WHILE_DECODE
@ -52,6 +54,8 @@ escape:
sta SPRITE_YPOS
sta FIRE_Y
sta KEYPTR
sta FRAME
sta RANDOM_PTR
lda #$44
sta GREEN0

78
demosplash2019/zp.bug Normal file
View File

@ -0,0 +1,78 @@
glitchy:
pattern -> 625E -> 765E -> 18
line -> 62C0 -> 76c0 -> 0
subf -> 62c4 -> 76c4 -> 02
stop at beginning
4e/4f
0228 0268
0a28 0a68
0e28 0e68
9428 9468
9828 9868
stop after song int
0228/0229, 0268/0269
0A28 0A68
0E28 0E68
9428 9468
9828 9868
stop at escape
diff: 38 vs ff
75,76,77,7B
stack
0260?
1401 has zp address? (oh, loader for what to write to it)
7130 =
5d30 = NOTE SAMPLE POSITION
9428 = 8028
/////////
replace with 3, escape fails
$20 bad
$48 bad
$50 bad was RANDOM_PTR
$60 good
$80 good
ZP at escape, ZP init to $ff
00: 4c 3c d4 4c 3a db 00 00 ff ff 4c 99 e1 22 22 00
10: ff ff 00 00 00 ff 00 00 ff ff 00 00 ff ff 00 00
20: ff ff ff ff 28 fe e5 2c a5 f9 ff ff ff ff 0f ff
30: 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
40: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
50: 0d ff ff ff ff ff 00 04 ff ff ff ff ff ff ff ff
60: 00 00 ff ff ff ff ff ff ff ff ff ff ff ff ff ff
70: 52 04 9d 00 a2 03 0e 30 00 1f 0e 28 00 ff b1 89
80: 30 93>da<91 01 00 ff ff 00 00 01 ff ff ff ff ff
90: 4c 38 64 ff 26 ff ff ff ff ff ff ff ff ff ff ff
a0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
b0: f5 33>f6<33 f9 33 f7 33 f8 33 ff ff 01 ff 09 1e
c0: ff ff ff ff ff ff>3f<00 b1 04 10 00 00 1e 03 20
d0: 10 7c a7 10 0c 00 00 00 00 00 00 00 3c ff ff 00
e0: 7c a7 ff 05 ff 00 ff ff fc c0 a5 02 ff 00 04 ff
f0: 52 34 ff 0c 1a 01 00 15 ff ff 0c 28 00 10 00 04
82 = SAMPLE_L DA on FF
B2 = DOOR_X (maybe this one is OK)
C6 = WASTE_CYCLES (OK)
B3/B2 -- first room, 33CA (-1400 = 1FCA = door c4_r0_x)
second room 33DF (-1400 = 1FDF = door c4_r1_x)
third room 33DF
fourth room 33F6 (-1400 = 1FF6 = door_c4_r3_x)

View File

@ -49,14 +49,6 @@ BLAST2 = $5F
FRAMEL = $60
FRAMEH = $61
WAITING = $62
LETTERL = $63
LETTERH = $64
LETTERX = $65
LETTERY = $66
LETTERD = $67
LETTER = $68
BLARGH = $69
FIRE = $6A
ASTEROID_EXPLODE = $6B