diff options
author | AJR <ajrhacker@users.noreply.github.com> | 2020-03-13 23:16:16 -0400 |
---|---|---|
committer | AJR <ajrhacker@users.noreply.github.com> | 2020-03-13 23:16:20 -0400 |
commit | 475e834cdc393b966ce029676d5c770292baf3f4 (patch) | |
tree | 3afc4b5abb9d36ff5ddab40174f5d5f07b30f114 | |
parent | d1a38e9422ed8c199b7683d3af76fa8860290b36 (diff) |
metro.cpp: Fix loss of sound in games with uPD7810s other than daitorid, pururun & gunmast (nw)
-rw-r--r-- | src/mame/drivers/metro.cpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/mame/drivers/metro.cpp b/src/mame/drivers/metro.cpp index 37acb9c31e3..2ef77b5a178 100644 --- a/src/mame/drivers/metro.cpp +++ b/src/mame/drivers/metro.cpp @@ -314,13 +314,12 @@ WRITE8_MEMBER(metro_state::sound_data_w) { machine().scheduler().synchronize(timer_expired_delegate(FUNC(metro_state::sound_data_sync), this), data); m_audiocpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); // seen rxd_r - m_maincpu->spin_until_interrupt(); - m_busy_sndcpu = 1; } TIMER_CALLBACK_MEMBER(metro_state::sound_data_sync) { m_sound_data = param; + m_busy_sndcpu = 1; } @@ -363,7 +362,7 @@ WRITE8_MEMBER(metro_state::upd7810_portb_w) 6 5 !clock YM2413 I/O 4 !clock MSM6295 I/O - 3 + 3 !enable read from 6295 2 !enable write to YM2413/6295 1 select YM2413 register or data port 0 @@ -394,6 +393,13 @@ WRITE8_MEMBER(metro_state::upd7810_portb_w) m_oki->write(m_porta); } + if (BIT(m_portb, 3) && !BIT(data, 3)) /* clock 1->0 */ + { + /* read */ + if (!BIT(data, 4)) + m_porta = m_oki->read(); + } + m_portb = data; } |