summaryrefslogtreecommitdiff
path: root/app/Kconfig
blob: ee26f46270913c26746ce9254da544ac9845c788 (plain)
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
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
# Copyright (c) 2020 The ZMK Contributors
# SPDX-License-Identifier: MIT

mainmenu "ZMK Firmware"

menu "ZMK"

menu "Basic Keyboard Setup"

config ZMK_KEYBOARD_NAME
	string "Keyboard Name"

config USB_DEVICE_PRODUCT
	default ZMK_KEYBOARD_NAME

config BT_DEVICE_NAME
	default ZMK_KEYBOARD_NAME

config USB_DEVICE_VID
	default 0x1D50

config USB_DEVICE_PID
	default 0x615E

config USB_DEVICE_MANUFACTURER
	default "ZMK Project"

menu "HID Output Types"

config ZMK_USB
	bool "USB"
	select USB
	select USB_DEVICE_STACK
	select USB_DEVICE_HID

if ZMK_USB

config USB_NUMOF_EP_WRITE_RETRIES
	default 10

#ZMK_USB
endif

config ZMK_BLE
	bool "BLE (HID over GATT)"
	select BT
	select BT_SMP
	select BT_SMP_SC_PAIR_ONLY
	select BT_SMP_APP_PAIRING_ACCEPT
	select BT_PERIPHERAL
	select BT_GATT_DIS
	select BT_GATT_BAS
	select BT_SETTINGS
	select SETTINGS

if ZMK_BLE

config SYSTEM_WORKQUEUE_STACK_SIZE
	default 2048

config ZMK_BLE_CLEAR_BONDS_ON_START
	bool "Configuration that clears all bond information from the keyboard on startup."
	default n

# HID GATT notifications sent this way are *not* picked up by Linux, and possibly others.
config BT_GATT_NOTIFY_MULTIPLE
	default n

config BT_DEVICE_APPEARANCE
	default 961

config ZMK_BLE_PASSKEY_ENTRY
	bool "Experimental: Requiring typing passkey from host to pair BLE connection"
	default n

#ZMK_BLE
endif

#HID Output Types
endmenu

menu "Split Support"

config ZMK_SPLIT
	bool "Split keyboard support"
	default n

if ZMK_SPLIT

config ZMK_SPLIT_BLE
	bool "Split keyboard support via BLE transport"
	depends on ZMK_BLE
	default y
	select BT_USER_PHY_UPDATE

if ZMK_SPLIT_BLE

choice ZMK_SPLIT_BLE_ROLE
	bool "BLE Role For Split Communication"
	default ZMK_SPLIT_BLE_ROLE_CENTRAL

config ZMK_SPLIT_BLE_ROLE_CENTRAL
	bool "Central"
	select BT_CENTRAL
	select BT_GATT_CLIENT

config ZMK_SPLIT_BLE_ROLE_PERIPHERAL
	bool "Peripheral"

if ZMK_SPLIT_BLE_ROLE_PERIPHERAL

config ZMK_USB
	default n

config BT_MAX_PAIRED
	default 1

config BT_MAX_CONN
	default 1

config BT_GAP_AUTO_UPDATE_CONN_PARAMS
	default n

#ZMK_SPLIT_BLE_ROLE_PERIPHERAL
endif

#ZMK_SPLIT_BLE_ROLE
endchoice

#ZMK_SPLIT_BLE
endif

#ZMK_SPLIT
endif 

if ZMK_BLE

if ZMK_SPLIT_BLE && ZMK_SPLIT_BLE_ROLE_CENTRAL

config BT_MAX_CONN
	default 6

config BT_MAX_PAIRED
	default 6

#ZMK_SPLIT_BLE && ZMK_SPLIT_BLE_ROLE_CENTRAL
endif

if !ZMK_SPLIT_BLE

config BT_MAX_CONN
	default 5

config BT_MAX_PAIRED
	default 5

#!ZMK_SPLIT_BLE
endif

#ZMK_BLE
endif

#Split Support
endmenu

#Basic Keyboard Setup
endmenu

