Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bus/spectrum/musicmachine.cpp: confirm port decoding; fix save state #12853

Merged
merged 1 commit into from
Oct 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions src/devices/bus/spectrum/musicmachine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ spectrum_musicmachine_device::spectrum_musicmachine_device(const machine_config

void spectrum_musicmachine_device::device_start()
{
save_item(NAME(m_irq_select));
}

//-------------------------------------------------
Expand All @@ -75,9 +76,9 @@ u8 spectrum_musicmachine_device::iorq_r(offs_t offset)
switch (offset & 0xff)
{
case 0x7f:
if (offset == 0xfc7f)
if ((offset & 0x3ff) == 0x27f)
data = m_acia->status_r();
else
else if ((offset & 0x3ff) == 0x37f)
data = m_acia->data_r();
break;
case 0xbf:
Expand All @@ -99,9 +100,9 @@ void spectrum_musicmachine_device::iorq_w(offs_t offset, u8 data)
m_irq_select = data & 1;
break;
case 0x7f:
if (offset == 0xfc7f)
if ((offset & 0x3ff) == 0x07f)
m_acia->control_w(data);
else
else if ((offset & 0x3ff) == 0x17f)
m_acia->data_w(data);
break;
case 0x9f:
Expand Down
Loading