From 3968207f0211ee40bf84fe0bc037424271158930 Mon Sep 17 00:00:00 2001 From: Pieterv24 <9167905+Pieterv24@users.noreply.github.com> Date: Thu, 22 Apr 2021 22:00:50 +0200 Subject: [PATCH] Reintroduced matrix tester, but it's disabled by default and requires unlock --- quantum/via.c | 5 +++-- quantum/vial.h | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/quantum/via.c b/quantum/via.c index b7e6c9523324..03e11fbb3d6c 100644 --- a/quantum/via.c +++ b/quantum/via.c @@ -256,8 +256,9 @@ void raw_hid_receive(uint8_t *data, uint8_t length) { } case id_switch_matrix_state: { #ifdef VIAL_ENABLE - /* We don't need this wannabe keylogger */ - goto skip; + /* Disable wannabe keylogger unless unlocked */ + if (!vial_unlocked) + goto skip; #endif #if ((MATRIX_COLS / 8 + 1) * MATRIX_ROWS <= 28) diff --git a/quantum/vial.h b/quantum/vial.h index 3015448ebfce..5f6df86a9080 100644 --- a/quantum/vial.h +++ b/quantum/vial.h @@ -19,7 +19,7 @@ #include #include -#define VIAL_PROTOCOL_VERSION ((uint32_t)0x00000002) +#define VIAL_PROTOCOL_VERSION ((uint32_t)0x00000003) void vial_handle_cmd(uint8_t *data, uint8_t length);