From d0cd7e2eb3eac3f519e29eaf569927f95f1d633c Mon Sep 17 00:00:00 2001 From: Phil Taylor Date: Thu, 2 Feb 2023 16:45:45 +0000 Subject: [PATCH] Use correct data for F1 key --- usbcontroller.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usbcontroller.cpp b/usbcontroller.cpp index 1f50728..367d172 100644 --- a/usbcontroller.cpp +++ b/usbcontroller.cpp @@ -370,7 +370,7 @@ void usbController::runTimer() ledControl(false, 0); emit button(butptt->offCommand); } - else if (butf1 != Q_NULLPTR && ((unsigned char)data[5] == 0x7d) && ((unsigned char)lastData[5] != 0x7d)) + else if (butf1 != Q_NULLPTR && ((unsigned char)data[5] == 0x05) && ((unsigned char)lastData[5] != 0x05)) { // F-1 key up only (no other keys down) //emit button(true, 5); @@ -379,7 +379,7 @@ void usbController::runTimer() ledControl(true, 1); emit button(butf1->onCommand); } - else if (butf1 != Q_NULLPTR && ((unsigned char)data[5] != 0x7d) && ((unsigned char)lastData[5] == 0x7d)) + else if (butf1 != Q_NULLPTR && ((unsigned char)data[5] != 0x05) && ((unsigned char)lastData[5] == 0x05)) { // F-1 key down only (no other keys down) //emit button(false, 5);