Add mapper 541

This commit is contained in:
negativeExponent
2020-01-28 11:06:43 +08:00
parent dca5ff5a1a
commit 371e949ba1
3 changed files with 23 additions and 2 deletions

View File

@@ -472,6 +472,25 @@ void Mapper242_Init(CartInfo *info) {
Latch_Init(info, M242Sync, NULL, 0x0000, 0x8000, 0xFFFF, 1);
}
/*------------------ Map 541 ---------------------------*/
/* LittleCom 160-in-1 multicart */
static void M541Sync(void) {
if (latche & 2) {
/* NROM-128 */
setprg16(0x8000, latche >> 2);
setprg16(0xC000, latche >> 2);
} else {
/* NROM=256 */
setprg32(0x8000, latche >> 3);
}
setchr8(0);
setmirror(latche & 1);
}
void Mapper541_Init(CartInfo *info) {
Latch_Init(info, M541Sync, NULL, 0x0000, 0xC000, 0xFFFF, 0);
}
/*------------------ 190in1 ---------------------------*/
static void BMC190in1Sync(void) {

View File

@@ -659,9 +659,10 @@ static BMAPPINGLocal bmap[] = {
{(uint8_t*)"OK-411", 361, GN45_Init}, /* OK-411 is emulated together with GN-45 */
{(uint8_t*)"HUMMER/JY-052", 281, Mapper281_Init},
{(uint8_t*)"GN-45", 366, GN45_Init},
{(uint8_t*)"Bit Corp 4-in-1", 357, Mapper357_Init },
{(uint8_t*)"MMC3 PIRATE SFC-12", 372, Mapper372_Init },
{(uint8_t*)"LittleCom 160-in-1", 541, Mapper541_Init },
/* UNIF to NES 2.0 BOARDS */

View File

@@ -244,6 +244,7 @@ void NC7000M_Init(CartInfo *);
void J2282_Init(CartInfo *);
void Mapper357_Init(CartInfo *);
void Mapper372_Init(CartInfo *info);
void Mapper372_Init(CartInfo *);
void Mapper541_Init(CartInfo *);
#endif