Fix Toshinden Subaru with a hack for now. Seems that xa.c needs some further debugging.
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@87349 e17a0e51-4ae3-4d35-97c3-1a29b211df97
This commit is contained in:
parent
72053c4cec
commit
2ee144472e
|
@ -129,7 +129,7 @@ void psxDma2(u32 madr, u32 bcr, u32 chcr) { // GPU
|
|||
return;
|
||||
|
||||
case 0x01000201: // mem2vram
|
||||
bs=(bcr & 0xffff);
|
||||
bs=(bcr & 0xffff);
|
||||
size = (bcr >> 16) * bs; // BA blocks * BS words (word = 32-bits)
|
||||
#ifdef PSXDMA_LOG
|
||||
PSXDMA_LOG("*** DMA 2 - GPU mem2vram *** %lx addr = %lxh, BCR %lxh => size %d = BA(%d) * BS(%xh)\n",
|
||||
|
|
|
@ -298,12 +298,12 @@ u32 psxHwRead32(u32 add) {
|
|||
#endif
|
||||
|
||||
#ifdef PSXHW_LOG
|
||||
/* case 0x1f8010f0:
|
||||
PSXHW_LOG("DMA PCR 32bit read %x\n", psxHu32(0x10f0));
|
||||
return SWAPu32(HW_DMA_PCR); // dma rest channel
|
||||
case 0x1f8010f0:
|
||||
PSXHW_LOG("DMA PCR 32bit read %x\n", HW_DMA_PCR);
|
||||
return SWAPu32(HW_DMA_PCR); // DMA control register
|
||||
case 0x1f8010f4:
|
||||
PSXHW_LOG("DMA ICR 32bit read %x\n", psxHu32(0x10f4));
|
||||
return SWAPu32(HW_DMA_ICR); // interrupt enabler?*/
|
||||
PSXHW_LOG("DMA ICR 32bit read %x\n", HW_DMA_ICR);
|
||||
return SWAPu32(HW_DMA_ICR); // DMA interrupt register (enable/ack)
|
||||
#endif
|
||||
|
||||
// time for rootcounters :)
|
||||
|
@ -359,13 +359,19 @@ u32 psxHwRead32(u32 add) {
|
|||
hard = psxRcntRtarget(2);
|
||||
#ifdef PSXHW_LOG
|
||||
PSXHW_LOG("T2 target read32: %x\n", hard);
|
||||
#endif
|
||||
return hard;
|
||||
case 0x1f801014:
|
||||
hard = psxHu32(add);
|
||||
#ifdef PSXHW_LOG
|
||||
PSXHW_LOG("SPU delay [0x1014] read32: %8.8lx\n", hard);
|
||||
#endif
|
||||
return hard;
|
||||
|
||||
default:
|
||||
hard = psxHu32(add);
|
||||
#ifdef PSXHW_LOG
|
||||
PSXHW_LOG("*Unkwnown 32bit read at address %x\n", add);
|
||||
PSXHW_LOG("*Unknown 32bit read at address %x (0x%8.8lx)\n", add, hard);
|
||||
#endif
|
||||
return hard;
|
||||
}
|
||||
|
@ -721,6 +727,13 @@ void psxHwWrite32(u32 add, u32 value) {
|
|||
return;
|
||||
}
|
||||
|
||||
|
||||
case 0x1f801014:
|
||||
#ifdef PSXHW_LOG
|
||||
PSXHW_LOG("SPU delay [0x1014] write32: %8.8lx\n", value);
|
||||
#endif
|
||||
psxHu32ref(add) = SWAPu32(value);
|
||||
return;
|
||||
case 0x1f801810:
|
||||
#ifdef PSXHW_LOG
|
||||
PSXHW_LOG("GPU DATA 32bit write %x\n", value);
|
||||
|
|
|
@ -44,23 +44,38 @@ unsigned short CALLBACK SPUreadDMA(void)
|
|||
void CALLBACK SPUreadDMAMem(unsigned short * pusPSXMem,int iSize)
|
||||
{
|
||||
int i;
|
||||
unsigned char crc=0;
|
||||
|
||||
spuStat |= STAT_DATA_BUSY;
|
||||
|
||||
for(i=0;i<iSize;i++)
|
||||
{
|
||||
Check_IRQ( spuAddr, 0 );
|
||||
Check_IRQ( spuAddr, 0 );
|
||||
|
||||
|
||||
*pusPSXMem++=spuMem[spuAddr>>1]; // spu addr got by writeregister
|
||||
spuAddr+=2; // inc spu addr
|
||||
crc|=*pusPSXMem++=spuMem[spuAddr>>1]; // spu addr got by writeregister
|
||||
spuAddr+=2; // inc spu addr
|
||||
spuMem[spuAddr>>1];
|
||||
|
||||
// guess based on Vib Ribbon (below)
|
||||
// guess based on Vib Ribbon (below)
|
||||
if(spuAddr>0x7ffff) break;
|
||||
}
|
||||
|
||||
iSpuAsyncWait=0;
|
||||
|
||||
/*
|
||||
/* Toshiden Subaru "story screen" hack.
|
||||
/*
|
||||
/* After character selection screen, the game checks values inside returned
|
||||
/* SPU buffer and all values cannot be 0x0.
|
||||
/* Due to XA timings(?) we return buffer that has only NULLs.
|
||||
/* Setting little lag to MixXA() causes buffer to have some non-NULL values,
|
||||
/* but causes garbage sound so this hack is preferable.
|
||||
/*
|
||||
/* Note: When messing with xa.c like fixing Suikoden II's demo video sound issue
|
||||
/* this should be handled as well.
|
||||
*/
|
||||
if (crc == 0) *--pusPSXMem=0xFF;
|
||||
|
||||
spuStat &= ~STAT_DATA_BUSY;
|
||||
spuStat &= ~STAT_DMA_NON;
|
||||
spuStat &= ~STAT_DMA_W;
|
||||
|
|
Loading…
Reference in New Issue
Block a user