feat(hid): Configurable NKRO HID report support.

* Add Kconfig settings for NKRO or HKRO (boot compatible), HID
  report types for keyboard page.
* Updated report storage and set/unset for each config.
This commit is contained in:
Pete Johanson
2021-03-15 00:40:09 -04:00
parent 063b496c26
commit 91ba034896
3 changed files with 117 additions and 16 deletions

View File

@@ -25,7 +25,40 @@ config USB_DEVICE_PID
config USB_DEVICE_MANUFACTURER
default "ZMK Project"
menu "HID Output Types"
menu "HID"
choice ZMK_HID_REPORT_TYPE
prompt "HID Report Type"
config ZMK_HID_REPORT_TYPE_HKRO
bool "#-Key Roll Over (HKRO) HID Report"
help
Enable # key roll over for HID report. This selection is "boot keyboard" compatible
but limits the total number of possible keys to report as held to #.
config ZMK_HID_REPORT_TYPE_NKRO
bool "Full N-Key Roll Over (NKRO) HID Report"
help
Enable full N-Key Roll Over for HID output. This selection will prevent the keyboard
from working with some BIOS/UEFI versions that only support "boot keyboard" support.
This option also prevents using some infrequently used higher range HID usages.
endchoice
if ZMK_HID_REPORT_TYPE_HKRO
config ZMK_HID_KEYBOARD_REPORT_SIZE
int "# Keyboard Keys Reportable"
default 6
endif
config ZMK_HID_CONSUMER_REPORT_SIZE
int "# Consumer Keys Reportable"
default 6
menu "Output Types"
config ZMK_USB
bool "USB"
@@ -92,7 +125,10 @@ config ZMK_BLE_PASSKEY_ENTRY
#ZMK_BLE
endif
#HID Output Types
#Output Types
endmenu
# HID
endmenu
menu "Split Support"