diff options
author | Ivan Vangelista <mesgnet@yahoo.it> | 2019-02-08 18:35:41 +0100 |
---|---|---|
committer | Ivan Vangelista <mesgnet@yahoo.it> | 2019-02-08 18:35:41 +0100 |
commit | c9922586a39b1325d470af995f1e8bd9ecce1be9 (patch) | |
tree | 58f3acce93d7fa18e824053f6ae09f776b14eb2f /src/mame/drivers/apple2e.cpp | |
parent | 17cd12e89620152835a0be986822900e4570d43b (diff) |
some more MCFG macros removal (nw)
Diffstat (limited to 'src/mame/drivers/apple2e.cpp')
-rw-r--r-- | src/mame/drivers/apple2e.cpp | 64 |
1 files changed, 36 insertions, 28 deletions
diff --git a/src/mame/drivers/apple2e.cpp b/src/mame/drivers/apple2e.cpp index 24d18f16582..f1422ea17a6 100644 --- a/src/mame/drivers/apple2e.cpp +++ b/src/mame/drivers/apple2e.cpp @@ -3956,7 +3956,8 @@ static void apple2eaux_cards(device_slot_interface &device) device.option_add("rw3", A2EAUX_RAMWORKS3); /* Applied Engineering RamWorks III */ } -MACHINE_CONFIG_START(apple2e_state::apple2e) +void apple2e_state::apple2e(machine_config &config) +{ /* basic machine hardware */ M6502(config, m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &apple2e_state::apple2e_map); @@ -4052,11 +4053,11 @@ MACHINE_CONFIG_START(apple2e_state::apple2e) A2BUS_SLOT(config, "sl6", m_a2bus, apple2_cards, "diskiing"); A2BUS_SLOT(config, "sl7", m_a2bus, apple2_cards, nullptr); - MCFG_DEVICE_ADD(A2_AUXSLOT_TAG, A2EAUXSLOT, 0) - MCFG_A2EAUXSLOT_CPU("maincpu") - MCFG_A2EAUXSLOT_OUT_IRQ_CB(WRITELINE(*this, apple2e_state, a2bus_irq_w)) - MCFG_A2EAUXSLOT_OUT_NMI_CB(WRITELINE(*this, apple2e_state, a2bus_nmi_w)) - MCFG_A2EAUXSLOT_SLOT_ADD(A2_AUXSLOT_TAG, "aux", apple2eaux_cards, "ext80") // default to an extended 80-column card + A2EAUXSLOT(config, m_a2eauxslot, 0); + m_a2eauxslot->set_cputag(m_maincpu); + m_a2eauxslot->out_irq_callback().set(FUNC(apple2e_state::a2bus_irq_w)); + m_a2eauxslot->out_nmi_callback().set(FUNC(apple2e_state::a2bus_nmi_w)); + A2EAUXSLOT_SLOT(config, "aux", apple2eaux_cards, "ext80", A2_AUXSLOT_TAG); /* softlist config for baseline A2E By default, filter lists where possible to compatible disks for A2E */ @@ -4066,8 +4067,7 @@ MACHINE_CONFIG_START(apple2e_state::apple2e) CASSETTE(config, m_cassette); m_cassette->set_default_state(CASSETTE_STOPPED); - -MACHINE_CONFIG_END +} void apple2e_state::mprof3(machine_config &config) { @@ -4076,39 +4076,44 @@ void apple2e_state::mprof3(machine_config &config) m_ram->set_default_size("128K"); } -MACHINE_CONFIG_START(apple2e_state::apple2ee) +void apple2e_state::apple2ee(machine_config &config) +{ apple2e(config); subdevice<software_list_device>("flop525_orig")->set_filter("A2EE"); // Filter list to compatible disks for this machine. M65C02(config.replace(), m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &apple2e_state::apple2e_map); -MACHINE_CONFIG_END +} -MACHINE_CONFIG_START(apple2e_state::spectred) +void apple2e_state::spectred(machine_config &config) +{ apple2e(config); - MCFG_DEVICE_ADD("keyb_mcu", I8035, XTAL(4'000'000)) /* guessed frequency */ - MCFG_DEVICE_PROGRAM_MAP(spectred_keyb_map) + i8035_device &keyb_mcu(I8035(config, "keyb_mcu", XTAL(4'000'000))); /* guessed frequency */ + keyb_mcu.set_addrmap(AS_PROGRAM, &apple2e_state::spectred_keyb_map); //TODO: implement the actual interfacing to this 8035 MCU and // and then remove the keyb CPU inherited from apple2e -MACHINE_CONFIG_END +} -MACHINE_CONFIG_START(apple2e_state::tk3000) +void apple2e_state::tk3000(machine_config &config) +{ apple2e(config); M65C02(config.replace(), m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &apple2e_state::apple2e_map); -// MCFG_DEVICE_ADD("subcpu", Z80, 1021800) // schematics are illegible on where the clock comes from, but it *seems* to be the same as the 65C02 clock -// MCFG_DEVICE_PROGRAM_MAP(tk3000_kbd_map) -MACHINE_CONFIG_END +// z80_device &subcpu(Z80(config, "subcpu", 1021800)); // schematics are illegible on where the clock comes from, but it *seems* to be the same as the 65C02 clock +// subcpu.set_addrmap(AS_PROGRAM, &apple2e_state::tk3000_kbd_map); +} -MACHINE_CONFIG_START(apple2e_state::apple2ep) +void apple2e_state::apple2ep(machine_config &config) +{ apple2e(config); M65C02(config.replace(), m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &apple2e_state::apple2e_map); -MACHINE_CONFIG_END +} -MACHINE_CONFIG_START(apple2e_state::apple2c) +void apple2e_state::apple2c(machine_config &config) +{ apple2ee(config); subdevice<software_list_device>("flop525_orig")->set_filter("A2C"); // Filter list to compatible disks for this machine. @@ -4154,7 +4159,7 @@ MACHINE_CONFIG_START(apple2e_state::apple2c) config.device_remove(A2_AUXSLOT_TAG); m_ram->set_default_size("128K").set_extra_options("128K"); -MACHINE_CONFIG_END +} static void apple2cp_set_lines(device_t *device, uint8_t lines) { @@ -4272,14 +4277,16 @@ MACHINE_CONFIG_START(apple2e_state::apple2cp) m_ram->set_default_size("128K").set_extra_options("128K, 384K, 640K, 896K, 1152K"); MACHINE_CONFIG_END -MACHINE_CONFIG_START(apple2e_state::apple2c_iwm) +void apple2e_state::apple2c_iwm(machine_config &config) +{ apple2c(config); config.device_remove("sl6"); A2BUS_IWM_FDC(config, "sl6", A2BUS_7M_CLOCK).set_onboard(m_a2bus); -MACHINE_CONFIG_END +} -MACHINE_CONFIG_START(apple2e_state::apple2c_mem) +void apple2e_state::apple2c_mem(machine_config &config) +{ apple2c(config); M65C02(config.replace(), m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &apple2e_state::apple2c_memexp_map); @@ -4288,7 +4295,7 @@ MACHINE_CONFIG_START(apple2e_state::apple2c_mem) A2BUS_IWM_FDC(config, "sl6", A2BUS_7M_CLOCK).set_onboard(m_a2bus); m_ram->set_default_size("128K").set_extra_options("128K, 384K, 640K, 896K, 1152K"); -MACHINE_CONFIG_END +} const applefdc_interface fdc_interface = { @@ -4344,7 +4351,8 @@ MACHINE_CONFIG_START(apple2e_state::laser128ex2) m_ram->set_default_size("128K").set_extra_options("128K, 384K, 640K, 896K, 1152K"); MACHINE_CONFIG_END -MACHINE_CONFIG_START(apple2e_state::ceci) +void apple2e_state::ceci(machine_config &config) +{ apple2e(config); config.device_remove("sl1"); config.device_remove("sl2"); @@ -4361,7 +4369,7 @@ MACHINE_CONFIG_START(apple2e_state::ceci) config.device_remove(A2_AUXSLOT_TAG); m_ram->set_default_size("64K"); -MACHINE_CONFIG_END +} /*************************************************************************** |