stardot / b-em

An opensource BBC Micro emulator for Win32 and Linux
http://stardot.org.uk/forums/viewtopic.php?f=4&t=10823
GNU General Public License v2.0
112 stars 57 forks source link

Reads from FE3C will access system VIA on non-Integra machines #154

Closed ZornsLemma closed 3 years ago

ZornsLemma commented 3 years ago

I don't think this is likely to cause big problems, but I'm not sure it's right. 6502.c has:

        case 0xFE3C:
            if (integra)
                return cmos_read_data_integra();

        case 0xFE40:
        case 0xFE44:
        case 0xFE48:
        case 0xFE4C:
        case 0xFE50:
        case 0xFE54:
        case 0xFE58:
        case 0xFE5C:
                return sysvia_read((uint16_t)addr);

There's no "break;" after the "if (integra)" so the code will fall through to the system VIA case.

SteveFosdick commented 3 years ago

I think you're right. I have added the break in https://github.com/stardot/b-em/commit/e5adcafef6ac60137fd1d98bcc44974440a2e238

ZornsLemma commented 3 years ago

Great, thanks!