aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaarten Dekkers <maartenwut@gmail.com>2020-06-09 21:10:00 +0200
committerGitHub <noreply@github.com>2020-06-09 12:10:00 -0700
commit86812f22e42b493d7021fe4bcb726ac9412b8e55 (patch)
tree659af3bff1044f2ff4ba5f21a1ffef0cbdb5ed86
parentb83fb9eb711ea8c7b064a660bc20b62f4d812bd4 (diff)
downloadqmk_firmware-86812f22e42b493d7021fe4bcb726ac9412b8e55.tar.gz
qmk_firmware-86812f22e42b493d7021fe4bcb726ac9412b8e55.zip
[Keyboard] Add nt660 PCB (#9042)
* Upload nt660 files * Apply suggestions from code review * Apply suggestions from code review
-rw-r--r--keyboards/maartenwut/nt660/config.h256
-rw-r--r--keyboards/maartenwut/nt660/info.json234
-rw-r--r--keyboards/maartenwut/nt660/keymaps/default/keymap.c26
-rw-r--r--keyboards/maartenwut/nt660/keymaps/maartenwut/config.h3
-rw-r--r--keyboards/maartenwut/nt660/keymaps/maartenwut/keymap.c58
-rw-r--r--keyboards/maartenwut/nt660/keymaps/via/keymap.c44
-rw-r--r--keyboards/maartenwut/nt660/keymaps/via/rules.mk2
-rw-r--r--keyboards/maartenwut/nt660/nt660.c32
-rw-r--r--keyboards/maartenwut/nt660/nt660.h73
-rw-r--r--keyboards/maartenwut/nt660/readme.md19
-rw-r--r--keyboards/maartenwut/nt660/rules.mk34
11 files changed, 781 insertions, 0 deletions
diff --git a/keyboards/maartenwut/nt660/config.h b/keyboards/maartenwut/nt660/config.h
new file mode 100644
index 000000000..84e93b4f0
--- /dev/null
+++ b/keyboards/maartenwut/nt660/config.h
@@ -0,0 +1,256 @@
1/*
2Copyright 2020 Maarten Dekkers <maartenwut@gmail.com>
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 0x4705
24#define PRODUCT_ID 0x1F02
25#define DEVICE_VER 0x0001
26#define MANUFACTURER Maartenwut
27#define PRODUCT nt660
28#define DESCRIPTION Replacement PCB for Leopold FC660M
29
30/* key matrix size */
31#define MATRIX_ROWS 5
32#define MATRIX_COLS 15
33
34/*
35 * Keyboard Matrix Assignments
36 *
37 * Change this to how you wired your keyboard
38 * COLS: AVR pins used for columns, left to right
39 * ROWS: AVR pins used for rows, top to bottom
40 * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
41 * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
42 *
43 */
44#define MATRIX_ROW_PINS {B7,E6,F6,F7,C7}
45#define MATRIX_COL_PINS {D6,D7,B4,B5,B6,C6,B0,B1,B2,B3,F0,F1,F4,F5,D4}
46#define UNUSED_PINS
47
48/* COL2ROW or ROW2COL */
49#define DIODE_DIRECTION COL2ROW
50
51
52/*
53 * Split Keyboard specific options, make sure you have 'SPLIT_KEYBOARD = yes' in your rules.mk, and define SOFT_SERIAL_PIN.
54 */
55// #define SOFT_SERIAL_PIN D0 // or D1, D2, D3, E6
56
57// #define BACKLIGHT_PIN B7
58// #define BACKLIGHT_BREATHING
59// #define BACKLIGHT_LEVELS 3
60
61// #define RGB_DI_PIN E2
62// #ifdef RGB_DI_PIN
63// #define RGBLED_NUM 16
64// #define RGBLIGHT_HUE_STEP 8
65// #define RGBLIGHT_SAT_STEP 8
66// #define RGBLIGHT_VAL_STEP 8
67// #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
68// #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
69// /*== all animations enable ==*/
70// #define RGBLIGHT_ANIMATIONS
71// /*== or choose animations ==*/
72// #define RGBLIGHT_EFFECT_BREATHING
73// #define RGBLIGHT_EFFECT_RAINBOW_MOOD
74// #define RGBLIGHT_EFFECT_RAINBOW_SWIRL
75// #define RGBLIGHT_EFFECT_SNAKE
76// #define RGBLIGHT_EFFECT_KNIGHT
77// #define RGBLIGHT_EFFECT_CHRISTMAS
78// #define RGBLIGHT_EFFECT_STATIC_GRADIENT
79// #define RGBLIGHT_EFFECT_RGB_TEST
80// #define RGBLIGHT_EFFECT_ALTERNATING
81// /*== customize breathing effect ==*/
82// /*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/
83// #define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64
84// /*==== use exp() and sin() ====*/
85// #define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7
86// #define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255
87// #endif
88
89/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
90#define DEBOUNCE 5
91
92/* define if matrix has ghost (lacks anti-ghosting diodes) */
93//#define MATRIX_HAS_GHOST
94
95/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
96#define LOCKING_SUPPORT_ENABLE
97/* Locking resynchronize hack */
98#define LOCKING_RESYNC_ENABLE
99
100/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
101 * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
102 */
103// #define GRAVE_ESC_CTRL_OVERRIDE
104
105/*
106 * Force NKRO
107 *
108 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
109 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
110 * makefile for this to work.)
111 *
112 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
113 * until the next keyboard reset.
114 *
115 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
116 * fully operational during normal computer usage.
117 *
118 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
119 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
120 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
121 * power-up.
122 *
123 */
124//#define FORCE_NKRO
125
126/*
127 * Magic Key Options
128 *
129 * Magic keys are hotkey commands that allow control over firmware functions of
130 * the keyboard. They are best used in combination with the HID Listen program,
131 * found here: https://www.pjrc.com/teensy/hid_listen.html
132 *
133 * The options below allow the magic key functionality to be changed. This is
134 * useful if your keyboard/keypad is missing keys and you want magic key support.
135 *
136 */
137
138/* key combination for magic key command */
139/* defined by default; to change, uncomment and set to the combination you want */
140// #define IS_COMMAND() (get_mods() == MOD_MASK_SHIFT)
141
142/* control how magic key switches layers */
143//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
144//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
145//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
146
147/* override magic key keymap */
148//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
149//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
150//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
151//#define MAGIC_KEY_HELP H
152//#define MAGIC_KEY_HELP_ALT SLASH
153//#define MAGIC_KEY_DEBUG D
154//#define MAGIC_KEY_DEBUG_MATRIX X
155//#define MAGIC_KEY_DEBUG_KBD K
156//#define MAGIC_KEY_DEBUG_MOUSE M
157//#define MAGIC_KEY_VERSION V
158//#define MAGIC_KEY_STATUS S
159//#define MAGIC_KEY_CONSOLE C
160//#define MAGIC_KEY_LAYER0 0
161//#define MAGIC_KEY_LAYER0_ALT GRAVE
162//#define MAGIC_KEY_LAYER1 1
163//#define MAGIC_KEY_LAYER2 2
164//#define MAGIC_KEY_LAYER3 3
165//#define MAGIC_KEY_LAYER4 4
166//#define MAGIC_KEY_LAYER5 5
167//#define MAGIC_KEY_LAYER6 6
168//#define MAGIC_KEY_LAYER7 7
169//#define MAGIC_KEY_LAYER8 8
170//#define MAGIC_KEY_LAYER9 9
171//#define MAGIC_KEY_BOOTLOADER B
172//#define MAGIC_KEY_BOOTLOADER_ALT ESC
173//#define MAGIC_KEY_LOCK CAPS
174//#define MAGIC_KEY_EEPROM E
175//#define MAGIC_KEY_EEPROM_CLEAR BSPACE
176//#define MAGIC_KEY_NKRO N
177//#define MAGIC_KEY_SLEEP_LED Z
178
179/*
180 * Feature disable options
181 * These options are also useful to firmware size reduction.
182 */
183
184/* disable debug print */
185//#define NO_DEBUG
186
187/* disable print */
188//#define NO_PRINT
189
190/* disable action features */
191//#define NO_ACTION_LAYER
192//#define NO_ACTION_TAPPING
193//#define NO_ACTION_ONESHOT
194
195/* disable these deprecated features by default */
196#define NO_ACTION_MACRO
197#define NO_ACTION_FUNCTION
198
199/*
200 * MIDI options
201 */
202
203/* Prevent use of disabled MIDI features in the keymap */
204//#define MIDI_ENABLE_STRICT 1
205
206/* enable basic MIDI features:
207 - MIDI notes can be sent when in Music mode is on
208*/
209//#define MIDI_BASIC
210
211/* enable advanced MIDI features:
212 - MIDI notes can be added to the keymap
213 - Octave shift and transpose
214 - Virtual sustain, portamento, and modulation wheel
215 - etc.
216*/
217//#define MIDI_ADVANCED
218
219/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
220//#define MIDI_TONE_KEYCODE_OCTAVES 1
221
222/*
223 * HD44780 LCD Display Configuration
224 */
225/*
226#define LCD_LINES 2 //< number of visible lines of the display
227#define LCD_DISP_LENGTH 16 //< visibles characters per line of the display
228
229#define LCD_IO_MODE 1 //< 0: memory mapped mode, 1: IO port mode
230
231#if LCD_IO_MODE
232#define LCD_PORT PORTB //< port for the LCD lines
233#define LCD_DATA0_PORT LCD_PORT //< port for 4bit data bit 0
234#define LCD_DATA1_PORT LCD_PORT //< port for 4bit data bit 1
235#define LCD_DATA2_PORT LCD_PORT //< port for 4bit data bit 2
236#define LCD_DATA3_PORT LCD_PORT //< port for 4bit data bit 3
237#define LCD_DATA0_PIN 4 //< pin for 4bit data bit 0
238#define LCD_DATA1_PIN 5 //< pin for 4bit data bit 1
239#define LCD_DATA2_PIN 6 //< pin for 4bit data bit 2
240#define LCD_DATA3_PIN 7 //< pin for 4bit data bit 3
241#define LCD_RS_PORT LCD_PORT //< port for RS line
242#define LCD_RS_PIN 3 //< pin for RS line
243#define LCD_RW_PORT LCD_PORT //< port for RW line
244#define LCD_RW_PIN 2 //< pin for RW line
245#define LCD_E_PORT LCD_PORT //< port for Enable line
246#define LCD_E_PIN 1 //< pin for Enable line
247#endif
248*/
249
250/* Bootmagic Lite key configuration */
251// #define BOOTMAGIC_LITE_ROW 0
252// #define BOOTMAGIC_LITE_COLUMN 0
253
254#define QMK_ESC_OUTPUT D6 // usually COL
255#define QMK_ESC_INPUT B7 // usually ROW
256#define QMK_LED D0
diff --git a/keyboards/maartenwut/nt660/info.json b/keyboards/maartenwut/nt660/info.json
new file mode 100644
index 000000000..4b2b61969
--- /dev/null
+++ b/keyboards/maartenwut/nt660/info.json
@@ -0,0 +1,234 @@
1{
2 "keyboard_name": "nt660",
3 "url": "",
4 "maintainer": "maartenwut",
5 "width": 16.5,
6 "height": 5,
7 "layouts": {
8 "LAYOUT_all": {
9 "layout": [
10 {"label":"k00", "x":0, "y":0},
11 {"label":"k01", "x":1, "y":0},
12 {"label":"k02", "x":2, "y":0},
13 {"label":"k03", "x":3, "y":0},
14 {"label":"k04", "x":4, "y":0},
15 {"label":"k05", "x":5, "y":0},
16 {"label":"k06", "x":6, "y":0},
17 {"label":"k07", "x":7, "y":0},
18 {"label":"k08", "x":8, "y":0},
19 {"label":"k09", "x":9, "y":0},
20 {"label":"k0a", "x":10, "y":0},
21 {"label":"k0b", "x":11, "y":0},
22 {"label":"k0c", "x":12, "y":0},
23 {"label":"k0f", "x":13, "y":0, "w":2},
24 {"label":"k0d", "x":15.5, "y":0},
25
26 {"label":"k10", "x":0, "y":1, "w":1.5},
27 {"label":"k11", "x":1.5, "y":1},
28 {"label":"k12", "x":2.5, "y":1},
29 {"label":"k13", "x":3.5, "y":1},
30 {"label":"k14", "x":4.5, "y":1},
31 {"label":"k15", "x":5.5, "y":1},
32 {"label":"k16", "x":6.5, "y":1},
33 {"label":"k17", "x":7.5, "y":1},
34 {"label":"k18", "x":8.5, "y":1},
35 {"label":"k19", "x":9.5, "y":1},
36 {"label":"k1a", "x":10.5, "y":1},
37 {"label":"k1b", "x":11.5, "y":1},
38 {"label":"k1c", "x":12.5, "y":1},
39 {"label":"k1f", "x":13.5, "y":1, "w":1.5},
40 {"label":"k1d", "x":15.5, "y":1},
41
42 {"label":"k20", "x":0, "y":2, "w":1.75},
43 {"label":"k21", "x":1.75, "y":2},
44 {"label":"k22", "x":2.75, "y":2},
45 {"label":"k23", "x":3.75, "y":2},
46 {"label":"k24", "x":4.75, "y":2},
47 {"label":"k25", "x":5.75, "y":2},
48 {"label":"k26", "x":6.75, "y":2},
49 {"label":"k27", "x":7.75, "y":2},
50 {"label":"k28", "x":8.75, "y":2},
51 {"label":"k29", "x":9.75, "y":2},
52 {"label":"k2a", "x":10.75, "y":2},
53 {"label":"k2b", "x":11.75, "y":2},
54 {"label":"k2c", "x":12.75, "y":2},
55 {"label":"k2f", "x":13.75, "y":2, "w":1.25},
56
57 {"label":"k30", "x":0, "y":3, "w":1.25},
58 {"label":"k31", "x":1.25, "y":3},
59 {"label":"k32", "x":2.25, "y":3},
60 {"label":"k33", "x":3.25, "y":3},
61 {"label":"k34", "x":4.25, "y":3},
62 {"label":"k35", "x":5.25, "y":3},
63 {"label":"k36", "x":6.25, "y":3},
64 {"label":"k37", "x":7.25, "y":3},
65 {"label":"k38", "x":8.25, "y":3},
66 {"label":"k39", "x":9.25, "y":3},
67 {"label":"k3a", "x":10.25, "y":3},
68 {"label":"k3b", "x":11.25, "y":3},
69 {"label":"k3c", "x":12.25, "y":3, "w":2.25},
70 {"label":"k3f", "x":14.5, "y":3},
71
72 {"label":"k40", "x":0, "y":4, "w":1.25},
73 {"label":"k41", "x":1.25, "y":4},
74 {"label":"k42", "x":2.25, "y":4, "w":1.25},
75 {"label":"k46", "x":3.5, "y":4, "w":6.25},
76 {"label":"k49", "x":9.75, "y":4, "w":1.25},
77 {"label":"k4a", "x":11, "y":4, "w":1.25},
78 {"label":"k4b", "x":12.25, "y":4, "w":1.25},
79 {"label":"k4c", "x":13.5, "y":4},
80 {"label":"k4f", "x":14.5, "y":4},
81 {"label":"k4d", "x":15.5, "y":4}
82 ]
83 },
84 "LAYOUT_66_ansi": {
85 "layout": [
86 {"label":"Esc", "x":0, "y":0},
87 {"label":"!", "x":1, "y":0},
88 {"label":"@", "x":2, "y":0},
89 {"label":"#", "x":3, "y":0},
90 {"label":"$", "x":4, "y":0},
91 {"label":"%", "x":5, "y":0},
92 {"label":"^", "x":6, "y":0},
93 {"label":"&", "x":7, "y":0},
94 {"label":"*", "x":8, "y":0},
95 {"label":"(", "x":9, "y":0},
96 {"label":")", "x":10, "y":0},
97 {"label":"_", "x":11, "y":0},
98 {"label":"+", "x":12, "y":0},
99 {"label":"Backspace", "x":13, "y":0, "w":2},
100 {"label":"Insert", "x":15.5, "y":0},
101
102 {"label":"Tab", "x":0, "y":1, "w":1.5},
103 {"label":"Q", "x":1.5, "y":1},
104 {"label":"W", "x":2.5, "y":1},
105 {"label":"E", "x":3.5, "y":1},
106 {"label":"R", "x":4.5, "y":1},
107 {"label":"T", "x":5.5, "y":1},
108 {"label":"Y", "x":6.5, "y":1},
109 {"label":"U", "x":7.5, "y":1},
110 {"label":"I", "x":8.5, "y":1},
111 {"label":"O", "x":9.5, "y":1},
112 {"label":"P", "x":10.5, "y":1},
113 {"label":"{", "x":11.5, "y":1},
114 {"label":"}", "x":12.5, "y":1},
115 {"label":"|", "x":13.5, "y":1, "w":1.5},
116 {"label":"Delete", "x":15.5, "y":1},
117
118 {"label":"Caps Lock", "x":0, "y":2, "w":1.75},
119 {"label":"A", "x":1.75, "y":2},
120 {"label":"S", "x":2.75, "y":2},
121 {"label":"D", "x":3.75, "y":2},
122 {"label":"F", "x":4.75, "y":2},
123 {"label":"G", "x":5.75, "y":2},
124 {"label":"H", "x":6.75, "y":2},
125 {"label":"J", "x":7.75, "y":2},
126 {"label":"K", "x":8.75, "y":2},
127 {"label":"L", "x":9.75, "y":2},
128 {"label":":", "x":10.75, "y":2},
129 {"label":"\"", "x":11.75, "y":2},
130 {"label":"Enter", "x":12.75, "y":2, "w":2.25},
131
132 {"label":"Shift", "x":0, "y":3, "w":2.25},
133 {"label":"Z", "x":2.25, "y":3},
134 {"label":"X", "x":3.25, "y":3},
135 {"label":"C", "x":4.25, "y":3},
136 {"label":"V", "x":5.25, "y":3},
137 {"label":"B", "x":6.25, "y":3},
138 {"label":"N", "x":7.25, "y":3},
139 {"label":"M", "x":8.25, "y":3},
140 {"label":"<", "x":9.25, "y":3},
141 {"label":">", "x":10.25, "y":3},
142 {"label":"?", "x":11.25, "y":3},
143 {"label":"Shift", "x":12.25, "y":3, "w":2.25},
144 {"label":"\u2191", "x":14.5, "y":3},
145
146 {"label":"Ctrl", "x":0, "y":4, "w":1.25},
147 {"label":"Win", "x":1.25, "y":4},
148 {"label":"Alt", "x":2.25, "y":4, "w":1.25},
149 {"x":3.5, "y":4, "w":6.25},
150 {"label":"Alt", "x":9.75, "y":4, "w":1.25},
151 {"label":"Win", "x":11, "y":4, "w":1.25},
152 {"label":"Menu", "x":12.25, "y":4, "w":1.25},
153 {"label":"\u2190", "x":13.5, "y":4},
154 {"label":"\u2193", "x":14.5, "y":4},
155 {"label":"\u2192", "x":15.5, "y":4}
156 ]
157 },
158 "LAYOUT_66_iso": {
159 "layout": [
160 {"label":"Esc", "x":0, "y":0},
161 {"label":"!", "x":1, "y":0},
162 {"label":"@", "x":2, "y":0},
163 {"label":"#", "x":3, "y":0},
164 {"label":"$", "x":4, "y":0},
165 {"label":"%", "x":5, "y":0},
166 {"label":"^", "x":6, "y":0},
167 {"label":"&", "x":7, "y":0},
168 {"label":"*", "x":8, "y":0},
169 {"label":"(", "x":9, "y":0},
170 {"label":")", "x":10, "y":0},
171 {"label":"_", "x":11, "y":0},
172 {"label":"+", "x":12, "y":0},
173 {"label":"Backspace", "x":13, "y":0, "w":2},
174 {"label":"Insert", "x":15.5, "y":0},
175
176 {"label":"Tab", "x":0, "y":1, "w":1.5},
177 {"label":"Q", "x":1.5, "y":1},
178 {"label":"W", "x":2.5, "y":1},
179 {"label":"E", "x":3.5, "y":1},
180 {"label":"R", "x":4.5, "y":1},
181 {"label":"T", "x":5.5, "y":1},
182 {"label":"Y", "x":6.5, "y":1},
183 {"label":"U", "x":7.5, "y":1},
184 {"label":"I", "x":8.5, "y":1},
185 {"label":"O", "x":9.5, "y":1},
186 {"label":"P", "x":10.5, "y":1},
187 {"label":"{", "x":11.5, "y":1},
188 {"label":"}", "x":12.5, "y":1},
189 {"label":"Delete", "x":15.5, "y":1},
190
191 {"label":"Caps Lock", "x":0, "y":2, "w":1.75},
192 {"label":"A", "x":1.75, "y":2},
193 {"label":"S", "x":2.75, "y":2},
194 {"label":"D", "x":3.75, "y":2},
195 {"label":"F", "x":4.75, "y":2},
196 {"label":"G", "x":5.75, "y":2},
197 {"label":"H", "x":6.75, "y":2},
198 {"label":"J", "x":7.75, "y":2},
199 {"label":"K", "x":8.75, "y":2},
200 {"label":"L", "x":9.75, "y":2},
201 {"label":":", "x":10.75, "y":2},
202 {"label":"\"", "x":11.75, "y":2},
203 {"label":"|", "x":12.75, "y":2},
204 {"label":"Enter", "x":13.75, "y":1, "w":1.25, "h":2},
205
206 {"label":"Shift", "x":0, "y":3, "w":1.25},
207 {"label":"NUBS", "x":1.25, "y":3},
208 {"label":"Z", "x":2.25, "y":3},
209 {"label":"X", "x":3.25, "y":3},
210 {"label":"C", "x":4.25, "y":3},
211 {"label":"V", "x":5.25, "y":3},
212 {"label":"B", "x":6.25, "y":3},
213 {"label":"N", "x":7.25, "y":3},
214 {"label":"M", "x":8.25, "y":3},
215 {"label":"<", "x":9.25, "y":3},
216 {"label":">", "x":10.25, "y":3},
217 {"label":"?", "x":11.25, "y":3},
218 {"label":"Shift", "x":12.25, "y":3, "w":2.25},
219 {"label":"\u2191", "x":14.5, "y":3},
220
221 {"label":"Ctrl", "x":0, "y":4, "w":1.25},
222 {"label":"Win", "x":1.25, "y":4},
223 {"label":"Alt", "x":2.25, "y":4, "w":1.25},
224 {"x":3.5, "y":4, "w":6.25},
225 {"label":"Alt", "x":9.75, "y":4, "w":1.25},
226 {"label":"Win", "x":11, "y":4, "w":1.25},
227 {"label":"Menu", "x":12.25, "y":4, "w":1.25},
228 {"label":"\u2190", "x":13.5, "y":4},
229 {"label":"\u2193", "x":14.5, "y":4},
230 {"label":"\u2192", "x":15.5, "y":4}
231 ]
232 }
233 }
234}
diff --git a/keyboards/maartenwut/nt660/keymaps/default/keymap.c b/keyboards/maartenwut/nt660/keymaps/default/keymap.c
new file mode 100644
index 000000000..305cc8c87
--- /dev/null
+++ b/keyboards/maartenwut/nt660/keymaps/default/keymap.c
@@ -0,0 +1,26 @@
1/* Copyright 2020 Maarten Dekkers <maartenwut@gmail.com>
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
20[0] = LAYOUT_all(
21 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS,
22 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL,
23 KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT,
24 KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
25 KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_APP, KC_RCTRL,KC_LEFT, KC_DOWN, KC_RGHT),
26};
diff --git a/keyboards/maartenwut/nt660/keymaps/maartenwut/config.h b/keyboards/maartenwut/nt660/keymaps/maartenwut/config.h
new file mode 100644
index 000000000..9b18f5826
--- /dev/null
+++ b/keyboards/maartenwut/nt660/keymaps/maartenwut/config.h
@@ -0,0 +1,3 @@
1#pragma once
2
3#define RETRO_TAPPING
diff --git a/keyboards/maartenwut/nt660/keymaps/maartenwut/keymap.c b/keyboards/maartenwut/nt660/keymaps/maartenwut/keymap.c
new file mode 100644
index 000000000..3232f8e55
--- /dev/null
+++ b/keyboards/maartenwut/nt660/keymaps/maartenwut/keymap.c
@@ -0,0 +1,58 @@
1/* Copyright 2020 Maarten Dekkers <maartenwut@gmail.com>
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
18// Each layer gets a name for readability, which is then used in the keymap matrix below.
19// The underscores don't mean anything - you can have a layer called STUFF or any other name.
20// Layer names don't all need to be of the same length, obviously, and you can also skip them
21// entirely and just use numbers.
22#define _MA 0
23#define _GA 1
24#define _FL 2
25#define _SP 3
26
27#define SPACE LT(_SP, KC_SPC)
28
29const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
30
31[_MA] = LAYOUT_all(
32 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_MPLY,
33 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL,
34 KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, _______, KC_ENT,
35 KC_LSFT, _______, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
36 KC_LCTL, KC_LGUI, KC_LALT, SPACE, KC_RALT, KC_RCTRL,MO(_FL), KC_LEFT, KC_DOWN, KC_RGHT),
37
38[_GA] = LAYOUT_all(
39 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
40 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
41 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
42 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
43 _______, _______, _______, KC_SPC, _______, _______, _______, _______, _______, _______),
44
45[_FL] = LAYOUT_all(
46 KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, RESET, KC_PSCR,
47 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_INS,
48 _______, _______, _______, _______, _______, TG(_GA), _______, _______, _______, _______, _______, _______, _______, _______,
49 _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______,
50 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______),
51
52[_SP] = LAYOUT_all(
53 KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______,
54 _______, _______, _______, _______, _______, _______, _______, _______, KC_UP, _______, _______, _______, _______, _______, _______,
55 _______, _______, _______, _______, _______, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______,
56 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
57 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______),
58};
diff --git a/keyboards/maartenwut/nt660/keymaps/via/keymap.c b/keyboards/maartenwut/nt660/keymaps/via/keymap.c
new file mode 100644
index 000000000..5b8c2e342
--- /dev/null
+++ b/keyboards/maartenwut/nt660/keymaps/via/keymap.c
@@ -0,0 +1,44 @@
1/* Copyright 2020 Maarten Dekkers <maartenwut@gmail.com>
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
20[0] = LAYOUT_all(
21 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS,
22 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL,
23 KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT,
24 KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
25 KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTRL,KC_LEFT, KC_DOWN, KC_RGHT),
26[1] = LAYOUT_all(
27 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
28 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
29 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
30 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
31 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______),
32[2] = LAYOUT_all(
33 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
34 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
35 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
36 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
37 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______),
38[3] = LAYOUT_all(
39 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
40 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
41 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
42 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
43 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______),
44};
diff --git a/keyboards/maartenwut/nt660/keymaps/via/rules.mk b/keyboards/maartenwut/nt660/keymaps/via/rules.mk
new file mode 100644
index 000000000..36b7ba9cb
--- /dev/null
+++ b/keyboards/maartenwut/nt660/keymaps/via/rules.mk
@@ -0,0 +1,2 @@
1VIA_ENABLE = yes
2LTO_ENABLE = yes
diff --git a/keyboards/maartenwut/nt660/nt660.c b/keyboards/maartenwut/nt660/nt660.c
new file mode 100644
index 000000000..8ecc58ec1
--- /dev/null
+++ b/keyboards/maartenwut/nt660/nt660.c
@@ -0,0 +1,32 @@
1/* Copyright 2020 Maarten Dekkers <maartenwut@gmail.com>
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 "nt660.h"
17void matrix_init_kb(void) {
18 matrix_init_user();
19 led_init_ports();
20}
21
22void led_init_ports(void) {
23 setPinOutput(D0);
24}
25
26bool led_update_kb(led_t led_state) {
27 if(led_update_user(led_state)) {
28 writePin(D0, !led_state.caps_lock);
29 }
30
31 return true;
32}
diff --git a/keyboards/maartenwut/nt660/nt660.h b/keyboards/maartenwut/nt660/nt660.h
new file mode 100644
index 000000000..ce3d4fa62
--- /dev/null
+++ b/keyboards/maartenwut/nt660/nt660.h
@@ -0,0 +1,73 @@
1/* Copyright 2020 Maarten Dekkers <maartenwut@gmail.com>
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#pragma once
17
18#include "quantum.h"
19
20#define XXX KC_NO
21
22/* This is a shortcut to help you visually see your layout.
23 *
24 * The first section contains all of the arguments representing the physical
25 * layout of the board and position of the keys.
26 *
27 * The second converts the arguments into a two-dimensional array which
28 * represents the switch matrix.
29 */
30
31#define LAYOUT_all( \
32 k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0f, k0d, \
33 k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1f, k1d, \
34 k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2f, \
35 k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3f, \
36 k40, k41, k42, k46, k49, k4a, k4b, k4c, k4f, k4d \
37) \
38{ \
39 {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0f, k0d}, \
40 {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1f, k1d}, \
41 {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2f, XXX}, \
42 {k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3f, XXX}, \
43 {k40, k41, k42, XXX, XXX, XXX, k46, XXX, XXX, k49, k4a, k4b, k4c, k4f, k4d} \
44}
45#define LAYOUT_66_ansi( \
46 k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0f, k0d, \
47 k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1f, k1d, \
48 k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2f, \
49 k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3f, \
50 k40, k41, k42, k46, k49, k4a, k4b, k4c, k4f, k4d \
51) \
52{ \
53 {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0f, k0d}, \
54 {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1f, k1d}, \
55 {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, XXX, k2f, XXX}, \
56 {k30, XXX, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3f, XXX}, \
57 {k40, k41, k42, XXX, XXX, XXX, k46, XXX, XXX, k49, k4a, k4b, k4c, k4f, k4d} \
58}
59
60#define LAYOUT_66_iso( \
61 k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0f, k0d, \
62 k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, \
63 k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2f, \
64 k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3f, \
65 k40, k41, k42, k46, k49, k4a, k4b, k4c, k4f, k4d \
66) \
67{ \
68 {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0f, k0d}, \
69 {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, XXX, k1d}, \
70 {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2f, XXX}, \
71 {k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3f, XXX}, \
72 {k40, k41, k42, XXX, XXX, XXX, k46, XXX, XXX, k49, k4a, k4b, k4c, k4f, k4d} \
73}
diff --git a/keyboards/maartenwut/nt660/readme.md b/keyboards/maartenwut/nt660/readme.md
new file mode 100644
index 000000000..cb7b19ca5
--- /dev/null
+++ b/keyboards/maartenwut/nt660/readme.md
@@ -0,0 +1,19 @@
1# nt660
2
3A drop-in replacement PCB for the Leopold FC660M.
4
5* Keyboard Maintainer: [Maartenwut](https://github.com/Maartenwut)
6* Hardware Supported: nt660 PCB
7* Hardware Availability: [maartenwut.com](https://maartenwut.com/product/nt-660/)
8
9## Flashing
10
11In place of the DIP switches on the original PCB there is a small button. Press that to jump to the bootloader.
12
13---
14
15Make example for this keyboard (after setting up your build environment):
16
17 make maartenwut/nt660:default
18
19See 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).
diff --git a/keyboards/maartenwut/nt660/rules.mk b/keyboards/maartenwut/nt660/rules.mk
new file mode 100644
index 000000000..b633c90f0
--- /dev/null
+++ b/keyboards/maartenwut/nt660/rules.mk
@@ -0,0 +1,34 @@
1# MCU name
2MCU = atmega32u4
3
4# Bootloader selection
5# Teensy halfkay
6# Pro Micro caterina
7# Atmel DFU atmel-dfu
8# LUFA DFU lufa-dfu
9# QMK DFU qmk-dfu
10# ATmega32A bootloadHID
11# ATmega328P USBasp
12BOOTLOADER = qmk-dfu
13
14# Build Options
15# change yes to no to disable
16#
17BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
18MOUSEKEY_ENABLE = no # Mouse keys
19EXTRAKEY_ENABLE = yes # Audio control and System control
20CONSOLE_ENABLE = no # Console for debug
21COMMAND_ENABLE = no # Commands for debug and configuration
22# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
23SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
24# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
25NKRO_ENABLE = no # USB Nkey Rollover
26BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
27RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
28MIDI_ENABLE = no # MIDI support
29BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
30AUDIO_ENABLE = no # Audio output on port C6
31FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
32HD44780_ENABLE = no # Enable support for HD44780 based LCDs
33
34LAYOUTS = 66_ansi 66_iso