From ebeb173cb8fe7f3f0572a68be7557d5e621e985d Mon Sep 17 00:00:00 2001 From: Jesse Vincent Date: Tue, 17 Sep 2019 23:56:06 -0700 Subject: [PATCH] Temporarily back out use of KeyAddr in one function in ATMegaKeyboard. The "new" code we've backed out caused all key events to be about key 0,0. I suspect that this is GCC doing something crazy with that one function. I don't understand what's going on. @noseglasses: any idea? --- src/kaleidoscope/hardware/ATMegaKeyboard.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/kaleidoscope/hardware/ATMegaKeyboard.cpp b/src/kaleidoscope/hardware/ATMegaKeyboard.cpp index fe866c44..34ce075b 100644 --- a/src/kaleidoscope/hardware/ATMegaKeyboard.cpp +++ b/src/kaleidoscope/hardware/ATMegaKeyboard.cpp @@ -110,7 +110,8 @@ void __attribute__((optimize(3))) ATMegaKeyboard::actOnMatrixScan() { uint8_t keyState = (bitRead(KeyboardHardware.previousKeyState_[row], col) << 0) | (bitRead(KeyboardHardware.keyState_[row], col) << 1); if (keyState) { - handleKeyswitchEvent(Key_NoKey, KeyAddr(row, col), keyState); + //handleKeyswitchEvent(Key_NoKey, KeyAddr(row, col), keyState); + handleKeyswitchEvent(Key_NoKey, row, col, keyState); } } KeyboardHardware.previousKeyState_[row] = KeyboardHardware.keyState_[row];