mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 15:27:46 -04:00
emulator timing fixes, VDP DMA fixes, improved DAC audio
This commit is contained in:
parent
b9bc876c9c
commit
43e1401008
10 changed files with 118 additions and 98 deletions
|
@ -288,6 +288,8 @@ Cz80_Exec_End:
|
|||
#if CZ80_ENCRYPTED_ROM
|
||||
CPU->OPBase = OPBase;
|
||||
#endif
|
||||
if (CPU->HaltState)
|
||||
CPU->ICount = 0;
|
||||
cycles -= CPU->ICount;
|
||||
#if !CZ80_EMULATE_R_EXACTLY
|
||||
zR = (zR + (cycles >> 2)) & 0x7f;
|
||||
|
|
|
@ -687,13 +687,14 @@ OP_CCF:
|
|||
OP(0x76): // HALT
|
||||
OP_HALT:
|
||||
CPU->HaltState = 1;
|
||||
CPU->ICount = 0;
|
||||
// CPU->ICount = 0;
|
||||
goto Cz80_Check_Interrupt;
|
||||
|
||||
OP(0xf3): // DI
|
||||
OP_DI:
|
||||
zIFF = 0;
|
||||
RET(4)
|
||||
USE_CYCLES(4)
|
||||
goto Cz80_Exec_nocheck;
|
||||
|
||||
OP(0xfb): // EI
|
||||
OP_EI:
|
||||
|
@ -712,8 +713,6 @@ OP_EI:
|
|||
if (CPU->IRQState)
|
||||
{
|
||||
afterEI = 1;
|
||||
CPU->ExtraCycles += 1 - CPU->ICount;
|
||||
CPU->ICount = 1;
|
||||
}
|
||||
}
|
||||
else zIFF2 = (1 << 2);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue