diff --git a/CHANGES b/CHANGES index 6661f12bc..8095d4625 100644 --- a/CHANGES +++ b/CHANGES @@ -10,6 +10,7 @@ Bugfixes: - LR35902: Fix events running with the wrong cycle active - GB Video: Clear screen when LCDC is off - GBA Cheats: Fix key-activated CodeBreaker cheats + - GB SIO: Don't auto-clock external shift clock Misc: - All: Only update version info if needed - FFmpeg: Encoding cleanup diff --git a/src/gb/sio.c b/src/gb/sio.c index 7e114b2e9..035b3a42e 100644 --- a/src/gb/sio.c +++ b/src/gb/sio.c @@ -46,7 +46,9 @@ int32_t GBSIOProcessEvents(struct GBSIO* sio, int32_t cycles) { void GBSIOWriteSC(struct GBSIO* sio, uint8_t sc) { sio->period = 0x1000; // TODO Shift Clock if (GBRegisterSCIsEnable(sc)) { - sio->nextEvent = sio->p->cpu->cycles + sio->period; + if (GBRegisterSCIsShiftClock(sc)) { + sio->nextEvent = sio->p->cpu->cycles + sio->period; + } sio->remainingBits = 8; } }