aboutsummaryrefslogtreecommitdiff
path: root/keyboards/nk87/config.h
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/nk87/config.h')
-rwxr-xr-xkeyboards/nk87/config.h146
1 files changed, 146 insertions, 0 deletions
diff --git a/keyboards/nk87/config.h b/keyboards/nk87/config.h
new file mode 100755
index 000000000..4a1098a90
--- /dev/null
+++ b/keyboards/nk87/config.h
@@ -0,0 +1,146 @@
1/*
2Copyright 2020 Yiancar
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 2 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17
18#pragma once
19
20#include "config_common.h"
21
22/* USB Device descriptor parameter */
23#define VENDOR_ID 0x8968
24#define PRODUCT_ID 0x4E4C
25#define DEVICE_VER 0x0001
26#define MANUFACTURER Yiancar-Designs
27#define PRODUCT NK87
28
29/* key matrix size */
30#define MATRIX_ROWS 6
31#define MATRIX_COLS 17
32
33#define MATRIX_ROW_PINS { A7, B3, B4, B5, A8, A4 }
34#define MATRIX_COL_PINS { A13, A10, A9, A14, A15, B8, B9, C13, C14, C15, A0, A1, A2, A3, A5, B1, B10 }
35// To enable debugger set A13 A14 -> A5 A7
36
37/* COL2ROW, ROW2COL*/
38#define DIODE_DIRECTION COL2ROW
39
40/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
41#define DEBOUNCE 5
42
43/* define if matrix has ghost (lacks anti-ghosting diodes) */
44//#define MATRIX_HAS_GHOST
45
46/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
47 * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
48 */
49// #define GRAVE_ESC_CTRL_OVERRIDE
50
51/*
52 * Force NKRO
53 *
54 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
55 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
56 * makefile for this to work.)
57 *
58 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
59 * until the next keyboard reset.
60 *
61 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
62 * fully operational during normal computer usage.
63 *
64 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
65 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
66 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
67 * power-up.
68 *
69 */
70//#define FORCE_NKRO
71
72/*
73 * Magic Key Options
74 *
75 * Magic keys are hotkey commands that allow control over firmware functions of
76 * the keyboard. They are best used in combination with the HID Listen program,
77 * found here: https://www.pjrc.com/teensy/hid_listen.html
78 *
79 * The options below allow the magic key functionality to be changed. This is
80 * useful if your keyboard/keypad is missing keys and you want magic key support.
81 *
82 */
83
84/* Bootmagic Lite key configuration */
85#define BOOTMAGIC_LITE_ROW 0
86#define BOOTMAGIC_LITE_COLUMN 0
87
88/* Backlight options */
89
90#define RGB_BACKLIGHT_ENABLED 1
91
92#define RGB_BACKLIGHT_NK87
93
94// they aren't really used if RGB_BACKLIGHT_HS60 defined
95#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
96#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
97#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 0
98#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
99#define RGB_BACKLIGHT_USE_ISO_ENTER 0
100#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
101
102// disable backlight when USB suspended (PC sleep/hibernate/shutdown)
103#define RGB_BACKLIGHT_DISABLE_WHEN_USB_SUSPENDED 0
104
105// disable backlight after timeout in minutes, 0 = no timeout
106#define RGB_BACKLIGHT_DISABLE_AFTER_TIMEOUT 0
107
108// the default brightness
109#define RGB_BACKLIGHT_BRIGHTNESS 255
110
111// the default effect (RGB test)
112#define RGB_BACKLIGHT_EFFECT 6
113
114// the default effect speed (0-3)
115#define RGB_BACKLIGHT_EFFECT_SPEED 0
116
117// the default color1 and color2
118#define RGB_BACKLIGHT_COLOR_1 { .h = 0, .s = 255 }
119#define RGB_BACKLIGHT_COLOR_2 { .h = 127, .s = 255 }
120
121#define DRIVER_COUNT 2
122#define DRIVER_LED_TOTAL 128
123
124// These define which keys in the matrix are alphas/mods
125// Used for backlight effects so colors are different for
126// alphas vs. mods
127// Each value is for a row, bit 0 is column 0
128// Alpha=0 Mod=1
129// Rows are shifted one down, F-row cannot be dynamically modified at the moment.
130#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_0 0b1110000000000000
131#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_1 0b1100000000000001
132#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_2 0b0010000000000001
133#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_3 0b1001000000000001
134#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_4 0b1111100000000111
135
136#define RGB_BACKLIGHT_CAPS_LOCK_INDICATOR { .color = { .h = 0, .s = 0 }, .index = 255 }
137#define RGB_BACKLIGHT_LAYER_1_INDICATOR { .color = { .h = 0, .s = 0 }, .index = 255 }
138#define RGB_BACKLIGHT_LAYER_2_INDICATOR { .color = { .h = 0, .s = 0 }, .index = 255 }
139#define RGB_BACKLIGHT_LAYER_3_INDICATOR { .color = { .h = 0, .s = 0 }, .index = 255 }
140
141// Backlight config starts after VIA's EEPROM usage,
142// dynamic keymaps start after this.
143#define VIA_EEPROM_CUSTOM_CONFIG_SIZE 32
144
145// VIA lighting is handled by the keyboard-level code
146#define VIA_CUSTOM_LIGHTING_ENABLE