From 3a2e4c0c509654e616035c1806b0cb8251cc6b99 Mon Sep 17 00:00:00 2001 From: David Haywood <28625134+DavidHaywood@users.noreply.github.com> Date: Mon, 1 Jun 2020 14:01:43 +0100 Subject: [PATCH] Plug and Play work (#6774) * various SunPlus updates + new sets from Sean (nw) * tweak, still not correct tho (nw) * new working machines ----- Genesis Collection Volume 2 (Radica, Arcade Legends) (USA) [Sean Riddle, David Haywood, Kev (FBN), anonymous] * new WORKING machines ---- Vs Power Plus [Sean Riddle, Dave 'Foxhack' Silva] * (nw) * (nw) --- src/devices/machine/spg2xx_video.cpp | 58 +++++++++++---- src/devices/machine/spg2xx_video.h | 2 +- src/mame/drivers/megadriv_rad.cpp | 8 ++- src/mame/drivers/nes_vt.cpp | 31 ++++++-- src/mame/drivers/spg29x.cpp | 101 ++++++++++++++++++++++++--- src/mame/drivers/spg2xx.cpp | 14 ++-- src/mame/drivers/spg2xx_lexibook.cpp | 79 +++++++++++++++++++++ src/mame/mame.lst | 5 ++ 8 files changed, 263 insertions(+), 35 deletions(-) diff --git a/src/devices/machine/spg2xx_video.cpp b/src/devices/machine/spg2xx_video.cpp index 2b74571fd12..63521609cdc 100644 --- a/src/devices/machine/spg2xx_video.cpp +++ b/src/devices/machine/spg2xx_video.cpp @@ -67,6 +67,10 @@ void spg2xx_video_device::device_start() save_item(NAME(m_video_regs)); + save_item(NAME(m_ycmp_table)); + + + m_sprlimit_read_cb.resolve_safe(0); m_video_irq_cb.resolve(); @@ -83,7 +87,7 @@ void spg2xx_video_device::device_reset() for (int i = 0; i < 480; i++) { - m_ycmp_table[i] = -1; + m_ycmp_table[i] = 0xffffffff; } } @@ -208,29 +212,44 @@ bool spg2xx_video_device::get_tile_info(uint32_t tilemap_rambase, uint32_t palet return true; } - - +// 3 is good +// this builds up a line table for the vcmp effect, this is not correct when step is used void spg2xx_video_device::update_vcmp_table() { + int currentline = 0; + + int step = m_video_regs[0x1e] & 0xff; + if (step & 0x80) + step = step - 0x100; + + int current_inc_value = (m_video_regs[0x1c]<<4); + + int counter = 0; + for (int i = 0; i < 480; i++) { - int currentline = 0; - if (i < m_video_regs[0x1d]) { - m_ycmp_table[i] = -1; + m_ycmp_table[i] = 0xffffffff; } else { - if (currentline < 240) + if ((currentline >= 0) && (currentline < 240)) { m_ycmp_table[i] = currentline; - currentline += m_video_regs[0x1c]; } - else + + counter += current_inc_value; + + while (counter >= (0x20<<4)) { - m_ycmp_table[i] = -1; + currentline++; + current_inc_value += step; + + counter -= (0x20<<4); } + + } } } @@ -311,6 +330,21 @@ void spg2xx_video_device::draw_page(const rectangle &cliprect, uint32_t* dst, ui return; } + uint32_t logical_scanline = scanline; + + if (ctrl & 0x0040) // 'vertical compression feature' (later models only?) + { + if (m_video_regs[0x1e] != 0x0000) + popmessage("vertical compression mode with non-0 step amount %04x offset %04x step %04x\n", m_video_regs[0x1c], m_video_regs[0x1d], m_video_regs[0x1e]); + + logical_scanline = m_ycmp_table[scanline]; + if (logical_scanline == 0xffffffff) + return; + + //logical_scanline >>= 5; + } + + const uint32_t xscroll = regs[0]; const uint32_t yscroll = regs[1]; const uint32_t tilemap_rambase = regs[4]; @@ -319,7 +353,7 @@ void spg2xx_video_device::draw_page(const rectangle &cliprect, uint32_t* dst, ui const uint32_t tile_h = 8 << ((attr & 0x00c0) >> 6); const uint32_t tile_w = 8 << (tile_width); const uint32_t tile_count_x = 512 / tile_w; // all tilemaps are 512 pixels wide - const uint32_t bitmap_y = (scanline + yscroll) & 0xff; // all tilemaps are 256 pixels high + const uint32_t bitmap_y = (logical_scanline + yscroll) & 0xff; // all tilemaps are 256 pixels high const uint32_t y0 = bitmap_y / tile_h; const uint32_t tile_scanline = bitmap_y % tile_h; const uint8_t bpp = attr & 0x0003; @@ -332,7 +366,7 @@ void spg2xx_video_device::draw_page(const rectangle &cliprect, uint32_t* dst, ui if (row_scroll) { // Tennis in My Wireless Sports confirms the need to add the scroll value here rather than rowscroll being screen-aligned - realxscroll += (int16_t)m_scrollram[(scanline+yscroll) & 0xff]; + realxscroll += (int16_t)m_scrollram[(logical_scanline+yscroll) & 0xff]; } for (uint32_t x0 = 0; x0 < (320+tile_w)/tile_w; x0++) diff --git a/src/devices/machine/spg2xx_video.h b/src/devices/machine/spg2xx_video.h index cb7a7f4cb62..58857a0374e 100644 --- a/src/devices/machine/spg2xx_video.h +++ b/src/devices/machine/spg2xx_video.h @@ -83,7 +83,7 @@ protected: uint8_t m_rgb5_to_rgb8[32]; uint32_t m_rgb555_to_rgb888[0x8000]; - int m_ycmp_table[480]; + uint32_t m_ycmp_table[480]; void update_vcmp_table(); uint16_t m_video_regs[0x100]; diff --git a/src/mame/drivers/megadriv_rad.cpp b/src/mame/drivers/megadriv_rad.cpp index b6a6003e4e3..a5b5dd14036 100644 --- a/src/mame/drivers/megadriv_rad.cpp +++ b/src/mame/drivers/megadriv_rad.cpp @@ -180,6 +180,11 @@ ROM_START( rad_gen1 ) ROM_LOAD16_WORD_SWAP( "radicav1.bin", 0x000000, 0x400000, CRC(3b4c8438) SHA1(5ed9c053f9ebc8d4bf571d57e562cf347585d158) ) ROM_END +ROM_START( rad_gen2 ) + ROM_REGION( 0x400000, "maincpu", 0 ) + ROM_LOAD16_WORD_SWAP( "genesisred.bin", 0x000000, 0x400000, CRC(7c1a0f0e) SHA1(a6441f75a4cd48f1563aeafdfbdde00202d4067c) ) +ROM_END + ROM_START( rad_ssoc ) ROM_REGION( 0x400000, "maincpu", 0 ) ROM_LOAD( "sensiblesoccer.bin", 0x000000, 0x400000, CRC(b8745ab3) SHA1(0ab3f26e5ffd288e5a3a5db676951b9095299eb0) ) // should be byteswapped? @@ -209,9 +214,10 @@ void megadriv_radica_state::init_megadriv_radica_6button_ntsc() m_megadrive_io_write_data_port_ptr = write16sm_delegate(*this, FUNC(md_base_state::megadrive_io_write_data_port_6button)); } -CONS( 2004, rad_sonic, 0, 0, megadriv_radica_3button_ntsc, megadriv_radica_3button_1player, megadriv_radica_state, init_megadriv, "Radica / Sega", "Super Sonic Gold (Radica Plug & Play) (USA)", 0) CONS( 2004, rad_gen1, 0, 0, megadriv_radica_3button_ntsc, megadriv_radica_3button_1player, megadriv_radica_state, init_megadriv, "Radica / Sega", "Genesis Collection Volume 1 (Radica, Arcade Legends) (USA)", 0) +CONS( 2004, rad_gen2, 0, 0, megadriv_radica_3button_ntsc, megadriv_radica_3button_1player, megadriv_radica_state, init_megadriv, "Radica / Sega", "Genesis Collection Volume 2 (Radica, Arcade Legends) (USA)", 0) +CONS( 2004, rad_sonic, 0, 0, megadriv_radica_3button_ntsc, megadriv_radica_3button_1player, megadriv_radica_state, init_megadriv, "Radica / Sega", "Super Sonic Gold (Radica Plug & Play) (USA)", 0) // box calls this Volume 3 CONS( 2004, rad_sf2, 0, 0, megadriv_radica_6button_ntsc, megadriv_radica_6button, megadriv_radica_state, init_megadriv_radica_6button_ntsc,"Radica / Capcom / Sega", "Street Fighter II: Special Champion Edition [Ghouls'n Ghosts] (Radica, Arcade Legends) (USA)", 0) CONS( 2004, rad_sf2p, rad_sf2,0, megadriv_radica_6button_pal, megadriv_radica_6button, megadriv_radica_state, init_megadriv_radica_6button_pal, "Radica / Capcom / Sega", "Street Fighter II: Special Champion Edition [Ghouls'n Ghosts] (Radica, Arcade Legends) (Europe)", 0) diff --git a/src/mame/drivers/nes_vt.cpp b/src/mame/drivers/nes_vt.cpp index 1fac87b913f..ea7ac7398c6 100644 --- a/src/mame/drivers/nes_vt.cpp +++ b/src/mame/drivers/nes_vt.cpp @@ -1574,6 +1574,12 @@ ROM_START( lxcmcydp ) ROM_LOAD( "cyberarcade-disneyprincess.bin", 0x00000, 0x4000000, CRC(05946f81) SHA1(33eea2b70f5427e7613c836b8a08148731fac231) ) ROM_END +ROM_START( lxcmcysp ) + ROM_REGION( 0x4000000, "mainrom", 0 ) + // sub-board was marked for 2GB capacity (A0-A26 address lines), but only address lines A0-A24 are connected to the chip + ROM_LOAD( "lexibookspiderman.bin", 0x00000, 0x4000000, CRC(ef6e8847) SHA1(0012df193c52fd48595d85886fd431619c5d5e3e) ) +ROM_END + ROM_START( lxcmc250 ) ROM_REGION( 0x4000000, "mainrom", 0 ) // sub-board was marked for 2GB capacity (A0-A26 address lines), but only address lines A0-A24 are connected to the chip @@ -1788,11 +1794,22 @@ ROM_START( ablping ) ROM_LOAD( "abl_pingpong.bin", 0x00000, 0x200000, CRC(b31de1fb) SHA1(94e8afb2315ba1fa0892191c8e1832391e401c70) ) ROM_END -ROM_START( dgun2573 ) +ROM_START( dgun2573 ) // bad ROM inside unit ROM_REGION( 0x2000000, "mainrom", 0 ) ROM_LOAD( "dgun2573.bin", 0x00000, 0x2000000, BAD_DUMP CRC(cde71a53) SHA1(d0d4c1965876291861781ecde46b1142b062f1f3) ) ROM_END +/* From a different unit, but also a bad ROM inside, some of the same areas appear to be corrupt. The first 128KByte still has some incorrect / corrupt images for menu) + For example, "13. Backstroke" image is corrupt. That's stored in the 0xc000 - 0xffff region of the ROM. Using the data from rminitv instead fixes it + however things get more confusing with "25. Freestyle Stroke" which is stored in the 0x10000 - 0x1ffff area. This area is already a match for 'rminitv' so would + appear to not be a bad dump, however the image in this section of ROM and 'rminitv' references it elsewhere. This suggests the chip might have been reprogrammed + from something else, and the process failed to erase / replace one of the old blocks? */ + +ROM_START( dgun2573a ) + ROM_REGION( 0x2000000, "mainrom", 0 ) + ROM_LOAD( "gamer.bin", 0x00000, 0x2000000, BAD_DUMP CRC(abe72c09) SHA1(b81ab3adf6905367c2e52f0d8bf71fb73c2b697f)) +ROM_END + ROM_START( bittboy ) ROM_REGION( 0x2000000, "mainrom", 0 ) ROM_LOAD( "bittboy_flash_read_s29gl256n-tf-v2.bin", 0x00000, 0x2000000, CRC(24c802d7) SHA1(c1300ff799b93b9b53060b94d3985db4389c5d3a) ) @@ -1967,7 +1984,7 @@ CONS( 2005, vgpocket, 0, 0, nes_vt_vg_4mb, nes_vt, nes_vt_hh_state, empty_ini CONS( 200?, vgpmini, 0, 0, nes_vt_vg_4mb, nes_vt, nes_vt_hh_state, empty_init, "Performance Designed Products", "VG Pocket Mini (VG-1500)", MACHINE_WRONG_COLORS | MACHINE_IMPERFECT_GRAPHICS ) // VG Pocket Max (VG-2500) (blue case, 75 games) // VG Pocket Max (VG-3000) (white case, 75 games) (does the game selection differ, or only the case?) -// VG Pocket Caplet is likely SunPlus hardware instead. (has common SunPlus games) +// VG Pocket Caplet is SunPlus hardware instead, see spg2xx_lexibook.cpp // Runs fine, non-sport 121 in 1 games perfect, but minor graphical issues in // sport games, also no sound in menu or sport games due to missing PCM @@ -1983,6 +2000,7 @@ CONS( 200?, lxcmc250, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_stat CONS( 200?, lxcmcysw, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Star Wars Rebels", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme CONS( 200?, lxcmcyfz, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Frozen", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme CONS( 200?, lxcmcydp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Disney Princess", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme +CONS( 200?, lxcmcysp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Marvel Ultimate Spider-Man", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme // GB-NO13-Main-VT389-2 on PCBs CONS( 2016, rtvgc300, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Retro TV Game Console - 300 Games", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme @@ -2006,6 +2024,7 @@ CONS( 2017, rtvgc300fz,0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_stat (units for use with TV) Lexibook Retro TV Game Console (300 Games) - Cars + Lexibook Retro TV Game Console (300 Games) - PJ Masks (more?) */ @@ -2128,10 +2147,10 @@ CONS( 2016, mog_m320, 0, 0, nes_vt_hh_8mb, nes_vt, nes_vt_hh_state, em // similar menus to above, but with opcode scrambling -// palette issues in some games because they actually use the old VT style palette -// but no way to switch? -// some menu gfx broken, probably because this is a bad dump -CONS( 2015, dgun2573, 0, 0, nes_vt_fp_32mb, nes_vt, nes_vt_hh_state, empty_init, "dreamGEAR", "My Arcade Gamer V Portable Gaming System (DGUN-2573)", MACHINE_WRONG_COLORS | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +// some menu gfx broken, both units contained bad ROM, seems to be common issue? +CONS( 2015, dgun2573, 0, 0, nes_vt_fp_32mb, nes_vt, nes_vt_hh_state, empty_init, "dreamGEAR", "My Arcade Gamer V Portable Gaming System (DGUN-2573) (set 1)", MACHINE_WRONG_COLORS | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2015, dgun2573a, 0, 0, nes_vt_fp_32mb, nes_vt, nes_vt_hh_state, empty_init, "dreamGEAR", "My Arcade Gamer V Portable Gaming System (DGUN-2573) (set 2)", MACHINE_WRONG_COLORS | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + CONS( 2015, rminitv, 0, 0, nes_vt_fp_pal_32mb, nes_vt, nes_vt_hh_state, empty_init, "Orb Gaming", "Retro 'Mini TV' Console 300-in-1", MACHINE_IMPERFECT_GRAPHICS ) // single 32Mbyte bank! // New platform with scrambled opcodes, same as DGUN-2561. Runs fine with minor GFX and sound issues in menu // Use DIP switch to select console or cartridge, as cartridge is fake and just toggles a GPIO diff --git a/src/mame/drivers/spg29x.cpp b/src/mame/drivers/spg29x.cpp index 9994cf685ac..f8da86aa1d7 100644 --- a/src/mame/drivers/spg29x.cpp +++ b/src/mame/drivers/spg29x.cpp @@ -75,6 +75,7 @@ public: m_maincpu(*this, "maincpu") { } + void spg29x(machine_config &config); void hyperscan(machine_config &config); protected: @@ -100,6 +101,7 @@ private: void spg290_blit_character(bitmap_rgb32 &bitmap, const rectangle &cliprect, uint32_t control, uint32_t attribute, int posy, int posx, uint32_t nptr, uint32_t buf_start, uint32_t transrgb); void spg290_mem(address_map &map); + void spg290_bios_mem(address_map &map); static const device_timer_id TIMER_SPG290 = 0; static const device_timer_id TIMER_I2C = 1; @@ -188,6 +190,24 @@ private: int m_firstvector; }; +class spg29x_zone3d_game_state : public spg29x_game_state +{ +public: + spg29x_zone3d_game_state(const machine_config& mconfig, device_type type, const char* tag) : + spg29x_game_state(mconfig, type, tag) + { } + + void init_zone3d(); + +protected: + void machine_reset() override; + +private: +}; + + + + #if LOG_SPG290_REGISTER_ACCESS @@ -623,6 +643,11 @@ void spg29x_game_state::spg290_mem(address_map &map) map(0x08000000, 0x09ffffff).rw(FUNC(spg29x_game_state::spg290_regs_r), FUNC(spg29x_game_state::spg290_regs_w)); map(0x0a000000, 0x0a003fff).ram(); // internal SRAM map(0x0b000000, 0x0b007fff).rom().region("spg290", 0); // internal ROM +} + +void spg29x_game_state::spg290_bios_mem(address_map& map) +{ + spg290_mem(map); map(0x10000000, 0x100fffff).rom().region("bios", 0).mirror(0x0e000000); map(0x11000000, 0x110fffff).rom().region("bios", 0).mirror(0x0e000000); } @@ -675,7 +700,26 @@ void spg29x_nand_game_state::machine_reset() } -void spg29x_game_state::hyperscan(machine_config &config) +void spg29x_zone3d_game_state::machine_reset() +{ + spg29x_game_state::machine_reset(); + + uint8_t* rom = memregion("spi")->base(); + int size = memregion("spi")->bytes(); + + uint32_t destaddr = 0x1dc; + for (uint32_t addr = 0; addr < size; addr++) + { + address_space& mem = m_maincpu->space(AS_PROGRAM); + uint8_t byte = rom[addr]; + mem.write_byte(addr+destaddr, byte); + } + + m_maincpu->set_state_int(SCORE_PC, 0x1000); +} + + +void spg29x_game_state::spg29x(machine_config &config) { /* basic machine hardware */ SCORE7(config, m_maincpu, XTAL(27'000'000) * 4); // 108MHz S+core 7 @@ -693,7 +737,11 @@ void spg29x_game_state::hyperscan(machine_config &config) screen.screen_vblank().set(FUNC(spg29x_game_state::spg290_vblank_irq)); } - +void spg29x_game_state::hyperscan(machine_config &config) +{ + spg29x(config); + m_maincpu->set_addrmap(AS_PROGRAM, &spg29x_game_state::spg290_bios_mem); +} void spg29x_nand_game_state::nand_init(int blocksize, int blocksize_stripped) { @@ -742,6 +790,10 @@ void spg29x_nand_game_state::nand_jak_bbsf() m_firstvector = 0x8; } +void spg29x_zone3d_game_state::init_zone3d() +{ + +} /* ROM definition */ @@ -755,8 +807,6 @@ ROM_END ROM_START( jak_bbh ) - ROM_REGION( 0x100000, "bios", ROMREGION_32BIT | ROMREGION_LE | ROMREGION_ERASE00 ) - ROM_REGION( 0x4200000, "nand", 0 ) // ID returned C25A, read as what appears to be a compatible type. ROM_LOAD("bigbuckhunterpro_as_hy27us0812a_c25a.bin", 0x000000, 0x4200000, CRC(e2627540) SHA1(c8c6e5fbc4084fa695390bbb4e1e52e671f050da) ) @@ -766,8 +816,6 @@ ROM_END ROM_START( jak_bbsf ) - ROM_REGION( 0x100000, "bios", ROMREGION_32BIT | ROMREGION_LE | ROMREGION_ERASE00 ) - ROM_REGION( 0x4200000, "nand", 0 ) ROM_LOAD("bigbucksafari.bin", 0x000000, 0x4200000, CRC(dc5f9bf1) SHA1(27893c396d62f353ced52ef88fd9ade5c051598f) ) @@ -775,6 +823,38 @@ ROM_START( jak_bbsf ) ROM_LOAD32_DWORD("internal.rom", 0x000000, 0x008000, NO_DUMP) ROM_END +ROM_START( zone3d ) + ROM_REGION( 0x100000, "spi", 0 ) + ROM_LOAD("zone_25l8006e_c22014.bin", 0x000000, 0x100000, CRC(8c571771) SHA1(cdb46850286d31bf58d45b75ffc396ed774ac4fd) ) + + /* + model: Lexar SD + revision: LX01 + serial number: 00000000XL10 + + size: 362.00 MiB (741376 sectors * 512 bytes) + unk1: 0000000000000007 + unk2: 00000000000000fa + unk3: 01 + + The SD card has no label, but there's some printing on the back: + MMAGF0380M3085-WY + TC00201106 by Taiwan + + -- + Dumped with hardware write blocker, so this image is correct, and hasn't been corrupted by Windows + + Image contains a FAT filesystem with a number of compressed? programs that presumably get loaded into RAM by + the bootloader in the serial flash ROM + */ + + DISK_REGION( "cfcard" ) + DISK_IMAGE( "zone3d", 0, SHA1(77971e2dbfb2ceac12f482d72539c2e042fd9108) ) + + ROM_REGION( 0x008000, "spg290", ROMREGION_32BIT | ROMREGION_LE ) + ROM_LOAD32_DWORD("internal.rom", 0x000000, 0x008000, NO_DUMP) +ROM_END + /* Driver */ @@ -783,7 +863,12 @@ COMP( 2006, hyprscan, 0, 0, hyperscan, hyperscan, spg29x_game_state, // There were 1 player and 2 player versions for these JAKKS guns. The 2nd gun appears to be simply a controller (no AV connectors) but as they were separate products with the 2 player verisons being released up to a year after the original, the code could differ. // If they differ, it is currently uncertain which versions these ROMs are from -COMP( 2009, jak_bbh, 0, 0, hyperscan, hyperscan, spg29x_nand_game_state, nand_jak_bbh, "JAKKS Pacific Inc", "Big Buck Hunter Pro (JAKKS Pacific TV Game)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND ) //has ISSI 404A (24C04) -COMP( 2011, jak_bbsf, 0, 0, hyperscan, hyperscan, spg29x_nand_game_state, nand_jak_bbsf,"JAKKS Pacific Inc", "Big Buck Safari (JAKKS Pacific TV Game)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND ) // has ISSI 416A (24C16) +COMP( 2009, jak_bbh, 0, 0, spg29x, hyperscan, spg29x_nand_game_state, nand_jak_bbh, "JAKKS Pacific Inc", "Big Buck Hunter Pro (JAKKS Pacific TV Game)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND ) //has ISSI 404A (24C04) +COMP( 2011, jak_bbsf, 0, 0, spg29x, hyperscan, spg29x_nand_game_state, nand_jak_bbsf,"JAKKS Pacific Inc", "Big Buck Safari (JAKKS Pacific TV Game)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND ) // has ISSI 416A (24C16) +// ends up doing the fllowing, which causes a jump to 0xbf000024, where we have nothing mapped (internal ROM related, or thinks it's loaded code there? This is the area Hyperscan uses as 'BIOS' not Internal ROM so could be RAM here) +// 000011D4: ldis r8, 0xbf00 +// 000011D8: ori r8, 0x0024 +// 000011DC: br r8 +COMP( 201?, zone3d, 0, 0, spg29x, hyperscan, spg29x_zone3d_game_state, init_zone3d,"Zone", "Zone 3D", MACHINE_NOT_WORKING | MACHINE_NO_SOUND ) diff --git a/src/mame/drivers/spg2xx.cpp b/src/mame/drivers/spg2xx.cpp index cec94997e9f..5ae2e2a919b 100644 --- a/src/mame/drivers/spg2xx.cpp +++ b/src/mame/drivers/spg2xx.cpp @@ -725,13 +725,13 @@ static INPUT_PORTS_START( senspeed ) PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_NAME("Accelerate / Select") PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_NAME("Reverse / Confirm") - PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("A") - PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_NAME("B") - PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_NAME("C") - PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_NAME("D") - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_NAME("E") - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_NAME("F") - PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON7 ) PORT_NAME("G") + PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("A (Autojacks)") + PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_NAME("B (Belt Tires)") + PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_NAME("C (Cutting Saw)") + PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_NAME("D (Deflector)") + PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_NAME("E (Evening Eyes)") + PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_NAME("F (Frogman Mode)") + PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON7 ) PORT_NAME("G (Go Robot)") PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start / Pause") PORT_DIPNAME( 0x1000, 0x1000, DEF_STR( Unknown ) ) PORT_DIPSETTING( 0x1000, DEF_STR( Off ) ) diff --git a/src/mame/drivers/spg2xx_lexibook.cpp b/src/mame/drivers/spg2xx_lexibook.cpp index a44d049d257..1ac7783b176 100644 --- a/src/mame/drivers/spg2xx_lexibook.cpp +++ b/src/mame/drivers/spg2xx_lexibook.cpp @@ -38,6 +38,25 @@ protected: virtual void portb_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; }; +class spg2xx_vsplus_game_state : public spg2xx_lexizeus_game_state +{ +public: + spg2xx_vsplus_game_state(const machine_config &mconfig, device_type type, const char *tag) : + spg2xx_lexizeus_game_state(mconfig, type, tag) + { } + + void vsplus(machine_config &config); + + void init_vsplus(); + +protected: + //virtual void machine_start() override; + //virtual void machine_reset() override; + + virtual void portb_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; +}; + + static INPUT_PORTS_START( lexizeus ) // how many buttons does this have? I accidentally entered a secret test mode before that seemed to indicate 6, but can't get there again PORT_START("P1") @@ -196,6 +215,27 @@ static INPUT_PORTS_START( lexiseal ) PORT_BIT( 0xfffc, IP_ACTIVE_LOW, IPT_UNUSED ) INPUT_PORTS_END +static INPUT_PORTS_START( vsplus ) + PORT_START("P1") + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) + PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) + PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) + PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) + PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_NAME("B") + PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("A") + PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_NAME("Pause") + PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED ) + + PORT_START("P2") + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_NAME("Rapid A") + PORT_BIT( 0x0006, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_NAME("Rapid B") + PORT_BIT( 0xfff0, IP_ACTIVE_LOW, IPT_UNUSED ) + + PORT_START("P3") + PORT_BIT( 0xffff, IP_ACTIVE_LOW, IPT_UNUSED ) +INPUT_PORTS_END void spg2xx_lexiseal_game_state::portb_w(offs_t offset, uint16_t data, uint16_t mem_mask) @@ -213,6 +253,17 @@ void spg2xx_lexiseal_game_state::portb_w(offs_t offset, uint16_t data, uint16_t } +void spg2xx_vsplus_game_state::portb_w(offs_t offset, uint16_t data, uint16_t mem_mask) +{ + if (mem_mask & 0x0080) + { + if (data & 0x0080) + switch_bank(1); + else + switch_bank(0); + } +} + void spg2xx_lexiseal_game_state::lexiseal(machine_config &config) { non_spg_base(config); @@ -231,6 +282,20 @@ void spg2xx_lexizeus_game_state::lexizeus(machine_config &config) m_maincpu->portc_in().set_ioport("P3"); } +void spg2xx_vsplus_game_state::vsplus(machine_config &config) +{ + non_spg_base(config); + m_maincpu->portb_out().set(FUNC(spg2xx_vsplus_game_state::portb_w)); + m_maincpu->porta_in().set_ioport("P1"); + m_maincpu->portb_in().set_ioport("P2"); + m_maincpu->portc_in().set_ioport("P3"); + + // output was PAL when connected to TV at least + m_maincpu->set_pal(true); + m_screen->set_refresh_hz(50); +} + + void spg2xx_lexizeus_game_state::init_zeus() { uint16_t *ROM = (uint16_t*)memregion("maincpu")->base(); @@ -259,13 +324,24 @@ void spg2xx_lexizeus_game_state::init_zeus() } } +void spg2xx_vsplus_game_state::init_vsplus() +{ + uint16_t *ROM = (uint16_t*)memregion("maincpu")->base(); + int size = memregion("maincpu")->bytes(); + decrypt_ac_ff(ROM, size); +} ROM_START( lexizeus ) ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "lexibook1g900us.bin", 0x0000, 0x800000, CRC(c2370806) SHA1(cbb599c29c09b62b6a9951c724cd9fc496309cf9)) ROM_END +ROM_START( vsplus ) + ROM_REGION( 0x1000000, "maincpu", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "vsplus.bin", 0x0000, 0x1000000, CRC(2b13d2cc) SHA1(accae7606d83a313b8ec0232d2d67b63c9c617af) ) +ROM_END + ROM_START( lexiseal ) ROM_REGION( 0x1000000, "maincpu", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "lexibook_seal.bin", 0x0000, 0x1000000, CRC(3529f154) SHA1(f5f142600c6b2d037b97e007364ea2fa228e0163) ) @@ -332,6 +408,9 @@ ROM_END CONS( 200?, lexizeus, 0, 0, lexizeus, lexizeus, spg2xx_lexizeus_game_state, init_zeus, "Lexibook", "Zeus IG900 20-in-1 (US?)", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) // bad sound and some corrupt bg tilemap entries in Tiger Rescue, verify ROM data (same game runs in Zone 60 without issue) +CONS( 200?, vsplus, 0, 0, vsplus, vsplus, spg2xx_vsplus_game_state, init_vsplus, "", "Vs Power Plus 30-in-1", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) + + CONS( 200?, lexiseal, 0, 0, lexiseal, lexiseal, spg2xx_lexiseal_game_state, init_zeus, "Lexibook / Sit Up Limited", "Seal 50-in-1", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) // also has bad sound in Tiger Rescue, but no corrupt tilemap // there are versions of the Seal that actually show Lexibook on the boot screen rather than just the unit diff --git a/src/mame/mame.lst b/src/mame/mame.lst index bf6d6497107..d1e4aaa5490 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -22037,6 +22037,7 @@ twinktmb // MegaDrive-based hack rad_sf2 // (c)2004 Radica rad_sf2p // (c)2004 Radica rad_gen1 // (c)2004 Radica +rad_gen2 // (c)2004 Radica rad_ssoc // (c)2004 Radica rad_sonic @@ -31631,6 +31632,7 @@ lxcmc250 lxcmcysw lxcmcyfz lxcmcydp +lxcmcysp rtvgc300 rtvgc300fz red5mam @@ -31675,6 +31677,7 @@ sy889 sy888b rfcp168 dgun2573 +dgun2573a dgun2593 bittboy mc_89in1 @@ -37452,6 +37455,7 @@ karaokd2 hyprscan // jak_bbh jak_bbsf +zone3d @source:spg29x_lexibook_jg7425.cpp lx_jg7425 @@ -37536,6 +37540,7 @@ lexizeus // Lexibook lexiseal // discpal vgcaplet +vsplus @source:spg2xx_mysprtch.cpp mysprtch