diff options
| author | SND\notaz_cp <SND\notaz_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97> | 2013-01-11 18:57:57 +0000 |
|---|---|---|
| committer | SND\notaz_cp <SND\notaz_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97> | 2013-01-11 18:57:57 +0000 |
| commit | 27c28fcc73ea885981eb2258fc4f0f986bf8cae5 (patch) | |
| tree | 423372c22e9d990a1eb81cd5f07f2a9682ef6730 /libpcsxcore | |
| parent | 2cc65d700ac29d4e05308b42fbfab52ae6fc389d (diff) | |
| download | pcsxr-27c28fcc73ea885981eb2258fc4f0f986bf8cae5.tar.gz | |
cdrom: workaround timing problems
not needed in ReARMed for some reason.
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@82209 e17a0e51-4ae3-4d35-97c3-1a29b211df97
Diffstat (limited to 'libpcsxcore')
| -rwxr-xr-x | libpcsxcore/cdrom.c | 10 | ||||
| -rwxr-xr-x | libpcsxcore/cdrom.h | 1 |
2 files changed, 11 insertions, 0 deletions
diff --git a/libpcsxcore/cdrom.c b/libpcsxcore/cdrom.c index 0986f70f..41537d56 100755 --- a/libpcsxcore/cdrom.c +++ b/libpcsxcore/cdrom.c @@ -1204,6 +1204,15 @@ void cdrReadInterrupt() { return; } + if ((psxHu32ref(0x1070) & psxHu32ref(0x1074) & SWAP32((u32)0x4)) && !cdr.ReadRescheduled) { + // HACK: with BIAS 2, emulated CPU is often slower than real thing, + // game may be unfinished with prev data read, so reschedule + // (Brave Fencer Musashi) + CDREAD_INT(cdReadTime / 2); + cdr.ReadRescheduled = 1; + return; + } + cdr.OCUP = 1; SetResultSize(1); cdr.StatP |= STATUS_READ|STATUS_ROTATING; @@ -1263,6 +1272,7 @@ void cdrReadInterrupt() { } cdr.Readed = 0; + cdr.ReadRescheduled = 0; CDREAD_INT((cdr.Mode & MODE_SPEED) ? (cdReadTime / 2) : cdReadTime); diff --git a/libpcsxcore/cdrom.h b/libpcsxcore/cdrom.h index c0534e71..4f622add 100755 --- a/libpcsxcore/cdrom.h +++ b/libpcsxcore/cdrom.h @@ -88,6 +88,7 @@ typedef struct { u32 eCycle; u8 Seeked; + u8 ReadRescheduled; u8 LidCheck; u8 FastForward; |