menu "Display/LED Options"

rsource "src/display/Kconfig"

config ZMK_RGB_UNDERGLOW
	bool "RGB Adressable LED Underglow"
	select LED_STRIP

if ZMK_RGB_UNDERGLOW

# This default value cuts down on tons of excess .conf files, if you're using GPIO, manually disable this
config SPI
	default y

config ZMK_RGB_UNDERGLOW_EXT_POWER
	bool "RGB underglow toggling also controls external power"
	default y

config ZMK_RGB_UNDERGLOW_HUE_STEP
	int "RGB underglow hue step in degrees of 360"
	default 10

config ZMK_RGB_UNDERGLOW_SAT_STEP
	int "RGB underglow sturation step in percent"
	default 10

config ZMK_RGB_UNDERGLOW_BRT_STEP
	int "RGB underglow brightness step in percent"
	default 10

config ZMK_RGB_UNDERGLOW_HUE_START
	int "RGB underglow start hue value from 0-359"
	default 0

config ZMK_RGB_UNDERGLOW_SAT_START
	int "RGB underglow start saturations value from 0-100"
	default 100

config ZMK_RGB_UNDERGLOW_BRT_START
	int "RGB underglow start brightness value from 0-100"
	default 100

config ZMK_RGB_UNDERGLOW_SPD_START
	int "RGB underglow start animation speed value from 1-5"
	default 3

config ZMK_RGB_UNDERGLOW_EFF_START
	int "RGB underglow start effect int value related to the effect enum list"
	default 0

config ZMK_RGB_UNDERGLOW_ON_START
	bool "RGB underglow starts on by default"
	default y

#ZMK_RGB_UNDERGLOW
endif

#Display/LED Options
endmenu

menu "Power Management"

config ZMK_SLEEP
	bool "Enable deep sleep support"
	imply USB

if ZMK_SLEEP

config SYS_POWER_DEEP_SLEEP_STATES
	default y

choice SYS_PM_POLICY
	default SYS_PM_POLICY_APP
endchoice

config ZMK_IDLE_SLEEP_TIMEOUT
	int "Milliseconds to wait to sleep when going idle"
	default 900000

#ZMK_SLEEP
endif

config ZMK_EXT_POWER
	bool "Enable support to control external power output"
	default y

#Power Management
endmenu

menu "Advanced"

menu "Initialization Priorities"

if USB

config ZMK_USB_INIT_PRIORITY
	int "USB Init Priority"
	default 50

#USB
endif

if ZMK_BLE || ZMK_SPLIT_BLE

config ZMK_BLE_INIT_PRIORITY
	int "BLE Init Priority"
	default 50

#ZMK_BLE || ZMK_SPLIT_BLE
endif

#Initialization Priorities
endmenu

menu "KSCAN Settings"

config ZMK_KSCAN_EVENT_QUEUE_SIZE
	int "Size of the event queue for KSCAN events to buffer events"
	default 4

config ZMK_KSCAN_MOCK_DRIVER
	bool "Enable mock kscan driver to simulate key presses"
	default n

config ZMK_KSCAN_COMPOSITE_DRIVER
	bool "Enable composite kscan driver to combine kscan devices"
	default n

#KSCAN Settings
endmenu

if SETTINGS

config ZMK_SETTINGS_SAVE_DEBOUNCE
	int "Milliseconds to debounce settings saves"
	default 60000

#SETTINGS
endif

#Advanced
endmenu

#ZMK
endmenu

config HEAP_MEM_POOL_SIZE
	default 8192

config KERNEL_BIN_NAME
	default "zmk"

config REBOOT
	default y

module = ZMK
module-str = zmk
source "subsys/logging/Kconfig.template.log_config"

rsource "boards/Kconfig"
rsource "boards/shields/*/Kconfig.defconfig"
rsource "boards/shields/*/Kconfig.shield"

osource "$(ZMK_CONFIG)/boards/shields/*/Kconfig.defconfig"
osource "$(ZMK_CONFIG)/boards/shields/*/Kconfig.shield"


source "Kconfig.zephyr"