GBA Hardware: More RTC fixes

This commit is contained in:
Vicki Pfau 2018-02-04 13:54:49 -08:00
parent 154b447ae6
commit e11227177f
1 changed files with 3 additions and 1 deletions

View File

@ -172,6 +172,8 @@ void _rtcReadPins(struct GBACartridgeHardware* hw) {
case 1: case 1:
if ((hw->pinState & 5) == 5) { if ((hw->pinState & 5) == 5) {
hw->rtc.transferStep = 2; hw->rtc.transferStep = 2;
} else {
hw->rtc.transferStep = 0;
} }
_outputPins(hw, 5); _outputPins(hw, 5);
break; break;
@ -203,7 +205,7 @@ void _rtcReadPins(struct GBACartridgeHardware* hw) {
hw->rtc.bytesRemaining = 0; hw->rtc.bytesRemaining = 0;
hw->rtc.commandActive = 0; hw->rtc.commandActive = 0;
hw->rtc.command = 0; hw->rtc.command = 0;
hw->rtc.transferStep = 0; hw->rtc.transferStep = hw->pinState & 1;
_outputPins(hw, 1); _outputPins(hw, 1);
} }
} }