Use Platform::File calls in NDS::debug (#1888)
This commit is contained in:
parent
679c37ddce
commit
651b0f680c
13
src/NDS.cpp
13
src/NDS.cpp
|
@ -2074,25 +2074,24 @@ void debug(u32 param)
|
||||||
//for (int i = 0; i < 9; i++)
|
//for (int i = 0; i < 9; i++)
|
||||||
// printf("VRAM %c: %02X\n", 'A'+i, GPU->VRAMCNT[i]);
|
// printf("VRAM %c: %02X\n", 'A'+i, GPU->VRAMCNT[i]);
|
||||||
|
|
||||||
FILE*
|
Platform::FileHandle* shit = Platform::OpenFile("debug/DSfirmware.bin", FileMode::Write);
|
||||||
shit = fopen("debug/DSfirmware.bin", "wb");
|
Platform::FileWrite(ARM9->ITCM, 0x8000, 1, shit);
|
||||||
fwrite(ARM9->ITCM, 0x8000, 1, shit);
|
|
||||||
for (u32 i = 0x02000000; i < 0x02400000; i+=4)
|
for (u32 i = 0x02000000; i < 0x02400000; i+=4)
|
||||||
{
|
{
|
||||||
u32 val = ARM7Read32(i);
|
u32 val = ARM7Read32(i);
|
||||||
fwrite(&val, 4, 1, shit);
|
Platform::FileWrite(&val, 4, 1, shit);
|
||||||
}
|
}
|
||||||
for (u32 i = 0x037F0000; i < 0x03810000; i+=4)
|
for (u32 i = 0x037F0000; i < 0x03810000; i+=4)
|
||||||
{
|
{
|
||||||
u32 val = ARM7Read32(i);
|
u32 val = ARM7Read32(i);
|
||||||
fwrite(&val, 4, 1, shit);
|
Platform::FileWrite(&val, 4, 1, shit);
|
||||||
}
|
}
|
||||||
for (u32 i = 0x06000000; i < 0x06040000; i+=4)
|
for (u32 i = 0x06000000; i < 0x06040000; i+=4)
|
||||||
{
|
{
|
||||||
u32 val = ARM7Read32(i);
|
u32 val = ARM7Read32(i);
|
||||||
fwrite(&val, 4, 1, shit);
|
Platform::FileWrite(&val, 4, 1, shit);
|
||||||
}
|
}
|
||||||
fclose(shit);
|
Platform::CloseFile(shit);
|
||||||
|
|
||||||
/*FILE*
|
/*FILE*
|
||||||
shit = fopen("debug/directboot9.bin", "wb");
|
shit = fopen("debug/directboot9.bin", "wb");
|
||||||
|
|
Loading…
Reference in New Issue