File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -222,7 +222,7 @@ size_t USBHIDKeyboard::pressRaw(uint8_t k)
222
222
uint8_t i;
223
223
if (k >= 0xE0 && k < 0xE8 ) {
224
224
// it's a modifier key
225
- _keyReport.modifiers |= (1 <<(k-0x80 ));
225
+ _keyReport.modifiers |= (1 <<(k-0xE0 ));
226
226
} else if (k && k < 0xA5 ) {
227
227
// Add k to the key report only if it's not already present
228
228
// and if there is an empty slot.
@@ -253,7 +253,7 @@ size_t USBHIDKeyboard::releaseRaw(uint8_t k)
253
253
uint8_t i;
254
254
if (k >= 0xE0 && k < 0xE8 ) {
255
255
// it's a modifier key
256
- _keyReport.modifiers &= ~(1 <<(k-0x80 ));
256
+ _keyReport.modifiers &= ~(1 <<(k-0xE0 ));
257
257
} else if (k && k < 0xA5 ) {
258
258
// Test the key report to see if k is present. Clear it if it exists.
259
259
// Check all positions in case the key is present more than once (which it shouldn't be)
You can’t perform that action at this time.
0 commit comments