diff options
author | Arisotura <thetotalworm@gmail.com> | 2020-10-25 18:14:40 +0100 |
---|---|---|
committer | Arisotura <thetotalworm@gmail.com> | 2020-10-25 18:14:40 +0100 |
commit | 9fdc1de6feba27a30ab15cab0be74bac04b797ae (patch) | |
tree | 4004b26f82b86c2ed1e75f31a85da9f604bc9367 /src | |
parent | 65be1840f02a7499fa08178abcefddfefec6d9b0 (diff) |
add a few missing 32bit I/O accesses (IPC, SPI)
Diffstat (limited to 'src')
-rw-r--r-- | src/NDS.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/NDS.cpp b/src/NDS.cpp index 90149ad..d42e735 100644 --- a/src/NDS.cpp +++ b/src/NDS.cpp @@ -3001,6 +3001,7 @@ u32 ARM9IORead32(u32 addr) case 0x04000130: return (KeyInput & 0xFFFF) | (KeyCnt << 16); case 0x04000180: return IPCSync9; + case 0x04000184: return ARM9IORead16(addr); case 0x040001A0: return NDSCart::SPICnt | (NDSCart::ReadSPIData() << 16); case 0x040001A4: return NDSCart::ROMCnt; @@ -3378,10 +3379,11 @@ void ARM9IOWrite32(u32 addr, u32 val) case 0x04000130: KeyCnt = val >> 16; return; + case 0x04000180: + case 0x04000184: ARM9IOWrite16(addr, val); return; - case 0x04000188: if (IPCFIFOCnt9 & 0x8000) { @@ -3640,6 +3642,7 @@ u32 ARM7IORead32(u32 addr) case 0x04000138: return RTC::Read(); case 0x04000180: return IPCSync7; + case 0x04000184: return ARM7IORead16(addr); case 0x040001A0: return NDSCart::SPICnt | (NDSCart::ReadSPIData() << 16); case 0x040001A4: return NDSCart::ROMCnt; @@ -3940,6 +3943,7 @@ void ARM7IOWrite32(u32 addr, u32 val) case 0x04000138: RTC::Write(val & 0xFFFF, false); return; case 0x04000180: + case 0x04000184: ARM7IOWrite16(addr, val); return; case 0x04000188: @@ -3984,6 +3988,11 @@ void ARM7IOWrite32(u32 addr, u32 val) case 0x040001B0: *(u32*)&ROMSeed0[8] = val; return; case 0x040001B4: *(u32*)&ROMSeed1[8] = val; return; + case 0x040001C0: + SPI::WriteCnt(val & 0xFFFF); + SPI::WriteData((val >> 16) & 0xFF); + return; + case 0x04000208: IME[1] = val & 0x1; UpdateIRQ(1); return; case 0x04000210: IE[1] = val; UpdateIRQ(1); return; case 0x04000214: IF[1] &= ~val; UpdateIRQ(1); return; |