MBC3 work
This commit is contained in:
@@ -51,8 +51,7 @@ Byte *AddressSpace::MBCRead(const Word address) {
|
|||||||
return &twoBitBankRegister;
|
return &twoBitBankRegister;
|
||||||
if (address <= 0x7FFF)
|
if (address <= 0x7FFF)
|
||||||
return &romRamSelect;
|
return &romRamSelect;
|
||||||
}
|
} else if (MBC == MBC1Ram || MBC == MBC1RamBattery) {
|
||||||
if (MBC == MBC1Ram || MBC == MBC1RamBattery) {
|
|
||||||
if (address <= 0x1FFF)
|
if (address <= 0x1FFF)
|
||||||
return &ramEnable;
|
return &ramEnable;
|
||||||
// bits 0-4
|
// bits 0-4
|
||||||
@@ -63,14 +62,16 @@ Byte *AddressSpace::MBCRead(const Word address) {
|
|||||||
}
|
}
|
||||||
if (address <= 0x7FFF)
|
if (address <= 0x7FFF)
|
||||||
return &romRamSelect;
|
return &romRamSelect;
|
||||||
}
|
} else if (MBC == MBC2 || MBC == MBC2Battery) {
|
||||||
if (MBC == MBC2 || MBC == MBC2Battery) {
|
|
||||||
if (address <= 0x3FFF) {
|
if (address <= 0x3FFF) {
|
||||||
if (address & 0x0100)
|
if (address & 0x0100)
|
||||||
return &romBankRegister;
|
return &romBankRegister;
|
||||||
else
|
else
|
||||||
return &ramEnable;
|
return &ramEnable;
|
||||||
}
|
}
|
||||||
|
} else if (MBC == MBC3 || MBC == MBC3TimerBattery) {
|
||||||
|
} else if (MBC == MBC3Ram || MBC == MBC3RamBattery ||
|
||||||
|
MBC == MBC3TimerRamBattery) {
|
||||||
}
|
}
|
||||||
return &dummyVal;
|
return &dummyVal;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user