From a74ff88d247559b25c8cb672e871dc1c18a0cb44 Mon Sep 17 00:00:00 2001 From: Michael Zapf Date: Mon, 30 Dec 2024 16:27:17 +0100 Subject: tms52xx: Do not treat write accesses during SPEAK execution as NOP, but delay them. --- src/devices/sound/tms5220.cpp | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/src/devices/sound/tms5220.cpp b/src/devices/sound/tms5220.cpp index dd02cf8d714..273e368ce3c 100644 --- a/src/devices/sound/tms5220.cpp +++ b/src/devices/sound/tms5220.cpp @@ -1728,15 +1728,24 @@ TIMER_CALLBACK_MEMBER(tms5220_device::set_io_ready) { LOGMASKED(LOG_IO_READY, "m_timer_io_ready: in SPKEXT and FIFO was full! cannot service write now, delaying 16 cycles...\n"); m_timer_io_ready->adjust(clocks_to_attotime(16), 1); - break; } else { - LOGMASKED(LOG_IO_READY, "m_timer_io_ready: Serviced write: %02x\n", m_write_latch); - data_write(m_write_latch); - m_io_ready = param; - break; + // MZ: Tests with a real TI Speech Synthesizer seem to prove + // that during SPEAK, writes are not serviced either. + if (talk_status()) + { + LOGMASKED(LOG_IO_READY, "m_timer_io_ready: Speech generation is active! Cannot service write now, delaying 16 cycles...\n"); + m_timer_io_ready->adjust(clocks_to_attotime(16), 1); + } + else + { + LOGMASKED(LOG_IO_READY, "m_timer_io_ready: Serviced write: %02x\n", m_write_latch); + data_write(m_write_latch); + m_io_ready = param; + } } + break; case 0x01: /* Read */ m_read_latch = status_read(true); -- cgit v1.2.3