aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryiancar <yiangosyiangou@cytanet.com.cy>2021-06-26 05:42:09 +0100
committerGitHub <noreply@github.com>2021-06-25 21:42:09 -0700
commitad3169f500e027296adf6961fcd948caa023891d (patch)
tree62476a35ed0d1ad1b1b28e8386c677a53750d28e
parentb1ea4842e38d0d3e609d8b0d6016ab0a4288bdc4 (diff)
downloadqmk_firmware-ad3169f500e027296adf6961fcd948caa023891d.tar.gz
qmk_firmware-ad3169f500e027296adf6961fcd948caa023891d.zip
[Keyboard] Add NK1 (#13212)
Co-authored-by: Ryan <fauxpark@gmail.com> Co-authored-by: yiancar <yiancar@gmail.com>
-rw-r--r--keyboards/nk1/config.h93
-rwxr-xr-xkeyboards/nk1/info.json12
-rw-r--r--keyboards/nk1/keymaps/default/keymap.c21
-rw-r--r--keyboards/nk1/keymaps/default/readme.md1
-rw-r--r--keyboards/nk1/keymaps/via/keymap.c21
-rw-r--r--keyboards/nk1/keymaps/via/readme.md1
-rw-r--r--keyboards/nk1/keymaps/via/rules.mk1
-rw-r--r--keyboards/nk1/nk1.c17
-rw-r--r--keyboards/nk1/nk1.h25
-rw-r--r--keyboards/nk1/readme.md32
-rw-r--r--keyboards/nk1/rules.mk24
11 files changed, 248 insertions, 0 deletions
diff --git a/keyboards/nk1/config.h b/keyboards/nk1/config.h
new file mode 100644
index 000000000..122df2e6d
--- /dev/null
+++ b/keyboards/nk1/config.h
@@ -0,0 +1,93 @@
1
2/* Copyright 2021 Yiancar
3 *
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along 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 0x4E4D
25#define DEVICE_VER 0x0001
26#define MANUFACTURER Yiancar-Designs
27#define PRODUCT NK1
28
29/* key matrix size */
30#define MATRIX_ROWS 1
31#define MATRIX_COLS 1
32
33/* Keyboard Matrix Assignments */
34#define DIRECT_PINS { \
35 { D4 } \
36}
37
38/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
39#define DEBOUNCE 5
40
41/* define if matrix has ghost (lacks anti-ghosting diodes) */
42//#define MATRIX_HAS_GHOST
43
44/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
45 * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
46 */
47// #define GRAVE_ESC_CTRL_OVERRIDE
48
49/*
50 * Force NKRO
51 *
52 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
53 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
54 * makefile for this to work.)
55 *
56 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
57 * until the next keyboard reset.
58 *
59 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
60 * fully operational during normal computer usage.
61 *
62 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
63 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
64 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
65 * power-up.
66 *
67 */
68//#define FORCE_NKRO
69
70/*
71 * Magic Key Options
72 *
73 * Magic keys are hotkey commands that allow control over firmware functions of
74 * the keyboard. They are best used in combination with the HID Listen program,
75 * found here: https://www.pjrc.com/teensy/hid_listen.html
76 *
77 * The options below allow the magic key functionality to be changed. This is
78 * useful if your keyboard/keypad is missing keys and you want magic key support.
79 *
80 */
81
82#define RGB_DI_PIN F0
83#ifdef RGB_DI_PIN
84 #define RGBLED_NUM 9
85 #define RGBLIGHT_HUE_STEP 8
86 #define RGBLIGHT_SAT_STEP 8
87 #define RGBLIGHT_VAL_STEP 8
88 #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
89 #define RGBLIGHT_ANIMATIONS
90#endif
91
92/* There is only 1 Button so limiting VIA to 1 layer */
93#define DYNAMIC_KEYMAP_LAYER_COUNT 1
diff --git a/keyboards/nk1/info.json b/keyboards/nk1/info.json
new file mode 100755
index 000000000..3bf8d4745
--- /dev/null
+++ b/keyboards/nk1/info.json
@@ -0,0 +1,12 @@
1{
2 "keyboard_name": "NK1",
3 "url": "www.yiancar-designs.com",
4 "maintainer": "yiancar",
5 "width": 1,
6 "height": 1,
7 "layouts": {
8 "LAYOUT_ortho_1x1": {
9 "layout": [{"x": 0, "y": 0}]
10 }
11 }
12}
diff --git a/keyboards/nk1/keymaps/default/keymap.c b/keyboards/nk1/keymaps/default/keymap.c
new file mode 100644
index 000000000..550a0f487
--- /dev/null
+++ b/keyboards/nk1/keymaps/default/keymap.c
@@ -0,0 +1,21 @@
1/* Copyright 2021 Yiancar
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#include QMK_KEYBOARD_H
17
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19[0] = LAYOUT_ortho_1x1( /* Base */
20 KC_ENT)
21};
diff --git a/keyboards/nk1/keymaps/default/readme.md b/keyboards/nk1/keymaps/default/readme.md
new file mode 100644
index 000000000..6e9c78ee5
--- /dev/null
+++ b/keyboards/nk1/keymaps/default/readme.md
@@ -0,0 +1 @@
# The default keymap for NK1
diff --git a/keyboards/nk1/keymaps/via/keymap.c b/keyboards/nk1/keymaps/via/keymap.c
new file mode 100644
index 000000000..550a0f487
--- /dev/null
+++ b/keyboards/nk1/keymaps/via/keymap.c
@@ -0,0 +1,21 @@
1/* Copyright 2021 Yiancar
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#include QMK_KEYBOARD_H
17
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19[0] = LAYOUT_ortho_1x1( /* Base */
20 KC_ENT)
21};
diff --git a/keyboards/nk1/keymaps/via/readme.md b/keyboards/nk1/keymaps/via/readme.md
new file mode 100644
index 000000000..10025a596
--- /dev/null
+++ b/keyboards/nk1/keymaps/via/readme.md
@@ -0,0 +1 @@
# The default keymap for NK1 with VIA enabled
diff --git a/keyboards/nk1/keymaps/via/rules.mk b/keyboards/nk1/keymaps/via/rules.mk
new file mode 100644
index 000000000..036bd6d1c
--- /dev/null
+++ b/keyboards/nk1/keymaps/via/rules.mk
@@ -0,0 +1 @@
VIA_ENABLE = yes \ No newline at end of file
diff --git a/keyboards/nk1/nk1.c b/keyboards/nk1/nk1.c
new file mode 100644
index 000000000..683347856
--- /dev/null
+++ b/keyboards/nk1/nk1.c
@@ -0,0 +1,17 @@
1/* Copyright 2021 Yiancar
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16
17#include "nk1.h"
diff --git a/keyboards/nk1/nk1.h b/keyboards/nk1/nk1.h
new file mode 100644
index 000000000..3962e1851
--- /dev/null
+++ b/keyboards/nk1/nk1.h
@@ -0,0 +1,25 @@
1/* Copyright 2021 Yiancar
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16
17#pragma once
18
19#include "quantum.h"
20
21#define LAYOUT_ortho_1x1( \
22 K00 \
23) { \
24 { K00 } \
25}
diff --git a/keyboards/nk1/readme.md b/keyboards/nk1/readme.md
new file mode 100644
index 000000000..bc668481b
--- /dev/null
+++ b/keyboards/nk1/readme.md
@@ -0,0 +1,32 @@
1# NK1
2
3A big switch keypad!
4
5* Keyboard Maintainer: [Yiancar](https://yiancar-designs.com/) and on [GitHub](https://github.com/yiancar)
6* Hardware Supported: A BIG keypad with ATmega 32u4
7* Hardware Availability: https://novelkeys.xyz/
8
9## Instructions
10
11### Build
12
13Make example for this keyboard (after setting up your build environment):
14
15 make nk1:default
16
17See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
18
19### Reset
20
21- Unplug
22- Hold the key
23- Plug In
24- Unplug
25- Release the key
26
27### Flash
28
29- Unplug
30- Hold the key
31- Plug In
32- Flash using QMK Toolbox or dfu-util (`make nk1:<keymap>:flash`)
diff --git a/keyboards/nk1/rules.mk b/keyboards/nk1/rules.mk
new file mode 100644
index 000000000..8dd72e9a6
--- /dev/null
+++ b/keyboards/nk1/rules.mk
@@ -0,0 +1,24 @@
1# MCU name
2MCU = atmega32u4
3
4# Bootloader selection
5BOOTLOADER = atmel-dfu
6
7# Build Options
8# change yes to no to disable
9#
10BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
11MOUSEKEY_ENABLE = yes # Mouse keys
12EXTRAKEY_ENABLE = yes # Audio control and System control
13CONSOLE_ENABLE = no # Console for debug
14COMMAND_ENABLE = no # Commands for debug and configuration
15# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
16SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
17# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
18NKRO_ENABLE = yes # USB Nkey Rollover
19BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
20RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
21BLUETOOTH_ENABLE = no # Enable Bluetooth
22AUDIO_ENABLE = no # Audio output
23
24LAYOUTS = ortho_1x1