hello, im using Neviksti's snes-starterkit (WLA-DX assembler) and messing with the example Hello.asm...
let me show some example code:
; some other init code/misc stuff goes here....
; do some math with the decimal flag clear
PrintString "\nDecimal flag clear: 9+8 = "
lda #9
clc
adc #8
sta var2
PrintNum var2
;this is what i put in
rep #$30 ;16 bit A, X, Y
lda #$FEEB
sta $0000
sep #$30 ;8 bit A,X,Y
;end of 'this is what i put in'
forever:
wai ;wait for next frame
;do whatever you feel like here
;let's print the current frame number
SetCursorPos 20, 10
ldy #FrameNum
PrintString "Frame num = %d "
jmp forever
Snes9x Geiger's Debugger will crash every time (as in program hard crash)
bsnes will just give be a blank screen.
Why is this happening? I was told to look at the output generated by WLA-DX after it processes the macros, but I'm not sure how to do that. I do suspect that there is an issue with the macros here, I just don't know how to pinpoint it.
I also thought maybe interrupt had something to do with it, like it was trying to run some other code in the middle of the thing i inserted, so i
disabled interrupts before and then enabled them after my snippet but it did not help.
any help would be appreciated, thanks.
let me show some example code:
Code:
; some other init code/misc stuff goes here....
; do some math with the decimal flag clear
PrintString "\nDecimal flag clear: 9+8 = "
lda #9
clc
adc #8
sta var2
PrintNum var2
;this is what i put in
rep #$30 ;16 bit A, X, Y
lda #$FEEB
sta $0000
sep #$30 ;8 bit A,X,Y
;end of 'this is what i put in'
forever:
wai ;wait for next frame
;do whatever you feel like here
;let's print the current frame number
SetCursorPos 20, 10
ldy #FrameNum
PrintString "Frame num = %d "
jmp forever
Snes9x Geiger's Debugger will crash every time (as in program hard crash)
bsnes will just give be a blank screen.
Why is this happening? I was told to look at the output generated by WLA-DX after it processes the macros, but I'm not sure how to do that. I do suspect that there is an issue with the macros here, I just don't know how to pinpoint it.
I also thought maybe interrupt had something to do with it, like it was trying to run some other code in the middle of the thing i inserted, so i
disabled interrupts before and then enabled them after my snippet but it did not help.
any help would be appreciated, thanks.