diff options
Diffstat (limited to 'src/mame/drivers/flstory.cpp')
-rw-r--r-- | src/mame/drivers/flstory.cpp | 60 |
1 files changed, 13 insertions, 47 deletions
diff --git a/src/mame/drivers/flstory.cpp b/src/mame/drivers/flstory.cpp index 88505594557..47a3456f29c 100644 --- a/src/mame/drivers/flstory.cpp +++ b/src/mame/drivers/flstory.cpp @@ -70,7 +70,7 @@ static ADDRESS_MAP_START( flstory_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(flstory_mcu_r, flstory_mcu_w) + AM_RANGE(0xd000, 0xd000) AM_DEVREADWRITE("bmcu", taito68705_mcu_device, mcu_r, mcu_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) @@ -81,7 +81,7 @@ static ADDRESS_MAP_START( flstory_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(flstory_mcu_status_r) + AM_RANGE(0xd805, 0xd805) AM_DEVREAD("bmcu", taito68705_mcu_device, 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") @@ -441,17 +441,6 @@ static ADDRESS_MAP_START( sound_map, AS_PROGRAM, 8, flstory_state ) AM_RANGE(0xe000, 0xefff) AM_ROM /* space for diagnostics ROM */ ADDRESS_MAP_END -static ADDRESS_MAP_START( flstory_m68705_map, AS_PROGRAM, 8, flstory_state ) - ADDRESS_MAP_GLOBAL_MASK(0x7ff) - AM_RANGE(0x0000, 0x0000) AM_READWRITE(flstory_68705_port_a_r, flstory_68705_port_a_w) - AM_RANGE(0x0001, 0x0001) AM_READWRITE(flstory_68705_port_b_r, flstory_68705_port_b_w) - AM_RANGE(0x0002, 0x0002) AM_READWRITE(flstory_68705_port_c_r, flstory_68705_port_c_w) - AM_RANGE(0x0004, 0x0004) AM_WRITE(flstory_68705_ddr_a_w) - AM_RANGE(0x0005, 0x0005) AM_WRITE(flstory_68705_ddr_b_w) - AM_RANGE(0x0006, 0x0006) AM_WRITE(flstory_68705_ddr_c_w) - AM_RANGE(0x0010, 0x007f) AM_RAM - AM_RANGE(0x0080, 0x07ff) AM_ROM -ADDRESS_MAP_END @@ -992,22 +981,12 @@ void flstory_state::machine_start() save_item(NAME(m_snd_ctrl2)); save_item(NAME(m_snd_ctrl3)); /* mcu */ - save_item(NAME(m_from_main)); - save_item(NAME(m_from_mcu)); - save_item(NAME(m_mcu_sent)); - save_item(NAME(m_main_sent)); - save_item(NAME(m_port_a_in)); - save_item(NAME(m_port_a_out)); - save_item(NAME(m_ddr_a)); - save_item(NAME(m_port_b_in)); - save_item(NAME(m_port_b_out)); - save_item(NAME(m_ddr_b)); - save_item(NAME(m_port_c_in)); - save_item(NAME(m_port_c_out)); - save_item(NAME(m_ddr_c)); save_item(NAME(m_mcu_select)); + save_item(NAME(m_from_mcu)); } + + MACHINE_RESET_MEMBER(flstory_state,flstory) { MACHINE_RESET_CALL_MEMBER(ta7630); @@ -1026,20 +1005,8 @@ MACHINE_RESET_MEMBER(flstory_state,flstory) m_snd_ctrl2 = 0; m_snd_ctrl3 = 0; /* mcu */ - m_from_main = 0; - m_from_mcu = 0; - m_mcu_sent = 0; - m_main_sent = 0; - m_port_a_in = 0; - m_port_a_out = 0; - m_ddr_a = 0; - m_port_b_in = 0; - m_port_b_out = 0; - m_ddr_b = 0; - m_port_c_in = 0; - m_port_c_out = 0; - m_ddr_c = 0; m_mcu_select = 0; + m_from_mcu = 0; } static MACHINE_CONFIG_START( flstory, flstory_state ) @@ -1054,8 +1021,7 @@ static MACHINE_CONFIG_START( flstory, flstory_state ) 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) /* verified on pcb */ - MCFG_CPU_PROGRAM_MAP(flstory_m68705_map) + MCFG_DEVICE_ADD("bmcu", TAITO68705_MCU, XTAL_18_432MHz/6) /* verified on pcb */ MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* 100 CPU slices per frame - an high value to ensure proper */ /* synchronization of the CPUs */ @@ -1316,7 +1282,7 @@ ROM_START( flstory ) ROM_LOAD( "snd.22", 0x0000, 0x2000, CRC(d58b201d) SHA1(1c9c2936ec95a8fa920d58668bea420c5e15008f) ) ROM_LOAD( "snd.23", 0x2000, 0x2000, CRC(25e7fd9d) SHA1(b9237459e3d8acf8502a693914e50714a37d515e) ) - ROM_REGION( 0x0800, "mcu", 0 ) /* 2k for the microcontroller */ + ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ ROM_LOAD( "a45.mcu", 0x0000, 0x0800, CRC(5378253c) SHA1(e1ae1ab01e470b896c1d74ad4088928602a21a1b) ) ROM_REGION( 0x20000, "gfx1", ROMREGION_INVERT ) @@ -1340,7 +1306,7 @@ ROM_START( flstoryj ) ROM_LOAD( "a45_12.8", 0x0000, 0x2000, CRC(d6f593fb) SHA1(8551ef22c2cdd9df8d7949a178883f56ea56a4a2) ) ROM_LOAD( "a45_13.9", 0x2000, 0x2000, CRC(451f92f9) SHA1(f4196e6d3420983b74001303936d086a48b10827) ) - ROM_REGION( 0x0800, "mcu", 0 ) /* 2k for the microcontroller */ + ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ ROM_LOAD( "a45.mcu", 0x0000, 0x0800, CRC(5378253c) SHA1(e1ae1ab01e470b896c1d74ad4088928602a21a1b) ) ROM_REGION( 0x20000, "gfx1", ROMREGION_INVERT ) @@ -1367,7 +1333,7 @@ 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, "cpu2", 0 ) /* 2k for the microcontroller */ + 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 ) @@ -1394,7 +1360,7 @@ 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, "cpu2", 0 ) /* 2k for the microcontroller */ + 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 ) @@ -1509,7 +1475,7 @@ ROM_START( victnine ) ROM_LOAD( "a16-16.38", 0x8000, 0x2000, CRC(9395351b) SHA1(8f97bdf03dec47bcaaa62fb66c545566776116be) ) ROM_LOAD( "a16-17.39", 0xa000, 0x2000, CRC(872270b3) SHA1(2298cb8ced6c3e9afb430faab1b38ba8f2fa93b5) ) - ROM_REGION( 0x0800, "cpu2", 0 ) /* 2k for the microcontroller */ + ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ ROM_LOAD( "a16-18.mcu", 0x0000, 0x0800, NO_DUMP ) ROM_REGION( 0x10000, "gfx1", ROMREGION_INVERT ) @@ -1578,7 +1544,7 @@ ROM_START( rumba ) ROM_LOAD( "a23_09.bin", 0x2000, 0x2000, CRC(d0a101d3) SHA1(c92bb1ce67bec394fd8ce303d9e61eac12493b5d) ) ROM_LOAD( "a23_10.bin", 0x4000, 0x2000, CRC(f9447bd4) SHA1(68c02249ca0e5b923cddb4bff8d090963b9c78e4) ) - ROM_REGION( 0x0800, "mcu", 0 ) /* 2k for the microcontroller */ + ROM_REGION( 0x0800, "bmcu:mcu", 0 ) /* 2k for the microcontroller */ ROM_LOAD( "a23-11.mc68705p5s", 0x0000, 0x0800, NO_DUMP ) ROM_REGION( 0x8000, "gfx1", ROMREGION_INVERT ) |