/
capabilities.kll
110 lines (86 loc) · 3.5 KB
/
capabilities.kll
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
# pjrcUSB
Name = pjrcUSBCapabilities;
Version = 0.9;
Author = "HaaTa (Jacob Alexander) 2014-2017";
KLL = 0.5;
# Modified Date
Date = 2016-05-31;
# Output capabilities
consCtrlOut => Output_consCtrlSend_capability( consCode : 2 );
noneOut => Output_noneSend_capability();
sysCtrlOut => Output_sysCtrlSend_capability( sysCode : 1 );
usbKeyOut => Output_usbCodeSend_capability( usbCode : 1 );
mouseOut => Output_usbMouse_capability( mouseCode : 2, relative_x : 2, relative_y : 2 );
# Configuration capabilities
kbdProtocolBoot => Output_kbdProtocolBoot_capability();
kbdProtocolNKRO => Output_kbdProtocolNKRO_capability();
toggleKbdProtocol => Output_toggleKbdProtocol_capability();
# Locale Settings
keyboardLocale => KeyboardLocale_define;
keyboardLocale = 0;
# Default KRO Mode
# Set to 0 for Boot Mode (6KRO)
# Set to 1 for NKRO Mode (default)
usbProtocol => USBProtocol_define;
usbProtocol = 1;
# Secure Bootloader Mode
# XXX (HaaTa)
# Currently disabled, but this should be enabled by default when infrastructure is ready.
secureBootloaderEnabled => SecureBootloader_define;
secureBootloaderEnabled = 0;
#secureBootloaderEnabled = 1;
# Bootloader Mode capability
# XXX (HaaTa)
# By default this is disabled on purpose
# It is a large security hazard
flashModeEnabled => flashModeEnabled_define;
flashModeEnabled = 0;
flashMode => Output_flashMode_capability();
## USB Compatibility Flags ##
# Some OSs and USB Chipsets have issues with USB features
# These flags are available to provide ways to debug them
# Enable USB Suspend/Low Power mode
# After a period of inactivity, the USB host may request that the device go into low power mode
# This is different than system sleep, though it may occur around the same time
enableUSBSuspend => enableUSBSuspend_define;
enableUSBSuspend = 1;
# Enable Low-power Negotiation
# In order to support low-powered USB hosts, such as an Apple IPad, a low power auto-negotiation scheme has been implemented
# Unfortunately, badly behaved USB Chipsets and OSs may not work correctly with this support enabled
# Typical symptoms:
# * USB constantly re-initializing when first plugging in
enableUSBLowPowerNegotiation => enableUSBLowPowerNegotiation_define;
enableUSBLowPowerNegotiation = 0;
# Enable Device Restart on USB Timeout
# *USE AS LAST RETORT*
# To work around some USB OS, Chipset and Firwmare bugs, an auto-restart mechanism has been implemented
# Depending on the situation, this can be rather aggressive.
# This behaves differently than the Low-power negotiation restart and have very different triggering schemes.
enableDeviceRestartOnUSBTimeout => enableDeviceRestartOnUSBTimeout_define;
enableDeviceRestartOnUSBTimeout = 0;
# Enable Host-Resume (wake-from-sleep)
# On specific actions (such as USB key actions), will trigger the host device to wake if USB is suspended
enableUSBResume => enableUSBResume_define;
enableUSBResume = 1;
## USB Endpoint Configuration ##
# 1 - Enable endpoint
# 0 - Disable endpoint
# Any/all endpoints can be disabled
# But you'll lose functionality for that feature
# Disabling endpoints will save RAM and Flash on the target MCU
# Joystick Endpoint
# *Currently Unused*
enableJoystick => enableJoystick_define;
enableJoystick = 0;
# Mouse Endpoint
enableMouse => enableMouse_define;
enableMouse = 1;
# Keyboard Endpoint
enableKeyboard => enableKeyboard_define;
enableKeyboard = 1;
# CDC / Serial Port Endpoint
enableVirtualSerialPort => enableVirtualSerialPort_define;
enableVirtualSerialPort = 1;
# Raw I/O Endpoint
enableRawIO => enableRawIO_define;
enableRawIO = 1;