1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-11-26 08:49:37 +00:00

Fix Disk II sense-write-protect clocking preference

Ensure we're actually in the sense-write-protect loop before deciding
that we don't need to process anymore.

Closes #1218
This commit is contained in:
Ryan Carsten Schmidt 2023-12-04 09:19:52 -06:00
parent ab608178f3
commit b91a791e01

View File

@ -164,7 +164,7 @@ void DiskII::decide_clocking_preference() {
// If in sense-write-protect mode, clocking is just-in-time if the shift register hasn't yet filled with the value that // If in sense-write-protect mode, clocking is just-in-time if the shift register hasn't yet filled with the value that
// corresponds to the current write protect status. Otherwise it is none. // corresponds to the current write protect status. Otherwise it is none.
if((inputs_ & ~input_flux) == input_command) { if((inputs_ & ~input_flux) == input_command) {
clocking_preference_ = (shift_register_ == (is_write_protected() ? 0xff : 0x00)) ? ClockingHint::Preference::None : ClockingHint::Preference::JustInTime; clocking_preference_ = ((shift_register_ == (is_write_protected() ? 0xff : 0x00)) && ((state_ & 0xf) == 0xa || (state_ & 0xf) == 0xe)) ? ClockingHint::Preference::None : ClockingHint::Preference::JustInTime;
} }
// Announce a change if there was one. // Announce a change if there was one.