Skip to content

Commit cc43097

Browse files
committed
fix hid re-definition with blehid
1 parent c13027e commit cc43097

File tree

3 files changed

+10
-452
lines changed

3 files changed

+10
-452
lines changed

libraries/Bluefruit52Lib/src/services/BLEHidAdafruit.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,8 @@ bool BLEHidAdafruit::keyPress(uint16_t conn_hdl, char ch)
267267
hid_keyboard_report_t report;
268268
varclr(&report);
269269

270-
report.modifier = ( HID_ASCII_TO_KEYCODE[(uint8_t)ch].shift ) ? KEYBOARD_MODIFIER_LEFTSHIFT : 0;
271-
report.keycode[0] = HID_ASCII_TO_KEYCODE[(uint8_t)ch].keycode;
270+
report.modifier = ( hid_ascii_to_keycode[(uint8_t)ch].shift ) ? KEYBOARD_MODIFIER_LEFTSHIFT : 0;
271+
report.keycode[0] = hid_ascii_to_keycode[(uint8_t)ch].keycode;
272272

273273
return keyboardReport(conn_hdl, &report);
274274
}
@@ -345,7 +345,7 @@ bool BLEHidAdafruit::mouseReport(uint16_t conn_hdl, uint8_t buttons, int8_t x, i
345345
.x = x,
346346
.y = y,
347347
.wheel = wheel,
348-
.pan = pan
348+
// .pan = pan
349349
};
350350

351351
_mse_buttons = buttons;

libraries/Bluefruit52Lib/src/services/BLEHidGeneric.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ bool BLEHidGeneric::bootMouseReport(void const* data, int len)
286286
/*------------------------------------------------------------------*/
287287
/* Ascii to Keycode
288288
*------------------------------------------------------------------*/
289-
const hid_ascii_to_keycode_entry_t HID_ASCII_TO_KEYCODE[128] =
289+
const hid_ascii_to_keycode_entry_t hid_ascii_to_keycode[128] =
290290
{
291291
{0, 0 }, // 0x00 Null
292292
{0, 0 }, // 0x01
@@ -424,7 +424,7 @@ const hid_ascii_to_keycode_entry_t HID_ASCII_TO_KEYCODE[128] =
424424
/*------------------------------------------------------------------*/
425425
/* Keycode to Ascii
426426
*------------------------------------------------------------------*/
427-
const hid_keycode_to_ascii_t HID_KEYCODE_TO_ASCII[128] =
427+
const hid_keycode_to_ascii_t hid_keycode_to_ascii[128] =
428428
{
429429
{0 , 0 }, // 0x00
430430
{0 , 0 }, // 0x01

0 commit comments

Comments
 (0)