From 96e722ed77f7359da537e8dce8cadceb9f7108d9 Mon Sep 17 00:00:00 2001 From: tmk Date: Wed, 27 Oct 2021 00:34:34 +0900 Subject: [PATCH] ibmpc: Return host_send when receiving - To avoid missing key stroke during command sending - LED lock indicators can be out of sync due to this --- tmk_core/protocol/ibmpc.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tmk_core/protocol/ibmpc.cpp b/tmk_core/protocol/ibmpc.cpp index 71e4fd86..95f69e17 100644 --- a/tmk_core/protocol/ibmpc.cpp +++ b/tmk_core/protocol/ibmpc.cpp @@ -92,6 +92,13 @@ int16_t IBMPC::host_send(uint8_t data) dprintf("w%02X ", data); + // Return when receiving data + //if (isr_state & 0x0FFF) { + if (isr_state != 0x8000) { + dprintf("isr:%04X ", isr_state); + return -1; + } + int_off(); RETRY: