summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/machine/z80ctc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/machine/z80ctc.cpp')
-rw-r--r--src/devices/machine/z80ctc.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/devices/machine/z80ctc.cpp b/src/devices/machine/z80ctc.cpp
index 735ea85b8e7..1ee73a25b3c 100644
--- a/src/devices/machine/z80ctc.cpp
+++ b/src/devices/machine/z80ctc.cpp
@@ -77,12 +77,17 @@ DEFINE_DEVICE_TYPE(Z80CTC_CHANNEL, z80ctc_channel_device, "z80ctc_channel", "Z80
//-------------------------------------------------
z80ctc_device::z80ctc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
- : device_t(mconfig, Z80CTC, tag, owner, clock)
+ : z80ctc_device(mconfig, Z80CTC, tag, owner, clock)
+{
+}
+
+z80ctc_device::z80ctc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
+ : device_t(mconfig, type, tag, owner, clock)
, device_z80daisy_interface(mconfig, *this)
+ , m_channel(*this, "ch%u", 0U)
, m_intr_cb(*this)
, m_zc_cb(*this)
, m_vector(0)
- , m_channel(*this, "ch%u", 0U)
{
}
@@ -363,7 +368,11 @@ u8 z80ctc_channel_device::read()
if(!m_timer->remaining().is_never())
return u8((m_timer->remaining().as_double() / period.as_double()) + 1.0);
else
- return 0;
+ {
+ // value read-back is required by x1turbo for YM internal board detection.
+ // cfr. x1turbo40 argus wpiset 0x704,1,rw
+ return m_down;
+ }
}
}