Hi all, I've been trying to iron out some of the many bugs that my emulator still has. Fortunately, each day I manage to fix most of them, and today I think my compatibility ratio for commercial games is near 100%.
I've been trying to fix edge case scenarios, so for starters, this test:
https://github.com/Gekkio/mooneye-gb/bl ... ming.s#L21
Which fails on BGB, kigb, NefustoGB (my emu), but works perfect on higan (byuu always manage to emulate everything wow).
So, I'm a little confused with it, the first test says it's expecting OAM to be locked for the argument parameter for instruction E9 (add sp,e), but not for the instruction reading phase (the E9 itself)
My emulator, returns 0xFF for all the memory map (except high ram) when DMA is being done. When I reach PC = 0xFDFF, my DMA routine already finished and I read instruction as: E9 42, the 42 being the first byte on the OAM memory. This is wrong, the expected value in the test is: E9 FF.
If I adjust my OAM to take 4 more cycles (or 1 machine cycle), I get FF as the instruction (instead of E9), and since that's a restart to 0x38, the flow goes elsewhere and does nothing more. This is even worse.
I'm guessing I don't have to lock all memory when there's a DMA, or maybe when a new instruction is fetch, it's supposed to bypass the DMA lock ?
Any leads on this ?
Thanks,
I've been trying to fix edge case scenarios, so for starters, this test:
https://github.com/Gekkio/mooneye-gb/bl ... ming.s#L21
Which fails on BGB, kigb, NefustoGB (my emu), but works perfect on higan (byuu always manage to emulate everything wow).
So, I'm a little confused with it, the first test says it's expecting OAM to be locked for the argument parameter for instruction E9 (add sp,e), but not for the instruction reading phase (the E9 itself)
My emulator, returns 0xFF for all the memory map (except high ram) when DMA is being done. When I reach PC = 0xFDFF, my DMA routine already finished and I read instruction as: E9 42, the 42 being the first byte on the OAM memory. This is wrong, the expected value in the test is: E9 FF.
If I adjust my OAM to take 4 more cycles (or 1 machine cycle), I get FF as the instruction (instead of E9), and since that's a restart to 0x38, the flow goes elsewhere and does nothing more. This is even worse.
I'm guessing I don't have to lock all memory when there's a DMA, or maybe when a new instruction is fetch, it's supposed to bypass the DMA lock ?
Any leads on this ?
Thanks,