static void ExpMemory_write08(u32 procnum, u32 adr, u8 val) { if (adr >= 0x09000000) { u32 offs = (adr - 0x09000000); if (offs >= expMemSize) return; T1WriteByte(expMemory, offs, val); } EXPINFO("ExpMemory: write 08 at 0x%08X = 0x%02X\n", adr, val); }
void FASTCALL Vdp1FrameBufferWriteByte(u32 addr, u8 val) { addr &= 0x3FFFF; if (VIDCore->Vdp1WriteFrameBuffer) { VIDCore->Vdp1WriteFrameBuffer(0, addr, val); return; } T1WriteByte(Vdp1FrameBuffer, addr, val); }
void FormatBackupRam(void *mem, u32 size) { int i, i2; u32 i3; u8 header[32] = { 0xFF, 'B', 0xFF, 'a', 0xFF, 'c', 0xFF, 'k', 0xFF, 'U', 0xFF, 'p', 0xFF, 'R', 0xFF, 'a', 0xFF, 'm', 0xFF, ' ', 0xFF, 'F', 0xFF, 'o', 0xFF, 'r', 0xFF, 'm', 0xFF, 'a', 0xFF, 't' }; // Fill in header for(i2 = 0; i2 < 4; i2++) for(i = 0; i < 32; i++) T1WriteByte(mem, (i2 * 32) + i, header[i]); // Clear the rest for(i3 = 0x80; i3 < size; i3+=2) { T1WriteByte(mem, i3, 0xFF); T1WriteByte(mem, i3+1, 0x00); } }
void SPU_Reset(void) { int i; SPU_core->reset(); if(SPU_user) SPU_user->reset(); if(SNDCore && SPU_user) { SNDCore->DeInit(); SNDCore->Init(SPU_user->bufsize*2); //todo - check success? } // Reset Registers for (i = 0x400; i < 0x51D; i++) T1WriteByte(MMU.ARM7_REG, i, 0); }
extern "C" void SPU_Reset(NDS_state *state) { int i; state->SPU_core->reset(); if(state->SPU_user) state->SPU_user->reset(); if(state->SNDCore && state->SPU_user) { state->SNDCore->DeInit(state); state->SNDCore->Init(state, state->SPU_user->bufsize*2); //todo - check success? } // Reset Registers for (i = 0x400; i < 0x51D; i++) T1WriteByte(state->MMU->ARM7_REG, i, 0); state->samples = 0; }
void SPU_Reset(void) { int i; SPU_core->reset(); if(SPU_user) { //--DCN: Originally this was first; //SPU_user->reset(); if(SNDCore) { SNDCore->DeInit(); SNDCore->Init(SPU_user->bufsize*2); SNDCore->SetVolume(volume); } SPU_user->reset(); } // Reset Registers for (i = 0x400; i < 0x51D; i++) T1WriteByte(MMU.ARM7_REG, i, 0); samples = 0; }
void FASTCALL Vdp1RamWriteByte(u32 addr, u8 val) { addr &= 0x7FFFF; T1WriteByte(Vdp1Ram, addr, val); }
static void FASTCALL BupRamMemoryWriteByte(u32 addr, u8 val) { T1WriteByte(BupRam, (addr & 0xFFFF) | 0x1, val); BupRamWritten = 1; }