bus/nes: Added support for Y2K 420 in 1. (#8622)

New working software list additions (nes.xml)
-----------------------------------
Y2K 420 in 1 [BootGod]
This commit is contained in:
0kmg 2021-09-27 18:59:23 -08:00 committed by GitHub
parent fba640eb41
commit bb492c0dba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 109 additions and 3 deletions

View File

@ -80344,6 +80344,21 @@ be better to redump them properly. -->
</part>
</software>
<software name="mc_420y2">
<description>Y2K 420 in 1</description>
<year>19??</year>
<publisher>&lt;pirate&gt;</publisher>
<part name="cart" interface="nes_cart">
<feature name="slot" value="bmc_420y2k" />
<dataarea name="prg" size="1048576">
<rom name="teletubbies y2k (420-in-1).prg" size="1048576" crc="272709b9" sha1="fd795bdb46dbd15b3252500d2a9787c8acc6ba20" status="baddump" />
</dataarea>
<!-- 8k VRAM on cartridge -->
<dataarea name="vram" size="8192">
</dataarea>
</part>
</software>
<software name="mc_45" supported="partial">
<description>45 in 1 (JY-120A)</description>
<year>19??</year>

View File

@ -66,7 +66,8 @@ DEFINE_DEVICE_TYPE(NES_BMC_HIK300, nes_bmc_hik300_device, "nes_bmc_hik30
DEFINE_DEVICE_TYPE(NES_BMC_S700, nes_bmc_s700_device, "nes_bmc_s700", "NES Cart BMC Super 700 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_BALL11, nes_bmc_ball11_device, "nes_bmc_ball11", "NES Cart BMC Ball 11 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_22GAMES, nes_bmc_22games_device, "nes_bmc_22games", "NES Cart BMC 22 Games PCB")
DEFINE_DEVICE_TYPE(NES_BMC_64Y2K, nes_bmc_64y2k_device, "nes_bmc_64y2k", "NES Cart BMC 64 in 1 Y2K PCB")
DEFINE_DEVICE_TYPE(NES_BMC_64Y2K, nes_bmc_64y2k_device, "nes_bmc_64y2k", "NES Cart BMC Y2K 64 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_420Y2K, nes_bmc_420y2k_device, "nes_bmc_420y2k", "NES Cart BMC Y2K 420 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_12IN1, nes_bmc_12in1_device, "nes_bmc_12in1", "NES Cart BMC 12 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_20IN1, nes_bmc_20in1_device, "nes_bmc_20in1", "NES Cart BMC 20 in 1 PCB")
DEFINE_DEVICE_TYPE(NES_BMC_21IN1, nes_bmc_21in1_device, "nes_bmc_21in1", "NES Cart BMC 21 in 1 PCB")
@ -305,6 +306,11 @@ nes_bmc_64y2k_device::nes_bmc_64y2k_device(const machine_config &mconfig, const
{
}
nes_bmc_420y2k_device::nes_bmc_420y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
: nes_nrom_device(mconfig, NES_BMC_420Y2K, tag, owner, clock), m_latch(0), m_reg(0)
{
}
nes_bmc_12in1_device::nes_bmc_12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
: nes_nrom_device(mconfig, NES_BMC_12IN1, tag, owner, clock)
{
@ -824,6 +830,23 @@ void nes_bmc_64y2k_device::pcb_reset()
set_nt_mirroring(PPU_MIRROR_VERT);
}
void nes_bmc_420y2k_device::device_start()
{
common_start();
save_item(NAME(m_latch));
save_item(NAME(m_reg));
}
void nes_bmc_420y2k_device::pcb_reset()
{
prg16_89ab(0);
prg16_cdef(7);
chr8(0, CHRRAM);
m_latch = 0;
m_reg = 0;
}
void nes_bmc_12in1_device::device_start()
{
common_start();
@ -2226,6 +2249,48 @@ void nes_bmc_64y2k_device::write_h(offs_t offset, uint8_t data)
m_reg[3] = data; // reg[3] is currently unused?!?
}
/*-------------------------------------------------
Board BMC-TELETUBBIES
(name assigned by BootGod who said the board has
no markings, a glop top, and an 8K VRAM chip)
Games: Y2K 420 in 1
iNES: mapper 237
In MAME: Supported.
-------------------------------------------------*/
void nes_bmc_420y2k_device::write_h(offs_t offset, u8 data)
{
LOG_MMC(("bmc_420y2k write_h, offset: %04x, data: %02x\n", offset, data));
if (BIT(m_latch, 1)) // lock bit
m_reg = (m_reg & ~0x07) | (data & 0x07);
else
{
m_latch = offset;
m_reg = data;
}
u8 bank = BIT(m_latch, 2) << 5 | (m_reg & 0x1f);
u8 mode = BIT(m_reg, 6);
prg16_89ab(bank & ~mode); // strangely for UNROM games it DOESN'T ignore the NROM mode bit
prg16_cdef(bank | (BIT(m_reg, 7) ? mode : 0x07));
set_nt_mirroring(BIT(m_reg, 5) ? PPU_MIRROR_HORZ : PPU_MIRROR_VERT);
}
u8 nes_bmc_420y2k_device::read_h(offs_t offset)
{
LOG_MMC(("bmc_420y2k read_h, offset: %04x\n", offset));
// latch bit 0 is only used to determine the menu, and the behavior of
// this cart seems hardwired to OR $02 (ORing $00-$03 allows four menus)
return hi_access_rom(offset | (m_latch & 1) << 1);
}
/*-------------------------------------------------
BMC-12IN1

View File

@ -672,6 +672,28 @@ private:
};
// ======================> nes_bmc_420y2k_device
class nes_bmc_420y2k_device : public nes_nrom_device
{
public:
// construction/destruction
nes_bmc_420y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
virtual u8 read_h(offs_t offset) override;
virtual void write_h(offs_t offset, u8 data) override;
virtual void pcb_reset() override;
protected:
// device-level overrides
virtual void device_start() override;
private:
u8 m_latch, m_reg;
};
// ======================> nes_bmc_12in1_device
class nes_bmc_12in1_device : public nes_nrom_device
@ -1141,6 +1163,7 @@ DECLARE_DEVICE_TYPE(NES_BMC_S700, nes_bmc_s700_device)
DECLARE_DEVICE_TYPE(NES_BMC_BALL11, nes_bmc_ball11_device)
DECLARE_DEVICE_TYPE(NES_BMC_22GAMES, nes_bmc_22games_device)
DECLARE_DEVICE_TYPE(NES_BMC_64Y2K, nes_bmc_64y2k_device)
DECLARE_DEVICE_TYPE(NES_BMC_420Y2K, nes_bmc_420y2k_device)
DECLARE_DEVICE_TYPE(NES_BMC_12IN1, nes_bmc_12in1_device)
DECLARE_DEVICE_TYPE(NES_BMC_20IN1, nes_bmc_20in1_device)
DECLARE_DEVICE_TYPE(NES_BMC_21IN1, nes_bmc_21in1_device)

View File

@ -401,6 +401,7 @@ void nes_cart(device_slot_interface &device)
device.option_add_internal("bmc_ball11", NES_BMC_BALL11);
device.option_add_internal("bmc_22games", NES_BMC_22GAMES);
device.option_add_internal("bmc_64y2k", NES_BMC_64Y2K);
device.option_add_internal("bmc_420y2k", NES_BMC_420Y2K);
device.option_add_internal("bmc_12in1", NES_BMC_12IN1);
device.option_add_internal("bmc_20in1", NES_BMC_20IN1);
device.option_add_internal("bmc_21in1", NES_BMC_21IN1);

View File

@ -270,7 +270,7 @@ static const nes_mmc mmc_list[] =
{ 234, AVE_MAXI15 },
{ 235, BMC_GOLD150 }, // 235 Golden Game x-in-1 - Unsupported
{ 236, BMC_70IN1 },
// 237 Teletubbies 420-in-1 multicart. Dump available?
{ 237, BMC_TELETUBBIES },
{ 238, UNL_603_5052 },
// 239 Unused
{ 240, CNE_SHLZ },

View File

@ -278,6 +278,7 @@ static const nes_pcb pcb_list[] =
{ "bmc_ball11", BMC_BALLGAMES_11IN1 },
{ "bmc_22games", BMC_22GAMES },
{ "bmc_64y2k", BMC_64IN1NR },
{ "bmc_420y2k", BMC_TELETUBBIES },
{ "bmc_12in1", BMC_12IN1 },
{ "bmc_20in1", BMC_20IN1 },
{ "bmc_21in1", BMC_21IN1 },

View File

@ -86,7 +86,7 @@ enum
TXC_MJBLOCK, TXC_STRIKEW, TXC_TW,
// Multigame Carts
BMC_64IN1NR, BMC_190IN1, BMC_A65AS, BMC_A88S1, BMC_F15,
BMC_GN45, BMC_HIK8IN1, BMC_S24IN1SC03, BMC_T262,
BMC_GN45, BMC_HIK8IN1, BMC_S24IN1SC03, BMC_T262, BMC_TELETUBBIES,
BMC_WS, BMC_SUPERBIG_7IN1, BMC_SUPERHIK_4IN1, BMC_BALLGAMES_11IN1,
BMC_MARIOPARTY_7IN1, BMC_GOLD_7IN1, BMC_SUPER_700IN1, BMC_FAMILY_4646,
BMC_36IN1, BMC_21IN1, BMC_150IN1, BMC_35IN1, BMC_64IN1,

View File

@ -80,6 +80,7 @@ void nes_state::machine_start()
BMC_800IN1,
BMC_8157,
BMC_GOLD150,
BMC_TELETUBBIES,
BMC_VT5201,
BTL_PALTHENA,
CAMERICA_ALADDIN,