diff options
-rw-r--r-- | scripts/target/mame/mess.lua | 6 | ||||
-rw-r--r-- | src/devices/cpu/m6502/oxavix2000.lst | 4 | ||||
-rw-r--r-- | src/mame/drivers/spg2xx.cpp | 6 | ||||
-rw-r--r-- | src/mame/drivers/xavix.cpp | 534 | ||||
-rw-r--r-- | src/mame/drivers/xavix_2000.cpp | 287 | ||||
-rw-r--r-- | src/mame/drivers/xavix_2002.cpp | 547 | ||||
-rw-r--r-- | src/mame/includes/xavix.h | 53 | ||||
-rw-r--r-- | src/mame/includes/xavix_2000.h | 27 | ||||
-rw-r--r-- | src/mame/includes/xavix_2002.h | 55 | ||||
-rw-r--r-- | src/mame/machine/xavix.cpp | 51 | ||||
-rw-r--r-- | src/mame/mame.lst | 19 | ||||
-rw-r--r-- | src/mame/mess.flt | 2 |
12 files changed, 951 insertions, 640 deletions
diff --git a/scripts/target/mame/mess.lua b/scripts/target/mame/mess.lua index c602dab6000..da6496ac1d9 100644 --- a/scripts/target/mame/mess.lua +++ b/scripts/target/mame/mess.lua @@ -4005,10 +4005,14 @@ files { MAME_DIR .. "src/mame/machine/generalplus_gpl16250.h", MAME_DIR .. "src/mame/drivers/generalplus_gpl32612.cpp", MAME_DIR .. "src/mame/drivers/xavix.cpp", + MAME_DIR .. "src/mame/includes/xavix.h", + MAME_DIR .. "src/mame/drivers/xavix_2000.cpp", + MAME_DIR .. "src/mame/includes/xavix_2000.h", + MAME_DIR .. "src/mame/drivers/xavix_2002.cpp", + MAME_DIR .. "src/mame/includes/xavix_2002.h", MAME_DIR .. "src/mame/video/xavix.cpp", MAME_DIR .. "src/mame/machine/xavix.cpp", MAME_DIR .. "src/mame/audio/xavix.cpp", - MAME_DIR .. "src/mame/includes/xavix.h", MAME_DIR .. "src/mame/machine/xavix_mtrk_wheel.cpp", MAME_DIR .. "src/mame/machine/xavix_mtrk_wheel.h", MAME_DIR .. "src/mame/machine/xavix_madfb_ball.cpp", diff --git a/src/devices/cpu/m6502/oxavix2000.lst b/src/devices/cpu/m6502/oxavix2000.lst index a457c651418..def34dfaefe 100644 --- a/src/devices/cpu/m6502/oxavix2000.lst +++ b/src/devices/cpu/m6502/oxavix2000.lst @@ -355,8 +355,8 @@ ldapa_imp prefetch(); cmppa_imp - fatalerror("unhandled opcode %02x%04x: %02x\n", m_codebank, PPC, inst_state); - read_pc_noinc(); + TMP = read_full_data(m_pa); + do_cmp(A, TMP); prefetch(); sbcpa_imp diff --git a/src/mame/drivers/spg2xx.cpp b/src/mame/drivers/spg2xx.cpp index fe6631aaf8c..3ffed32cb32 100644 --- a/src/mame/drivers/spg2xx.cpp +++ b/src/mame/drivers/spg2xx.cpp @@ -1781,6 +1781,10 @@ ROM_START( wfcentro ) ROM_LOAD16_WORD_SWAP( "winfuncentro.bin", 0x000000, 0x800000, CRC(fd6ad052) SHA1(78af844729bf4843dc70531349e38a8c25caf748) ) ROM_END +ROM_START( tiktokmm ) + ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "webcamthingy.bin", 0x000000, 0x800000, CRC(54c0d4a9) SHA1(709ee607ca447baa6f7e686268df1998372fe617) ) +ROM_END void spg2xx_game_state::init_crc() { @@ -1904,3 +1908,5 @@ CONS( 2007, ordentv, 0, 0, ordentv, ordentv, spg2xx_game_ordentv_s CONS( 200?, wfcentro, 0, 0, wfcentro, spg2xx, spg2xx_game_wfcentro_state, empty_init, "WinFun", "Centro TV de Diseno Artistico (Spain)", MACHINE_NOT_WORKING ) +// set 2862 to 0003 (irq enable) when it stalls on boot to show something (doesn't turn on IRQs again otherwise?) needs camera emulating +CONS( 200?, tiktokmm, 0, 0, spg2xx, spg2xx, spg2xx_game_wfcentro_state, empty_init, "TikTokTech Ltd. / 3T Games / Senario", "Moving Music (MM-TV110)", MACHINE_NOT_WORKING ) diff --git a/src/mame/drivers/xavix.cpp b/src/mame/drivers/xavix.cpp index 0215cf6e5c8..64174166145 100644 --- a/src/mame/drivers/xavix.cpp +++ b/src/mame/drivers/xavix.cpp @@ -233,10 +233,6 @@ #include "emu.h" #include "includes/xavix.h" -// NTSC clock for regular XaviX? -#define MAIN_CLOCK XTAL(21'477'272) -// some games (eg Radica Opus) run off a 3.579545MHz XTAL ( same as the above /6 ) so presumably there is a divider / multiplier circuit on some PCBs? -// TODO: what's the PAL clock? /* rad_madf has callf #$8f3f21 in various places, and expects to jump to code in ROM, it is unclear how things map in this case, as presumably the CPU 0 page memory and stack are still at 0 but ROM must be in the 3xxx range (game hasn't got far enough to call this yet to help either) @@ -547,22 +543,7 @@ static INPUT_PORTS_START( xavix_i2c ) INPUT_PORTS_END -static INPUT_PORTS_START( epo_tfit ) - PORT_INCLUDE(xavix) - PORT_MODIFY("IN0") - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // select - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // back - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) - PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) - PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) - PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) - PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) - - PORT_MODIFY("IN1") - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) -INPUT_PORTS_END static INPUT_PORTS_START( tomcpin ) @@ -582,176 +563,6 @@ static INPUT_PORTS_START( tomcpin ) PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_POWER_OFF ) PORT_NAME("Power Switch") // pressing this will turn the game off. INPUT_PORTS_END -static INPUT_PORTS_START( mrangbat ) - PORT_INCLUDE(xavix_i2c) - - PORT_MODIFY("IN0") - PORT_DIPNAME( 0x01, 0x00, "IN0" ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x01, DEF_STR( On ) ) - PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x02, DEF_STR( On ) ) - PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x04, DEF_STR( On ) ) - PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x08, DEF_STR( On ) ) - PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x10, DEF_STR( On ) ) - PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x20, DEF_STR( On ) ) - PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x40, DEF_STR( On ) ) - PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x80, DEF_STR( On ) ) - - PORT_MODIFY("IN1") - PORT_DIPNAME( 0x01, 0x00, "IN1" ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x01, DEF_STR( On ) ) - PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x02, DEF_STR( On ) ) - PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x04, DEF_STR( On ) ) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) - PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x10, DEF_STR( On ) ) - PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x20, DEF_STR( On ) ) - PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x40, DEF_STR( On ) ) - PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x80, DEF_STR( On ) ) - - PORT_START("EX0") // NOT A JOYSTICK!! - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1) PORT_16WAY // Red/Up 1 - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(2) PORT_16WAY // Red/Up 2 - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(2) PORT_16WAY // Green / Circle / Right 2 - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(2) PORT_16WAY // Pink / Star / Left 2 - PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) PORT_16WAY // Blue / Square / Right 1 - PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) PORT_16WAY // Yellow / Triangle / Left 1 - PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) - PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) - - - PORT_START("EX1") - PORT_DIPNAME( 0x01, 0x00, "EX1" ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x01, DEF_STR( On ) ) - PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x02, DEF_STR( On ) ) - PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x04, DEF_STR( On ) ) - PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x08, DEF_STR( On ) ) - PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x10, DEF_STR( On ) ) - PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x20, DEF_STR( On ) ) - PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x40, DEF_STR( On ) ) - PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x80, DEF_STR( On ) ) - - PORT_START("EX2") - PORT_DIPNAME( 0x01, 0x00, "EX2" ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x01, DEF_STR( On ) ) - PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x02, DEF_STR( On ) ) - PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x04, DEF_STR( On ) ) - PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x08, DEF_STR( On ) ) - PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x10, DEF_STR( On ) ) - PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x20, DEF_STR( On ) ) - PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x40, DEF_STR( On ) ) - PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x80, DEF_STR( On ) ) -INPUT_PORTS_END - -static INPUT_PORTS_START( epo_bowl ) - PORT_INCLUDE(xavix) - - PORT_MODIFY("IN0") - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_PLAYER(1) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1) - PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) - PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) - - PORT_MODIFY("IN1") - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) -INPUT_PORTS_END - - -static INPUT_PORTS_START( ttv_lotr ) - PORT_INCLUDE(xavix) - - PORT_MODIFY("IN1") - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) -INPUT_PORTS_END - -static INPUT_PORTS_START( xavix_bowl ) - PORT_INCLUDE(xavix) - - PORT_MODIFY("IN1") - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) -INPUT_PORTS_END - -static INPUT_PORTS_START( epo_sdb ) - PORT_INCLUDE(xavix) - - PORT_MODIFY("MOUSE0X") - PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(1) - PORT_MODIFY("MOUSE0Y") - PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(1) - PORT_MODIFY("MOUSE1X") - PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(2) - PORT_MODIFY("MOUSE1Y") - PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(2) - - PORT_MODIFY("IN0") - PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(2) - - PORT_MODIFY("IN1") - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1) -INPUT_PORTS_END - static INPUT_PORTS_START( ltv_tam ) PORT_INCLUDE(xavix_i2c) @@ -819,14 +630,6 @@ INPUT_PORTS_END -static INPUT_PORTS_START( xavixp ) - PORT_INCLUDE(xavix) - - PORT_MODIFY("REGION") // PAL/NTSC flag - PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_CUSTOM ) -INPUT_PORTS_END - - /* Test mode lists the following LED (on power button?) @@ -1208,19 +1011,6 @@ static INPUT_PORTS_START( rad_bb2 ) PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_POWER_OFF ) PORT_NAME("Power Switch") // pressing this will turn the game off. INPUT_PORTS_END -static INPUT_PORTS_START( ttv_mx ) - PORT_INCLUDE(xavix_i2c) - - PORT_MODIFY("IN0") - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // Accel - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // Brake - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Pause") - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED ) - PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Motion Up") // you tilt the device, but actual inputs are digital - PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Motion Down") - PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("Motion Left") - PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("Motion Right") -INPUT_PORTS_END static INPUT_PORTS_START( rad_fb ) @@ -1613,81 +1403,7 @@ void xavix_state::xavixp_nv(machine_config &config) NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1); } -void xavix_state::xavix2000(machine_config &config) -{ - xavix(config); - - XAVIX2000(config.replace(), m_maincpu, MAIN_CLOCK); - m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map); - m_maincpu->set_addrmap(5, &xavix_state::xavix_lowbus_map); - m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map); - m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt)); - m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors)); - - m_palette->set_entries(512); -} - -void xavix_state::xavix2002(machine_config &config) -{ - xavix(config); - XAVIX2002(config.replace(), m_maincpu, MAIN_CLOCK); - m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map); - m_maincpu->set_addrmap(5, &xavix_state::superxavix_lowbus_map); // has extra video, io etc. - m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map); - m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt)); - m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors)); - - m_palette->set_entries(512); - - XAVIX2002IO(config, m_xavix2002io, 0); -} - - - -void xavix_i2c_jmat_state::xavix2002_i2c_jmat(machine_config &config) -{ - xavix2002_i2c_24c04(config); - - m_xavix2002io->read_0_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io0)); - m_xavix2002io->write_0_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io0)); - m_xavix2002io->read_1_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io1)); - m_xavix2002io->write_1_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io1)); - m_xavix2002io->read_2_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io2)); - m_xavix2002io->write_2_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io2)); -} - - -void xavix_state::xavix2000_nv(machine_config &config) -{ - xavix2000(config); - - NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1); -} - -void xavix_2000_nv_sdb_state::xavix2000_nv_sdb(machine_config &config) -{ - xavix2000_nv(config); - - m_anport->read_0_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport0_r)); - m_anport->read_1_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport1_r)); - m_anport->read_2_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport2_r)); - m_anport->read_3_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport3_r)); -} - -void xavix_i2c_state::xavix2000_i2c_24c04(machine_config &config) -{ - xavix2000(config); - - I2C_24C04(config, "i2cmem", 0); -} - -void xavix_i2c_state::xavix2000_i2c_24c02(machine_config &config) -{ - xavix2000(config); - - I2C_24C02(config, "i2cmem", 0); -} void xavix_mtrk_state::xavix_mtrk(machine_config &config) { @@ -1843,28 +1559,6 @@ void xavix_cart_state::xavix_cart_ddrfammt(machine_config &config) } -void xavix_i2c_state::xavix2002_i2c_24c04(machine_config &config) -{ - xavix2002(config); - - I2C_24C04(config, "i2cmem", 0); -} - -void xavix_i2c_state::xavix2002_i2c_mrangbat(machine_config &config) -{ - xavix2002(config); - - I2C_24C02(config, "i2cmem", 0); // 24C02? - - m_xavix2002io->read_0_callback().set_ioport("EX0"); - //m_xavix2002io->write_0_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io0)); - m_xavix2002io->read_1_callback().set_ioport("EX1"); - //m_xavix2002io->write_1_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io1)); - m_xavix2002io->read_2_callback().set_ioport("EX2"); - //m_xavix2002io->write_2_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io2)); - -} - void xavix_state::init_xavix() { @@ -2020,11 +1714,6 @@ ROM_START( epo_efdx ) ROM_LOAD("excitefishing.bin", 0x000000, 0x400000, CRC(9c85b261) SHA1(6a363faed2ec89c5176e46554a98ca1e20132579) ) ROM_END -ROM_START( epo_bowl ) - ROM_REGION(0x200000, "bios", ROMREGION_ERASE00) - ROM_LOAD("bowling.bin", 0x000000, 0x200000, CRC(d34f8d9e) SHA1(ebe3792172dc43904b9226beb27f1da89d2388cc) ) -ROM_END - ROM_START( epo_esdx ) ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) ROM_LOAD("baseballdx.bin", 0x000000, 0x400000, CRC(fe2e832e) SHA1(e6343f5e5f52316538d918d0d67c15764aa40f65) ) @@ -2279,7 +1968,7 @@ CONS( 2002, epo_esdx, 0, 0, xavix, epo_epp, xavix_state, CONS( 2000, epo_epp, 0, 0, xavix, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Ping Pong (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) CONS( 2000, epo_eppk, epo_epp, 0, xavix, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD / Sonokong", "Real Ping Pong (Korea)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) -// Excite Ping Pong 2 is from 2003, and there's a 3rd game from 2006 also +// Excite Ping Pong 2 is from 2003 CONS( 2006, epo_epp3, 0, 0, xavix, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Challenge Ai-chan! Excite Ping Pong (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) @@ -2336,226 +2025,5 @@ CONS( 2003, evio, 0, 0, xavix_cart_evio, evio, xavix_cart_st CONS( 2002, gcslottv, 0, 0, xavix_cart_gcslottv, gcslottv, xavix_cart_gcslottv_state, init_xavix, "Takara / Sammy / DCT / SSD Company LTD", "Gachinko Contest! Slot machine TV (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND /*|MACHINE_IS_BIOS_ROOT*/ ) - - // Let’s!TVプレイ 超にんきスポット!ころがしほーだい たまごっちりぞーと (Let's! TV Play Chou Ninki Spot! Korogashi-Houdai Tamagotchi Resort) (only on the Japanese list? http://test.shinsedai.co.jp/english/products/Applied/list.html ) This also allows you to use an IR reciever to import a Tamagotchi from compatible games CONS( 2006, ltv_tam, 0, 0, xavix_i2c_24lc04_tam, ltv_tam,xavix_i2c_ltv_tam_state, init_xavix, "Bandai / SSD Company LTD", "Let's! TV Play Chou Ninki Spot! Korogashi-Houdai Tamagotchi Resort (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) - - -/* SuperXaviX(?) (XaviX 2000 type CPU) hardware titles (2nd XaviX generation?) - - these use the SSD 2000 NEC 85605-621 type CPU - - XavixPort Golf is "SSD 2003 SuperXaviX MXIC 2003 3009" (not dumped yet, but actually marked as SuperXaviX unlike the others!) - - This CPU type adds extra opcodes that don't appear to be present in the 97/98 types - It does not appear to support the bitmap modes or 16-bit ROMs found in the 2002 type -*/ - -ROM_START( epo_sdb ) - ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) - ROM_LOAD("superdashball.bin", 0x000000, 0x400000, CRC(a004a764) SHA1(47a96822d4d7d6a0f6be5cd729c3747dbab65979) ) -ROM_END - -ROM_START( epo_ebox ) - ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) - ROM_LOAD("exciteboxing.bin", 0x000000, 0x400000, CRC(e25ae4f5) SHA1(7f7b613f0ab8f43f5cad0d13de538921e77cae9c) ) -ROM_END - -ROM_START( ttv_sw ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "jedi.bin", 0x000000, 0x800000, CRC(51cae5fd) SHA1(1ed8d556f31b4182259ca8c766d60c824d8d9744) ) -ROM_END - -ROM_START( ttv_lotr ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "lotr.bin", 0x000000, 0x800000, CRC(a034ecd5) SHA1(264a9d4327af0a075841ad6129db67d82cf741f1) ) -ROM_END - -ROM_START( ttv_mx ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "mxdirtrebel.bin", 0x000000, 0x800000, CRC(e64bf1a1) SHA1(137f97d7d857697a13e0c8984509994dc7bc5fc5) ) -ROM_END - -ROM_START( drgqst ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "dragonquest.bin", 0x000000, 0x800000, CRC(3d24413f) SHA1(1677e81cedcf349de7bf091a232dc82c6424efba) ) -ROM_END - -ROM_START( ban_onep ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00) - ROM_LOAD("onepiece.bin", 0x000000, 0x800000, CRC(c5cb5a5f) SHA1(db85f6cc48d77c5a4967b9b8e2999167e3dfc8c8) ) -ROM_END - - -CONS( 2002, epo_ebox, 0, 0, xavix2000_nv, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Boxing (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // doesn't use XaviX2000 extra opcodes, but had that type of CPU - // die not confirmed, but uses extra opcodes. (hangs on title screen due to combination of freq_timer_done nested interrupts tripping, and waiting on bits in input ports to change -CONS( 2002, epo_bowl, 0, 0, xavix2000_i2c_24c02, epo_bowl, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Bowling (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) - -CONS( 2004, epo_sdb, 0, 0, xavix2000_nv_sdb, epo_sdb, xavix_2000_nv_sdb_state, init_xavix, "Epoch / SSD Company LTD", "Super Dash Ball (Japan)", MACHINE_IMPERFECT_SOUND ) - -CONS( 2005, ttv_sw, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Star Wars Saga Edition - Lightsaber Battle Game", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) -CONS( 2005, ttv_lotr, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Lord Of The Rings - Warrior of Middle-Earth", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) -CONS( 2005, ttv_mx, 0, 0, xavix2000_i2c_24c04, ttv_mx, xavix_i2c_state, init_xavix, "Tiger / SSD Company LTD", "MX Dirt Rebel", MACHINE_IMPERFECT_SOUND ) -CONS( 2003, drgqst, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Square Enix / SSD Company LTD", "Kenshin Dragon Quest: Yomigaerishi Densetsu no Ken", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) - -// hangs after starting a game, or after quite a long time in attract mode (first problem could be bad save data read with the eeprom code, 2nd problem might just be how it is, ends up in a dead loop, not executing invalid code, idle timeout / battery saver) -CONS( 2004, ban_onep, 0, 0, xavix2000_i2c_24c04, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Bandai / SSD Company LTD", "One Piece Punch Battle (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) - -/* SuperXaviX (XaviX 2002 type CPU) hardware titles (3rd XaviX generation?) - - these use the SSD 2002 NEC 85054-611 type CPU - differences include support for 16-bit ROMs, various bitmap modes, interlace screen modes etc. - possibly higher horizontal resolution for bitmap layers with others scaled to fit? - -*/ - -/* The 'XaviXPORT' isn't a real console, more of a TV adapter, all the actual hardware (CPU including video hw, sound hw) is in the cartridges and controllers - and can vary between games, see notes at top of driver. - - The 'Domyos Interactive System (DiS)' released in France by Decathlon appears to be identical to XaviXPORT (but for PAL regions, and with an entirely different software range) -*/ - -// XaviXPORT -ROM_START( xavtenni ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "xavixtennis.bin", 0x000000, 0x800000, CRC(23a1d918) SHA1(2241c59e8ea8328013e55952ebf9060ea0a4675b) ) -ROM_END - -ROM_START( xavbaseb ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "xpbaseball.bin", 0x000000, 0x800000, CRC(e9ed692d) SHA1(537e390e972156dc7da66ee127ae4c8052038ee5) ) -ROM_END - -ROM_START( xavbowl ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "xpbowling.bin", 0x000000, 0x800000, CRC(2873460b) SHA1(ea8e2392f5a12961a23eb66dca8e07dec81ce8c8) ) -ROM_END - -ROM_START( xavbassf ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "xpbassfishing.bin", 0x000000, 0x800000, CRC(09ab2f29) SHA1(616254176315d0947002e9ae5a6371a3ffa2e8eb) ) - - // code for the nRF24E1s, stored in SEEPROMs. One in the cartridge, one in the rod/reel - ROM_REGION( 0x1001, "reel_io", ROMREGION_ERASE00 ) - ROM_LOAD( "xpbassfishingnrf24e1reel.bin", 0x0000, 0x1001, CRC(cfbb19ae) SHA1(32464e4e4be33fdbc7768311f93ce437a316c616) ) - - ROM_REGION( 0x800000, "base_io", ROMREGION_ERASE00 ) - ROM_LOAD( "xpbassfishingnrf24e1cart.bin", 0x0000, 0x1001, CRC(62f6303e) SHA1(126b2663e252fb80948f53153e4046e63dd8be32) ) -ROM_END - -ROM_START( xavbox ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "xpboxing.bin", 0x000000, 0x800000, CRC(b61e7717) SHA1(162b9c53ac8c9d7b6972db44f7bc1cb0a7837b70) ) -ROM_END - -// Several of the XaviXport and DiS games are 2 glob setups (and must have some kind of banking) - -ROM_START( xavjmat ) - ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(1420640d) SHA1(dd714cd57cff885293688f74f69b5c1726e20ec0) ) - - ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) - ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(52dc318c) SHA1(dc50e0747ba29cfb1048fd4a55d26870086c869b) ) -ROM_END - -// currently copies the wrong code into RAM to execute (due to extended ROM size, and possible banking) -// [:] ':maincpu' (00E074): rom_dmatrg_w (do DMA?) 01 -// [:] (possible DMA op SRC 00ebe2d3 DST 358a LEN 0398) -// needs to come from 006be2d3 (so still from lower 8MB, not upper 8MB) - -ROM_START( xavmusic ) - ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(e7c8ad59) SHA1(d47fac8b480de4db88a1b306ff8830a65d1738a3) ) - - ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) - ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(977c956f) SHA1(debc086d0cf6c391002ad163e7bfaa2f010cc8f5) ) -ROM_END - - -// Domyos DiS (XaviX 2002 based titles) -ROM_START( domfitex ) - ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(841fe3cd) SHA1(8678b8a0c5198b24169a84dbe3ae979bb0838f23) ) - - ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) - ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(1dc844ea) SHA1(c23da9006227f7fe4982998c17759d403a47472a) ) -ROM_END - -ROM_START( domfitch ) - ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(0ff2a7a6) SHA1(9b924cc4330e3f8d9204390854048fe2325bfdf7) ) - - ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) - ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(284583f6) SHA1(bd2d5304f1e01eed656b5de957ec0a0330a3d969) ) -ROM_END - -ROM_START( domdance ) - ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(74f9499d) SHA1(a64235075e32567cd6d2ab7b1284efcb8e7538e2) ) - - ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) - ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(e437565c) SHA1(f6db219ea14404b698ca453f6e50c726b2e77abb) ) -ROM_END - -ROM_START( domstepc ) - ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(cb37b5e9) SHA1(b742e3db98f36720adf5af9096c6bc235279de12) ) - - ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) - ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(dadaa744) SHA1(fd7ca77232a8fe228fc93b0a8a47ba3260349d90) ) -ROM_END - -ROM_START( mrangbat ) - ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) - ROM_LOAD("powerrangerspad.bin", 0x000000, 0x400000, CRC(d3a98775) SHA1(485c66242dd0ee436a278d23005aece48d606431) ) -ROM_END - -ROM_START( tmy_thom ) - ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) - ROM_LOAD( "thomastank.bin", 0x000000, 0x800000, CRC(a52a23be) SHA1(e5b3500239d9e56eb5405f7585982959e5a162da) ) -ROM_END - -ROM_START( epo_tfit ) - ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) - ROM_LOAD("tennisfitness.bin", 0x000000, 0x400000, CRC(cbf65bd2) SHA1(30b3da6f061b2dd91679db42a050f715901beb87) ) -ROM_END - - -CONS( 2004, xavtenni, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Tennis (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) -CONS( 2004, xavbaseb, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Baseball (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) -CONS( 2004, xavbowl, 0, 0, xavix2002_i2c_24c04, xavix_bowl, xavix_i2c_bowl_state, init_xavix, "SSD Company LTD", "XaviX Bowling (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera' -CONS( 2004, xavbox, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Boxing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera' -// Bass Fishing PCB is just like Tennis except with an RF daughterboard. -CONS( 2004, xavbassf, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Bass Fishing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) - -// TODO: check SEEPROM type and hookup, banking! -CONS( 2005, xavjmat, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "Jackie Chan J-Mat Fitness (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) -CONS( 2007, xavmusic, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Music & Circuit (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) - -// https://arnaudmeyer.wordpress.com/domyos-interactive-system/ -// Domyos Fitness Adventure -// Domyos Fitness Challenge -// Domyos Fitness Exercises -// Domyos Fit Race -// Domyos Soft Fitness -// Domyos Fitness Dance -// Domyos Fitness Play -// Domyos Fitness Training - -// Domyos Bike Concept (not listed on site above) - -// Has SEEPROM and an RTC. Exercise has some leftover PC buffer stuff. (TODO, check SEEPROM type, RTC type, banking) (both Exercises and Challenge are identical PCBs) -CONS( 2008, domfitex, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Exercises (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) -CONS( 2008, domfitch, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Challenge (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) -CONS( 2007, domdance, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Dance (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) -CONS( 2007, domstepc, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Step Concept (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) - -// some DIS games run on XaviX 2 instead, see xavix2.cpp for Domyos Fitness Adventure and Domyos Bike Concept - -CONS( 2005, mrangbat, 0, 0, xavix2002_i2c_mrangbat, mrangbat, xavix_i2c_state, init_xavix, "Bandai / SSD Company LTD", "Mahou Taiketsu Magiranger - Magimat de Dance & Battle (Japan)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) - -CONS( 2004, epo_tfit, 0, 0, xavix2002_i2c_24c04, epo_tfit, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Sports Tennis x Fitness (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // Epoch Tennis and Fitness has 24LC04 - -// TODO: does it have an SEEPROM? why does it hang? full title? -CONS( 2005, tmy_thom, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "Tomy / SSD Company LTD", "Thomas and Friends (Tomy)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) diff --git a/src/mame/drivers/xavix_2000.cpp b/src/mame/drivers/xavix_2000.cpp new file mode 100644 index 00000000000..30909fd8c17 --- /dev/null +++ b/src/mame/drivers/xavix_2000.cpp @@ -0,0 +1,287 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood +/***************************************************************************/ + +/* (XaviX 2000 type CPU) hardware titles (2nd XaviX generation?) + + these use the SSD 2000 NEC 85605-621 type CPU + + This CPU type adds extra opcodes that don't appear to be present in the 97/98 types + It does not appear to support the bitmap modes or 16-bit ROMs found in the 2002 type + + It is possible some games in the regular xavix.cpp drivers use this type, there + does not appear to be a way to tell unless the extra opcodes are used or the CPU + has been decapped + +*/ + +#include "emu.h" +#include "includes/xavix_2002.h" + +// #define VERBOSE 1 +#include "logmacro.h" + +static INPUT_PORTS_START( xavix ) + PORT_START("IN0") + PORT_DIPNAME( 0x01, 0x00, "IN0" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_START("IN1") + PORT_DIPNAME( 0x01, 0x00, "IN1" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_START("AN0") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN1") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN2") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN3") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN4") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN5") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN6") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN7") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + + PORT_START("MOUSE0X") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("MOUSE0Y") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("MOUSE1X") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("MOUSE1Y") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + + PORT_START("REGION") // PAL/NTSC flag + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_CUSTOM ) +INPUT_PORTS_END + +static INPUT_PORTS_START( xavix_i2c ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN1") + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) +INPUT_PORTS_END + +static INPUT_PORTS_START( epo_ebox ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN0") + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // select + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // back + // 04/08 not used for buttons? + PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) + PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) + PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) + PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) +INPUT_PORTS_END + + +static INPUT_PORTS_START( epo_bowl ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN0") + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1) + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_PLAYER(1) + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1) + PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) + PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) + + PORT_MODIFY("IN1") + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) +INPUT_PORTS_END + +static INPUT_PORTS_START( epo_sdb ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("MOUSE0X") + PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(1) + PORT_MODIFY("MOUSE0Y") + PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(1) + PORT_MODIFY("MOUSE1X") + PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(2) + PORT_MODIFY("MOUSE1Y") + PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(2) + + PORT_MODIFY("IN0") + PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(2) + + PORT_MODIFY("IN1") + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1) +INPUT_PORTS_END + + +static INPUT_PORTS_START( ttv_lotr ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN1") + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r) + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) +INPUT_PORTS_END + +static INPUT_PORTS_START( ttv_mx ) + PORT_INCLUDE(xavix_i2c) + + PORT_MODIFY("IN0") + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // Accel + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // Brake + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Pause") + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Motion Up") // you tilt the device, but actual inputs are digital + PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Motion Down") + PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("Motion Left") + PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("Motion Right") +INPUT_PORTS_END + + +void xavix_state::xavix2000(machine_config &config) +{ + xavix(config); + + XAVIX2000(config.replace(), m_maincpu, MAIN_CLOCK); + m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map); + m_maincpu->set_addrmap(5, &xavix_state::xavix_lowbus_map); + m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map); + m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt)); + m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors)); + + m_palette->set_entries(512); +} + +void xavix_state::xavix2000_nv(machine_config &config) +{ + xavix2000(config); + + NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1); +} + +void xavix_2000_nv_sdb_state::xavix2000_nv_sdb(machine_config &config) +{ + xavix2000_nv(config); + + m_anport->read_0_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport0_r)); + m_anport->read_1_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport1_r)); + m_anport->read_2_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport2_r)); + m_anport->read_3_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport3_r)); +} + +void xavix_i2c_state::xavix2000_i2c_24c04(machine_config &config) +{ + xavix2000(config); + + I2C_24C04(config, "i2cmem", 0); +} + +void xavix_i2c_state::xavix2000_i2c_24c02(machine_config &config) +{ + xavix2000(config); + + I2C_24C02(config, "i2cmem", 0); +} + + + +ROM_START( epo_sdb ) + ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) + ROM_LOAD("superdashball.bin", 0x000000, 0x400000, CRC(a004a764) SHA1(47a96822d4d7d6a0f6be5cd729c3747dbab65979) ) +ROM_END + +ROM_START( epo_ebox ) + ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) + ROM_LOAD("exciteboxing.bin", 0x000000, 0x400000, CRC(e25ae4f5) SHA1(7f7b613f0ab8f43f5cad0d13de538921e77cae9c) ) +ROM_END + +ROM_START( epo_bowl ) + ROM_REGION(0x200000, "bios", ROMREGION_ERASE00) + ROM_LOAD("bowling.bin", 0x000000, 0x200000, CRC(d34f8d9e) SHA1(ebe3792172dc43904b9226beb27f1da89d2388cc) ) +ROM_END + +ROM_START( ttv_sw ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "jedi.bin", 0x000000, 0x800000, CRC(51cae5fd) SHA1(1ed8d556f31b4182259ca8c766d60c824d8d9744) ) +ROM_END + +ROM_START( ttv_lotr ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "lotr.bin", 0x000000, 0x800000, CRC(a034ecd5) SHA1(264a9d4327af0a075841ad6129db67d82cf741f1) ) +ROM_END + +ROM_START( ttv_mx ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "mxdirtrebel.bin", 0x000000, 0x800000, CRC(e64bf1a1) SHA1(137f97d7d857697a13e0c8984509994dc7bc5fc5) ) +ROM_END + +ROM_START( drgqst ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "dragonquest.bin", 0x000000, 0x800000, CRC(3d24413f) SHA1(1677e81cedcf349de7bf091a232dc82c6424efba) ) +ROM_END + +ROM_START( ban_onep ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00) + ROM_LOAD("onepiece.bin", 0x000000, 0x800000, CRC(c5cb5a5f) SHA1(db85f6cc48d77c5a4967b9b8e2999167e3dfc8c8) ) +ROM_END + +// doesn't use extra opcodes? +CONS( 2002, epo_ebox, 0, 0, xavix2000_nv, epo_ebox, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Boxing (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // doesn't use XaviX2000 extra opcodes, but had that type of CPU + // die not confirmed, but uses extra opcodes. (hangs on title screen due to combination of freq_timer_done nested interrupts tripping, and waiting on bits in input ports to change +CONS( 2002, epo_bowl, 0, 0, xavix2000_i2c_24c02, epo_bowl, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Bowling (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) + +CONS( 2004, epo_sdb, 0, 0, xavix2000_nv_sdb, epo_sdb, xavix_2000_nv_sdb_state, init_xavix, "Epoch / SSD Company LTD", "Super Dash Ball (Japan)", MACHINE_IMPERFECT_SOUND ) + +CONS( 2005, ttv_sw, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Star Wars Saga Edition - Lightsaber Battle Game", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) +CONS( 2005, ttv_lotr, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Lord Of The Rings - Warrior of Middle-Earth", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) +CONS( 2005, ttv_mx, 0, 0, xavix2000_i2c_24c04, ttv_mx, xavix_i2c_state, init_xavix, "Tiger / SSD Company LTD", "MX Dirt Rebel", MACHINE_IMPERFECT_SOUND ) +CONS( 2003, drgqst, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Square Enix / SSD Company LTD", "Kenshin Dragon Quest: Yomigaerishi Densetsu no Ken", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) + +// hangs after starting a game, or after quite a long time in attract mode (first problem could be bad save data read with the eeprom code, 2nd problem might just be how it is, ends up in a dead loop, not executing invalid code, idle timeout / battery saver) +CONS( 2004, ban_onep, 0, 0, xavix2000_i2c_24c04, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Bandai / SSD Company LTD", "One Piece Punch Battle (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) diff --git a/src/mame/drivers/xavix_2002.cpp b/src/mame/drivers/xavix_2002.cpp new file mode 100644 index 00000000000..5cde7e9e328 --- /dev/null +++ b/src/mame/drivers/xavix_2002.cpp @@ -0,0 +1,547 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood +/***************************************************************************/ + +/* SuperXaviX (XaviX 2002 type CPU) hardware titles (3rd XaviX generation?) + + these use the SSD 2002 NEC 85054-611 type CPU + differences include support for 16-bit ROMs, high resolution bitmap modes, interlace screen modes, extra IO + + XavixPort Golf is "SSD 2003 SuperXaviX MXIC 2003 3009" (not dumped yet, but actually marked as SuperXaviX unlike the others!) + +*/ + +#include "emu.h" +#include "includes/xavix_2002.h" + +// #define VERBOSE 1 +#include "logmacro.h" + +/* The 'XaviXPORT' isn't a real console, more of a TV adapter, all the actual hardware (CPU including video hw, sound hw) is in the cartridges and controllers + and can vary between games, see notes at top of driver. + + The 'Domyos Interactive System (DiS)' released in France by Decathlon appears to be identical to XaviXPORT (but for PAL regions, and with an entirely different software range) +*/ + + +static INPUT_PORTS_START( xavix ) + PORT_START("IN0") + PORT_DIPNAME( 0x01, 0x00, "IN0" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_START("IN1") + PORT_DIPNAME( 0x01, 0x00, "IN1" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_START("AN0") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN1") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN2") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN3") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN4") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN5") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN6") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("AN7") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + + PORT_START("MOUSE0X") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("MOUSE0Y") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("MOUSE1X") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_START("MOUSE1Y") + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) + + PORT_START("REGION") // PAL/NTSC flag + PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_CUSTOM ) +INPUT_PORTS_END + +static INPUT_PORTS_START( xavix_i2c ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN1") + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) +INPUT_PORTS_END + + +static INPUT_PORTS_START( epo_tfit ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN0") + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // select + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // back + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) + PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) + PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) + PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) + PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) + + PORT_MODIFY("IN1") + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) +INPUT_PORTS_END + + +static INPUT_PORTS_START( mrangbat ) + PORT_INCLUDE(xavix_i2c) + + PORT_MODIFY("IN0") + PORT_DIPNAME( 0x01, 0x00, "IN0" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_MODIFY("IN1") + PORT_DIPNAME( 0x01, 0x00, "IN1" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_START("EX0") // NOT A JOYSTICK!! + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1) PORT_16WAY // Red/Up 1 + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(2) PORT_16WAY // Red/Up 2 + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(2) PORT_16WAY // Green / Circle / Right 2 + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(2) PORT_16WAY // Pink / Star / Left 2 + PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) PORT_16WAY // Blue / Square / Right 1 + PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) PORT_16WAY // Yellow / Triangle / Left 1 + PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) + PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) + + + PORT_START("EX1") + PORT_DIPNAME( 0x01, 0x00, "EX1" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) + + PORT_START("EX2") + PORT_DIPNAME( 0x01, 0x00, "EX2" ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x01, DEF_STR( On ) ) + PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x02, DEF_STR( On ) ) + PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x04, DEF_STR( On ) ) + PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x08, DEF_STR( On ) ) + PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x10, DEF_STR( On ) ) + PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x20, DEF_STR( On ) ) + PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x40, DEF_STR( On ) ) + PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) + PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) + PORT_DIPSETTING( 0x80, DEF_STR( On ) ) +INPUT_PORTS_END + +static INPUT_PORTS_START( xavix_bowl ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("IN1") + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r) + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda) +INPUT_PORTS_END + +static INPUT_PORTS_START( xavixp ) + PORT_INCLUDE(xavix) + + PORT_MODIFY("REGION") // PAL/NTSC flag + PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_CUSTOM ) +INPUT_PORTS_END + + +/* SuperXavix IO port handliner (per game) */ + +uint8_t xavix_i2c_jmat_state::read_extended_io0() +{ + LOG("%s: read_extended_io0\n", machine().describe_context()); + return 0x00; +} + +uint8_t xavix_i2c_jmat_state::read_extended_io1() +{ + LOG("%s: read_extended_io1\n", machine().describe_context()); + + // reads this by reading the byte, then shifting right 4 times to place value into carry flag + return m_i2cmem->read_sda() << 3; + //return 0x00; +} + +uint8_t xavix_i2c_jmat_state::read_extended_io2() +{ + LOG("%s: read_extended_io2\n", machine().describe_context()); + return 0x00; +} + +void xavix_i2c_jmat_state::write_extended_io0(uint8_t data) +{ + LOG("%s: io0_data_w %02x\n", machine().describe_context(), data); +} + +void xavix_i2c_jmat_state::write_extended_io1(uint8_t data) +{ + LOG("%s: io1_data_w %02x\n", machine().describe_context(), data); + + m_i2cmem->write_sda((data & 0x08) >> 3); + m_i2cmem->write_scl((data & 0x10) >> 4); + +} + +void xavix_i2c_jmat_state::write_extended_io2(uint8_t data) +{ + LOG("%s: io2_data_w %02x\n", machine().describe_context(), data); +} + +READ_LINE_MEMBER(xavix_i2c_lotr_state::camera_r) // seems to be some kind of camera status bits +{ + return machine().rand(); +} + +READ_LINE_MEMBER(xavix_i2c_bowl_state::camera_r) // seems to be some kind of camera status bits +{ + return machine().rand(); +} + +void xavix_state::xavix2002(machine_config &config) +{ + xavix(config); + + XAVIX2002(config.replace(), m_maincpu, MAIN_CLOCK); + m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map); + m_maincpu->set_addrmap(5, &xavix_state::superxavix_lowbus_map); // has extra video, io etc. + m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map); + m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt)); + m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors)); + + m_palette->set_entries(512); + + XAVIX2002IO(config, m_xavix2002io, 0); +} + + + +void xavix_i2c_jmat_state::xavix2002_i2c_jmat(machine_config &config) +{ + xavix2002_i2c_24c04(config); + + m_xavix2002io->read_0_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io0)); + m_xavix2002io->write_0_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io0)); + m_xavix2002io->read_1_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io1)); + m_xavix2002io->write_1_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io1)); + m_xavix2002io->read_2_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io2)); + m_xavix2002io->write_2_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io2)); +} + +void xavix2002_superpttv_state::xavix2002_superpctv(machine_config& config) +{ + xavix2002(config); + + m_xavix2002io->read_0_callback().set(FUNC(xavix2002_superpttv_state::read_extended_io0)); + m_xavix2002io->read_1_callback().set(FUNC(xavix2002_superpttv_state::read_extended_io1)); + m_xavix2002io->read_2_callback().set(FUNC(xavix2002_superpttv_state::read_extended_io2)); +} + + +void xavix_i2c_state::xavix2002_i2c_24c04(machine_config &config) +{ + xavix2002(config); + + I2C_24C04(config, "i2cmem", 0); +} + +void xavix_i2c_state::xavix2002_i2c_mrangbat(machine_config &config) +{ + xavix2002(config); + + I2C_24C02(config, "i2cmem", 0); // 24C02? + + m_xavix2002io->read_0_callback().set_ioport("EX0"); + m_xavix2002io->read_1_callback().set_ioport("EX1"); + m_xavix2002io->read_2_callback().set_ioport("EX2"); +} + + +// XaviXPORT +ROM_START( xavtenni ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "xavixtennis.bin", 0x000000, 0x800000, CRC(23a1d918) SHA1(2241c59e8ea8328013e55952ebf9060ea0a4675b) ) +ROM_END + +ROM_START( xavbaseb ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "xpbaseball.bin", 0x000000, 0x800000, CRC(e9ed692d) SHA1(537e390e972156dc7da66ee127ae4c8052038ee5) ) +ROM_END + +ROM_START( xavbowl ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "xpbowling.bin", 0x000000, 0x800000, CRC(2873460b) SHA1(ea8e2392f5a12961a23eb66dca8e07dec81ce8c8) ) +ROM_END + +ROM_START( xavbassf ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "xpbassfishing.bin", 0x000000, 0x800000, CRC(09ab2f29) SHA1(616254176315d0947002e9ae5a6371a3ffa2e8eb) ) + + // code for the nRF24E1s, stored in SEEPROMs. One in the cartridge, one in the rod/reel + ROM_REGION( 0x1001, "reel_io", ROMREGION_ERASE00 ) + ROM_LOAD( "xpbassfishingnrf24e1reel.bin", 0x0000, 0x1001, CRC(cfbb19ae) SHA1(32464e4e4be33fdbc7768311f93ce437a316c616) ) + + ROM_REGION( 0x800000, "base_io", ROMREGION_ERASE00 ) + ROM_LOAD( "xpbassfishingnrf24e1cart.bin", 0x0000, 0x1001, CRC(62f6303e) SHA1(126b2663e252fb80948f53153e4046e63dd8be32) ) +ROM_END + +ROM_START( xavbox ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "xpboxing.bin", 0x000000, 0x800000, CRC(b61e7717) SHA1(162b9c53ac8c9d7b6972db44f7bc1cb0a7837b70) ) +ROM_END + +// Several of the XaviXport and DiS games are 2 glob setups (and must have some kind of banking) + +ROM_START( xavjmat ) + ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(1420640d) SHA1(dd714cd57cff885293688f74f69b5c1726e20ec0) ) + + ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) + ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(52dc318c) SHA1(dc50e0747ba29cfb1048fd4a55d26870086c869b) ) +ROM_END + +// currently copies the wrong code into RAM to execute (due to extended ROM size, and possible banking) +// [:] ':maincpu' (00E074): rom_dmatrg_w (do DMA?) 01 +// [:] (possible DMA op SRC 00ebe2d3 DST 358a LEN 0398) +// needs to come from 006be2d3 (so still from lower 8MB, not upper 8MB) + +ROM_START( xavmusic ) + ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(e7c8ad59) SHA1(d47fac8b480de4db88a1b306ff8830a65d1738a3) ) + + ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) + ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(977c956f) SHA1(debc086d0cf6c391002ad163e7bfaa2f010cc8f5) ) +ROM_END + + +// Domyos DiS (XaviX 2002 based titles) +ROM_START( domfitex ) + ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(841fe3cd) SHA1(8678b8a0c5198b24169a84dbe3ae979bb0838f23) ) + + ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) + ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(1dc844ea) SHA1(c23da9006227f7fe4982998c17759d403a47472a) ) +ROM_END + +ROM_START( domfitch ) + ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(0ff2a7a6) SHA1(9b924cc4330e3f8d9204390854048fe2325bfdf7) ) + + ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) + ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(284583f6) SHA1(bd2d5304f1e01eed656b5de957ec0a0330a3d969) ) +ROM_END + +ROM_START( domdance ) + ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(74f9499d) SHA1(a64235075e32567cd6d2ab7b1284efcb8e7538e2) ) + + ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) + ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(e437565c) SHA1(f6db219ea14404b698ca453f6e50c726b2e77abb) ) +ROM_END + +ROM_START( domstepc ) + ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(cb37b5e9) SHA1(b742e3db98f36720adf5af9096c6bc235279de12) ) + + ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 ) + ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(dadaa744) SHA1(fd7ca77232a8fe228fc93b0a8a47ba3260349d90) ) +ROM_END + +ROM_START( mrangbat ) + ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) + ROM_LOAD("powerrangerspad.bin", 0x000000, 0x400000, CRC(d3a98775) SHA1(485c66242dd0ee436a278d23005aece48d606431) ) +ROM_END + +ROM_START( tmy_thom ) + ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 ) + ROM_LOAD( "thomastank.bin", 0x000000, 0x800000, CRC(a52a23be) SHA1(e5b3500239d9e56eb5405f7585982959e5a162da) ) +ROM_END + +ROM_START( epo_tfit ) + ROM_REGION(0x400000, "bios", ROMREGION_ERASE00) + ROM_LOAD("tennisfitness.bin", 0x000000, 0x400000, CRC(cbf65bd2) SHA1(30b3da6f061b2dd91679db42a050f715901beb87) ) +ROM_END + +ROM_START( suprpctv ) + ROM_REGION(0x800000, "bios", ROMREGION_ERASE00) // inverted line? + ROM_LOAD("superpctv.bin", 0x200000, 0x200000, CRC(4a55a81c) SHA1(178b4b595a3aefc6d1c176031b436fc3312009e7) ) + ROM_CONTINUE(0x000000, 0x200000) + ROM_CONTINUE(0x600000, 0x200000) + ROM_CONTINUE(0x400000, 0x200000) +ROM_END + +ROM_START( udance ) + ROM_REGION(0x800000, "bios", ROMREGION_ERASE00) + ROM_LOAD("udancerom0.bin", 0x000000, 0x800000, CRC(3066580a) SHA1(545257c75a892894faf386f4ab9a31967cdbe8ae) ) + + ROM_REGION(0x800000, "biosx", ROMREGION_ERASE00) + ROM_LOAD("udancerom1.bin", 0x000000, 0x800000, CRC(7dbaabde) SHA1(38c523dcdf8185465fc550fb9b0e8c7909f839be) ) +ROM_END + + +CONS( 2004, xavtenni, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Tennis (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2004, xavbaseb, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Baseball (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2004, xavbowl, 0, 0, xavix2002_i2c_24c04, xavix_bowl, xavix_i2c_bowl_state, init_xavix, "SSD Company LTD", "XaviX Bowling (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera' +CONS( 2004, xavbox, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Boxing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera' +// Bass Fishing PCB is just like Tennis except with an RF daughterboard. +CONS( 2004, xavbassf, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Bass Fishing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + +// TODO: check SEEPROM type and hookup, banking! +CONS( 2005, xavjmat, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "Jackie Chan J-Mat Fitness (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2007, xavmusic, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Music & Circuit (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + +// https://arnaudmeyer.wordpress.com/domyos-interactive-system/ +// Domyos Fitness Adventure +// Domyos Fitness Challenge +// Domyos Fitness Exercises +// Domyos Fit Race +// Domyos Soft Fitness +// Domyos Fitness Dance +// Domyos Fitness Play +// Domyos Fitness Training + +// Domyos Bike Concept (not listed on site above) + +// Has SEEPROM and an RTC. Exercise has some leftover PC buffer stuff. (TODO, check SEEPROM type, RTC type, banking) (both Exercises and Challenge are identical PCBs) +CONS( 2008, domfitex, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Exercises (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2008, domfitch, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Challenge (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2007, domdance, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Dance (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +CONS( 2007, domstepc, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Step Concept (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + +// some DIS games run on XaviX 2 instead, see xavix2.cpp for Domyos Fitness Adventure and Domyos Bike Concept + +CONS( 2005, mrangbat, 0, 0, xavix2002_i2c_mrangbat, mrangbat, xavix_i2c_state, init_xavix, "Bandai / SSD Company LTD", "Mahou Taiketsu Magiranger - Magimat de Dance & Battle (Japan)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + +CONS( 2004, epo_tfit, 0, 0, xavix2002_i2c_24c04, epo_tfit, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Sports Tennis x Fitness (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // Epoch Tennis and Fitness has 24LC04 + +// TODO: does it have an SEEPROM? why does it hang? full title? +CONS( 2005, tmy_thom, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "Tomy / SSD Company LTD", "Thomas and Friends (Tomy)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + +// has HT24LC16 +CONS( 2008, udance, 0, 0, xavix2002, xavix, xavix_state, init_xavix, "Tiger / SSD Company LTD", "U-Dance", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + +// this has RAM in the usual ROM space, needs handling, also has Atmel 24LC64. +CONS( 200?, suprpctv, 0, 0, xavix2002_superpctv, xavix, xavix2002_superpttv_state, init_xavix, "Epoch / SSD Company LTD", "Super PC TV (Epoch)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) + + diff --git a/src/mame/includes/xavix.h b/src/mame/includes/xavix.h index e6b869dc537..f6ddc11e8e3 100644 --- a/src/mame/includes/xavix.h +++ b/src/mame/includes/xavix.h @@ -24,6 +24,12 @@ #include "machine/xavix_anport.h" #include "machine/xavix_math.h" +// NTSC clock for regular XaviX? +#define MAIN_CLOCK XTAL(21'477'272) +// some games (eg Radica Opus) run off a 3.579545MHz XTAL ( same as the above /6 ) so presumably there is a divider / multiplier circuit on some PCBs? +// TODO: what's the PAL clock? + + class xavix_sound_device : public device_t, public device_sound_interface { public: @@ -596,26 +602,6 @@ private: }; -class xavix_2000_nv_sdb_state : public xavix_state -{ -public: - xavix_2000_nv_sdb_state(const machine_config &mconfig, device_type type, const char *tag) - : xavix_state(mconfig, type, tag) - { } - - void xavix2000_nv_sdb(machine_config &config); - -protected: - -private: - uint8_t sdb_anport0_r() { return m_mouse0x->read()^0x7f; } - uint8_t sdb_anport1_r() { return m_mouse0y->read()^0x7f; } - uint8_t sdb_anport2_r() { return m_mouse1x->read()^0x7f; } - uint8_t sdb_anport3_r() { return m_mouse1y->read()^0x7f; } - -}; - - class xavix_i2c_state : public xavix_state { public: @@ -673,24 +659,6 @@ private: }; -class xavix_i2c_jmat_state : public xavix_i2c_state -{ -public: - xavix_i2c_jmat_state(const machine_config &mconfig, device_type type, const char *tag) - : xavix_i2c_state(mconfig, type, tag) - { } - - void xavix2002_i2c_jmat(machine_config &config); - -private: - uint8_t read_extended_io0(); - uint8_t read_extended_io1(); - uint8_t read_extended_io2(); - void write_extended_io0(uint8_t data); - void write_extended_io1(uint8_t data); - void write_extended_io2(uint8_t data); -}; - class xavix_i2c_lotr_state : public xavix_i2c_state { @@ -705,15 +673,6 @@ protected: //virtual void write_io1(uint8_t data, uint8_t direction) override; }; -class xavix_i2c_bowl_state : public xavix_i2c_state -{ -public: - xavix_i2c_bowl_state(const machine_config &mconfig, device_type type, const char *tag) - : xavix_i2c_state(mconfig, type, tag) - { } - - DECLARE_READ_LINE_MEMBER(camera_r); -}; diff --git a/src/mame/includes/xavix_2000.h b/src/mame/includes/xavix_2000.h new file mode 100644 index 00000000000..0611ba3149c --- /dev/null +++ b/src/mame/includes/xavix_2000.h @@ -0,0 +1,27 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood +#ifndef MAME_INCLUDES_XAVIX_2000_H +#define MAME_INCLUDES_XAVIX_2000_H + +#include "xavix.h" + + +class xavix_2000_nv_sdb_state : public xavix_state +{ +public: + xavix_2000_nv_sdb_state(const machine_config &mconfig, device_type type, const char *tag) + : xavix_state(mconfig, type, tag) + { } + + void xavix2000_nv_sdb(machine_config &config); + +protected: + +private: + uint8_t sdb_anport0_r() { return m_mouse0x->read()^0x7f; } + uint8_t sdb_anport1_r() { return m_mouse0y->read()^0x7f; } + uint8_t sdb_anport2_r() { return m_mouse1x->read()^0x7f; } + uint8_t sdb_anport3_r() { return m_mouse1y->read()^0x7f; } +}; + +#endif // MAME_INCLUDES_XAVIX_2000_H diff --git a/src/mame/includes/xavix_2002.h b/src/mame/includes/xavix_2002.h new file mode 100644 index 00000000000..66bbfe380bb --- /dev/null +++ b/src/mame/includes/xavix_2002.h @@ -0,0 +1,55 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood +#ifndef MAME_INCLUDES_XAVIX_2002_H +#define MAME_INCLUDES_XAVIX_2002_H + +#include "xavix_2000.h" + +class xavix_i2c_jmat_state : public xavix_i2c_state +{ +public: + xavix_i2c_jmat_state(const machine_config &mconfig, device_type type, const char *tag) + : xavix_i2c_state(mconfig, type, tag) + { } + + void xavix2002_i2c_jmat(machine_config &config); + +private: + uint8_t read_extended_io0(); + uint8_t read_extended_io1(); + uint8_t read_extended_io2(); + void write_extended_io0(uint8_t data); + void write_extended_io1(uint8_t data); + void write_extended_io2(uint8_t data); +}; + +class xavix2002_superpttv_state : public xavix_state +{ +public: + xavix2002_superpttv_state(const machine_config &mconfig, device_type type, const char *tag) + : xavix_state(mconfig, type, tag) + { } + + void xavix2002_superpctv(machine_config &config); + +private: + uint8_t read_extended_io0() { return 0x00; }; + uint8_t read_extended_io1() { return 0x00; }; + uint8_t read_extended_io2() { return 0x00; }; + //void write_extended_io0(uint8_t data); + //void write_extended_io1(uint8_t data); + //void write_extended_io2(uint8_t data); +}; + +class xavix_i2c_bowl_state : public xavix_i2c_state +{ +public: + xavix_i2c_bowl_state(const machine_config &mconfig, device_type type, const char *tag) + : xavix_i2c_state(mconfig, type, tag) + { } + + DECLARE_READ_LINE_MEMBER(camera_r); +}; + + +#endif // MAME_INCLUDES_XAVIX_2002_H diff --git a/src/mame/machine/xavix.cpp b/src/mame/machine/xavix.cpp index b6b97e40866..317e5a3ee9e 100644 --- a/src/mame/machine/xavix.cpp +++ b/src/mame/machine/xavix.cpp @@ -379,15 +379,6 @@ void xavix_state::dispctrl_posirq_y_w(uint8_t data) /* Per Game IO port callbacks */ -READ_LINE_MEMBER(xavix_i2c_lotr_state::camera_r) // seems to be some kind of camera status bits -{ - return machine().rand(); -} - -READ_LINE_MEMBER(xavix_i2c_bowl_state::camera_r) // seems to be some kind of camera status bits -{ - return machine().rand(); -} READ_LINE_MEMBER(xavix_ekara_state::ekara_multi0_r) { @@ -512,48 +503,6 @@ void xavix_ekara_state::write_io1(uint8_t data, uint8_t direction) m_extraiowrite = extraiowrite; } -/* SuperXavix IO port handliner (per game) */ - -uint8_t xavix_i2c_jmat_state::read_extended_io0() -{ - LOG("%s: read_extended_io0\n", machine().describe_context()); - return 0x00; -} - -uint8_t xavix_i2c_jmat_state::read_extended_io1() -{ - LOG("%s: read_extended_io1\n", machine().describe_context()); - - // reads this by reading the byte, then shifting right 4 times to place value into carry flag - return m_i2cmem->read_sda() << 3; - //return 0x00; -} - -uint8_t xavix_i2c_jmat_state::read_extended_io2() -{ - LOG("%s: read_extended_io2\n", machine().describe_context()); - return 0x00; -} - -void xavix_i2c_jmat_state::write_extended_io0(uint8_t data) -{ - LOG("%s: io0_data_w %02x\n", machine().describe_context(), data); -} - -void xavix_i2c_jmat_state::write_extended_io1(uint8_t data) -{ - LOG("%s: io1_data_w %02x\n", machine().describe_context(), data); - - m_i2cmem->write_sda((data & 0x08) >> 3); - m_i2cmem->write_scl((data & 0x10) >> 4); - -} - -void xavix_i2c_jmat_state::write_extended_io2(uint8_t data) -{ - LOG("%s: io2_data_w %02x\n", machine().describe_context(), data); -} - // the cart pins Popira 2 uses for IO with cart gc0010 are not controllable by the CPU on other ekara systems READ_LINE_MEMBER(xavix_popira2_cart_state::i2c_r) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index ee3410972d0..0dfa3e07138 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -38011,6 +38011,7 @@ dreamlss senspeed ordentv wfcentro +tiktokmm @source:spg2xx_digimake.cpp rad_digi @@ -42261,15 +42262,11 @@ rad_snowp // rad_madf // rad_fb // rad_socr // -epo_bowl // epo_esdx // epo_epp // epo_eppk // epo_epp3 // epo_efdx // -epo_tfit -epo_ebox // -epo_sdb // epo_guru // epo_dmon // rad_rh // @@ -42284,8 +42281,6 @@ jarajal // tcarnavi // tomcpin tomplc -mrangbat -ban_onep // ekara // ekaraa // ekaraj // @@ -42301,10 +42296,22 @@ taikodp // jpopira // evio // gcslottv // + +@source:xavix_2000.cpp +epo_ebox // +epo_bowl // +epo_sdb // ttv_sw // ttv_lotr // ttv_mx // drgqst // +ban_onep // + +@source:xavix_2002.cpp +suprpctv +udance +mrangbat +epo_tfit tmy_thom // xavtenni // xavbaseb // diff --git a/src/mame/mess.flt b/src/mame/mess.flt index 16246345cbf..02b0021e210 100644 --- a/src/mame/mess.flt +++ b/src/mame/mess.flt @@ -1101,6 +1101,8 @@ x1.cpp x1twin.cpp x68k.cpp xavix.cpp +xavix_2000.cpp +xavix_2002.cpp xavix2.cpp xbase09.cpp xbox.cpp |