From 66dfc8b4e9b1d528b604ea3bd4acdcb83667b163 Mon Sep 17 00:00:00 2001 From: nsx0r Date: Tue, 18 Jul 2023 07:17:17 +0200 Subject: [NES] fix mapper 148 --- Cart_Reader/NES.ino | 23 ++--------------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/Cart_Reader/NES.ino b/Cart_Reader/NES.ino index 9bdd4a9..f958b3e 100644 --- a/Cart_Reader/NES.ino +++ b/Cart_Reader/NES.ino @@ -3331,9 +3331,10 @@ void readCHR(bool readrom) { break; case 3: // 8K/16K/32K - bus conflicts + case 148: // Sachen SA-008-A and Tengen 800008 - Bus conflicts banks = int_pow(2, chrsize) / 2; for (size_t i = 0; i < banks; i++) { - for (size_t x = 0; x < 0x2000; x++) { + for (size_t x = 0; x < 0x8000; x++) { if (read_prg_byte(0x8000 + x) == i) { write_prg_byte(0x8000 + x, i); break; @@ -4063,26 +4064,6 @@ void readCHR(bool readrom) { } break; - case 148: // Sachen SA-008-A and Tengen 800008 -- Bus conflicts - banks = int_pow(2, chrsize); - busConflict = true; - for (size_t i = 0; i < banks; i++) { - for (size_t x = 0; x < 0x8000; x++) { - if (read_prg_byte(0x8000 + x) == i) { - write_prg_byte(0x8000 + x, i & 0x07); - busConflict = false; - break; - } - } - if (busConflict) { - write_prg_byte(0x8000 + i, i & 0x07); - } - for (size_t address = 0x0; address < 0x2000; address += 512) { - dumpCHR(address); - } - } - break; - case 174: // 64k for (size_t i = 0; i < 8; i++) { write_prg_byte(0xFF00 + (i << 1), 0); -- cgit v1.2.3