From d13c7623cf0dbdf2e723f1916229fe57264d03d0 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 20 Jun 2017 05:01:11 +0100 Subject: Onna Sansirou - Typhoon Gal - use 68705 dump, replace inaccurate protection sim [ShouTime, brizzo] also set 2 seems to be a bootleg, it's unprotected at the very least. --- src/mame/drivers/flstory.cpp | 40 ++++++++++++++++++++++++---------------- src/mame/includes/flstory.h | 3 --- src/mame/machine/flstory.cpp | 42 ------------------------------------------ 3 files changed, 24 insertions(+), 61 deletions(-) diff --git a/src/mame/drivers/flstory.cpp b/src/mame/drivers/flstory.cpp index 8c5fd46ff7a..a564caed845 100644 --- a/src/mame/drivers/flstory.cpp +++ b/src/mame/drivers/flstory.cpp @@ -100,7 +100,7 @@ static ADDRESS_MAP_START( onna34ro_map, AS_PROGRAM, 8, flstory_state ) AM_RANGE(0x0000, 0xbfff) AM_ROM AM_RANGE(0xc000, 0xc7ff) AM_RAM_WRITE(flstory_videoram_w) AM_SHARE("videoram") AM_RANGE(0xc800, 0xcfff) AM_RAM /* unknown */ - AM_RANGE(0xd000, 0xd000) AM_READWRITE(onna34ro_mcu_r, onna34ro_mcu_w) +// AM_RANGE(0xd000, 0xd000) AM_DEVREADWRITE("bmcu", taito68705_mcu_device, data_r, data_w) AM_RANGE(0xd001, 0xd001) AM_WRITENOP /* watchdog? */ AM_RANGE(0xd002, 0xd002) AM_WRITENOP /* coin lock out? */ AM_RANGE(0xd400, 0xd400) AM_READWRITE(from_snd_r, sound_command_w) @@ -111,7 +111,7 @@ static ADDRESS_MAP_START( onna34ro_map, AS_PROGRAM, 8, flstory_state ) AM_RANGE(0xd802, 0xd802) AM_READ_PORT("DSW2") AM_RANGE(0xd803, 0xd803) AM_READ_PORT("SYSTEM") AM_RANGE(0xd804, 0xd804) AM_READ_PORT("P1") - AM_RANGE(0xd805, 0xd805) AM_READ(onna34ro_mcu_status_r) +// AM_RANGE(0xd805, 0xd805) AM_READ(flstory_mcu_status_r) AM_RANGE(0xd806, 0xd806) AM_READ_PORT("P2") // AM_RANGE(0xda00, 0xda00) AM_WRITEONLY AM_RANGE(0xdc00, 0xdc9f) AM_RAM AM_SHARE("spriteram") @@ -122,6 +122,12 @@ static ADDRESS_MAP_START( onna34ro_map, AS_PROGRAM, 8, flstory_state ) AM_RANGE(0xe000, 0xe7ff) AM_RAM AM_SHARE("workram") /* work RAM */ ADDRESS_MAP_END +static ADDRESS_MAP_START( onna34ro_mcu_map, AS_PROGRAM, 8, flstory_state ) + AM_IMPORT_FROM(onna34ro_map) + AM_RANGE(0xd000, 0xd000) AM_DEVREADWRITE("bmcu", taito68705_mcu_device, data_r, data_w) + AM_RANGE(0xd805, 0xd805) AM_READ(flstory_mcu_status_r) +ADDRESS_MAP_END + CUSTOM_INPUT_MEMBER(flstory_state::victnine_mcu_status_bit01_r) { address_space &space = m_maincpu->space(AS_PROGRAM); @@ -895,9 +901,6 @@ static MACHINE_CONFIG_START( onna34ro ) MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60) /* IRQ generated by ??? */ /* NMI generated by the main CPU */ -// MCFG_CPU_ADD("mcu", M68705, XTAL_18_432MHz/6) /* ??? */ -// MCFG_CPU_PROGRAM_MAP(m68705_map) - MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* 100 CPU slices per frame - an high value to ensure proper */ /* synchronization of the CPUs */ MCFG_MACHINE_RESET_OVERRIDE(flstory_state,flstory) @@ -946,6 +949,13 @@ static MACHINE_CONFIG_START( onna34ro ) MCFG_SOUND_ROUTE_EX(0, "dac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE_EX(0, "dac", -1.0, DAC_VREF_NEG_INPUT) MACHINE_CONFIG_END +static MACHINE_CONFIG_DERIVED( onna34ro_mcu, onna34ro ) + MCFG_CPU_MODIFY("maincpu") + MCFG_CPU_PROGRAM_MAP(onna34ro_mcu_map) + + MCFG_DEVICE_ADD("bmcu", TAITO68705_MCU, XTAL_18_432MHz/6) /* ? */ +MACHINE_CONFIG_END + static MACHINE_CONFIG_START( victnine ) /* basic machine hardware */ @@ -1140,8 +1150,8 @@ ROM_START( onna34ro ) ROM_LOAD( "a52-15.37s", 0x6000, 0x2000, CRC(5afc21d0) SHA1(317d5fb3a48ce5e13e02c5c6431fa08ada115d27) ) ROM_LOAD( "a52-16.38s", 0x8000, 0x2000, CRC(ccf42aee) SHA1(a6eb01c5384724999631b55700dade430b71ca95) ) - ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ - ROM_LOAD( "a52-17.54c", 0x0000, 0x0800, NO_DUMP ) + ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ + ROM_LOAD( "a52_17.54c", 0x0000, 0x0800, CRC(0ab2612e) SHA1(2bc74e9ef5b9dd51d733dc62902d92c269f7d6a7) ) ROM_REGION( 0x20000, "gfx1", ROMREGION_INVERT ) ROM_LOAD( "a52-04.11v", 0x00000, 0x4000, CRC(5b126294) SHA1(fc31e062e665f7313f923e84d6497716f0658ac0) ) @@ -1167,9 +1177,6 @@ ROM_START( onna34roa ) ROM_LOAD( "a52-15.37s", 0x6000, 0x2000, CRC(5afc21d0) SHA1(317d5fb3a48ce5e13e02c5c6431fa08ada115d27) ) ROM_LOAD( "a52-16.38s", 0x8000, 0x2000, CRC(ccf42aee) SHA1(a6eb01c5384724999631b55700dade430b71ca95) ) - ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ - ROM_LOAD( "a52-17.54c", 0x0000, 0x0800, NO_DUMP ) - ROM_REGION( 0x20000, "gfx1", ROMREGION_INVERT ) ROM_LOAD( "a52-04.11v", 0x00000, 0x4000, CRC(5b126294) SHA1(fc31e062e665f7313f923e84d6497716f0658ac0) ) ROM_LOAD( "a52-06.10v", 0x04000, 0x4000, CRC(78114721) SHA1(d0e52544e05ab4fd1b131ed49beb252048bcbe31) ) @@ -1340,6 +1347,7 @@ Dumped by Corrado Tomaselli on 9/12/2010 */ + ROM_START( rumba ) ROM_REGION( 0x10000, "maincpu", 0 ) /* 64k for the first CPU */ ROM_LOAD( "a23_01-1.bin", 0x0000, 0x4000, CRC(4bea6e18) SHA1(b9a85e65105773b5f93dcc5fc1e7c588b2d25056) ) @@ -1362,9 +1370,9 @@ ROM_START( rumba ) ROM_END -GAME( 1985, flstory, 0, flstory, flstory, flstory_state, 0, ROT180, "Taito", "The FairyLand Story", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) -GAME( 1985, flstoryj, flstory, flstory, flstory, flstory_state, 0, ROT180, "Taito", "The FairyLand Story (Japan)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) -GAME( 1985, onna34ro, 0, onna34ro, onna34ro, flstory_state, 0, ROT0, "Taito", "Onna Sansirou - Typhoon Gal (set 1)", MACHINE_UNEMULATED_PROTECTION | MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) -GAME( 1985, onna34roa, onna34ro, onna34ro, onna34ro, flstory_state, 0, ROT0, "Taito", "Onna Sansirou - Typhoon Gal (set 2)", MACHINE_UNEMULATED_PROTECTION | MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) -GAME( 1984, victnine, 0, victnine, victnine, flstory_state, 0, ROT0, "Taito", "Victorious Nine", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) -GAME( 1984, rumba, 0, rumba, rumba, flstory_state, 0, ROT270, "Taito", "Rumba Lumber", MACHINE_IMPERFECT_SOUND ) +GAME( 1985, flstory, 0, flstory, flstory, flstory_state, 0, ROT180, "Taito", "The FairyLand Story", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) +GAME( 1985, flstoryj, flstory, flstory, flstory, flstory_state, 0, ROT180, "Taito", "The FairyLand Story (Japan)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) +GAME( 1985, onna34ro, 0, onna34ro_mcu, onna34ro, flstory_state, 0, ROT0, "Taito", "Onna Sansirou - Typhoon Gal", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) +GAME( 1985, onna34roa, onna34ro, onna34ro, onna34ro, flstory_state, 0, ROT0, "Taito", "Onna Sansirou - Typhoon Gal (bootleg)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) +GAME( 1984, victnine, 0, victnine, victnine, flstory_state, 0, ROT0, "Taito", "Victorious Nine", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) // MCU still simulated +GAME( 1984, rumba, 0, rumba, rumba, flstory_state, 0, ROT270, "Taito", "Rumba Lumber", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) diff --git a/src/mame/includes/flstory.h b/src/mame/includes/flstory.h index 0ceedda2127..0826b4bd05a 100644 --- a/src/mame/includes/flstory.h +++ b/src/mame/includes/flstory.h @@ -67,9 +67,6 @@ public: DECLARE_WRITE8_MEMBER(nmi_disable_w); DECLARE_WRITE8_MEMBER(nmi_enable_w); DECLARE_READ8_MEMBER(flstory_mcu_status_r); - DECLARE_WRITE8_MEMBER(onna34ro_mcu_w); - DECLARE_READ8_MEMBER(onna34ro_mcu_r); - DECLARE_READ8_MEMBER(onna34ro_mcu_status_r); DECLARE_WRITE8_MEMBER(victnine_mcu_w); DECLARE_READ8_MEMBER(victnine_mcu_r); DECLARE_READ8_MEMBER(victnine_mcu_status_r); diff --git a/src/mame/machine/flstory.cpp b/src/mame/machine/flstory.cpp index c3ffc7d1ff1..042f8a1cdd2 100644 --- a/src/mame/machine/flstory.cpp +++ b/src/mame/machine/flstory.cpp @@ -21,48 +21,6 @@ READ8_MEMBER(flstory_state::flstory_mcu_status_r) ((CLEAR_LINE != m_bmcu->mcu_semaphore_r()) ? 0x02 : 0x00); } -WRITE8_MEMBER(flstory_state::onna34ro_mcu_w) -{ - uint16_t score_adr = m_workram[0x29e] * 0x100 + m_workram[0x29d]; - - switch (data) - { - case 0x0e: - m_from_mcu = 0xff; - break; - case 0x01: - m_from_mcu = 0x6a; - break; - case 0x40: - if(score_adr >= 0xe000 && score_adr < 0xe800) - m_from_mcu = m_workram[score_adr - 0xe000]; /* score l*/ - break; - case 0x41: - if(score_adr >= 0xe000 && score_adr < 0xe800) - m_from_mcu = m_workram[(score_adr + 1) - 0xe000]; /* score m*/ - break; - case 0x42: - if(score_adr >= 0xe000 && score_adr < 0xe800) - m_from_mcu = m_workram[(score_adr + 2) - 0xe000] & 0x0f; /* score h*/ - break; - default: - m_from_mcu = 0x80; - } -} - -READ8_MEMBER(flstory_state::onna34ro_mcu_r) -{ - return m_from_mcu; -} - -READ8_MEMBER(flstory_state::onna34ro_mcu_status_r) -{ - int res = 3; - - return res; -} - - #define VICTNINE_MCU_SEED (m_workram[0x685]) static const uint8_t victnine_mcu_data[0x100] = -- cgit v1.2.3