Skip to content

Commit

Permalink
Update NES.ino : added mapper 268 submapper 0
Browse files Browse the repository at this point in the history
Update NES.ino : added mapper 268 submapper 0
  • Loading branch information
nsx0r authored Nov 14, 2024
1 parent 970edb8 commit 443f33e
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions Cart_Reader/NES.ino
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ static const struct mapper_NES PROGMEM mapsize[] = {
{ 246, 5, 5, 7, 7, 0, 0 }, // C&E Feng Shen Bang [UNLICENSED]
// 248 - bad mapper, not used
{ 255, 4, 7, 5, 8, 0, 0 }, // 110-in-1 multicart (same as 225) [UNLICENSED]
{ 268, 0, 11, 0, 0, 0, 0 }, // MindKids/CoolGirl submapper 0
{ 446, 0, 8, 0, 0, 0, 0 }, // Mindkids SMD172B_FGPA submapper 0 & 1
{ 552, 0, 5, 0, 6, 0, 0 } // Taito X1-017 actual bank order
};
Expand Down Expand Up @@ -2738,6 +2739,21 @@ void readPRG(bool readrom) {
}
break;

case 268: // submapper 0
banks = int_pow(2, prgsize) * 2;
for (size_t i = 0; i < banks; i++) {
write_prg_byte(0x6000, ((i & 0x70) >> 4) | ((i & 0xC00) >> 6));
write_prg_byte(0x6001, ((i & 0x80) >> 3) | ((i & 0x300) >> 6) | 0x60);
write_prg_byte(0x6002, 0x00);
write_prg_byte(0x6003, 0x00);
write_prg_byte(0x8000, 6);
write_prg_byte(0x8001, i);
for (size_t address = 0x0; address < 0x2000; address += 512) {
dumpPRG(base, address);
}
}
break;

case 446:
banks = int_pow(2, prgsize) * 2;
write_prg_byte(0x5003, 0);
Expand Down

0 comments on commit 443f33e

Please sign in to comment.