diff options
author | 2019-03-25 23:13:40 +0100 | |
---|---|---|
committer | 2019-03-25 23:13:40 +0100 | |
commit | b380514764cf857469bae61c11143a19f79a74c5 (patch) | |
tree | 63c8012e262618f08a332da31dd714281aa2c5ed /src/devices/bus/spectrum/uspeech.cpp | |
parent | c24473ddff715ecec2e258a6eb38960cf8c8e98e (diff) |
Revert "conflict resolution (nw)"
This reverts commit c24473ddff715ecec2e258a6eb38960cf8c8e98e, reversing
changes made to 009cba4fb8102102168ef32870892438327f3705.
Diffstat (limited to 'src/devices/bus/spectrum/uspeech.cpp')
-rw-r--r-- | src/devices/bus/spectrum/uspeech.cpp | 40 |
1 files changed, 13 insertions, 27 deletions
diff --git a/src/devices/bus/spectrum/uspeech.cpp b/src/devices/bus/spectrum/uspeech.cpp index 60374fd3c2c..87f66ca0182 100644 --- a/src/devices/bus/spectrum/uspeech.cpp +++ b/src/devices/bus/spectrum/uspeech.cpp @@ -76,7 +76,6 @@ spectrum_uspeech_device::spectrum_uspeech_device(const machine_config &mconfig, void spectrum_uspeech_device::device_start() { - save_item(NAME(m_romcs)); } @@ -99,59 +98,46 @@ READ_LINE_MEMBER(spectrum_uspeech_device::romcs) return m_romcs; } -void spectrum_uspeech_device::opcode_fetch(offs_t offset) -{ - if (!machine().side_effects_disabled() && (offset == 0x0038)) - { - m_romcs = !m_romcs; - } -} -uint8_t spectrum_uspeech_device::iorq_r(offs_t offset) +READ8_MEMBER(spectrum_uspeech_device::mreq_r) { - if (!machine().side_effects_disabled() && (offset == 0x0038)) + uint8_t data; + + if (!machine().side_effects_disabled() && (offset == 0x38)) { m_romcs = !m_romcs; } - return 0xff; -} - -uint8_t spectrum_uspeech_device::mreq_r(offs_t offset) -{ - uint8_t data = 0xff; - - switch (offset & 0xf000) + switch (offset) { - case 0x0000: - data = m_rom->base()[offset & 0x7ff]; - break; case 0x1000: - data = !m_nsp->lrq_r(); + data = !m_nsp->lrq_r(); // (m_nsp->lrq_r() && (m_nsp->sby_r() != 0)) ? 0x00 : 0x01; + break; + default: + data = m_rom->base()[offset & 0x7ff]; break; } return data; } -void spectrum_uspeech_device::mreq_w(offs_t offset, uint8_t data) +WRITE8_MEMBER(spectrum_uspeech_device::mreq_w) { - switch (offset & 0xf001) + switch (offset) { case 0x1000: - case 0x1001: // allophone m_nsp->ald_w(data & 0x3f); break; case 0x3000: // intonation low - m_nsp->set_clock(3050000); // oscillator frequency read from hardware + m_nsp->set_clock(3500000); // CK / 4 ?? break; case 0x3001: // intonation high - m_nsp->set_clock(3260000); // oscillator frequency read from hardware + m_nsp->set_clock(3800000); // TODO: the exact frequency is unknown break; } } |