From 7d32bde074ae8198d2521a176cd084314138f9f8 Mon Sep 17 00:00:00 2001 From: gm-matthew <108370479+gm-matthew@users.noreply.github.com> Date: Wed, 22 May 2024 22:31:02 +0100 Subject: [PATCH] When disabling sound IRQs via MIDI control port, clear current IRQ Prevents Dirt Devils hanging during boot --- Src/Model3/Model3.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Src/Model3/Model3.cpp b/Src/Model3/Model3.cpp index 8d71692..86fb83a 100644 --- a/Src/Model3/Model3.cpp +++ b/Src/Model3/Model3.cpp @@ -1423,8 +1423,12 @@ void CModel3::Write8(UINT32 addr, UINT8 data) SoundBoard.WriteMIDIPort(data); IRQ.Deassert(0x40); } - else if ((addr&0xF) == 4) // MIDI control port + else if ((addr & 0xF) == 4) // MIDI control port + { midiCtrlPort = data; + if ((data & 0x20) == 0) + IRQ.Deassert(0x40); + } break; // Backup RAM