Merge pull request #8398 from 0kmg/nes-mappers-174,267

bus/nes: Added support for 8-in-1 and 5-in-1 multicarts.
This commit is contained in:
ajrhacker 2021-08-05 16:19:55 -04:00 committed by GitHub
commit 63e44c5537
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 154 additions and 7 deletions

View File

@ -51731,6 +51731,21 @@ preliminary proto for the PAL version, still running on NTSC systems) or the gfx
</part>
</software>
<software name="mc_8j119">
<description>FC Genjin 8 in 1 (JY-119)</description>
<year>199?</year>
<publisher>J.Y. Company</publisher>
<part name="cart" interface="nes_cart">
<feature name="slot" value="fcgj8in1" />
<dataarea name="prg" size="2097152">
<rom name="8-in-1 (jy-119).prg" size="2097152" crc="acb1f4e9" sha1="e65bf41010b4f3d4692b458698e355c233ecd729" status="baddump" />
</dataarea>
<dataarea name="chr" size="1048576">
<rom name="8-in-1 (jy-119).chr" size="1048576" crc="f4df8173" sha1="911ff9555fa908cda9fbc6347111b104f6510d4b" status="baddump" />
</dataarea>
</part>
</software>
<!-- Sachen / Thin Chen (and clones) -->
@ -79629,6 +79644,22 @@ be better to redump them properly. -->
</part>
</software>
<software name="mc_5tvg">
<description>TV Game 5 in 1</description>
<year>1989</year>
<publisher>NTDEC</publisher>
<part name="cart" interface="nes_cart">
<feature name="slot" value="bmc_2751" />
<feature name="pcb_model" value="2751" />
<dataarea name="prg" size="131072">
<rom name="5909-p" size="131072" crc="03679817" sha1="a8787e1a1e1a350f5ca85c9f9eed0d6403bfa4e8" status="baddump" />
</dataarea>
<dataarea name="chr" size="65536">
<rom name="5802-c" size="65536" crc="eb6d0182" sha1="c4019ff0dd390d2b753995f0638d2a28044ad4c4" status="baddump" />
</dataarea>
</part>
</software>
<software name="mc_52gam">
<description>52 Games</description>
<year>19??</year>

View File

