From e63341babb3ee30fdd4ea056fa87eb58b9d7fb31 Mon Sep 17 00:00:00 2001 From: Gergely Nagy Date: Wed, 21 Nov 2018 07:12:40 +0100 Subject: [PATCH] hardware/ErgoDox: Report the current keyboard state every cycle Instead of only reporting the state when the timer triggers, report it every loop, even if it is unchanged. This is based on a similar change to `ATMegaKeyboard`. Signed-off-by: Gergely Nagy --- src/kaleidoscope/hardware/ez/ErgoDox.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/kaleidoscope/hardware/ez/ErgoDox.cpp b/src/kaleidoscope/hardware/ez/ErgoDox.cpp index 92ee98b9..088be547 100644 --- a/src/kaleidoscope/hardware/ez/ErgoDox.cpp +++ b/src/kaleidoscope/hardware/ez/ErgoDox.cpp @@ -120,10 +120,13 @@ void ErgoDox::actOnMatrixScan() { } void ErgoDox::scanMatrix() { - if (!do_scan_) - return; + if (do_scan_) { + do_scan_ = false; + // We only want to update our matrix if the timer has expired. + readMatrix(); + } - readMatrix(); + // We ALWAYS want to tell Kaleidoscope about the state of the matrix actOnMatrixScan(); }