summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/interact.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/interact.cpp')
-rw-r--r--src/mame/drivers/interact.cpp80
1 files changed, 41 insertions, 39 deletions
diff --git a/src/mame/drivers/interact.cpp b/src/mame/drivers/interact.cpp
index 7733f480b04..9a199c37d5d 100644
--- a/src/mame/drivers/interact.cpp
+++ b/src/mame/drivers/interact.cpp
@@ -127,75 +127,77 @@ uint32_t interact_state::screen_update_interact(screen_device &screen, bitmap_in
return 0;
}
-void interact_state::interact(machine_config &config)
-{
+MACHINE_CONFIG_START(interact_state::interact)
+
/* basic machine hardware */
- I8080(config, m_maincpu, XTAL(2'000'000));
- m_maincpu->set_addrmap(AS_PROGRAM, &interact_state::interact_mem);
- m_maincpu->set_periodic_int(FUNC(interact_state::irq0_line_hold), attotime::from_hz(50)); /* put on the I8080 irq in Hz*/
+ MCFG_DEVICE_ADD("maincpu", I8080, XTAL(2'000'000))
+ MCFG_DEVICE_PROGRAM_MAP(interact_mem)
+ MCFG_DEVICE_PERIODIC_INT_DRIVER(interact_state, irq0_line_hold, 50) /* put on the I8080 irq in Hz*/
MCFG_MACHINE_RESET_OVERRIDE(interact_state,interact)
MCFG_MACHINE_START_OVERRIDE(interact_state,interact)
/* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(60);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
- screen.set_size(256, 79);
- screen.set_visarea(0, 112, 0, 77);
- screen.set_screen_update(FUNC(interact_state::screen_update_interact));
- screen.set_palette(m_palette);
+ MCFG_SCREEN_ADD("screen", RASTER)
+ MCFG_SCREEN_REFRESH_RATE(60)
+ MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */
+ MCFG_SCREEN_SIZE(256, 79)
+ MCFG_SCREEN_VISIBLE_AREA(0, 112, 0, 77)
+ MCFG_SCREEN_UPDATE_DRIVER(interact_state, screen_update_interact)
+ MCFG_SCREEN_PALETTE("palette")
- PALETTE(config, m_palette).set_entries(16); /* 8 colours, but only 4 at a time*/
+ MCFG_PALETTE_ADD("palette", 16) /* 8 colours, but only 4 at a time*/
MCFG_VIDEO_START_OVERRIDE(interact_state,hec2hrp)
hector_audio(config);
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_STOPPED | CASSETTE_MASK_SPEAKER);
- m_cassette->set_interface("interact_cass");
+ MCFG_CASSETTE_ADD("cassette")
+ MCFG_CASSETTE_FORMATS(hector_cassette_formats)
+ MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_MASK_SPEAKER)
+ MCFG_CASSETTE_INTERFACE("interact_cass")
- SOFTWARE_LIST(config, "cass_list").set_original("interact");
+ MCFG_SOFTWARE_LIST_ADD("cass_list","interact")
/* printer */
- PRINTER(config, m_printer, 0);
-}
+ MCFG_DEVICE_ADD("printer", PRINTER, 0)
+
+MACHINE_CONFIG_END
+
+MACHINE_CONFIG_START(interact_state::hector1)
-void interact_state::hector1(machine_config &config)
-{
/* basic machine hardware */
- Z80(config, m_maincpu, XTAL(1'750'000));
- m_maincpu->set_addrmap(AS_PROGRAM, &interact_state::interact_mem);
- m_maincpu->set_periodic_int(FUNC(interact_state::irq0_line_hold), attotime::from_hz(50)); /* put on the I8080 irq in Hz*/
+ MCFG_DEVICE_ADD("maincpu", Z80, XTAL(1'750'000))
+ MCFG_DEVICE_PROGRAM_MAP(interact_mem)
+ MCFG_DEVICE_PERIODIC_INT_DRIVER(interact_state, irq0_line_hold, 50) /* put on the I8080 irq in Hz*/
MCFG_MACHINE_RESET_OVERRIDE(interact_state,interact)
MCFG_MACHINE_START_OVERRIDE(interact_state,interact)
/* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(60);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
- screen.set_size(256, 79);
- screen.set_visarea(0, 112, 0, 77);
- screen.set_screen_update(FUNC(interact_state::screen_update_interact));
- screen.set_palette(m_palette);
+ MCFG_SCREEN_ADD("screen", RASTER)
+ MCFG_SCREEN_REFRESH_RATE(60)
+ MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */
+ MCFG_SCREEN_SIZE(256, 79)
+ MCFG_SCREEN_VISIBLE_AREA(0, 112, 0, 77)
+ MCFG_SCREEN_UPDATE_DRIVER(interact_state, screen_update_interact)
+ MCFG_SCREEN_PALETTE("palette")
- PALETTE(config, m_palette).set_entries(16); /* 8 colours, but only 4 at a time*/
+ MCFG_PALETTE_ADD("palette", 16) /* 8 colours, but only 4 at a time*/
MCFG_VIDEO_START_OVERRIDE(interact_state,hec2hrp)
hector_audio(config);
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_STOPPED | CASSETTE_MASK_SPEAKER);
- m_cassette->set_interface("interact_cass");
+ MCFG_CASSETTE_ADD("cassette")
+ MCFG_CASSETTE_FORMATS(hector_cassette_formats)
+ MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_MASK_SPEAKER)
+ MCFG_CASSETTE_INTERFACE("interact_cass")
/* printer */
- PRINTER(config, m_printer, 0);
-}
+ MCFG_DEVICE_ADD("printer", PRINTER, 0)
+
+MACHINE_CONFIG_END
/* Input ports */
static INPUT_PORTS_START( interact )