summaryrefslogtreecommitdiffstats
path: root/src/mame/drivers/shougi.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/shougi.cpp')
-rw-r--r--src/mame/drivers/shougi.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/mame/drivers/shougi.cpp b/src/mame/drivers/shougi.cpp
index 7ff83a5da3a..ae4f0db2e5e 100644
--- a/src/mame/drivers/shougi.cpp
+++ b/src/mame/drivers/shougi.cpp
@@ -92,8 +92,8 @@ PROM : Type MB7051
class shougi_state : public driver_device
{
public:
- shougi_state(const machine_config &mconfig, device_type type, const char *tag)
- : driver_device(mconfig, type, tag),
+ shougi_state(const machine_config &mconfig, device_type type, const char *tag) :
+ driver_device(mconfig, type, tag),
m_maincpu(*this, "maincpu"),
m_subcpu(*this, "sub"),
m_alpha_8201(*this, "alpha_8201"),
@@ -383,13 +383,13 @@ MACHINE_CONFIG_START(shougi_state::shougi)
MCFG_DEVICE_ADD("alpha_8201", ALPHA_8201, XTAL(10'000'000)/4/8)
- MCFG_DEVICE_ADD("mainlatch", LS259, 0)
- MCFG_ADDRESSABLE_LATCH_Q0_OUT_CB(NOOP) // 0: sharedram = sub, 1: sharedram = main (TODO!)
- MCFG_ADDRESSABLE_LATCH_Q1_OUT_CB(WRITELINE(*this, shougi_state, nmi_enable_w))
- MCFG_ADDRESSABLE_LATCH_Q2_OUT_CB(NOOP) // ?
- MCFG_ADDRESSABLE_LATCH_Q3_OUT_CB(WRITELINE("alpha_8201", alpha_8201_device, mcu_start_w)) // start/halt ALPHA-8201
- MCFG_ADDRESSABLE_LATCH_Q4_OUT_CB(WRITELINE("alpha_8201", alpha_8201_device, bus_dir_w)) MCFG_DEVCB_INVERT // ALPHA-8201 shared RAM bus direction: 0: mcu, 1: maincpu
- MCFG_ADDRESSABLE_LATCH_Q7_OUT_CB(NOOP) // nothing? connected to +5v via resistor
+ ls259_device &mainlatch(LS259(config, "mainlatch"));
+ mainlatch.q_out_cb<0>().set_nop(); // 0: sharedram = sub, 1: sharedram = main (TODO!)
+ mainlatch.q_out_cb<1>().set(FUNC(shougi_state::nmi_enable_w));
+ mainlatch.q_out_cb<2>().set_nop(); // ?
+ mainlatch.q_out_cb<3>().set("alpha_8201", FUNC(alpha_8201_device::mcu_start_w)); // start/halt ALPHA-8201
+ mainlatch.q_out_cb<4>().set("alpha_8201", FUNC(alpha_8201_device::bus_dir_w)).invert(); // ALPHA-8201 shared RAM bus direction: 0: mcu, 1: maincpu
+ mainlatch.q_out_cb<7>().set_nop(); // nothing? connected to +5v via resistor
MCFG_QUANTUM_PERFECT_CPU("maincpu")