add 32bit writes to some IO ports. fixes #313
This commit is contained in:
parent
c4182b5ad3
commit
6d01677a57
14
src/NDS.cpp
14
src/NDS.cpp
|
@ -1548,7 +1548,7 @@ void debug(u32 param)
|
||||||
// printf("VRAM %c: %02X\n", 'A'+i, GPU::VRAMCNT[i]);
|
// printf("VRAM %c: %02X\n", 'A'+i, GPU::VRAMCNT[i]);
|
||||||
|
|
||||||
FILE*
|
FILE*
|
||||||
shit = fopen("debug/card.bin", "wb");
|
shit = fopen("debug/manic.bin", "wb");
|
||||||
for (u32 i = 0x02000000; i < 0x02400000; i+=4)
|
for (u32 i = 0x02000000; i < 0x02400000; i+=4)
|
||||||
{
|
{
|
||||||
u32 val = ARM7Read32(i);
|
u32 val = ARM7Read32(i);
|
||||||
|
@ -2819,6 +2819,11 @@ void ARM9IOWrite32(u32 addr, u32 val)
|
||||||
{
|
{
|
||||||
switch (addr)
|
switch (addr)
|
||||||
{
|
{
|
||||||
|
case 0x04000004:
|
||||||
|
GPU::SetDispStat(0, val & 0xFFFF);
|
||||||
|
GPU::SetVCount(val >> 16);
|
||||||
|
return;
|
||||||
|
|
||||||
case 0x04000060: GPU3D::Write32(addr, val); return;
|
case 0x04000060: GPU3D::Write32(addr, val); return;
|
||||||
case 0x04000064:
|
case 0x04000064:
|
||||||
case 0x04000068: GPU::GPU2D_A->Write32(addr, val); return;
|
case 0x04000068: GPU::GPU2D_A->Write32(addr, val); return;
|
||||||
|
@ -3382,6 +3387,11 @@ void ARM7IOWrite32(u32 addr, u32 val)
|
||||||
{
|
{
|
||||||
switch (addr)
|
switch (addr)
|
||||||
{
|
{
|
||||||
|
case 0x04000004:
|
||||||
|
GPU::SetDispStat(1, val & 0xFFFF);
|
||||||
|
GPU::SetVCount(val >> 16);
|
||||||
|
return;
|
||||||
|
|
||||||
case 0x040000B0: DMAs[4]->SrcAddr = val; return;
|
case 0x040000B0: DMAs[4]->SrcAddr = val; return;
|
||||||
case 0x040000B4: DMAs[4]->DstAddr = val; return;
|
case 0x040000B4: DMAs[4]->DstAddr = val; return;
|
||||||
case 0x040000B8: DMAs[4]->WriteCnt(val); return;
|
case 0x040000B8: DMAs[4]->WriteCnt(val); return;
|
||||||
|
@ -3465,6 +3475,8 @@ void ARM7IOWrite32(u32 addr, u32 val)
|
||||||
case 0x04000210: IE[1] = val; UpdateIRQ(1); return;
|
case 0x04000210: IE[1] = val; UpdateIRQ(1); return;
|
||||||
case 0x04000214: IF[1] &= ~val; UpdateIRQ(1); return;
|
case 0x04000214: IF[1] &= ~val; UpdateIRQ(1); return;
|
||||||
|
|
||||||
|
case 0x04000304: PowerControl7 = val & 0xFFFF; return;
|
||||||
|
|
||||||
case 0x04000308:
|
case 0x04000308:
|
||||||
if (ARM7BIOSProt == 0)
|
if (ARM7BIOSProt == 0)
|
||||||
ARM7BIOSProt = val & 0xFFFE;
|
ARM7BIOSProt = val & 0xFFFE;
|
||||||
|
|
Loading…
Reference in New Issue