Usercalls and _LEVEL3
Posted: Sun Sep 08, 2013 3:05 am
Hello everyone.
I have been trying to implement a disassembled PCM code in my game.
The dissassemble seems to be fine (I already tested a recompiled version of the same file in the game where I took it), but, the interrupts doesn't seem to work fine on mine game.
According to certain parts of the manual and the way it's done in the game I took the code from, it uses the interrupt Level3 (which has timing) to run the code. And the code is done like this:
http://pastebin.com/KpKQUu8A
However, it only makes the Sub-CPU to be stuck at $5EE (part of BIOS/CD-SYSTEM section), doing a btst #0,($5EA4).w (_Usermode-2). With Gens's debugging tool, I see that magically a random $01 number appears there, so that's what what makes it stick there.
Any ideas of what is going on?
Thanks
I have been trying to implement a disassembled PCM code in my game.
The dissassemble seems to be fine (I already tested a recompiled version of the same file in the game where I took it), but, the interrupts doesn't seem to work fine on mine game.
According to certain parts of the manual and the way it's done in the game I took the code from, it uses the interrupt Level3 (which has timing) to run the code. And the code is done like this:
http://pastebin.com/KpKQUu8A
However, it only makes the Sub-CPU to be stuck at $5EE (part of BIOS/CD-SYSTEM section), doing a btst #0,($5EA4).w (_Usermode-2). With Gens's debugging tool, I see that magically a random $01 number appears there, so that's what what makes it stick there.
Any ideas of what is going on?
Thanks