diff options
Diffstat (limited to 'src/mame/drivers/limenko.cpp')
-rw-r--r-- | src/mame/drivers/limenko.cpp | 94 |
1 files changed, 47 insertions, 47 deletions
diff --git a/src/mame/drivers/limenko.cpp b/src/mame/drivers/limenko.cpp index 9ec24d9ff16..446ab848b66 100644 --- a/src/mame/drivers/limenko.cpp +++ b/src/mame/drivers/limenko.cpp @@ -704,27 +704,27 @@ GFXDECODE_END MACHINE DRIVERS *****************************************************************************************************/ - -MACHINE_CONFIG_START(limenko_state::limenko) - MCFG_DEVICE_ADD("maincpu", E132XN, 20000000*4) /* 4x internal multiplier */ - MCFG_DEVICE_PROGRAM_MAP(limenko_map) - MCFG_DEVICE_IO_MAP(limenko_io_map) - MCFG_DEVICE_VBLANK_INT_DRIVER("screen", limenko_state, irq0_line_hold) +void limenko_state::limenko(machine_config &config) +{ + E132XN(config, m_maincpu, 20000000*4); /* 4x internal multiplier */ + m_maincpu->set_addrmap(AS_PROGRAM, &limenko_state::limenko_map); + m_maincpu->set_addrmap(AS_IO, &limenko_state::limenko_io_map); + m_maincpu->set_vblank_int("screen", FUNC(limenko_state::irq0_line_hold)); EEPROM_93C46_16BIT(config, "eeprom"); /* video hardware */ - MCFG_SCREEN_ADD("screen", RASTER) - MCFG_SCREEN_REFRESH_RATE(60) - MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) - MCFG_SCREEN_SIZE(384, 240) - MCFG_SCREEN_VISIBLE_AREA(0, 383, 0, 239) - MCFG_SCREEN_UPDATE_DRIVER(limenko_state, screen_update_limenko) - MCFG_SCREEN_PALETTE("palette") - - MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_limenko) - MCFG_PALETTE_ADD("palette", 0x1000) - MCFG_PALETTE_FORMAT(xBBBBBGGGGGRRRRR) + screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); + screen.set_refresh_hz(60); + screen.set_vblank_time(ATTOSECONDS_IN_USEC(0)); + screen.set_size(384, 240); + screen.set_visarea(0, 383, 0, 239); + screen.set_screen_update(FUNC(limenko_state::screen_update_limenko)); + screen.set_palette(m_palette); + + GFXDECODE(config, m_gfxdecode, m_palette, gfx_limenko); + PALETTE(config, m_palette, 0x1000); + m_palette->set_format(PALETTE_FORMAT_xBBBBBGGGGGRRRRR); /* sound hardware */ SPEAKER(config, "lspeaker").front_left(); @@ -734,21 +734,22 @@ MACHINE_CONFIG_START(limenko_state::limenko) m_soundlatch->data_pending_callback().set("qs1000", FUNC(qs1000_device::set_irq)); m_soundlatch->set_separate_acknowledge(true); - MCFG_DEVICE_ADD("qs1000", QS1000, XTAL(24'000'000)) - MCFG_QS1000_EXTERNAL_ROM(true) - MCFG_QS1000_IN_P1_CB(READ8("soundlatch", generic_latch_8_device, read)) - MCFG_QS1000_OUT_P1_CB(WRITE8(*this, limenko_state, qs1000_p1_w)) - MCFG_QS1000_OUT_P2_CB(WRITE8(*this, limenko_state, qs1000_p2_w)) - MCFG_QS1000_OUT_P3_CB(WRITE8(*this, limenko_state, qs1000_p3_w)) - MCFG_SOUND_ROUTE(0, "lspeaker", 1.0) - MCFG_SOUND_ROUTE(1, "rspeaker", 1.0) -MACHINE_CONFIG_END - -MACHINE_CONFIG_START(limenko_state::spotty) - MCFG_DEVICE_ADD("maincpu", GMS30C2232, 20000000) /* 20 MHz, no internal multiplier */ - MCFG_DEVICE_PROGRAM_MAP(spotty_map) - MCFG_DEVICE_IO_MAP(spotty_io_map) - MCFG_DEVICE_VBLANK_INT_DRIVER("screen", limenko_state, irq0_line_hold) + qs1000_device &qs1000(QS1000(config, "qs1000", XTAL(24'000'000))); + qs1000.set_external_rom(true); + qs1000.p1_in().set("soundlatch", FUNC(generic_latch_8_device::read)); + qs1000.p1_out().set(FUNC(limenko_state::qs1000_p1_w)); + qs1000.p2_out().set(FUNC(limenko_state::qs1000_p2_w)); + qs1000.p3_out().set(FUNC(limenko_state::qs1000_p3_w)); + qs1000.add_route(0, "lspeaker", 1.0); + qs1000.add_route(1, "rspeaker", 1.0); +} + +void limenko_state::spotty(machine_config &config) +{ + GMS30C2232(config, m_maincpu, 20000000); /* 20 MHz, no internal multiplier */ + m_maincpu->set_addrmap(AS_PROGRAM, &limenko_state::spotty_map); + m_maincpu->set_addrmap(AS_IO, &limenko_state::spotty_io_map); + m_maincpu->set_vblank_int("screen", FUNC(limenko_state::irq0_line_hold)); at89c4051_device &audiocpu(AT89C4051(config, "audiocpu", 4000000)); /* 4 MHz */ audiocpu.port_in_cb<1>().set(FUNC(limenko_state::spotty_sound_r)); @@ -759,27 +760,26 @@ MACHINE_CONFIG_START(limenko_state::spotty) EEPROM_93C46_16BIT(config, "eeprom"); /* video hardware */ - MCFG_SCREEN_ADD("screen", RASTER) - MCFG_SCREEN_REFRESH_RATE(60) - MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) - MCFG_SCREEN_SIZE(384, 240) - MCFG_SCREEN_VISIBLE_AREA(0, 383, 0, 239) - MCFG_SCREEN_UPDATE_DRIVER(limenko_state, screen_update_limenko) - MCFG_SCREEN_PALETTE("palette") - - MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_limenko) - MCFG_PALETTE_ADD("palette", 0x1000) - MCFG_PALETTE_FORMAT(xBBBBBGGGGGRRRRR) - + screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); + screen.set_refresh_hz(60); + screen.set_vblank_time(ATTOSECONDS_IN_USEC(0)); + screen.set_size(384, 240); + screen.set_visarea(0, 383, 0, 239); + screen.set_screen_update(FUNC(limenko_state::screen_update_limenko)); + screen.set_palette(m_palette); + + GFXDECODE(config, m_gfxdecode, m_palette, gfx_limenko); + PALETTE(config, m_palette, 0x1000); + m_palette->set_format(PALETTE_FORMAT_xBBBBBGGGGGRRRRR); /* sound hardware */ SPEAKER(config, "mono").front_center(); GENERIC_LATCH_8(config, m_soundlatch); - MCFG_DEVICE_ADD("oki", OKIM6295, 4000000 / 4 , okim6295_device::PIN7_HIGH) //? - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) -MACHINE_CONFIG_END + OKIM6295(config, m_oki, 4000000 / 4 , okim6295_device::PIN7_HIGH); //? + m_oki->add_route(ALL_OUTPUTS, "mono", 1.0); +} /***************************************************************************************************** |