aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfloookay <33830863+floookay@users.noreply.github.com>2021-10-16 04:01:35 +0200
committerGitHub <noreply@github.com>2021-10-15 19:01:35 -0700
commitb0d293a841977d393c81bef443f7e28f7764ee30 (patch)
treec6cff944c3583fca5e4a6ec9fbafe645d2140b6b
parent8bb1fd04d4d4501a7bc1312e10d1fa639851fd8f (diff)
downloadqmk_firmware-b0d293a841977d393c81bef443f7e28f7764ee30.tar.gz
qmk_firmware-b0d293a841977d393c81bef443f7e28f7764ee30.zip
[Keyboard] add Pluckey (#14672)
Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
-rw-r--r--keyboards/pluckey/config.h90
-rw-r--r--keyboards/pluckey/info.json149
-rw-r--r--keyboards/pluckey/keymaps/default/keymap.c77
-rw-r--r--keyboards/pluckey/keymaps/default/readme.md4
-rw-r--r--keyboards/pluckey/pluckey.c38
-rw-r--r--keyboards/pluckey/pluckey.h46
-rw-r--r--keyboards/pluckey/readme.md19
-rw-r--r--keyboards/pluckey/rules.mk23
8 files changed, 446 insertions, 0 deletions
diff --git a/keyboards/pluckey/config.h b/keyboards/pluckey/config.h
new file mode 100644
index 000000000..295fe93a8
--- /dev/null
+++ b/keyboards/pluckey/config.h
@@ -0,0 +1,90 @@
1/*
2Copyright 2021 floookay
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 0xF100
24#define PRODUCT_ID 0x91CE
25#define DEVICE_VER 0x0001
26#define MANUFACTURER floookay
27#define PRODUCT pluckey
28
29/* key matrix size */
30// Rows are doubled-up
31#define MATRIX_ROWS 10
32#define MATRIX_COLS 7
33
34/*
35 * Keyboard Matrix Assignments
36 *
37 * COLS: AVR pins used for columns, left to right
38 * ROWS: AVR pins used for rows, top to bottom
39 * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
40 * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
41 *
42 */
43#define MATRIX_ROW_PINS { B4, F5, F6, B6, B5 }
44#define MATRIX_COL_PINS { D1, D0, D4, C6, D7, E6, F7 }
45#define UNUSED_PINS { F4, B1 }
46#define DIODE_DIRECTION COL2ROW
47
48/* encoder support */
49#define ENCODERS_PAD_A { B3 }
50#define ENCODERS_PAD_B { B2 }
51#define ENCODER_RESOLUTION 2
52#define ENCODERS_PAD_A_RIGHT { B2 }
53#define ENCODERS_PAD_B_RIGHT { B3 }
54#define ENCODER_RESOLUTION_RIGHT 2
55
56/* communication between sides */
57#define USE_SERIAL
58#define SOFT_SERIAL_PIN D2
59
60/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
61#define DEBOUNCE 5
62
63/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
64#define LOCKING_SUPPORT_ENABLE
65/* Locking resynchronize hack */
66#define LOCKING_RESYNC_ENABLE
67
68/*
69 * Feature disable options
70 * These options are also useful to firmware size reduction.
71 */
72
73/* disable debug print */
74//#define NO_DEBUG
75
76/* disable print */
77//#define NO_PRINT
78
79/* disable action features */
80//#define NO_ACTION_LAYER
81//#define NO_ACTION_TAPPING
82//#define NO_ACTION_ONESHOT
83
84/* disable these deprecated features by default */
85#define NO_ACTION_MACRO
86#define NO_ACTION_FUNCTION
87
88/* Bootmagic Lite key configuration */
89//#define BOOTMAGIC_LITE_ROW 0
90//#define BOOTMAGIC_LITE_COLUMN 0
diff --git a/keyboards/pluckey/info.json b/keyboards/pluckey/info.json
new file mode 100644
index 000000000..0a6bd1832
--- /dev/null
+++ b/keyboards/pluckey/info.json
@@ -0,0 +1,149 @@
1{
2 "keyboard_name": "pluckey",
3 "url": "https://github.com/floookay/pluckey",
4 "maintainer": "floookay",
5 "layouts": {
6 "LAYOUT": {
7 "layout": [
8 {"x":3.5, "y":0},
9 {"x":15, "y":0},
10 {"x":2.5, "y":0.125},
11 {"x":4.5, "y":0.125},
12 {"x":14, "y":0.125},
13 {"x":16, "y":0.125},
14 {"x":5.5, "y":0.25},
15 {"x":6.5, "y":0.25},
16 {"x":12, "y":0.25},
17 {"x":13, "y":0.25},
18 {"x":0, "y":0.625, "w":1.5},
19 {"x":1.5, "y":0.625},
20 {"x":17, "y":0.625},
21 {"x":18, "y":0.625, "w":1.5},
22 {"x":3.5, "y":1.0},
23 {"x":15, "y":1.0},
24 {"x":2.5, "y":1.125},
25 {"x":4.5, "y":1.125},
26 {"x":14, "y":1.125},
27 {"x":16, "y":1.125},
28 {"x":5.5, "y":1.25},
29 {"x":6.5, "y":1.25},
30 {"x":12, "y":1.25},
31 {"x":13, "y":1.25},
32 {"x":0, "y":1.625, "w":1.5},
33 {"x":1.5, "y":1.625},
34 {"x":17, "y":1.625},
35 {"x":18, "y":1.625, "w":1.5},
36 {"x":3.5, "y":2},
37 {"x":15, "y":2},
38 {"x":2.5, "y":2.125},
39 {"x":4.5, "y":2.125},
40 {"x":14, "y":2.125},
41 {"x":16, "y":2.125},
42 {"x":5.5, "y":2.25},
43 {"x":6.5, "y":2.25},
44 {"x":12, "y":2.25},
45 {"x":13, "y":2.25},
46 {"x":0, "y":2.625, "w":1.5},
47 {"x":1.5, "y":2.625},
48 {"x":17, "y":2.625},
49 {"x":18, "y":2.625, "w":1.5},
50 {"x":6.5, "y":3.25},
51 {"x":12, "y":3.25},
52 {"x":3.5, "y":3},
53 {"x":15, "y":3},
54 {"x":2.5, "y":3.125},
55 {"x":4.5, "y":3.125},
56 {"x":14, "y":3.125},
57 {"x":16, "y":3.125},
58 {"x":5.5, "y":3.25},
59 {"x":13, "y":3.25},
60 {"x":0, "y":3.625, "w":1.5},
61 {"x":1.5, "y":3.625},
62 {"x":17, "y":3.625},
63 {"x":18, "y":3.625, "w":1.5},
64 {"x":7.5, "y":3.75},
65 {"x":11, "y":3.75},
66 {"x":3.5, "y":4},
67 {"x":15, "y":4},
68 {"x":2.5, "y":4.125},
69 {"x":4.5, "y":4.125},
70 {"x":14, "y":4.125},
71 {"x":16, "y":4.125},
72 {"x":5.75, "y":4.5, "w":1.5},
73 {"x":12.25, "y":4.5, "w":1.5},
74 {"x":7.25, "y":4.75},
75 {"x":11.25, "y":4.75}
76 ]
77 },
78 "LAYOUT_ergo": {
79 "layout": [
80 {"x":3.5, "y":0},
81 {"x":15, "y":0},
82 {"x":2.5, "y":0.125},
83 {"x":4.5, "y":0.125},
84 {"x":14, "y":0.125},
85 {"x":16, "y":0.125},
86 {"x":5.5, "y":0.25},
87 {"x":6.5, "y":0.25},
88 {"x":12, "y":0.25},
89 {"x":13, "y":0.25},
90 {"x":0, "y":0.625, "w":1.5},
91 {"x":1.5, "y":0.625},
92 {"x":17, "y":0.625},
93 {"x":18, "y":0.625, "w":1.5},
94 {"x":3.5, "y":1.0},
95 {"x":15, "y":1.0},
96 {"x":2.5, "y":1.125},
97 {"x":4.5, "y":1.125},
98 {"x":14, "y":1.125},
99 {"x":16, "y":1.125},
100 {"x":5.5, "y":1.25},
101 {"x":6.5, "y":1.25, "h":1.5},
102 {"x":12, "y":1.25, "h":1.5},
103 {"x":13, "y":1.25},
104 {"x":0, "y":1.625, "w":1.5},
105 {"x":1.5, "y":1.625},
106 {"x":17, "y":1.625},
107 {"x":18, "y":1.625, "w":1.5},
108 {"x":3.5, "y":2},
109 {"x":15, "y":2},
110 {"x":2.5, "y":2.125},
111 {"x":4.5, "y":2.125},
112 {"x":14, "y":2.125},
113 {"x":16, "y":2.125},
114 {"x":5.5, "y":2.25},
115 {"x":13, "y":2.25},
116 {"x":0, "y":2.625, "w":1.5},
117 {"x":1.5, "y":2.625},
118 {"x":17, "y":2.625},
119 {"x":18, "y":2.625, "w":1.5},
120 {"x":6.5, "y":2.75, "h":1.5},
121 {"x":12, "y":2.75, "h":1.5},
122 {"x":3.5, "y":3},
123 {"x":15, "y":3},
124 {"x":2.5, "y":3.125},
125 {"x":4.5, "y":3.125},
126 {"x":14, "y":3.125},
127 {"x":16, "y":3.125},
128 {"x":5.5, "y":3.25},
129 {"x":13, "y":3.25},
130 {"x":0, "y":3.625, "w":1.5},
131 {"x":1.5, "y":3.625},
132 {"x":17, "y":3.625},
133 {"x":18, "y":3.625, "w":1.5},
134 {"x":7.5, "y":3.75},
135 {"x":11, "y":3.75},
136 {"x":3.5, "y":4},
137 {"x":15, "y":4},
138 {"x":2.5, "y":4.125},
139 {"x":4.5, "y":4.125},
140 {"x":14, "y":4.125},
141 {"x":16, "y":4.125},
142 {"x":5.75, "y":4.5, "w":1.5},
143 {"x":12.25, "y":4.5, "w":1.5},
144 {"x":7.25, "y":4.75},
145 {"x":11.25, "y":4.75}
146 ]
147 }
148 }
149}
diff --git a/keyboards/pluckey/keymaps/default/keymap.c b/keyboards/pluckey/keymaps/default/keymap.c
new file mode 100644
index 000000000..31042fc69
--- /dev/null
+++ b/keyboards/pluckey/keymaps/default/keymap.c
@@ -0,0 +1,77 @@
1/* Copyright 2021 floookay
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// Defines names for use in layer keycodes and the keymap
19enum layer_names {
20 _BASE,
21 _LOWER,
22 _RAISE,
23 _ADJUST
24};
25
26// Defines the keycodes used by our macros in process_record_user
27enum custom_keycodes {
28 M_ARROW
29};
30
31#define MO_LOW MO(_LOWER)
32#define MO_RAIS MO(_RAISE)
33#define MO_ADJU MO(_ADJUST)
34#define MO_CURR _______
35
36const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
37 /* Base */
38 [_BASE] = LAYOUT(
39 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_MINS, KC_EQL, KC_6, KC_7, KC_8, KC_9, KC_0, KC_GRV,
40 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_LBRC, KC_RBRC, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
41 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_LPRN, KC_RPRN, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
42 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LCBR, KC_HOME, KC_END, KC_RCBR, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT,
43 KC_LGUI, KC_LALT, MO_LOW, KC_SPC, KC_BSPC, KC_ENT, KC_SPC, MO_RAIS, KC_RALT, KC_MEH
44 ),
45 [_LOWER] = LAYOUT(
46 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F11, KC_F12, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_PSCR,
47 _______, _______, _______, _______, KC_PIPE, KC_UNDS, KC_LPRN, KC_RPRN, KC_PLUS, KC_PIPE, _______, _______, _______, _______,
48 _______, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_LPRN, KC_RPRN, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, _______,
49 _______, _______, _______, _______, _______, _______, M_ARROW, KC_PGUP, KC_PGDN, _______, _______, _______, _______, _______, _______, _______,
50 _______, _______, MO_CURR, _______, KC_DEL, _______, _______, MO_ADJU, _______, _______
51 ),
52 [_RAISE] = LAYOUT(
53 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_PGUP, _______, _______, _______,
54 _______, _______, _______, KC_VOLU, _______, _______, KC_LPRN, KC_RPRN, _______, KC_BTN4, KC_UP, KC_BTN5, _______, _______,
55 _______, _______, KC_MPRV, KC_MPLY, KC_MNXT, _______, KC_LPRN, KC_RPRN, KC_HOME, KC_LEFT, KC_DOWN, KC_RGHT, KC_END, _______,
56 _______, _______, _______, KC_VOLD, _______, _______, M_ARROW, KC_PGUP, KC_PGDN, _______, _______, _______, KC_PGDN, _______, _______, _______,
57 _______, _______, MO_ADJU, _______, KC_DEL, _______, _______, MO_CURR, _______, _______
58 ),
59 [_ADJUST] = LAYOUT(
60 KC_SLEP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
61 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_WH_U, _______, _______, _______,
62 _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_WH_L, KC_WH_D, KC_WH_R, _______, _______,
63 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
64 _______, _______, _______, _______, KC_CLR, _______, _______, _______, _______, _______
65 )
66};
67
68bool process_record_user(uint16_t keycode, keyrecord_t *record) {
69 switch (keycode) {
70 case M_ARROW:
71 if (record->event.pressed) {
72 SEND_STRING("->");
73 }
74 break;
75 }
76 return true;
77}
diff --git a/keyboards/pluckey/keymaps/default/readme.md b/keyboards/pluckey/keymaps/default/readme.md
new file mode 100644
index 000000000..d94d03e58
--- /dev/null
+++ b/keyboards/pluckey/keymaps/default/readme.md
@@ -0,0 +1,4 @@
1# Default keymap
2
3![keymap](https://gist.githubusercontent.com/floookay/ea7313862e407c9b5aaea3d6ed3ce233/raw/0a37fe682f76bbaa55cbc56527e4666bedbf5761/layout.png)
4[Keyboard-Layout-Editor](http://www.keyboard-layout-editor.com/#/gists/13c9d00bd0c0c9e3fe3b3d8d98672ef9) [(raw)](https://gist.github.com/floookay/13c9d00bd0c0c9e3fe3b3d8d98672ef9)
diff --git a/keyboards/pluckey/pluckey.c b/keyboards/pluckey/pluckey.c
new file mode 100644
index 000000000..d9025726f
--- /dev/null
+++ b/keyboards/pluckey/pluckey.c
@@ -0,0 +1,38 @@
1/* Copyright 2021 floookay
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 "pluckey.h"
18
19#ifdef ENCODER_ENABLE
20bool encoder_update_kb(uint8_t index, bool clockwise) {
21 if (!encoder_update_user(index, clockwise)) { return false; }
22 if (index == 0) {
23 if (clockwise) {
24 tap_code_delay(KC_VOLU, 10);
25 } else {
26 tap_code_delay(KC_VOLD, 10);
27 }
28 }
29 else if (index == 1) {
30 if (clockwise) {
31 tap_code(KC_WH_U);
32 } else {
33 tap_code(KC_WH_D);
34 }
35 }
36 return true;
37}
38#endif
diff --git a/keyboards/pluckey/pluckey.h b/keyboards/pluckey/pluckey.h
new file mode 100644
index 000000000..628a89baa
--- /dev/null
+++ b/keyboards/pluckey/pluckey.h
@@ -0,0 +1,46 @@
1/* Copyright 2021 floookay
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/* This is a shortcut to help you visually see your layout.
22 *
23 * The first section contains all of the arguments representing the physical
24 * layout of the board and position of the keys.
25 *
26 * The second converts the arguments into a two-dimensional array which
27 * represents the switch matrix.
28 */
29#define LAYOUT( \
30 l00, l01, l02, l03, l04, l05, l06, r00, r01, r02, r03, r04, r05, r06, \
31 l10, l11, l12, l13, l14, l15, l16, r10, r11, r12, r13, r14, r15, r16, \
32 l20, l21, l22, l23, l24, l25, l26, r20, r21, r22, r23, r24, r25, r26, \
33 l30, l31, l32, l33, l34, l35, l36, l41, r45, r30, r31, r32, r33, r34, r35, r36, \
34 l42, l43, l44, l45, l46, r40, r41, r42, r43, r44 \
35){ \
36 { l00, l01, l02, l03, l04, l05, l06 }, \
37 { l10, l11, l12, l13, l14, l15, l16 }, \
38 { l20, l21, l22, l23, l24, l25, l26 }, \
39 { l30, l31, l32, l33, l34, l35, l36 }, \
40 { KC_NO, l41, l42, l43, l44, l45, l46 }, \
41 { r06, r05, r04, r03, r02, r01, r00 }, \
42 { r16, r15, r14, r13, r12, r11, r10 }, \
43 { r26, r25, r24, r23, r22, r21, r20 }, \
44 { r36, r35, r34, r33, r32, r31, r30 }, \
45 { KC_NO, r45, r44, r43, r42, r41, r40 } \
46}
diff --git a/keyboards/pluckey/readme.md b/keyboards/pluckey/readme.md
new file mode 100644
index 000000000..b0a1af99b
--- /dev/null
+++ b/keyboards/pluckey/readme.md
@@ -0,0 +1,19 @@
1# Pluckey
2
3![pluckey](https://gist.githubusercontent.com/floookay/ea7313862e407c9b5aaea3d6ed3ce233/raw/1757078b1adf7ac4d51d74f445107bdb46e013a3/sandwich%2520angle.jpg)
4
5The pluckey is an ergodox like split keyboard with moderate columnal stagger and a horizontal space key.
6
7* Keyboard Maintainer: [floookay](https://github.com/floookay)
8* Hardware Supported: pluckey pcbs with pro micro controllers
9* Hardware Availability: [pcb &amp; case files](https://github.com/floookay/pluckey)
10
11Make example for this keyboard (after setting up your build environment):
12
13 make pluckey:default
14
15Flashing example for this keyboard:
16
17 make pluckey:default:flash
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/pluckey/rules.mk b/keyboards/pluckey/rules.mk
new file mode 100644
index 000000000..4f4954434
--- /dev/null
+++ b/keyboards/pluckey/rules.mk
@@ -0,0 +1,23 @@
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 = yes # Enable Bootmagic Lite
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 = no # USB Nkey Rollover
19BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
20RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
21AUDIO_ENABLE = no # Audio output
22ENCODER_ENABLE = yes
23SPLIT_KEYBOARD = yes