aboutsummaryrefslogtreecommitdiffstats
path: root/protocol/pjrc
diff options
context:
space:
mode:
Diffstat (limited to 'protocol/pjrc')
-rw-r--r--protocol/pjrc/usb.c3
-rw-r--r--protocol/pjrc/usb_keyboard.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/protocol/pjrc/usb.c b/protocol/pjrc/usb.c
index b09ad3f23..2b267d480 100644
--- a/protocol/pjrc/usb.c
+++ b/protocol/pjrc/usb.c
@@ -930,6 +930,9 @@ ISR(USB_COM_vect)
}
if (bRequest == HID_SET_PROTOCOL) {
keyboard_protocol = wValue;
+#ifdef NKRO_ENABLE
+ keyboard_nkro = !!keyboard_protocol;
+#endif
clear_keyboard();
//usb_wait_in_ready();
usb_send_in();
diff --git a/protocol/pjrc/usb_keyboard.c b/protocol/pjrc/usb_keyboard.c
index c11995db6..d16833187 100644
--- a/protocol/pjrc/usb_keyboard.c
+++ b/protocol/pjrc/usb_keyboard.c
@@ -56,7 +56,7 @@ int8_t usb_keyboard_send_report(report_keyboard_t *report)
int8_t result = 0;
#ifdef NKRO_ENABLE
- if (keyboard_nkro && keyboard_protocol)
+ if (keyboard_nkro)
result = send_report(report, KBD2_ENDPOINT, 0, KBD2_SIZE);
else
#endif