diff options
author | 2021-06-21 13:53:49 -0700 | |
---|---|---|
committer | 2021-06-21 13:53:49 -0700 | |
commit | 32dbba7d2d4513774b2d877b4c88f2d0760bcf54 (patch) | |
tree | f9e6426cf8dc28413c456bdbcd450c85cb302422 /src/devices/sound/c140.cpp | |
parent | 5522729235b3ce81c839f3932c1aadc14de59e2b (diff) | |
parent | 2709c0143a8c7009715242c135b28403eeffce8b (diff) |
Merge branch 'master' into deprecateddeprecated
Diffstat (limited to 'src/devices/sound/c140.cpp')
-rw-r--r-- | src/devices/sound/c140.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/devices/sound/c140.cpp b/src/devices/sound/c140.cpp index c6e5a05271e..b04a35a0f31 100644 --- a/src/devices/sound/c140.cpp +++ b/src/devices/sound/c140.cpp @@ -478,8 +478,10 @@ inline u8 c140_device::keyon_status_read(u16 offset) u8 c140_device::c140_r(offs_t offset) { offset &= 0x1ff; - if ((offset & 0xf) == 0x5) + + if ((offset & 0xf) == 0x5 && offset < 0x180) return keyon_status_read(offset); + return m_REG[offset]; } @@ -552,9 +554,14 @@ void c140_device::c140_w(offs_t offset, u8 data) u8 c219_device::c219_r(offs_t offset) { + offset &= 0x1ff; + // assume same as c140 // TODO: what happens here on reading unmapped voice regs? - return c140_r(offset); + if ((offset & 0xf) == 0x5 && offset < 0x100) + return keyon_status_read(offset); + + return m_REG[offset]; } |