@ -50,8 +50,9 @@ DEFINE_DEVICE_TYPE(NES_SA9602B, nes_sa9602b_device, "nes_sa9602b",
DEFINE_DEVICE_TYPE(NES_SACHEN_SHERO, nes_sachen_shero_device, "nes_shero", "NES Cart Street Hero PCB")
//DEFINE_DEVICE_TYPE(NES_A9746, nes_a9746_device, "nes_bmc_a9746", "NES Cart A-9746 PCB")
DEFINE_DEVICE_TYPE(NES_FK23C, nes_fk23c_device, "nes_kf23c", "NES Cart KF23C PCB")
DEFINE_DEVICE_TYPE(NES_FK23CA, nes_fk23ca_device, "nes_kf23ca", "NES Cart KF23CA PCB")
DEFINE_DEVICE_TYPE(NES_FCGJ8IN1, nes_fcgj8in1_device, "nes_fcgj8in1", "NES Cart BMC FC Genjin 8 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_FK23C, nes_fk23c_device, "nes_fk23c", "NES Cart FK23C PCB")
DEFINE_DEVICE_TYPE(NES_FK23CA, nes_fk23ca_device, "nes_fk23ca", "NES Cart FK23CA PCB")
DEFINE_DEVICE_TYPE(NES_S24IN1SC03, nes_s24in1sc03_device, "nes_s24in1c03", "NES Cart Super 24 in 1 SC-03 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_15IN1, nes_bmc_15in1_device, "nes_bmc_15in1", "NES Cart BMC 15 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_SBIG7, nes_bmc_sbig7_device, "nes_bmc_sbig7", "NES Cart BMC Super BIG 7 in 1 PCB")
@ -172,6 +173,11 @@ nes_sachen_shero_device::nes_sachen_shero_device(const machine_config &mconfig,
//{
//}
nes_fcgj8in1_device::nes_fcgj8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
: nes_txrom_device(mconfig, NES_FCGJ8IN1, tag, owner, clock)
{
}
nes_fk23c_device::nes_fk23c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
: nes_txrom_device(mconfig, type, tag, owner, clock), m_mmc_cmd1(0)
{
@ -445,6 +451,12 @@ void nes_sachen_shero_device::pcb_reset()
mmc3_common_initialize(0xff, 0x1ff, 0);
}
void nes_fcgj8in1_device::pcb_reset()
{
m_chr_source = m_vrom_chunks ? CHRROM : CHRRAM;
mmc3_common_initialize(0x1f, 0x7f, 0);
}
void nes_fk23c_device::device_start()
{
mmc3_start();
@ -464,7 +476,6 @@ void nes_fk23c_device::pcb_reset()
mmc3_common_initialize(0xff, 0xff, 0);
fk23c_set_prg();
fk23c_set_chr();
}
void nes_fk23ca_device::pcb_reset()
@ -2203,6 +2214,33 @@ void nes_bmc_mario7in1_device::write_m(offs_t offset, uint8_t data)
m_prgram[offset] = data;
}
/*-------------------------------------------------
BMC-FCGENJIN-8IN1
Unknown Multigame Bootleg Board
Games: 8 in 1 (JY-119)
MMC3 clone with banking for multigame menu.
NES 2.0: mapper 267
In MAME: Supported.
-------------------------------------------------*/
void nes_fcgj8in1_device::write_m(offs_t offset, u8 data)
{
LOG_MMC(("fcgj8in1 write_m, offset: %04x, data: %02x\n", offset, data));
if (!(offset & 0x1000)) // game only banks via 0x6000, this mask is a guess
{
m_prg_base = (data & 0x20) << 2 | (data & 0x06) << 4;
set_prg(m_prg_base, m_prg_mask);
m_chr_base = m_prg_base << 2;
set_chr(m_chr_source, m_chr_base, m_chr_mask);
}
}
/*-------------------------------------------------
BMC-GOLD-7IN1

View File

@ -433,6 +433,20 @@ private:
#endif
// ======================> nes_fcgj8in1_device
class nes_fcgj8in1_device : public nes_txrom_device
{
public:
// construction/destruction
nes_fcgj8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
virtual void write_m(offs_t offset, u8 data) override;
virtual void pcb_reset() override;
};
// ======================> nes_fk23c_device
class nes_fk23c_device : public nes_txrom_device
@ -755,6 +769,7 @@ DECLARE_DEVICE_TYPE(NES_SACHEN_SHERO, nes_sachen_shero_device)
DECLARE_DEVICE_TYPE(NES_A9746, nes_a9746_device)
#endif
DECLARE_DEVICE_TYPE(NES_FCGJ8IN1, nes_fcgj8in1_device)
DECLARE_DEVICE_TYPE(NES_FK23C, nes_fk23c_device)
DECLARE_DEVICE_TYPE(NES_FK23CA, nes_fk23ca_device)
DECLARE_DEVICE_TYPE(NES_S24IN1SC03, nes_s24in1sc03_device)

View File

@ -55,6 +55,7 @@ DEFINE_DEVICE_TYPE(NES_BMC_TJ03, nes_bmc_tj03_device, "nes_bmc_tj03"
DEFINE_DEVICE_TYPE(NES_BMC_WS, nes_bmc_ws_device, "nes_bmc_ws", "NES Cart BMC WS PCB")
DEFINE_DEVICE_TYPE(NES_BMC_11160, nes_bmc_11160_device, "nes_bmc_1160", "NES Cart BMC-1160 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_G146, nes_bmc_g146_device, "nes_bmc_g146", "NES Cart BMC-G-146 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_2751, nes_bmc_2751_device, "nes_bmc_2751", "NES Cart BMC-2751 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_8157, nes_bmc_8157_device, "nes_bmc_8157", "NES Cart BMC-8157 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_HIK300, nes_bmc_hik300_device, "nes_bmc_hik300", "NES Cart BMC HIK 300 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_S700, nes_bmc_s700_device, "nes_bmc_s700", "NES Cart BMC Super 700 in 1 PCB")
@ -220,6 +221,11 @@ nes_bmc_g146_device::nes_bmc_g146_device(const machine_config &mconfig, const ch
{
}
nes_bmc_2751_device::nes_bmc_2751_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
: nes_nrom_device(mconfig, NES_BMC_2751, tag, owner, clock)
{
}
nes_bmc_8157_device::nes_bmc_8157_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
: nes_nrom_device(mconfig, NES_BMC_8157, tag, owner, clock)
{
@ -724,6 +730,19 @@ void nes_bmc_g146_device::pcb_reset()
chr8(0, m_chr_source);
}
void nes_bmc_2751_device::pcb_start(running_machine &machine, u8 *ciram_ptr, bool cart_mounted)
{
device_nes_cart_interface::pcb_start(machine, ciram_ptr, cart_mounted);
prg16_89ab(0);
prg16_cdef(0);
chr8(0, CHRROM);
}
void nes_bmc_2751_device::pcb_reset()
{
// this board does not reset to menu on soft reset
}
void nes_bmc_8157_device::device_start()
{
common_start();
@ -1939,6 +1958,29 @@ void nes_bmc_g146_device::write_h(offs_t offset, uint8_t data)
set_nt_mirroring(!BIT(offset, 7) ? PPU_MIRROR_HORZ : PPU_MIRROR_VERT);
}
/*-------------------------------------------------
Board BMC-2751
Games: 5 in 1
iNES: mapper 174
In MAME: Supported.
-------------------------------------------------*/
void nes_bmc_2751_device::write_h(offs_t offset, u8 data)
{
LOG_MMC(("bmc_2751 write_h, offset: %04x, data: %02x\n", offset, data));
u8 bank = (offset >> 4) & 0x07;
u8 mode = BIT(offset, 7);
prg16_89ab(bank & ~mode);
prg16_cdef(bank | mode);
chr8((offset >> 1) & 0x07, CHRROM);
set_nt_mirroring(BIT(offset, 0) ? PPU_MIRROR_HORZ : PPU_MIRROR_VERT);
}
/*-------------------------------------------------
Board BMC-8157

View File

@ -526,6 +526,21 @@ protected:
};
// ======================> nes_bmc_2751_device
class nes_bmc_2751_device : public nes_nrom_device
{
public:
// construction/destruction
nes_bmc_2751_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
virtual void write_h(offs_t offset, u8 data) override;
virtual void pcb_reset() override;
virtual void pcb_start(running_machine &machine, u8 *ciram_ptr, bool cart_mounted) override;
};
// ======================> nes_bmc_8157_device
class nes_bmc_8157_device : public nes_nrom_device
@ -1092,6 +1107,7 @@ DECLARE_DEVICE_TYPE(NES_BMC_TJ03, nes_bmc_tj03_device)
DECLARE_DEVICE_TYPE(NES_BMC_WS, nes_bmc_ws_device)
DECLARE_DEVICE_TYPE(NES_BMC_11160, nes_bmc_11160_device)
DECLARE_DEVICE_TYPE(NES_BMC_G146, nes_bmc_g146_device)
DECLARE_DEVICE_TYPE(NES_BMC_2751, nes_bmc_2751_device)
DECLARE_DEVICE_TYPE(NES_BMC_8157, nes_bmc_8157_device)
DECLARE_DEVICE_TYPE(NES_BMC_HIK300, nes_bmc_hik300_device)
DECLARE_DEVICE_TYPE(NES_BMC_S700, nes_bmc_s700_device)

View File

@ -378,6 +378,7 @@ void nes_cart(device_slot_interface &device)
device.option_add_internal("bmc_ws", NES_BMC_WS);
device.option_add_internal("bmc_g146", NES_BMC_G146);
device.option_add_internal("bmc_11160", NES_BMC_11160);
device.option_add_internal("bmc_2751", NES_BMC_2751);
device.option_add_internal("bmc_8157", NES_BMC_8157);
device.option_add_internal("bmc_hik300", NES_BMC_HIK300);
device.option_add_internal("bmc_s700", NES_BMC_S700);
@ -408,6 +409,7 @@ void nes_cart(device_slot_interface &device)
device.option_add_internal("bmc_reset42", NES_BMC_42IN1RESET); // mapper 226? or 233?
device.option_add_internal("bmc_lc160", NES_BMC_LC160);
// misc multigame cart MMC3 clone boards
device.option_add_internal("fcgj8in1", NES_FCGJ8IN1);
device.option_add_internal("fk23c", NES_FK23C);
device.option_add_internal("fk23ca", NES_FK23CA);
device.option_add_internal("s24in1c03", NES_S24IN1SC03);

View File

@ -207,7 +207,7 @@ static const nes_mmc mmc_list[] =
{ 171, KAISER_KS7058 },
{ 172, TXC_DUMARACING },
{ 173, TXC_MJBLOCK },
// 174 Bisqwit's TV GAME multicart (Legend of Kage, Goonies, etc). Dump available?
{ 174, BMC_2751 },
{ 175, KAISER_KS7022},
{ 176, UNL_XIAOZY },
{ 177, HENGG_SRICH },
@ -302,7 +302,7 @@ static const nes_mmc mmc_list[] =
{ 264, YOKO_BOARD },
{ 265, BMC_T262 },
{ 266, UNL_CITYFIGHT },
// 267 8 in 1 JY-119 multicart, not in nes.xml?
{ 267, BMC_FCGENJIN_8IN1 },
// 268 COOLBOY and MINDKIDS
// 269 mc_gx121 seems to be a PnP, but there are two actual multicarts for this mapper?
// 270 multicarts on OneBus Famiclones

View File

@ -282,9 +282,11 @@ static const nes_pcb pcb_list[] =
{ "bmc_190in1", BMC_190IN1 },
{ "bmc_800in1", BMC_800IN1 },
{ "bmc_1200in1", BMC_1200IN1 },
{ "bmc_2751", BMC_2751 },
{ "bmc_8157", BMC_8157 },
{ "bmc_g146", BMC_G146 },
{ "bmc_11160", BMC_11160 },
{ "fcgj8in1", BMC_FCGENJIN_8IN1 },
{ "fk23c", BMC_FK23C },
{ "fk23ca", BMC_FK23CA },
{ "s24in1c03", BMC_S24IN1SC03 },

View File

@ -96,8 +96,9 @@ enum
BMC_31IN1, BMC_22GAMES, BMC_20IN1, BMC_110IN1,
BMC_70IN1, BMC_800IN1, BMC_1200IN1,
BMC_GKA, BMC_GKB, BMC_VT5201, BMC_BENSHIENG, BMC_80013B, BMC_810544C,
BMC_NTD_03, BMC_G63IN1, BMC_FK23C, BMC_FK23CA, BMC_PJOY84,
BMC_POWERFUL_255, BMC_11160, BMC_G146, BMC_8157, BMC_830118C, BMC_841101C,
BMC_NTD_03, BMC_G63IN1, BMC_FCGENJIN_8IN1, BMC_FK23C, BMC_FK23CA,
BMC_PJOY84, BMC_POWERFUL_255, BMC_11160, BMC_G146,
BMC_2751, BMC_8157, BMC_830118C, BMC_841101C,
BMC_411120C, BMC_GOLD150, BMC_GOLD260, BMC_CH001, BMC_SUPER22,
BMC_12IN1, BMC_4IN1RESET, BMC_42IN1RESET, BMC_LITTLECOM160,
BMC_CTC09, BMC_K3046, BMC_SA005A, BMC_TJ03,