mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 15:27:46 -04:00
z80 timing change
git-svn-id: file:///home/notaz/opt/svn/PicoDrive@84 be3aeb3a-fb24-0410-a615-afba39da0efa
This commit is contained in:
parent
2433f40912
commit
d915372968
6 changed files with 32 additions and 15 deletions
15
Pico/Pico.c
15
Pico/Pico.c
|
@ -430,11 +430,18 @@ static int PicoFrameHints(void)
|
|||
getSamples(y);
|
||||
|
||||
// Run scanline:
|
||||
if(Pico.m.dma_bytes) SekCycleCnt+=CheckDMA();
|
||||
if (Pico.m.dma_bytes) SekCycleCnt+=CheckDMA();
|
||||
SekRun(cycles_68k);
|
||||
if((PicoOpt&4) && Pico.m.z80Run) {
|
||||
Pico.m.z80Run|=2;
|
||||
z80CycleAim+=cycles_z80;
|
||||
if ((PicoOpt&4) && Pico.m.z80Run) {
|
||||
if (Pico.m.z80Run & 2) z80CycleAim+=cycles_z80;
|
||||
else {
|
||||
int cnt = SekCyclesDone() - z80startCycle;
|
||||
cnt = (cnt>>1)-(cnt>>5);
|
||||
//if (cnt > cycles_z80) printf("FIXME: z80 cycles: %i\n", cnt);
|
||||
if (cnt > cycles_z80) cnt = cycles_z80;
|
||||
Pico.m.z80Run |= 2;
|
||||
z80CycleAim+=cnt;
|
||||
}
|
||||
total_z80+=z80_run(z80CycleAim-total_z80);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue