summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/polgar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/polgar.cpp')
-rw-r--r--src/mame/drivers/polgar.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/mame/drivers/polgar.cpp b/src/mame/drivers/polgar.cpp
index c0686570977..a935b2a50a8 100644
--- a/src/mame/drivers/polgar.cpp
+++ b/src/mame/drivers/polgar.cpp
@@ -515,14 +515,14 @@ MACHINE_CONFIG_START(mephisto_risc_state::mrisc)
MCFG_NVRAM_ADD_0FILL("nvram")
- MCFG_DEVICE_ADD("outlatch", HC259, 0)
- MCFG_ADDRESSABLE_LATCH_Q0_OUT_CB(OUTPUT("led100"))
- MCFG_ADDRESSABLE_LATCH_Q1_OUT_CB(OUTPUT("led101"))
- MCFG_ADDRESSABLE_LATCH_Q2_OUT_CB(OUTPUT("led102"))
- MCFG_ADDRESSABLE_LATCH_Q3_OUT_CB(OUTPUT("led103"))
- MCFG_ADDRESSABLE_LATCH_Q4_OUT_CB(OUTPUT("led104"))
- MCFG_ADDRESSABLE_LATCH_Q5_OUT_CB(OUTPUT("led105"))
- MCFG_ADDRESSABLE_LATCH_PARALLEL_OUT_CB(MEMBANK("rombank")) MCFG_DEVCB_MASK(0xc0) MCFG_DEVCB_XOR(0x40) MCFG_DEVCB_RSHIFT(-6)
+ hc259_device &outlatch(HC259(config, "outlatch"));
+ outlatch.q_out_cb<0>().set_output("led100");
+ outlatch.q_out_cb<1>().set_output("led101");
+ outlatch.q_out_cb<2>().set_output("led102");
+ outlatch.q_out_cb<3>().set_output("led103");
+ outlatch.q_out_cb<4>().set_output("led104");
+ outlatch.q_out_cb<5>().set_output("led105");
+ outlatch.parallel_out_cb().set_membank("rombank").rshift(6).mask(0x03).exor(0x01);
MCFG_RAM_ADD("ram")
MCFG_RAM_DEFAULT_SIZE("1M")
@@ -548,9 +548,9 @@ MACHINE_CONFIG_START(mephisto_academy_state::academy)
MCFG_DEVICE_MODIFY("maincpu")
MCFG_DEVICE_PROGRAM_MAP(academy_mem)
- MCFG_DEVICE_REPLACE("outlatch", HC259, 0)
- MCFG_ADDRESSABLE_LATCH_Q1_OUT_CB(WRITELINE(*this, mephisto_academy_state, academy_nmi_w))
- MCFG_ADDRESSABLE_LATCH_Q2_OUT_CB(WRITELINE("display:beeper", beep_device, set_state)) MCFG_DEVCB_INVERT
+ hc259_device &outlatch(HC259(config.replace(), "outlatch"));
+ outlatch.q_out_cb<1>().set(FUNC(mephisto_academy_state::academy_nmi_w));
+ outlatch.q_out_cb<2>().set("display:beeper", FUNC(beep_device::set_state)).invert();
MCFG_DEFAULT_LAYOUT(layout_mephisto_academy)
MACHINE_CONFIG_END