diff --git a/src/gb/memory.c b/src/gb/memory.c index 50a92b3d7..abe930c95 100644 --- a/src/gb/memory.c +++ b/src/gb/memory.c @@ -62,6 +62,7 @@ void GBMemoryReset(struct GB* gb) { gb->memory.wram = anonymousMemoryMap(GB_SIZE_WORKING_RAM); gb->memory.wramBank = &gb->memory.wram[GB_SIZE_WORKING_RAM_BANK0]; gb->memory.romBank = &gb->memory.rom[GB_SIZE_CART_BANK0]; + gb->memory.currentBank = 1; const struct GBCartridge* cart = &gb->memory.rom[0x100]; switch (cart->type) { diff --git a/src/lr35902/lr35902.c b/src/lr35902/lr35902.c index 5e0d1bbea..f957218c7 100644 --- a/src/lr35902/lr35902.c +++ b/src/lr35902/lr35902.c @@ -66,6 +66,7 @@ void LR35902Reset(struct LR35902Core* cpu) { cpu->executionState = LR35902_CORE_FETCH; cpu->halted = 0; + cpu->irqPending = false; cpu->irqh.reset(cpu); }