feat: implement EEPROM

This commit is contained in:
2022-10-21 05:12:38 -03:00
parent 084d4b28dd
commit 746c28004f
3 changed files with 329 additions and 11 deletions

View File

@@ -173,7 +173,7 @@ pub fn write(self: *Self, comptime T: type, address: u32, value: T) void {
0x07 => self.ppu.oam.write(T, align_addr, value),
// External Memory (Game Pak)
0x08...0x0D => {}, // EEPROM
0x08...0x0D => self.pak.write(T, self.dma._3.word_count, align_addr, value),
0x0E...0x0F => {
const rotate_by = switch (T) {
u32 => address & 3,