From d9528f0f263a23ccd594778cbdb908d01d541c26 Mon Sep 17 00:00:00 2001 From: Stephen White Date: Sun, 4 Nov 2018 17:52:00 +1100 Subject: [PATCH] SRQ needed to be inverted. --- src/iec_bus.cpp | 2 +- src/iec_bus.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/iec_bus.cpp b/src/iec_bus.cpp index 3d7627f..4917cbd 100644 --- a/src/iec_bus.cpp +++ b/src/iec_bus.cpp @@ -269,7 +269,7 @@ void IEC_Bus::ReadEmulationMode1581(void) } else { - PI_SRQ = false; + PI_SRQ = true; } Resetting = !ignoreReset && ((gplev0 & PIGPIO_MASK_IN_RESET) == (invertIECInputs ? PIGPIO_MASK_IN_RESET : 0)); diff --git a/src/iec_bus.h b/src/iec_bus.h index f723c6f..87fa7ff 100644 --- a/src/iec_bus.h +++ b/src/iec_bus.h @@ -488,7 +488,7 @@ public: if (ClockSetToOut) set |= 1 << PIGPIO_OUT_CLOCK; else clear |= 1 << PIGPIO_OUT_CLOCK; - if (!SRQSetToOut) set |= 1 << PIGPIO_OUT_SRQ; // fast clock is pulled high but we have an inverter in our hardware so to compensate we invert in software now + if (SRQSetToOut) set |= 1 << PIGPIO_OUT_SRQ; // fast clock is pulled high but we have an inverter in our hardware so to compensate we invert in software now else clear |= 1 << PIGPIO_OUT_SRQ; if (!invertIECOutputs) {