apple3: disable the VIAs in Apple II mode. [Paul Hagstrom, R. Belmont]

This commit is contained in:
arbee 2021-07-18 19:50:33 -04:00
parent 51888262b7
commit 3509215e4e

View File

@ -633,6 +633,7 @@ void apple3_state::apple3_via_0_out_b(uint8_t data)
void apple3_state::apple3_via_1_out_a(uint8_t data)
{
printf("via 1 out: A2 mode %02x\n", data & 0x40);
apple3_via_out(&m_via_1_a, data);
}
@ -901,11 +902,11 @@ uint8_t apple3_state::apple3_memory_r(offs_t offset)
{
rv = m_bank7wr[offset - 0xf000];
}
else if (offset >= 0xffd0 && offset <= 0xffdf)
else if ((offset >= 0xffd0 && offset <= 0xffdf) && (m_via_1_a & 0x40))
{
rv = m_via[0]->read(offset);
}
else if (offset >= 0xffe0 && offset <= 0xffef)
else if ((offset >= 0xffe0 && offset <= 0xffef) && (m_via_1_a & 0x40))
{
rv = m_via[1]->read(offset);
}
@ -1059,14 +1060,14 @@ void apple3_state::apple3_memory_w(offs_t offset, uint8_t data)
m_bank7wr[offset - 0xf000] = data;
}
}
else if (offset >= 0xffd0 && offset <= 0xffdf)
else if ((offset >= 0xffd0 && offset <= 0xffdf) && (m_via_1_a & 0x40))
{
if (!machine().side_effects_disabled())
{
m_via[0]->write(offset, data);
}
}
else if (offset >= 0xffe0 && offset <= 0xffef)
else if ((offset >= 0xffe0 && offset <= 0xffef) && (m_via_1_a & 0x40))
{
if (!machine().side_effects_disabled())
{