aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorQMK Bot <hello@qmk.fm>2021-01-24 21:55:02 +0000
committerQMK Bot <hello@qmk.fm>2021-01-24 21:55:02 +0000
commitdde9dc7b60267c7f8fe69bfc27a6062c7036dcd2 (patch)
tree17bdd111848793264e56738a19040ae242454786
parent949fb1a91c4fc934ecbedcd771c685dc8c8d9e09 (diff)
parentdeea6a98267e3b9bf793d9a64bfd586a07ef5c48 (diff)
downloadqmk_firmware-dde9dc7b60267c7f8fe69bfc27a6062c7036dcd2.tar.gz
qmk_firmware-dde9dc7b60267c7f8fe69bfc27a6062c7036dcd2.zip
Merge remote-tracking branch 'origin/master' into develop
-rw-r--r--keyboards/jones/readme.md24
-rw-r--r--keyboards/jones/rules.mk1
-rw-r--r--keyboards/jones/v03/config.h165
-rw-r--r--keyboards/jones/v03/info.json35
-rw-r--r--keyboards/jones/v03/keymaps/default/keymap.c27
-rw-r--r--keyboards/jones/v03/keymaps/default/readme.md1
-rw-r--r--keyboards/jones/v03/keymaps/default_jp/config.h23
-rw-r--r--keyboards/jones/v03/keymaps/default_jp/keymap.c343
-rw-r--r--keyboards/jones/v03/keymaps/default_jp/readme.md1
-rw-r--r--keyboards/jones/v03/keymaps/default_jp/rules.mk1
-rw-r--r--keyboards/jones/v03/matrix.c99
-rw-r--r--keyboards/jones/v03/readme.md24
-rw-r--r--keyboards/jones/v03/rules.mk29
-rw-r--r--keyboards/jones/v03/v03.c17
-rw-r--r--keyboards/jones/v03/v03.h105
-rw-r--r--keyboards/jones/v03_1/config.h166
-rw-r--r--keyboards/jones/v03_1/info.json35
-rw-r--r--keyboards/jones/v03_1/keymaps/default/keymap.c26
-rw-r--r--keyboards/jones/v03_1/keymaps/default/readme.md1
-rw-r--r--keyboards/jones/v03_1/keymaps/default_ansi/config.h26
-rw-r--r--keyboards/jones/v03_1/keymaps/default_ansi/keymap.c362
-rw-r--r--keyboards/jones/v03_1/keymaps/default_ansi/readme.md1
-rw-r--r--keyboards/jones/v03_1/keymaps/default_ansi/rules.mk1
-rw-r--r--keyboards/jones/v03_1/keymaps/default_jp/config.h26
-rw-r--r--keyboards/jones/v03_1/keymaps/default_jp/keymap.c364
-rw-r--r--keyboards/jones/v03_1/keymaps/default_jp/readme.md1
-rw-r--r--keyboards/jones/v03_1/keymaps/default_jp/rules.mk1
-rw-r--r--keyboards/jones/v03_1/matrix.c99
-rw-r--r--keyboards/jones/v03_1/readme.md24
-rw-r--r--keyboards/jones/v03_1/rules.mk29
-rw-r--r--keyboards/jones/v03_1/v03_1.c27
-rw-r--r--keyboards/jones/v03_1/v03_1.h105
32 files changed, 2189 insertions, 0 deletions
diff --git a/keyboards/jones/readme.md b/keyboards/jones/readme.md
new file mode 100644
index 000000000..180c12e18
--- /dev/null
+++ b/keyboards/jones/readme.md
@@ -0,0 +1,24 @@
1# Jones
2
3![Jones, ANSI style](https://github.com/jpskenn/Jones/raw/master/assets/IMG_2204.jpeg)
4
5![Jones, JP style](https://github.com/jpskenn/Jones/raw/master/assets/DSC_7189.jpeg)
6
7A 60% keyboard combined with Ortho-Linear and Row-staggered. It has gapless R2-R3 row.
8GH60 case compatible PCB and keyplate.
9
10* Keyboard Maintainer: [jpskenn](https://github.com/jpskenn)
11* Hardware Supported: Jones PCB, Keyplate
12* Hardware Availability: [GitHub](https://github.com/jpskenn/Jones), [BOOTH](https://jpskenn.booth.pm)
13
14Make example for this keyboard (after setting up your build environment):
15
16 make jones/v03_1:default_ansi
17
18Flashing example for this keyboard ([using the command line](https://docs.qmk.fm/#/newbs_flashing?id=flash-your-keyboard-from-the-command-line)):
19
20 make jones/v03_1:default_ansi:flash
21
22To reset the keyboard into bootloader mode, press the reset switch on the underside.
23
24See 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/jones/rules.mk b/keyboards/jones/rules.mk
new file mode 100644
index 000000000..6b4943035
--- /dev/null
+++ b/keyboards/jones/rules.mk
@@ -0,0 +1 @@
DEFAULT_FOLDER = jones/v03_1
diff --git a/keyboards/jones/v03/config.h b/keyboards/jones/v03/config.h
new file mode 100644
index 000000000..3683a43dd
--- /dev/null
+++ b/keyboards/jones/v03/config.h
@@ -0,0 +1,165 @@
1/*
2Copyright 2020 Takeshi Nishio
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 0xFEED
24#define PRODUCT_ID 0x175A
25#define DEVICE_VER 0x0030
26#define MANUFACTURER jpskenn
27#define PRODUCT Jones
28
29/* key matrix size */
30// Same size for Jones' custom Round-Robin matrix.
31#define MATRIX_ROWS 11
32#define MATRIX_COLS 11
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// Same pins for Jones' custom Round-Robin matrix.
45#define MATRIX_ROW_PINS { D4, D7, C7, F1, F4, F5, D6, D5, E6, B0, B1 }
46#define MATRIX_COL_PINS { D4, D7, C7, F1, F4, F5, D6, D5, E6, B0, B1 }
47#define UNUSED_PINS
48
49/* COL2ROW, ROW2COL*/
50// No need to define DIODE_DIRECTION for Jones' custom Round-Robin matrix.
51//#define DIODE_DIRECTION COL2ROW
52
53/* Rotary Encoder */
54#define ENCODERS_PAD_A { F6, B3 }
55#define ENCODERS_PAD_B { F7, B2 }
56#define ENCODER_RESOLUTION 4 //the default & suggested is 4
57
58/* Audio */
59#ifdef AUDIO_ENABLE
60 #define C6_AUDIO
61 #define B6_AUDIO // 2nd pin for simultaneous audio.
62 #define AUDIO_CLICKY
63#endif
64
65/*
66 * Split Keyboard specific options, make sure you have 'SPLIT_KEYBOARD = yes' in your rules.mk, and define SOFT_SERIAL_PIN.
67 */
68//#define SOFT_SERIAL_PIN D0 // or D1, D2, D3, E6
69
70// #define BACKLIGHT_PIN B7
71// #define BACKLIGHT_BREATHING
72// #define BACKLIGHT_LEVELS 3
73
74#define RGB_DI_PIN B7
75#ifdef RGB_DI_PIN
76 #define RGBLED_NUM 6 // Left(4) + Right(2)
77 #define RGBLIGHT_HUE_STEP 8
78 #define RGBLIGHT_SAT_STEP 8
79 #define RGBLIGHT_VAL_STEP 8
80 #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
81 // #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
82 /*== Lighting Layers ==*/
83 #define RGBLIGHT_LAYERS
84 // #define RGBLIGHT_MAX_LAYERS 2
85 #define RGBLIGHT_LAYERS_OVERRIDE_RGB_OFF // Overriding RGB Lighting on/off status
86 /*== all animations enable ==*/
87 // #define RGBLIGHT_ANIMATIONS
88 /*== or choose animations ==*/
89 // #define RGBLIGHT_EFFECT_BREATHING
90 // #define RGBLIGHT_EFFECT_RAINBOW_MOOD
91 #define RGBLIGHT_EFFECT_RAINBOW_SWIRL
92 // #define RGBLIGHT_EFFECT_SNAKE
93 #define RGBLIGHT_EFFECT_KNIGHT
94 // #define RGBLIGHT_EFFECT_CHRISTMAS
95 // #define RGBLIGHT_EFFECT_STATIC_GRADIENT
96 // #define RGBLIGHT_EFFECT_RGB_TEST
97 // #define RGBLIGHT_EFFECT_ALTERNATING
98 // /*== customize breathing effect ==*/
99 // /*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/
100 // #define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64
101 // /*==== use exp() and sin() ====*/
102 // #define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7
103 // #define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255
104#endif
105
106/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
107#define DEBOUNCE 5
108
109/* define if matrix has ghost (lacks anti-ghosting diodes) */
110//#define MATRIX_HAS_GHOST
111
112/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
113// #define LOCKING_SUPPORT_ENABLE
114/* Locking resynchronize hack */
115// #define LOCKING_RESYNC_ENABLE
116
117/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
118 * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
119 */
120// #define GRAVE_ESC_CTRL_OVERRIDE
121
122/*
123 * Force NKRO
124 *
125 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
126 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
127 * makefile for this to work.)
128 *
129 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
130 * until the next keyboard reset.
131 *
132 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
133 * fully operational during normal computer usage.
134 *
135 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
136 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
137 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
138 * power-up.
139 *
140 */
141//#define FORCE_NKRO
142
143/*
144 * Feature disable options
145 * These options are also useful to firmware size reduction.
146 */
147
148/* disable debug print */
149//#define NO_DEBUG
150
151/* disable print */
152//#define NO_PRINT
153
154/* disable action features */
155//#define NO_ACTION_LAYER
156//#define NO_ACTION_TAPPING
157//#define NO_ACTION_ONESHOT
158
159/* disable these deprecated features by default */
160#define NO_ACTION_MACRO
161#define NO_ACTION_FUNCTION
162
163/* Bootmagic Lite key configuration */
164// #define BOOTMAGIC_LITE_ROW 0
165// #define BOOTMAGIC_LITE_COLUMN 0
diff --git a/keyboards/jones/v03/info.json b/keyboards/jones/v03/info.json
new file mode 100644
index 000000000..eaee5a691
--- /dev/null
+++ b/keyboards/jones/v03/info.json
@@ -0,0 +1,35 @@
1{
2 "keyboard_name": "Jones",
3 "url": "https://github.com/jpskenn/Jones",
4 "maintainer": "jpskenn",
5 "width": 15,
6 "height": 5,
7 "layouts": {
8 "LAYOUT_ansi": {
9 "layout": [
10 {"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"", "x":7, "y":0}, {"label":"", "x":8, "y":0}, {"label":"", "x":9, "y":0}, {"label":"", "x":10, "y":0}, {"label":"", "x":11, "y":0}, {"label":"", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"~", "x":14, "y":0},
11 {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"Backspace", "x":11.5, "y":1, "w":1.5}, {"label":"{", "x":13, "y":1}, {"label":"}", "x":14, "y":1},
12 {"label":"Ctrl", "x":0.25, "y":2, "w":1.25}, {"label":"A", "x":1.5, "y":2}, {"label":"S", "x":2.5, "y":2}, {"label":"D", "x":3.5, "y":2}, {"label":"F", "x":4.5, "y":2}, {"label":"G", "x":5.5, "y":2}, {"label":"H", "x":6.5, "y":2}, {"label":"J", "x":7.5, "y":2}, {"label":"K", "x":8.5, "y":2}, {"label":"L", "x":9.5, "y":2}, {"label":":", "x":10.5, "y":2}, {"label":"Enter", "x":11.5, "y":2, "w":2.25}, {"label":"\u201d", "x":13.75, "y":2},
13 {"label":"Shift", "x":0.25, "y":3, "w":1.75}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"Shift", "x":12, "y":3}, {"label":"\u2191", "x":13, "y":3}, {"label":"Fn", "x":14, "y":3},
14 {"label":"Rotary", "x":0, "y":4}, {"label":"Caps", "x":1, "y":4}, {"label":"Opt", "x":2, "y":4, "w":1.25}, {"label":"Cmd", "x":3.25, "y":4, "w":1.25}, {"label":"Space & Shift", "x":4.5, "y":4, "w":2}, {"label":"Space & Raise", "x":6.5, "y":4, "w":2}, {"label":"Cmd", "x":8.5, "y":4, "w":1.25}, {"label":"Opt", "x":9.75, "y":4, "w":1.25}, {"label":"Ctrl", "x":11, "y":4}, {"label":"\u2190", "x":12, "y":4}, {"label":"\u2193", "x":13, "y":4}, {"label":"\u2192", "x":14, "y":4}
15 ]
16 },
17 "LAYOUT_jp": {
18 "layout": [
19 {"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"\"", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"&", "x":6, "y":0}, {"label":"'", "x":7, "y":0}, {"label":"(", "x":8, "y":0}, {"label":")", "x":9, "y":0}, {"label":"", "x":10, "y":0}, {"label":"=", "x":11, "y":0}, {"label":"BS", "x":12, "y":0}, {"label":"~", "x":13, "y":0}, {"label":"|", "x":14, "y":0},
20 {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"Enter", "x":11.5, "y":1, "w":1.25, "h":2, "r":180, "rx":12.125, "ry":1.5}, {"label":"`", "x":12.75, "y":1}, {"label":"{", "x":13.75, "y":1},
21 {"label":"Ctrl", "x":0.25, "y":2, "w":1.25}, {"label":"A", "x":1.5, "y":2}, {"label":"S", "x":2.5, "y":2}, {"label":"D", "x":3.5, "y":2}, {"label":"F", "x":4.5, "y":2}, {"label":"G", "x":5.5, "y":2}, {"label":"H", "x":6.5, "y":2}, {"label":"J", "x":7.5, "y":2}, {"label":"K", "x":8.5, "y":2}, {"label":"L", "x":9.5, "y":2}, {"label":"+", "x":10.5, "y":2}, {"label":"*", "x":13, "y":2}, {"label":"}", "x":14, "y":2},
22 {"label":"Shift", "x":0.25, "y":3, "w":1.75}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"_", "x":12, "y":3}, {"label":"\u2191", "x":13, "y":3}, {"label":"", "x":14, "y":3},
23 {"label":"Rotary", "x":0, "y":4}, {"label":"\u7530", "x":1, "y":4}, {"label":"Alt", "x":2, "y":4, "w":1.25}, {"label":"\u7121\u5909\u63db", "x":3.25, "y":4}, {"label":"Space", "x":4.25, "y":4, "w":2.25}, {"label":"Space", "x":6.5, "y":4, "w":2}, {"label":"\u5909\u63db", "x":8.5, "y":4, "w":1.25}, {"label":"\u30ab\u30ca", "x":9.75, "y":4, "w":1.25}, {"label":"\u76ee", "x":11, "y":4}, {"label":"\u2190", "x":12, "y":4}, {"label":"\u2193", "x":13, "y":4}, {"label":"\u2192", "x":14, "y":4}]
24 },
25 "LAYOUT_all": {
26 "layout": [
27 {"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"", "x":7, "y":0}, {"label":"", "x":8, "y":0}, {"label":"", "x":9, "y":0}, {"label":"", "x":10, "y":0}, {"label":"", "x":11, "y":0}, {"label":"", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"~", "x":14, "y":0},
28 {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"Backspace", "x":11.5, "y":1, "w":1.5}, {"label":"{", "x":13, "y":1}, {"label":"}", "x":14, "y":1},
29 {"label":"Ctrl", "x":0.25, "y":2, "w":1.25}, {"label":"A", "x":1.5, "y":2}, {"label":"S", "x":2.5, "y":2}, {"label":"D", "x":3.5, "y":2}, {"label":"F", "x":4.5, "y":2}, {"label":"G", "x":5.5, "y":2}, {"label":"H", "x":6.5, "y":2}, {"label":"J", "x":7.5, "y":2}, {"label":"K", "x":8.5, "y":2}, {"label":"L", "x":9.5, "y":2}, {"label":":", "x":10.5, "y":2}, {"label":"Enter", "x":11.5, "y":2, "w":1.5}, {"label":"\u201d", "x":13, "y":2}, {"label":"\u201d", "x":14, "y":2},
30 {"label":"Shift", "x":0.25, "y":3, "w":1.75}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"Shift", "x":12, "y":3}, {"label":"\u2191", "x":13, "y":3}, {"label":"Fn", "x":14, "y":3},
31 {"label":"Rotary", "x":0, "y":4}, {"label":"Caps", "x":1, "y":4}, {"label":"Opt", "x":2, "y":4, "w":1.25}, {"label":"Cmd", "x":3.25, "y":4, "w":1.25}, {"label":"Space & Shift", "x":4.5, "y":4, "w":2}, {"label":"Space & Raise", "x":6.5, "y":4, "w":2}, {"label":"Cmd", "x":8.5, "y":4, "w":1.25}, {"label":"Opt", "x":9.75, "y":4, "w":1.25}, {"label":"Ctrl", "x":11, "y":4}, {"label":"\u2190", "x":12, "y":4}, {"label":"\u2193", "x":13, "y":4}, {"label":"\u2192", "x":14, "y":4}
32 ]
33 }
34 }
35}
diff --git a/keyboards/jones/v03/keymaps/default/keymap.c b/keyboards/jones/v03/keymaps/default/keymap.c
new file mode 100644
index 000000000..05545c537
--- /dev/null
+++ b/keyboards/jones/v03/keymaps/default/keymap.c
@@ -0,0 +1,27 @@
1/* Copyright 2020 Takeshi Nishio
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#include "keymap_jp.h"
18
19const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
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, JP_MINS,KC_BSPC,JP_CIRC,JP_YEN,
22 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, XXXXXXX, JP_AT, JP_LBRC,
23 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, KC_ENT, JP_COLN,JP_RBRC,
24 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM,JP_DOT, JP_SLSH,JP_BSLS,KC_UP, XXXXXXX,
25 KC_MUTE,KC_LALT,KC_LGUI,KC_LANG2, KC_SPC, KC_SPC, KC_LANG1,KC_RGUI,KC_RALT,KC_LEFT,KC_DOWN,KC_RGHT
26 )
27}; \ No newline at end of file
diff --git a/keyboards/jones/v03/keymaps/default/readme.md b/keyboards/jones/v03/keymaps/default/readme.md
new file mode 100644
index 000000000..a23bc4c15
--- /dev/null
+++ b/keyboards/jones/v03/keymaps/default/readme.md
@@ -0,0 +1 @@
# Defalut keymap for Jones
diff --git a/keyboards/jones/v03/keymaps/default_jp/config.h b/keyboards/jones/v03/keymaps/default_jp/config.h
new file mode 100644
index 000000000..aa06121c1
--- /dev/null
+++ b/keyboards/jones/v03/keymaps/default_jp/config.h
@@ -0,0 +1,23 @@
1/* Copyright 2020 Takeshi Nishio
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// double tap to toggle
20#define TAPPING_TOGGLE 2
21
22// time for long press
23#define TAPPING_TERM 200
diff --git a/keyboards/jones/v03/keymaps/default_jp/keymap.c b/keyboards/jones/v03/keymaps/default_jp/keymap.c
new file mode 100644
index 000000000..d1a2a7abf
--- /dev/null
+++ b/keyboards/jones/v03/keymaps/default_jp/keymap.c
@@ -0,0 +1,343 @@
1/* Copyright 2020 Takeshi Nishio
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#include "keymap_jp.h"
18
19// Defines names for use in layer keycodes and the keymap
20enum layer_number {
21 _MAC = 0,
22 _WIN,
23 _NUM,
24 _LOWER,
25 _RAISE,
26 _NUM_RAISE,
27 _ADJUST
28};
29
30// Tap Dance
31enum tap_dances{
32 TD_LSFT_CAPS = 0,
33 TD_ESC_NUM,
34};
35
36// Tap Dance state
37enum {
38 SINGLE_TAP = 1,
39 DOUBLE_TAP,
40 TRIPLE_TAP,
41 TAP_HOLD,
42};
43
44// Declare the functions to be used with your tap dance key(s)
45// Function associated with all tap dances
46uint8_t cur_dance(qk_tap_dance_state_t *state);
47// Functions associated with individual tap dances
48void ql_finished(qk_tap_dance_state_t *state, void *user_data);
49void ql_reset(qk_tap_dance_state_t *state, void *user_data);
50
51// Tap Dance definitions
52qk_tap_dance_action_t tap_dance_actions[] = {
53 [TD_LSFT_CAPS] = ACTION_TAP_DANCE_DOUBLE(KC_LSFT, KC_CAPS),
54 [TD_ESC_NUM] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, ql_finished, ql_reset, 275),
55};
56
57// Defines the keycodes used by our macros in process_record_user
58enum custom_keycodes {
59 MAC = SAFE_RANGE,
60 WIN,
61};
62
63// Key Macro
64#define ESC_NUM TD(TD_ESC_NUM)
65#define S_CAP TD(TD_LSFT_CAPS)
66#define SP_RAI LT(_RAISE, KC_SPC)
67#define SP_NRAI LT(_NUM_RAISE, KC_SPC)
68#define SP_SFT MT(MOD_LSFT, KC_SPC)
69#define S_BSLS RSFT_T(JP_BSLS)
70#define C_SLSH RCTL_T(JP_SLSH)
71#define CT_E LCTL(KC_E)
72#define CT_A LCTL(KC_A)
73#define ALT_GRV LALT(KC_GRV)
74#define LOWER MO(_LOWER)
75#define NUM TG(_NUM)
76
77
78const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
79 [_MAC] = LAYOUT_jp(
80 ESC_NUM,KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS,KC_BSPC,JP_CIRC,JP_YEN,
81 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_AT, JP_LBRC,
82 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, KC_ENT, JP_COLN,JP_RBRC,
83 S_CAP, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM,JP_DOT, C_SLSH, S_BSLS, KC_UP, LOWER,
84 KC_MUTE,KC_LALT,KC_LGUI,KC_LANG2, SP_SFT, SP_RAI, KC_LANG1,KC_RGUI,KC_RALT,KC_LEFT,KC_DOWN,KC_RGHT
85 ),
86 [_WIN] = LAYOUT_jp(
87 _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
88 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,
89 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,
90 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
91 _______,KC_LGUI,KC_LALT,JP_MHEN, _______, _______, JP_HENK,JP_KANA,KC_APP, _______,_______,_______
92 ),
93 [_NUM] = LAYOUT_jp(
94 _______,_______,_______,_______,_______,_______,_______,XXXXXXX,KC_PSLS,KC_PSLS,KC_PAST,_______,_______,_______,_______,
95 _______, _______,_______,_______,_______,_______,_______,KC_P7, KC_P8, KC_P9, KC_PPLS, _______,_______,
96 _______, _______,_______,_______,_______,_______,_______,KC_P4, KC_P5, KC_P6, XXXXXXX,_______, _______,_______,
97 _______, _______,_______,_______,_______,_______,_______,KC_P1, KC_P2, KC_P3, KC_PENT,_______,_______,_______,
98 _______,_______,_______,_______, _______, SP_NRAI, KC_P0, KC_PDOT,_______,_______,_______,_______
99 ),
100 [_LOWER] = LAYOUT_jp(
101 KC_PAUS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
102 KC_PSCR, _______,_______,_______,_______,_______,_______,_______,_______,_______,KC_HOME, KC_END, KC_VOLU,
103 _______, _______,_______,_______,_______,_______,_______,_______,_______,KC_PGUP,KC_LEFT,KC_RGHT, _______,KC_VOLD,
104 _______, _______,_______,_______,_______,_______,_______,_______,_______,KC_PGDN,KC_DOWN,_______,KC_PGUP,_______,
105 _______,_______,_______,_______, _______, _______, _______,_______,_______,KC_HOME,KC_PGDN,KC_END
106 ),
107 [_RAISE] = LAYOUT_jp(
108 KC_PAUS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
109 KC_PSCR, _______,_______,CT_E, _______,_______,_______,_______,_______,_______,KC_PGUP, _______,_______,
110 _______, CT_A, _______,KC_DEL, KC_RGHT,KC_ESC, KC_LEFT,KC_DOWN,KC_UP, KC_RGHT,_______,_______, _______,_______,
111 _______, _______,_______,_______,_______,KC_LEFT,KC_PGDN,KC_ENT, _______,KC_MRWD,KC_MFFD,_______,KC_PGUP,_______,
112 _______,_______,_______,_______, _______, _______, _______,_______,_______,KC_HOME,KC_PGDN,KC_END
113 ),
114 [_NUM_RAISE] = LAYOUT_jp(
115 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS,KC_BSPC,JP_CIRC,JP_YEN,
116 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_AT, JP_LBRC,
117 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, KC_ENT, JP_COLN,JP_RBRC,
118 S_CAP, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM,JP_DOT, C_SLSH, S_BSLS, KC_UP, _______,
119 _______,_______,_______,_______, _______, _______, _______,_______,_______,_______,_______,_______
120 ),
121 [_ADJUST] = LAYOUT_jp(
122 _______,RGB_HUI,RGB_SAI,RGB_VAI,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
123 _______, _______,WIN, _______,RESET, _______,RGB_HUI,RGB_SAI,RGB_VAI,_______,RGB_RMOD, _______,_______,
124 _______, _______,_______,_______,_______,_______,RGB_HUD,RGB_SAD,RGB_VAD,RGB_TOG,RGB_MOD,_______, _______,_______,
125 _______, _______,_______,_______,_______,_______,NUM, MAC, _______,_______,_______,_______,_______,_______,
126 _______,_______,_______,_______, _______, _______, _______,_______,_______,_______,_______,_______
127 )
128};
129
130#if defined(AUDIO_ENABLE) && defined(MUSIC_MAP)
131const uint8_t music_map[MATRIX_ROWS][MATRIX_COLS] = LAYOUT_jp(
132 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65,
133 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50,
134 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
135 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
136 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11
137);
138#endif
139
140bool process_record_user(uint16_t keycode, keyrecord_t *record) {
141switch (keycode) {
142 case MAC: // Change default ayer --> Write to EEPROM
143 if (record->event.pressed) {
144 set_single_persistent_default_layer(_MAC);
145 }
146 return false;
147 break;
148 case WIN: // Change default ayer --> Write to EEPROM
149 if (record->event.pressed) {
150 set_single_persistent_default_layer(_WIN);
151 }
152 return false;
153 break;
154 default:
155 break;
156 }
157 return true;
158}
159
160//------------------------------------------------------------------------------
161// RGB Light settings
162#ifdef RGBLIGHT_LAYERS
163
164// for Default layer (= Base layer)
165const rgblight_segment_t PROGMEM my_mac_layer[] = RGBLIGHT_LAYER_SEGMENTS(
166 {0, 1, HSV_WHITE}
167);
168const rgblight_segment_t PROGMEM my_win_layer[] = RGBLIGHT_LAYER_SEGMENTS(
169 {0, 1, HSV_BLUE}
170);
171const rgblight_segment_t PROGMEM my_num_layer[] = RGBLIGHT_LAYER_SEGMENTS(
172 {0, 1, HSV_YELLOW}
173);
174
175// for temporal layer
176const rgblight_segment_t PROGMEM my_caps_layer[] = RGBLIGHT_LAYER_SEGMENTS(
177 {1, 1, HSV_MAGENTA}
178);
179
180const rgblight_segment_t PROGMEM my_lower_layer[] = RGBLIGHT_LAYER_SEGMENTS(
181 {1, 1, HSV_GREEN}
182);
183
184const rgblight_segment_t PROGMEM my_raise_layer[] = RGBLIGHT_LAYER_SEGMENTS(
185 {1, 1, HSV_CYAN}
186);
187
188const rgblight_segment_t PROGMEM my_num_raise_layer[] = RGBLIGHT_LAYER_SEGMENTS(
189 {1, 1, HSV_GOLD}
190);
191
192const rgblight_segment_t PROGMEM my_adjust_layer[] = RGBLIGHT_LAYER_SEGMENTS(
193 {1, 1, HSV_RED}
194);
195
196// Define the array of layers. Later layers take precedence
197const rgblight_segment_t* const PROGMEM my_rgb_layers[] = RGBLIGHT_LAYERS_LIST(
198 my_mac_layer,
199 my_win_layer,
200 my_num_layer,
201 my_caps_layer,
202 my_lower_layer,
203 my_raise_layer,
204 my_num_raise_layer,
205 my_adjust_layer
206);
207
208void keyboard_post_init_user(void) {
209 // Enable the LED layers
210 rgblight_layers = my_rgb_layers;
211}
212
213// Enabling and disabling lighting layers
214layer_state_t layer_state_set_user(layer_state_t state) {
215 state = update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
216
217 rgblight_set_layer_state(2, layer_state_cmp(state, _NUM));
218 rgblight_set_layer_state(4, layer_state_cmp(state, _LOWER));
219 rgblight_set_layer_state(5, layer_state_cmp(state, _RAISE));
220 rgblight_set_layer_state(6, layer_state_cmp(state, _NUM_RAISE));
221 rgblight_set_layer_state(7, layer_state_cmp(state, _ADJUST));
222
223 return state;
224}
225
226// Enabling and disabling lighting layers for default layer
227layer_state_t default_layer_state_set_user(layer_state_t state) {
228 rgblight_set_layer_state(0, layer_state_cmp(state, _MAC));
229 rgblight_set_layer_state(1, layer_state_cmp(state, _WIN));
230 rgblight_set_layer_state(2, layer_state_cmp(state, _NUM));
231
232 return state;
233}
234
235bool led_update_user(led_t led_state) {
236 rgblight_set_layer_state(3, led_state.caps_lock);
237 return true;
238}
239#endif
240
241
242//------------------------------------------------------------------------------
243// Rotary Encoder
244void encoder_update_user(uint8_t index, bool clockwise) {
245 if (index == 0) { /* First encoder, Right side */
246 if (clockwise) {
247 tap_code(KC_VOLD);
248 } else {
249 tap_code(KC_VOLU);
250 }
251 }
252 if (index == 1) { /* Second encoder, Left side */
253 if (clockwise) {
254 tap_code(KC_VOLD);
255 } else {
256 tap_code(KC_VOLU);
257 }
258 }
259}
260
261
262//------------------------------------------------------------------------------
263// Tap Dance function
264
265
266typedef struct {
267 bool is_press_action;
268 uint8_t state;
269} tap;
270
271// Determine the current tap dance state
272uint8_t cur_dance(qk_tap_dance_state_t *state) {
273 if (state->count == 1) {
274 if (!state->pressed) {
275 return SINGLE_TAP;
276 } else {
277 return TAP_HOLD;
278 }
279 } else if (state->count == 2) {
280 if (!state->pressed) {
281 return DOUBLE_TAP;
282 } else {
283 return TAP_HOLD;
284 }
285 } else if (state->count == 3) {
286 if (!state->pressed) {
287 return TRIPLE_TAP;
288 } else {
289 return TAP_HOLD;
290 }
291 } else {
292 return 8; // Magic number. At some point this method will expand to work for more presses
293 }
294}
295
296// Initialize tap structure associated with example tap dance key
297static tap ql_tap_state = {
298 .is_press_action = true,
299 .state = 0
300};
301
302// Functions that control what our tap dance key does
303void ql_finished(qk_tap_dance_state_t *state, void *user_data) {
304 ql_tap_state.state = cur_dance(state);
305 switch(state->keycode) {
306 case TD(TD_ESC_NUM): // ESC key action
307 switch (ql_tap_state.state) {
308 case SINGLE_TAP:
309 case DOUBLE_TAP:
310 // ESC
311 tap_code(KC_ESC);
312 break;
313 case TAP_HOLD:
314 // temporal layer change
315 layer_on(_NUM);
316 break;
317 case TRIPLE_TAP:
318 // toggle layer
319 // Check to see if the layer is already set
320 if (layer_state_is(_NUM)) {
321 // If already set, then switch it off
322 layer_off(_NUM);
323 } else {
324 // If not already set, then switch the layer on
325 layer_on(_NUM);
326 }
327 break;
328 }
329 break;
330 }
331}
332
333void ql_reset(qk_tap_dance_state_t *state, void *user_data) {
334 switch(state->keycode) {
335 case TD(TD_ESC_NUM):
336 // If the key was held down and now is released then switch off the layer
337 if (ql_tap_state.state == TAP_HOLD) {
338 layer_off(_NUM);
339 }
340 ql_tap_state.state = 0;
341 break;
342 }
343}
diff --git a/keyboards/jones/v03/keymaps/default_jp/readme.md b/keyboards/jones/v03/keymaps/default_jp/readme.md
new file mode 100644
index 000000000..a5d679aef
--- /dev/null
+++ b/keyboards/jones/v03/keymaps/default_jp/readme.md
@@ -0,0 +1 @@
# Default JP-style keymap for Jones
diff --git a/keyboards/jones/v03/keymaps/default_jp/rules.mk b/keyboards/jones/v03/keymaps/default_jp/rules.mk
new file mode 100644
index 000000000..d371e96a0
--- /dev/null
+++ b/keyboards/jones/v03/keymaps/default_jp/rules.mk
@@ -0,0 +1 @@
TAP_DANCE_ENABLE = yes # Enable Tap Dance \ No newline at end of file
diff --git a/keyboards/jones/v03/matrix.c b/keyboards/jones/v03/matrix.c
new file mode 100644
index 000000000..9f3e76f93
--- /dev/null
+++ b/keyboards/jones/v03/matrix.c
@@ -0,0 +1,99 @@
1/*
2Copyright 2012-2020 Jun Wako, Jack Humbert, Yiancar, Takeshi Nishio
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#include <stdint.h>
18#include <stdbool.h>
19#include "matrix.h"
20#include "quantum.h"
21
22#define ROW_SHIFTER ((uint16_t)1)
23
24static const pin_t row_pins[MATRIX_ROWS] = MATRIX_ROW_PINS;
25static const pin_t col_pins[MATRIX_COLS] = MATRIX_COL_PINS;
26
27static void select_row(uint8_t row) {
28 setPinOutput(row_pins[row]);
29 writePinLow(row_pins[row]);
30}
31
32static void unselect_row(uint8_t row) {
33 setPinInputHigh(row_pins[row]);
34}
35
36static void unselect_rows(void) {
37 for (uint8_t x = 0; x < MATRIX_ROWS; x++) {
38 setPinInputHigh(row_pins[x]);
39 }
40}
41
42static void init_pins(void) {
43 unselect_rows();
44 for (uint8_t x = 0; x < MATRIX_COLS; x++) {
45 setPinInputHigh(col_pins[x]);
46 }
47}
48
49static bool read_cols_on_row(matrix_row_t current_matrix[], uint8_t current_row) {
50 // Store last value of row prior to reading
51 matrix_row_t last_row_value = current_matrix[current_row];
52
53 // Clear data in matrix row
54 current_matrix[current_row] = 0;
55
56 // Select row and wait for row selecton to stabilize
57 select_row(current_row);
58 matrix_io_delay();
59
60 // For each col...
61 for (uint8_t col_index = 0; col_index < MATRIX_COLS; col_index++) {
62
63 // skip reading when index equals (= pin itself)
64 if (col_index != current_row) {
65 // Check col pin pin_state
66 if (readPin(col_pins[col_index]) == 0) {
67 // Pin LO, set col bit
68 current_matrix[current_row] |= (ROW_SHIFTER << col_index);
69 } else {
70 // Pin HI, clear col bit
71 current_matrix[current_row] &= ~(ROW_SHIFTER << col_index);
72 }
73 }
74 }
75
76 // Unselect row
77 unselect_row(current_row);
78
79 return (last_row_value != current_matrix[current_row]);
80}
81
82void matrix_init_custom(void) {
83 // initialize key pins
84 init_pins();
85
86 matrix_init_quantum();
87}
88
89bool matrix_scan_custom(matrix_row_t current_matrix[]) {
90 bool changed = false;
91
92 // Set row, read cols
93 for (uint8_t current_row = 0; current_row < MATRIX_ROWS; current_row++) {
94 changed |= read_cols_on_row(current_matrix, current_row);
95 }
96
97 matrix_scan_quantum();
98 return changed;
99}
diff --git a/keyboards/jones/v03/readme.md b/keyboards/jones/v03/readme.md
new file mode 100644
index 000000000..5edae3fb3
--- /dev/null
+++ b/keyboards/jones/v03/readme.md
@@ -0,0 +1,24 @@
1# Jones v.0.3
2
3![Jones, ANSI style](https://github.com/jpskenn/Jones/raw/master/assets/IMG_2204.jpeg)
4
5![Jones, JP style](https://github.com/jpskenn/Jones/raw/master/assets/DSC_7189.jpeg)
6
7A 60% keyboard combined with Ortho-Linear and Row-staggered. It has gapless R2-R3 row.
8GH60 case compatible PCB and keyplate.
9
10* Keyboard Maintainer: [jpskenn](https://github.com/jpskenn)
11* Hardware Supported: Jones PCB, Keyplate
12* Hardware Availability: [GitHub](https://github.com/jpskenn/Jones), [BOOTH](https://jpskenn.booth.pm)
13
14Make example for this keyboard (after setting up your build environment):
15
16 make jones/v03:default
17
18Flashing example for this keyboard ([using the command line](https://docs.qmk.fm/#/newbs_flashing?id=flash-your-keyboard-from-the-command-line)):
19
20 make jones/v03:default:flash
21
22To reset the keyboard into bootloader mode, press the reset switch on the underside.
23
24See 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/jones/v03/rules.mk b/keyboards/jones/v03/rules.mk
new file mode 100644
index 000000000..2a33056c2
--- /dev/null
+++ b/keyboards/jones/v03/rules.mk
@@ -0,0 +1,29 @@
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 = no # 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 = no # 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
24ENCODER_ENABLE = yes # Rotary Encoder
25
26CUSTOM_MATRIX = lite # Custom matrix for "Round-Robin Matrix"
27SRC += matrix.c
28
29LTO_ENABLE = yes
diff --git a/keyboards/jones/v03/v03.c b/keyboards/jones/v03/v03.c
new file mode 100644
index 000000000..9bc63fe96
--- /dev/null
+++ b/keyboards/jones/v03/v03.c
@@ -0,0 +1,17 @@
1/* Copyright 2020 Takeshi Nishio
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 "v03.h"
diff --git a/keyboards/jones/v03/v03.h b/keyboards/jones/v03/v03.h
new file mode 100644
index 000000000..6584f6cbc
--- /dev/null
+++ b/keyboards/jones/v03/v03.h
@@ -0,0 +1,105 @@
1/* Copyright 2020 Takeshi Nishio
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/*
22FULL 11x11 ROUND-ROBIN MATRIX for Reference
23{ KC_NO, k21, k31, k41, k51, k61, k71, k81, k91, ka1, kb1 }, \
24{ k12, KC_NO, k32, k42, k52, k62, k72, k82, k92, ka2, kb2 }, \
25{ k13, k23, KC_NO, k43, k53, k63, k73, k83, k93, ka3, kb3 }, \
26{ k14, k24, k34, KC_NO, k54, k64, k74, k84, k94, ka4, kb4 }, \
27{ k15, k25, k35, k45, KC_NO, k65, k75, k85, k95, ka5, kb5 }, \
28{ k16, k26, k36, k46, k56, KC_NO, k76, k86, k96, ka6, kb6 }, \
29{ k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
30{ k18, k28, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
31{ k19, k29, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
32{ k1a, k2a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, kba }, \
33{ k1b, k2b, k3b, k4b, k5b, k6b, k7b, k8b, k9b, kab, KC_NO } \
34*/
35
36/* This is a shortcut to help you visually see your layout.
37 *
38 * The first section contains all of the arguments representing the physical
39 * layout of the board and position of the keys.
40 *
41 * The second converts the arguments into a two-dimensional array which
42 * represents the switch matrix.
43 */
44#define LAYOUT_all( \
45 k17, k27, k37, k47, k57, k67, k76, k86, k96, ka6, kb6, k81, k91, ka1, kb1, \
46 k18, k38, k48, k58, k68, k78, k87, k97, ka7, kb7, k82, K92, ka2, kb2, \
47 k19, k39, k49, k59, k69, k79, k89, k98, ka8, kb8, k83, k93, ka3, kb3, \
48 k1a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, ka9, kb9, k84, k94, ka4, kb4, \
49 k1b, k2b, k3b, k4b, k6b, k8b, k9b, kab, k85, k95, ka5, kb5 \
50) \
51{ \
52 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k81, k91, ka1, kb1 }, \
53 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k82, KC_NO, ka2, kb2 }, \
54 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k83, k93, ka3, kb3 }, \
55 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k84, k94, ka4, kb4 }, \
56 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k85, k95, ka5, kb5 }, \
57 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k76, k86, k96, ka6, kb6 }, \
58 { k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
59 { k18, KC_NO, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
60 { k19, KC_NO, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
61 { k1a, KC_NO, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, KC_NO }, \
62 { k1b, k2b, k3b, k4b, KC_NO, k6b, KC_NO, k8b, k9b, kab, KC_NO } \
63}
64
65#define LAYOUT_ansi( \
66 k17, k27, k37, k47, k57, k67, k76, k86, k96, ka6, kb6, k81, k91, ka1, kb1, \
67 k18, k38, k48, k58, k68, k78, k87, k97, ka7, kb7, k82, k92, ka2, kb2, \
68 k19, k39, k49, k59, k69, k79, k89, k98, ka8, kb8, k83, k93, kb3, \
69 k1a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, ka9, kb9, k84, k94, ka4, kb4, \
70 k1b, k2b, k3b, k4b, k6b, k8b, k9b, kab, k85, k95, ka5, kb5 \
71) \
72{ \
73 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k81, k91, ka1, kb1 }, \
74 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k82, k92, ka2, kb2 }, \
75 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k83, k93, KC_NO, kb3 }, \
76 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k84, k94, ka4, kb4 }, \
77 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k85, k95, ka5, kb5 }, \
78 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k76, k86, k96, ka6, kb6 }, \
79 { k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
80 { k18, KC_NO, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
81 { k19, KC_NO, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
82 { k1a, KC_NO, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, KC_NO }, \
83 { k1b, k2b, k3b, k4b, KC_NO, k6b, KC_NO, k8b, k9b, kab, KC_NO } \
84}
85
86#define LAYOUT_jp( \
87 k17, k27, k37, k47, k57, k67, k76, k86, k96, ka6, kb6, k81, k91, ka1, kb1, \
88 k18, k38, k48, k58, k68, k78, k87, k97, ka7, kb7, k82, ka2, kb2, \
89 k19, k39, k49, k59, k69, k79, k89, k98, ka8, kb8, k83, k93, ka3, kb3, \
90 k1a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, ka9, kb9, k84, k94, ka4, kb4, \
91 k1b, k2b, k3b, k4b, k6b, k8b, k9b, kab, k85, k95, ka5, kb5 \
92) \
93{ \
94 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k81, k91, ka1, kb1 }, \
95 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k82, KC_NO, ka2, kb2 }, \
96 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k83, k93, ka3, kb3 }, \
97 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k84, k94, ka4, kb4 }, \
98 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k85, k95, ka5, kb5 }, \
99 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k76, k86, k96, ka6, kb6 }, \
100 { k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
101 { k18, KC_NO, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
102 { k19, KC_NO, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
103 { k1a, KC_NO, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, KC_NO }, \
104 { k1b, k2b, k3b, k4b, KC_NO, k6b, KC_NO, k8b, k9b, kab, KC_NO } \
105}
diff --git a/keyboards/jones/v03_1/config.h b/keyboards/jones/v03_1/config.h
new file mode 100644
index 000000000..a064e5639
--- /dev/null
+++ b/keyboards/jones/v03_1/config.h
@@ -0,0 +1,166 @@
1/*
2Copyright 2020 Takeshi Nishio
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 0xFEED
24#define PRODUCT_ID 0x175A
25#define DEVICE_VER 0x0031
26#define MANUFACTURER jpskenn
27#define PRODUCT Jones
28
29/* key matrix size */
30// Same size for Jones' custom Round-Robin matrix.
31#define MATRIX_ROWS 11
32#define MATRIX_COLS 11
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// Same pins for Jones' custom Round-Robin matrix.
45#define MATRIX_ROW_PINS { D4, D7, C7, F1, F4, F5, D6, D5, E6, B0, B1 }
46#define MATRIX_COL_PINS { D4, D7, C7, F1, F4, F5, D6, D5, E6, B0, B1 }
47#define UNUSED_PINS
48
49/* COL2ROW, ROW2COL*/
50// No need to define DIODE_DIRECTION for Jones' custom Round-Robin matrix.
51//#define DIODE_DIRECTION COL2ROW
52
53/* Rotary Encoder */
54#define ENCODERS_PAD_A { F6, B3 }
55#define ENCODERS_PAD_B { F7, B2 }
56#define ENCODER_RESOLUTION 4 //the default & suggested is 4
57
58/* Audio */
59#ifdef AUDIO_ENABLE
60 #define C6_AUDIO
61 #define B7_AUDIO // 2nd pin for simultaneous audio.
62 #define AUDIO_CLICKY
63#endif
64
65/*
66 * Split Keyboard specific options, make sure you have 'SPLIT_KEYBOARD = yes' in your rules.mk, and define SOFT_SERIAL_PIN.
67 */
68//#define SOFT_SERIAL_PIN D0 // or D1, D2, D3, E6
69
70// #define BACKLIGHT_PIN B7
71// #define BACKLIGHT_BREATHING
72// #define BACKLIGHT_LEVELS 3
73
74#define RGB_DI_PIN F0
75#ifdef RGB_DI_PIN
76 #define RGBLED_NUM 14 // Left(4) + Right(2) + Under(8)
77 #define RGBLIGHT_LED_MAP {0,1,2,3,13,12,4,5,6,7,8,9,10,11} // Left --> Right --> Under
78 #define RGBLIGHT_HUE_STEP 8
79 #define RGBLIGHT_SAT_STEP 8
80 #define RGBLIGHT_VAL_STEP 8
81 #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
82 // #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
83 /*== Lighting Layers ==*/
84 #define RGBLIGHT_LAYERS
85 // #define RGBLIGHT_MAX_LAYERS 2
86 #define RGBLIGHT_LAYERS_OVERRIDE_RGB_OFF // Overriding RGB Lighting on/off status
87 /*== all animations enable ==*/
88 // #define RGBLIGHT_ANIMATIONS
89 /*== or choose animations ==*/
90 // #define RGBLIGHT_EFFECT_BREATHING
91 // #define RGBLIGHT_EFFECT_RAINBOW_MOOD
92 #define RGBLIGHT_EFFECT_RAINBOW_SWIRL
93 // #define RGBLIGHT_EFFECT_SNAKE
94 #define RGBLIGHT_EFFECT_KNIGHT
95 // #define RGBLIGHT_EFFECT_CHRISTMAS
96 // #define RGBLIGHT_EFFECT_STATIC_GRADIENT
97 // #define RGBLIGHT_EFFECT_RGB_TEST
98 // #define RGBLIGHT_EFFECT_ALTERNATING
99 // /*== customize breathing effect ==*/
100 // /*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/
101 // #define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64
102 // /*==== use exp() and sin() ====*/
103 // #define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7
104 // #define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255
105#endif
106
107/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
108#define DEBOUNCE 5
109
110/* define if matrix has ghost (lacks anti-ghosting diodes) */
111//#define MATRIX_HAS_GHOST
112
113/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
114// #define LOCKING_SUPPORT_ENABLE
115/* Locking resynchronize hack */
116// #define LOCKING_RESYNC_ENABLE
117
118/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
119 * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
120 */
121// #define GRAVE_ESC_CTRL_OVERRIDE
122
123/*
124 * Force NKRO
125 *
126 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
127 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
128 * makefile for this to work.)
129 *
130 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
131 * until the next keyboard reset.
132 *
133 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
134 * fully operational during normal computer usage.
135 *
136 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
137 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
138 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
139 * power-up.
140 *
141 */
142//#define FORCE_NKRO
143
144/*
145 * Feature disable options
146 * These options are also useful to firmware size reduction.
147 */
148
149/* disable debug print */
150//#define NO_DEBUG
151
152/* disable print */
153//#define NO_PRINT
154
155/* disable action features */
156//#define NO_ACTION_LAYER
157//#define NO_ACTION_TAPPING
158//#define NO_ACTION_ONESHOT
159
160/* disable these deprecated features by default */
161#define NO_ACTION_MACRO
162#define NO_ACTION_FUNCTION
163
164/* Bootmagic Lite key configuration */
165// #define BOOTMAGIC_LITE_ROW 0
166// #define BOOTMAGIC_LITE_COLUMN 0
diff --git a/keyboards/jones/v03_1/info.json b/keyboards/jones/v03_1/info.json
new file mode 100644
index 000000000..eaee5a691
--- /dev/null
+++ b/keyboards/jones/v03_1/info.json
@@ -0,0 +1,35 @@
1{
2 "keyboard_name": "Jones",
3 "url": "https://github.com/jpskenn/Jones",
4 "maintainer": "jpskenn",
5 "width": 15,
6 "height": 5,
7 "layouts": {
8 "LAYOUT_ansi": {
9 "layout": [
10 {"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"", "x":7, "y":0}, {"label":"", "x":8, "y":0}, {"label":"", "x":9, "y":0}, {"label":"", "x":10, "y":0}, {"label":"", "x":11, "y":0}, {"label":"", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"~", "x":14, "y":0},
11 {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"Backspace", "x":11.5, "y":1, "w":1.5}, {"label":"{", "x":13, "y":1}, {"label":"}", "x":14, "y":1},
12 {"label":"Ctrl", "x":0.25, "y":2, "w":1.25}, {"label":"A", "x":1.5, "y":2}, {"label":"S", "x":2.5, "y":2}, {"label":"D", "x":3.5, "y":2}, {"label":"F", "x":4.5, "y":2}, {"label":"G", "x":5.5, "y":2}, {"label":"H", "x":6.5, "y":2}, {"label":"J", "x":7.5, "y":2}, {"label":"K", "x":8.5, "y":2}, {"label":"L", "x":9.5, "y":2}, {"label":":", "x":10.5, "y":2}, {"label":"Enter", "x":11.5, "y":2, "w":2.25}, {"label":"\u201d", "x":13.75, "y":2},
13 {"label":"Shift", "x":0.25, "y":3, "w":1.75}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"Shift", "x":12, "y":3}, {"label":"\u2191", "x":13, "y":3}, {"label":"Fn", "x":14, "y":3},
14 {"label":"Rotary", "x":0, "y":4}, {"label":"Caps", "x":1, "y":4}, {"label":"Opt", "x":2, "y":4, "w":1.25}, {"label":"Cmd", "x":3.25, "y":4, "w":1.25}, {"label":"Space & Shift", "x":4.5, "y":4, "w":2}, {"label":"Space & Raise", "x":6.5, "y":4, "w":2}, {"label":"Cmd", "x":8.5, "y":4, "w":1.25}, {"label":"Opt", "x":9.75, "y":4, "w":1.25}, {"label":"Ctrl", "x":11, "y":4}, {"label":"\u2190", "x":12, "y":4}, {"label":"\u2193", "x":13, "y":4}, {"label":"\u2192", "x":14, "y":4}
15 ]
16 },
17 "LAYOUT_jp": {
18 "layout": [
19 {"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"\"", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"&", "x":6, "y":0}, {"label":"'", "x":7, "y":0}, {"label":"(", "x":8, "y":0}, {"label":")", "x":9, "y":0}, {"label":"", "x":10, "y":0}, {"label":"=", "x":11, "y":0}, {"label":"BS", "x":12, "y":0}, {"label":"~", "x":13, "y":0}, {"label":"|", "x":14, "y":0},
20 {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"Enter", "x":11.5, "y":1, "w":1.25, "h":2, "r":180, "rx":12.125, "ry":1.5}, {"label":"`", "x":12.75, "y":1}, {"label":"{", "x":13.75, "y":1},
21 {"label":"Ctrl", "x":0.25, "y":2, "w":1.25}, {"label":"A", "x":1.5, "y":2}, {"label":"S", "x":2.5, "y":2}, {"label":"D", "x":3.5, "y":2}, {"label":"F", "x":4.5, "y":2}, {"label":"G", "x":5.5, "y":2}, {"label":"H", "x":6.5, "y":2}, {"label":"J", "x":7.5, "y":2}, {"label":"K", "x":8.5, "y":2}, {"label":"L", "x":9.5, "y":2}, {"label":"+", "x":10.5, "y":2}, {"label":"*", "x":13, "y":2}, {"label":"}", "x":14, "y":2},
22 {"label":"Shift", "x":0.25, "y":3, "w":1.75}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"_", "x":12, "y":3}, {"label":"\u2191", "x":13, "y":3}, {"label":"", "x":14, "y":3},
23 {"label":"Rotary", "x":0, "y":4}, {"label":"\u7530", "x":1, "y":4}, {"label":"Alt", "x":2, "y":4, "w":1.25}, {"label":"\u7121\u5909\u63db", "x":3.25, "y":4}, {"label":"Space", "x":4.25, "y":4, "w":2.25}, {"label":"Space", "x":6.5, "y":4, "w":2}, {"label":"\u5909\u63db", "x":8.5, "y":4, "w":1.25}, {"label":"\u30ab\u30ca", "x":9.75, "y":4, "w":1.25}, {"label":"\u76ee", "x":11, "y":4}, {"label":"\u2190", "x":12, "y":4}, {"label":"\u2193", "x":13, "y":4}, {"label":"\u2192", "x":14, "y":4}]
24 },
25 "LAYOUT_all": {
26 "layout": [
27 {"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"", "x":7, "y":0}, {"label":"", "x":8, "y":0}, {"label":"", "x":9, "y":0}, {"label":"", "x":10, "y":0}, {"label":"", "x":11, "y":0}, {"label":"", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"~", "x":14, "y":0},
28 {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"Backspace", "x":11.5, "y":1, "w":1.5}, {"label":"{", "x":13, "y":1}, {"label":"}", "x":14, "y":1},
29 {"label":"Ctrl", "x":0.25, "y":2, "w":1.25}, {"label":"A", "x":1.5, "y":2}, {"label":"S", "x":2.5, "y":2}, {"label":"D", "x":3.5, "y":2}, {"label":"F", "x":4.5, "y":2}, {"label":"G", "x":5.5, "y":2}, {"label":"H", "x":6.5, "y":2}, {"label":"J", "x":7.5, "y":2}, {"label":"K", "x":8.5, "y":2}, {"label":"L", "x":9.5, "y":2}, {"label":":", "x":10.5, "y":2}, {"label":"Enter", "x":11.5, "y":2, "w":1.5}, {"label":"\u201d", "x":13, "y":2}, {"label":"\u201d", "x":14, "y":2},
30 {"label":"Shift", "x":0.25, "y":3, "w":1.75}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"Shift", "x":12, "y":3}, {"label":"\u2191", "x":13, "y":3}, {"label":"Fn", "x":14, "y":3},
31 {"label":"Rotary", "x":0, "y":4}, {"label":"Caps", "x":1, "y":4}, {"label":"Opt", "x":2, "y":4, "w":1.25}, {"label":"Cmd", "x":3.25, "y":4, "w":1.25}, {"label":"Space & Shift", "x":4.5, "y":4, "w":2}, {"label":"Space & Raise", "x":6.5, "y":4, "w":2}, {"label":"Cmd", "x":8.5, "y":4, "w":1.25}, {"label":"Opt", "x":9.75, "y":4, "w":1.25}, {"label":"Ctrl", "x":11, "y":4}, {"label":"\u2190", "x":12, "y":4}, {"label":"\u2193", "x":13, "y":4}, {"label":"\u2192", "x":14, "y":4}
32 ]
33 }
34 }
35}
diff --git a/keyboards/jones/v03_1/keymaps/default/keymap.c b/keyboards/jones/v03_1/keymaps/default/keymap.c
new file mode 100644
index 000000000..d47166559
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default/keymap.c
@@ -0,0 +1,26 @@
1/* Copyright 2020 Takeshi Nishio
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_all(
20 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_BSLS,KC_GRV,
21 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_LBRC,KC_RBRC,
22 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_ENT, XXXXXXX,KC_QUOT,
23 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, XXXXXXX,
24 KC_MUTE,KC_LANG2,KC_LALT,KC_LGUI, KC_SPC, KC_SPC, KC_RGUI,KC_RALT,KC_LANG1,KC_LEFT,KC_DOWN,KC_RGHT
25 )
26}; \ No newline at end of file
diff --git a/keyboards/jones/v03_1/keymaps/default/readme.md b/keyboards/jones/v03_1/keymaps/default/readme.md
new file mode 100644
index 000000000..a23bc4c15
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default/readme.md
@@ -0,0 +1 @@
# Defalut keymap for Jones
diff --git a/keyboards/jones/v03_1/keymaps/default_ansi/config.h b/keyboards/jones/v03_1/keymaps/default_ansi/config.h
new file mode 100644
index 000000000..0b51190bb
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_ansi/config.h
@@ -0,0 +1,26 @@
1/* Copyright 2020 Takeshi Nishio
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// double tap to toggle
20#define TAPPING_TOGGLE 2
21
22// time for long press
23#define TAPPING_TERM 200
24
25// music map for music-mode
26#define MUSIC_MAP
diff --git a/keyboards/jones/v03_1/keymaps/default_ansi/keymap.c b/keyboards/jones/v03_1/keymaps/default_ansi/keymap.c
new file mode 100644
index 000000000..e1bc27305
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_ansi/keymap.c
@@ -0,0 +1,362 @@
1/* Copyright 2020 Takeshi Nishio
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_number {
20 _MAC = 0,
21 _WIN,
22 _NUM,
23 _LOWER,
24 _RAISE,
25 _NUM_RAISE,
26 _ADJUST
27};
28
29// Tap Dance
30enum tap_dances{
31 TD_LSFT_CAPS = 0,
32 TD_ESC_NUM,
33};
34
35// Tap Dance state
36enum {
37 SINGLE_TAP = 1,
38 DOUBLE_TAP,
39 TRIPLE_TAP,
40 TAP_HOLD,
41};
42
43// Declare the functions to be used with your tap dance key(s)
44// Function associated with all tap dances
45uint8_t cur_dance(qk_tap_dance_state_t *state);
46// Functions associated with individual tap dances
47void ql_finished(qk_tap_dance_state_t *state, void *user_data);
48void ql_reset(qk_tap_dance_state_t *state, void *user_data);
49
50// Tap Dance definitions
51qk_tap_dance_action_t tap_dance_actions[] = {
52 [TD_LSFT_CAPS] = ACTION_TAP_DANCE_DOUBLE(KC_LSFT, KC_CAPS),
53 [TD_ESC_NUM] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, ql_finished, ql_reset, 275),
54};
55
56// Defines the keycodes used by our macros in process_record_user
57enum custom_keycodes {
58 MAC = SAFE_RANGE,
59 WIN,
60};
61
62// Key Macro
63#define ESC_NUM TD(TD_ESC_NUM)
64#define S_CAP TD(TD_LSFT_CAPS)
65#define SP_RAI LT(_RAISE, KC_SPC)
66#define SP_NRAI LT(_NUM_RAISE, KC_SPC)
67#define SP_SFT MT(MOD_LSFT, KC_SPC)
68#define C_SLSH RCTL_T(KC_SLSH)
69#define CT_E LCTL(KC_E)
70#define CT_A LCTL(KC_A)
71#define ALT_GRV LALT(KC_GRV)
72#define LOWER MO(_LOWER)
73#define NUM TG(_NUM)
74
75
76const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
77 [_MAC] = LAYOUT_ansi(
78 ESC_NUM,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_BSLS,KC_GRV,
79 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_LBRC,KC_RBRC,
80 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_ENT, KC_QUOT,
81 S_CAP, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM,KC_DOT, C_SLSH, KC_RSFT,KC_UP, LOWER,
82 KC_MUTE,KC_LANG2,KC_LALT,KC_LGUI, SP_SFT, SP_RAI, KC_RGUI,KC_RALT,KC_LANG1,KC_LEFT,KC_DOWN,KC_RGHT
83 ),
84 [_WIN] = LAYOUT_ansi(
85 _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
86 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,
87 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,
88 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
89 _______,ALT_GRV,KC_LGUI,KC_LALT, _______, _______, KC_RALT,KC_APP, ALT_GRV,_______,_______,_______
90 ),
91 [_NUM] = LAYOUT_ansi(
92 _______,_______,_______,_______,_______,_______,_______,XXXXXXX,KC_PSLS,KC_PSLS,KC_PAST,_______,_______,_______,_______,
93 _______, _______,_______,_______,_______,_______,_______,KC_P7, KC_P8, KC_P9, KC_PPLS,_______, _______,_______,
94 _______, _______,_______,_______,_______,_______,_______,KC_P4, KC_P5, KC_P6, XXXXXXX,_______, _______,
95 _______, _______,_______,_______,_______,_______,_______,KC_P1, KC_P2, KC_P3, KC_PENT,_______,_______,_______,
96 _______,_______,_______,_______, _______, SP_NRAI, KC_P0, KC_PDOT,_______,_______,_______,_______
97 ),
98 [_LOWER] = LAYOUT_ansi(
99 KC_PAUS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
100 KC_PSCR, _______,_______,_______,_______,_______,_______,_______,_______,_______,KC_HOME,KC_UP, KC_END, KC_VOLU,
101 _______, _______,_______,_______,_______,_______,_______,_______,_______,KC_PGUP,KC_LEFT,KC_RGHT, KC_VOLD,
102 _______, _______,_______,_______,_______,_______,_______,_______,_______,KC_PGDN,KC_DOWN,_______,KC_PGUP,_______,
103 _______,_______,_______,_______, _______, _______, _______,_______,_______,KC_HOME,KC_PGDN,KC_END
104 ),
105 [_RAISE] = LAYOUT_ansi(
106 KC_PAUS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
107 KC_PSCR, _______,_______,CT_E, _______,_______,_______,_______,_______,_______,KC_PGUP,KC_DEL, _______,_______,
108 _______, CT_A, _______,KC_DEL, KC_RGHT,KC_ESC, KC_LEFT,KC_DOWN,KC_UP, KC_RGHT,KC_MINS,KC_INS, _______,
109 _______, _______,_______,_______,_______,KC_LEFT,KC_PGDN,KC_ENT, _______,KC_MRWD,KC_MFFD,_______,KC_PGUP,_______,
110 _______,_______,_______,_______, _______, _______, _______,_______,_______,KC_HOME,KC_PGDN,KC_END
111 ),
112 [_NUM_RAISE] = LAYOUT_ansi(
113 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_BSLS,KC_GRV,
114 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_LBRC,KC_RBRC,
115 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, KC_QUOT,
116 S_CAP, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM,KC_DOT, C_SLSH, KC_RSFT,KC_UP, _______,
117 _______,_______,_______,_______, _______, _______, _______,_______,_______,_______,_______,_______
118 ),
119 [_ADJUST] = LAYOUT_ansi(
120 _______,RGB_HUI,RGB_SAI,RGB_VAI,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
121 _______, _______,WIN, _______,RESET, _______,RGB_HUI,RGB_SAI,RGB_VAI,_______,RGB_RMOD,_______, _______,_______,
122 _______, AU_TOG, CK_TOGG,MU_TOG, MU_MOD, _______,RGB_HUD,RGB_SAD,RGB_VAD,RGB_TOG,RGB_MOD,_______, _______,
123 _______, CK_RST, CK_DOWN,CK_UP ,_______,_______,NUM, MAC, _______,_______,_______,_______,_______,_______,
124 _______,_______,_______,_______, _______, _______, _______,_______,_______,_______,_______,_______
125 )
126};
127
128bool process_record_user(uint16_t keycode, keyrecord_t *record) {
129 switch (keycode) {
130 case MAC: // Change default ayer --> Write to EEPROM
131 if (record->event.pressed) {
132 set_single_persistent_default_layer(_MAC);
133 }
134 return false;
135 break;
136 case WIN: // Change default ayer --> Write to EEPROM
137 if (record->event.pressed) {
138 set_single_persistent_default_layer(_WIN);
139 }
140 return false;
141 break;
142 default:
143 break;
144 }
145 return true;
146}
147
148//------------------------------------------------------------------------------
149// RGB Light settings
150#ifdef RGBLIGHT_LAYERS
151
152// Indicator LED settings
153#define JONES_LED_INDICATOR_INDEX 12 // where to start indicator
154#define JONES_LED_INDICATOR_COUNT 2 // how many leds for indicator
155#define JONES_LED_INDICATOR_CHANGE_COUNT 1 // how meny leds to change color for temporally layer
156#define JONES_LED_DIMMER_LEVEL 200 // brightness dimmer
157
158// for Default layer (= Base layer)
159const rgblight_segment_t PROGMEM my_mac_layer[] = RGBLIGHT_LAYER_SEGMENTS(
160 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_COUNT, HSV_WHITE - JONES_LED_DIMMER_LEVEL}
161);
162const rgblight_segment_t PROGMEM my_win_layer[] = RGBLIGHT_LAYER_SEGMENTS(
163 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_COUNT, HSV_BLUE - JONES_LED_DIMMER_LEVEL}
164);
165const rgblight_segment_t PROGMEM my_num_layer[] = RGBLIGHT_LAYER_SEGMENTS(
166 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_COUNT, HSV_YELLOW - JONES_LED_DIMMER_LEVEL}
167);
168
169// for temporal layer
170const rgblight_segment_t PROGMEM my_caps_layer[] = RGBLIGHT_LAYER_SEGMENTS(
171 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_MAGENTA - JONES_LED_DIMMER_LEVEL}
172);
173
174const rgblight_segment_t PROGMEM my_lower_layer[] = RGBLIGHT_LAYER_SEGMENTS(
175 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_GREEN - JONES_LED_DIMMER_LEVEL}
176);
177
178const rgblight_segment_t PROGMEM my_raise_layer[] = RGBLIGHT_LAYER_SEGMENTS(
179 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_CYAN - JONES_LED_DIMMER_LEVEL}
180);
181
182const rgblight_segment_t PROGMEM my_num_raise_layer[] = RGBLIGHT_LAYER_SEGMENTS(
183 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_GOLD - JONES_LED_DIMMER_LEVEL}
184);
185
186const rgblight_segment_t PROGMEM my_adjust_layer[] = RGBLIGHT_LAYER_SEGMENTS(
187 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_RED - JONES_LED_DIMMER_LEVEL}
188);
189
190// Define the array of layers. Later layers take precedence
191const rgblight_segment_t* const PROGMEM my_rgb_layers[] = RGBLIGHT_LAYERS_LIST(
192 my_mac_layer,
193 my_win_layer,
194 my_num_layer,
195 my_caps_layer,
196 my_lower_layer,
197 my_raise_layer,
198 my_num_raise_layer,
199 my_adjust_layer
200);
201
202void keyboard_post_init_user(void) {
203 // Enable the LED layers
204 rgblight_layers = my_rgb_layers;
205}
206
207// Enabling and disabling lighting layers
208layer_state_t layer_state_set_user(layer_state_t state) {
209 state = update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
210
211 rgblight_set_layer_state(2, layer_state_cmp(state, _NUM));
212 rgblight_set_layer_state(4, layer_state_cmp(state, _LOWER));
213 rgblight_set_layer_state(5, layer_state_cmp(state, _RAISE));
214 rgblight_set_layer_state(6, layer_state_cmp(state, _NUM_RAISE));
215 rgblight_set_layer_state(7, layer_state_cmp(state, _ADJUST));
216
217 return state;
218}
219
220// Enabling and disabling lighting layers for default layer
221layer_state_t default_layer_state_set_user(layer_state_t state) {
222 rgblight_set_layer_state(0, layer_state_cmp(state, _MAC));
223 rgblight_set_layer_state(1, layer_state_cmp(state, _WIN));
224 rgblight_set_layer_state(2, layer_state_cmp(state, _NUM));
225
226 return state;
227}
228
229bool led_update_user(led_t led_state) {
230 rgblight_set_layer_state(3, led_state.caps_lock);
231 return true;
232}
233#endif
234
235
236//------------------------------------------------------------------------------
237// Rotary Encoder
238void encoder_update_user(uint8_t index, bool clockwise) {
239 if (index == 0) { /* First encoder, Right side */
240 if (clockwise) {
241 tap_code(KC_VOLD);
242 } else {
243 tap_code(KC_VOLU);
244 }
245 }
246 if (index == 1) { /* Second encoder, Left side */
247 switch(biton32(layer_state)) {
248 case _LOWER:
249 if (clockwise) {
250 rgblight_decrease_hue();
251 } else {
252 rgblight_increase_hue();
253 }
254 break;
255 case _RAISE:
256 if (clockwise) {
257 rgblight_decrease_val();
258 } else {
259 rgblight_increase_val();
260 }
261 break;
262 case _ADJUST:
263 if (clockwise) {
264 rgblight_step_reverse();
265 } else {
266 rgblight_step();
267 }
268 break;
269 default:
270 if (clockwise) {
271 tap_code(KC_VOLD);
272 } else {
273 tap_code(KC_VOLU);
274 }
275 break;
276 }
277 }
278}
279
280
281//------------------------------------------------------------------------------
282// Tap Dance function
283
284
285typedef struct {
286 bool is_press_action;
287 uint8_t state;
288} tap;
289
290// Determine the current tap dance state
291uint8_t cur_dance(qk_tap_dance_state_t *state) {
292 if (state->count == 1) {
293 if (!state->pressed) {
294 return SINGLE_TAP;
295 } else {
296 return TAP_HOLD;
297 }
298 } else if (state->count == 2) {
299 if (!state->pressed) {
300 return DOUBLE_TAP;
301 } else {
302 return TAP_HOLD;
303 }
304 } else if (state->count == 3) {
305 if (!state->pressed) {
306 return TRIPLE_TAP;
307 } else {
308 return TAP_HOLD;
309 }
310 } else {
311 return 8; // Magic number. At some point this method will expand to work for more presses
312 }
313}
314
315// Initialize tap structure associated with example tap dance key
316static tap ql_tap_state = {
317 .is_press_action = true,
318 .state = 0
319};
320
321// Functions that control what our tap dance key does
322void ql_finished(qk_tap_dance_state_t *state, void *user_data) {
323 ql_tap_state.state = cur_dance(state);
324 switch(state->keycode) {
325 case TD(TD_ESC_NUM): // ESC key action
326 switch (ql_tap_state.state) {
327 case SINGLE_TAP:
328 case DOUBLE_TAP:
329 // ESC
330 tap_code(KC_ESC);
331 break;
332 case TAP_HOLD:
333 // temporal layer change
334 layer_on(_NUM);
335 break;
336 case TRIPLE_TAP:
337 // toggle layer
338 // Check to see if the layer is already set
339 if (layer_state_is(_NUM)) {
340 // If already set, then switch it off
341 layer_off(_NUM);
342 } else {
343 // If not already set, then switch the layer on
344 layer_on(_NUM);
345 }
346 break;
347 }
348 break;
349 }
350}
351
352void ql_reset(qk_tap_dance_state_t *state, void *user_data) {
353 switch(state->keycode) {
354 case TD(TD_ESC_NUM):
355 // If the key was held down and now is released then switch off the layer
356 if (ql_tap_state.state == TAP_HOLD) {
357 layer_off(_NUM);
358 }
359 ql_tap_state.state = 0;
360 break;
361 }
362}
diff --git a/keyboards/jones/v03_1/keymaps/default_ansi/readme.md b/keyboards/jones/v03_1/keymaps/default_ansi/readme.md
new file mode 100644
index 000000000..1838a84ad
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_ansi/readme.md
@@ -0,0 +1 @@
# Defalut ANSI-style keymap for Jones
diff --git a/keyboards/jones/v03_1/keymaps/default_ansi/rules.mk b/keyboards/jones/v03_1/keymaps/default_ansi/rules.mk
new file mode 100644
index 000000000..18b26d5c8
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_ansi/rules.mk
@@ -0,0 +1 @@
TAP_DANCE_ENABLE = yes # Enable Tap Dance \ No newline at end of file
diff --git a/keyboards/jones/v03_1/keymaps/default_jp/config.h b/keyboards/jones/v03_1/keymaps/default_jp/config.h
new file mode 100644
index 000000000..0b51190bb
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_jp/config.h
@@ -0,0 +1,26 @@
1/* Copyright 2020 Takeshi Nishio
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// double tap to toggle
20#define TAPPING_TOGGLE 2
21
22// time for long press
23#define TAPPING_TERM 200
24
25// music map for music-mode
26#define MUSIC_MAP
diff --git a/keyboards/jones/v03_1/keymaps/default_jp/keymap.c b/keyboards/jones/v03_1/keymaps/default_jp/keymap.c
new file mode 100644
index 000000000..70e4612b6
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_jp/keymap.c
@@ -0,0 +1,364 @@
1/* Copyright 2020 Takeshi Nishio
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#include "keymap_jp.h"
18
19// Defines names for use in layer keycodes and the keymap
20enum layer_number {
21 _MAC = 0,
22 _WIN,
23 _NUM,
24 _LOWER,
25 _RAISE,
26 _NUM_RAISE,
27 _ADJUST
28};
29
30// Tap Dance
31enum tap_dances{
32 TD_LSFT_CAPS = 0,
33 TD_ESC_NUM,
34};
35
36// Tap Dance state
37enum {
38 SINGLE_TAP = 1,
39 DOUBLE_TAP,
40 TRIPLE_TAP,
41 TAP_HOLD,
42};
43
44// Declare the functions to be used with your tap dance key(s)
45// Function associated with all tap dances
46uint8_t cur_dance(qk_tap_dance_state_t *state);
47// Functions associated with individual tap dances
48void ql_finished(qk_tap_dance_state_t *state, void *user_data);
49void ql_reset(qk_tap_dance_state_t *state, void *user_data);
50
51// Tap Dance definitions
52qk_tap_dance_action_t tap_dance_actions[] = {
53 [TD_LSFT_CAPS] = ACTION_TAP_DANCE_DOUBLE(KC_LSFT, KC_CAPS),
54 [TD_ESC_NUM] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, ql_finished, ql_reset, 275),
55};
56
57// Defines the keycodes used by our macros in process_record_user
58enum custom_keycodes {
59 MAC = SAFE_RANGE,
60 WIN,
61};
62
63// Key Macro
64#define ESC_NUM TD(TD_ESC_NUM)
65#define S_CAP TD(TD_LSFT_CAPS)
66#define SP_RAI LT(_RAISE, KC_SPC)
67#define SP_NRAI LT(_NUM_RAISE, KC_SPC)
68#define SP_SFT MT(MOD_LSFT, KC_SPC)
69#define S_BSLS RSFT_T(JP_BSLS)
70#define C_SLSH RCTL_T(JP_SLSH)
71#define CT_E LCTL(KC_E)
72#define CT_A LCTL(KC_A)
73#define ALT_GRV LALT(KC_GRV)
74#define LOWER MO(_LOWER)
75#define NUM TG(_NUM)
76
77
78const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
79 [_MAC] = LAYOUT_jp(
80 ESC_NUM,KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS,KC_BSPC,JP_CIRC,JP_YEN,
81 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_AT, JP_LBRC,
82 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, KC_ENT, JP_COLN,JP_RBRC,
83 S_CAP, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM,JP_DOT, C_SLSH, S_BSLS, KC_UP, LOWER,
84 KC_MUTE,KC_LALT,KC_LGUI,KC_LANG2, SP_SFT, SP_RAI, KC_LANG1,KC_RGUI,KC_RALT,KC_LEFT,KC_DOWN,KC_RGHT
85 ),
86 [_WIN] = LAYOUT_jp(
87 _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
88 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,
89 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,
90 _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
91 _______,KC_LGUI,KC_LALT,JP_MHEN, _______, _______, JP_HENK,JP_KANA,KC_APP, _______,_______,_______
92 ),
93 [_NUM] = LAYOUT_jp(
94 _______,_______,_______,_______,_______,_______,_______,XXXXXXX,KC_PSLS,KC_PSLS,KC_PAST,_______,_______,_______,_______,
95 _______, _______,_______,_______,_______,_______,_______,KC_P7, KC_P8, KC_P9, KC_PPLS, _______,_______,
96 _______, _______,_______,_______,_______,_______,_______,KC_P4, KC_P5, KC_P6, XXXXXXX,_______, _______,_______,
97 _______, _______,_______,_______,_______,_______,_______,KC_P1, KC_P2, KC_P3, KC_PENT,_______,_______,_______,
98 _______,_______,_______,_______, _______, SP_NRAI, KC_P0, KC_PDOT,_______,_______,_______,_______
99 ),
100 [_LOWER] = LAYOUT_jp(
101 KC_PAUS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
102 KC_PSCR, _______,_______,_______,_______,_______,_______,_______,_______,_______,KC_HOME, KC_END, KC_VOLU,
103 _______, _______,_______,_______,_______,_______,_______,_______,_______,KC_PGUP,KC_LEFT,KC_RGHT, _______,KC_VOLD,
104 _______, _______,_______,_______,_______,_______,_______,_______,_______,KC_PGDN,KC_DOWN,_______,KC_PGUP,_______,
105 _______,_______,_______,_______, _______, _______, _______,_______,_______,KC_HOME,KC_PGDN,KC_END
106 ),
107 [_RAISE] = LAYOUT_jp(
108 KC_PAUS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
109 KC_PSCR, _______,_______,CT_E, _______,_______,_______,_______,_______,_______,KC_PGUP, _______,_______,
110 _______, CT_A, _______,KC_DEL, KC_RGHT,KC_ESC, KC_LEFT,KC_DOWN,KC_UP, KC_RGHT,_______,_______, _______,_______,
111 _______, _______,_______,_______,_______,KC_LEFT,KC_PGDN,KC_ENT, _______,KC_MRWD,KC_MFFD,_______,KC_PGUP,_______,
112 _______,_______,_______,_______, _______, _______, _______,_______,_______,KC_HOME,KC_PGDN,KC_END
113 ),
114 [_NUM_RAISE] = LAYOUT_jp(
115 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS,KC_BSPC,JP_CIRC,JP_YEN,
116 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_AT, JP_LBRC,
117 KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, KC_ENT, JP_COLN,JP_RBRC,
118 S_CAP, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM,JP_DOT, C_SLSH, S_BSLS, KC_UP, _______,
119 _______,_______,_______,_______, _______, _______, _______,_______,_______,_______,_______,_______
120 ),
121 [_ADJUST] = LAYOUT_jp(
122 _______,RGB_HUI,RGB_SAI,RGB_VAI,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
123 _______, _______,WIN, _______,RESET, _______,RGB_HUI,RGB_SAI,RGB_VAI,_______,RGB_RMOD, _______,_______,
124 _______, AU_TOG, CK_TOGG,MU_TOG, MU_MOD, _______,RGB_HUD,RGB_SAD,RGB_VAD,RGB_TOG,RGB_MOD,_______, _______,_______,
125 _______, CK_RST, CK_DOWN,CK_UP ,_______,_______,NUM, MAC, _______,_______,_______,_______,_______,_______,
126 _______,_______,_______,_______, _______, _______, _______,_______,_______,_______,_______,_______
127 )
128};
129
130bool process_record_user(uint16_t keycode, keyrecord_t *record) {
131switch (keycode) {
132 case MAC: // Change default ayer --> Write to EEPROM
133 if (record->event.pressed) {
134 set_single_persistent_default_layer(_MAC);
135 }
136 return false;
137 break;
138 case WIN: // Change default ayer --> Write to EEPROM
139 if (record->event.pressed) {
140 set_single_persistent_default_layer(_WIN);
141 }
142 return false;
143 break;
144 default:
145 break;
146 }
147 return true;
148}
149
150//------------------------------------------------------------------------------
151// RGB Light settings
152#ifdef RGBLIGHT_LAYERS
153
154// Indicator LED settings
155#define JONES_LED_INDICATOR_INDEX 12 // where to start indicator
156#define JONES_LED_INDICATOR_COUNT 2 // how many leds for indicator
157#define JONES_LED_INDICATOR_CHANGE_COUNT 1 // how meny leds to change color for temporally layer
158#define JONES_LED_DIMMER_LEVEL 200 // brightness dimmer
159
160// for Default layer (= Base layer)
161const rgblight_segment_t PROGMEM my_mac_layer[] = RGBLIGHT_LAYER_SEGMENTS(
162 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_COUNT, HSV_WHITE - JONES_LED_DIMMER_LEVEL}
163);
164const rgblight_segment_t PROGMEM my_win_layer[] = RGBLIGHT_LAYER_SEGMENTS(
165 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_COUNT, HSV_BLUE - JONES_LED_DIMMER_LEVEL}
166);
167const rgblight_segment_t PROGMEM my_num_layer[] = RGBLIGHT_LAYER_SEGMENTS(
168 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_COUNT, HSV_YELLOW - JONES_LED_DIMMER_LEVEL}
169);
170
171// for temporal layer
172const rgblight_segment_t PROGMEM my_caps_layer[] = RGBLIGHT_LAYER_SEGMENTS(
173 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_MAGENTA - JONES_LED_DIMMER_LEVEL}
174);
175
176const rgblight_segment_t PROGMEM my_lower_layer[] = RGBLIGHT_LAYER_SEGMENTS(
177 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_GREEN - JONES_LED_DIMMER_LEVEL}
178);
179
180const rgblight_segment_t PROGMEM my_raise_layer[] = RGBLIGHT_LAYER_SEGMENTS(
181 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_CYAN - JONES_LED_DIMMER_LEVEL}
182);
183
184const rgblight_segment_t PROGMEM my_num_raise_layer[] = RGBLIGHT_LAYER_SEGMENTS(
185 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_GOLD - JONES_LED_DIMMER_LEVEL}
186);
187
188const rgblight_segment_t PROGMEM my_adjust_layer[] = RGBLIGHT_LAYER_SEGMENTS(
189 {JONES_LED_INDICATOR_INDEX , JONES_LED_INDICATOR_CHANGE_COUNT, HSV_RED - JONES_LED_DIMMER_LEVEL}
190);
191
192// Define the array of layers. Later layers take precedence
193const rgblight_segment_t* const PROGMEM my_rgb_layers[] = RGBLIGHT_LAYERS_LIST(
194 my_mac_layer,
195 my_win_layer,
196 my_num_layer,
197 my_caps_layer,
198 my_lower_layer,
199 my_raise_layer,
200 my_num_raise_layer,
201 my_adjust_layer
202);
203
204void keyboard_post_init_user(void) {
205 // Enable the LED layers
206 rgblight_layers = my_rgb_layers;
207}
208
209// Enabling and disabling lighting layers
210layer_state_t layer_state_set_user(layer_state_t state) {
211 state = update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
212
213 rgblight_set_layer_state(2, layer_state_cmp(state, _NUM));
214 rgblight_set_layer_state(4, layer_state_cmp(state, _LOWER));
215 rgblight_set_layer_state(5, layer_state_cmp(state, _RAISE));
216 rgblight_set_layer_state(6, layer_state_cmp(state, _NUM_RAISE));
217 rgblight_set_layer_state(7, layer_state_cmp(state, _ADJUST));
218
219 return state;
220}
221
222// Enabling and disabling lighting layers for default layer
223layer_state_t default_layer_state_set_user(layer_state_t state) {
224 rgblight_set_layer_state(0, layer_state_cmp(state, _MAC));
225 rgblight_set_layer_state(1, layer_state_cmp(state, _WIN));
226 rgblight_set_layer_state(2, layer_state_cmp(state, _NUM));
227
228 return state;
229}
230
231bool led_update_user(led_t led_state) {
232 rgblight_set_layer_state(3, led_state.caps_lock);
233 return true;
234}
235#endif
236
237
238//------------------------------------------------------------------------------
239// Rotary Encoder
240void encoder_update_user(uint8_t index, bool clockwise) {
241 if (index == 0) { /* First encoder, Right side */
242 if (clockwise) {
243 tap_code(KC_VOLD);
244 } else {
245 tap_code(KC_VOLU);
246 }
247 }
248 if (index == 1) { /* Second encoder, Left side */
249 switch(biton32(layer_state)) {
250 case _LOWER:
251 if (clockwise) {
252 rgblight_decrease_hue();
253 } else {
254 rgblight_increase_hue();
255 }
256 break;
257 case _RAISE:
258 if (clockwise) {
259 rgblight_decrease_val();
260 } else {
261 rgblight_increase_val();
262 }
263 break;
264 case _ADJUST:
265 if (clockwise) {
266 rgblight_step_reverse();
267 } else {
268 rgblight_step();
269 }
270 break;
271 default:
272 if (clockwise) {
273 tap_code(KC_VOLD);
274 } else {
275 tap_code(KC_VOLU);
276 }
277 break;
278 }
279 }
280}
281
282
283//------------------------------------------------------------------------------
284// Tap Dance function
285
286
287typedef struct {
288 bool is_press_action;
289 uint8_t state;
290} tap;
291
292// Determine the current tap dance state
293uint8_t cur_dance(qk_tap_dance_state_t *state) {
294 if (state->count == 1) {
295 if (!state->pressed) {
296 return SINGLE_TAP;
297 } else {
298 return TAP_HOLD;
299 }
300 } else if (state->count == 2) {
301 if (!state->pressed) {
302 return DOUBLE_TAP;
303 } else {
304 return TAP_HOLD;
305 }
306 } else if (state->count == 3) {
307 if (!state->pressed) {
308 return TRIPLE_TAP;
309 } else {
310 return TAP_HOLD;
311 }
312 } else {
313 return 8; // Magic number. At some point this method will expand to work for more presses
314 }
315}
316
317// Initialize tap structure associated with example tap dance key
318static tap ql_tap_state = {
319 .is_press_action = true,
320 .state = 0
321};
322
323// Functions that control what our tap dance key does
324void ql_finished(qk_tap_dance_state_t *state, void *user_data) {
325 ql_tap_state.state = cur_dance(state);
326 switch(state->keycode) {
327 case TD(TD_ESC_NUM): // ESC key action
328 switch (ql_tap_state.state) {
329 case SINGLE_TAP:
330 case DOUBLE_TAP:
331 // ESC
332 tap_code(KC_ESC);
333 break;
334 case TAP_HOLD:
335 // temporal layer change
336 layer_on(_NUM);
337 break;
338 case TRIPLE_TAP:
339 // toggle layer
340 // Check to see if the layer is already set
341 if (layer_state_is(_NUM)) {
342 // If already set, then switch it off
343 layer_off(_NUM);
344 } else {
345 // If not already set, then switch the layer on
346 layer_on(_NUM);
347 }
348 break;
349 }
350 break;
351 }
352}
353
354void ql_reset(qk_tap_dance_state_t *state, void *user_data) {
355 switch(state->keycode) {
356 case TD(TD_ESC_NUM):
357 // If the key was held down and now is released then switch off the layer
358 if (ql_tap_state.state == TAP_HOLD) {
359 layer_off(_NUM);
360 }
361 ql_tap_state.state = 0;
362 break;
363 }
364}
diff --git a/keyboards/jones/v03_1/keymaps/default_jp/readme.md b/keyboards/jones/v03_1/keymaps/default_jp/readme.md
new file mode 100644
index 000000000..0cb2c18a4
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_jp/readme.md
@@ -0,0 +1 @@
# Defalut JP-style keymap for Jones
diff --git a/keyboards/jones/v03_1/keymaps/default_jp/rules.mk b/keyboards/jones/v03_1/keymaps/default_jp/rules.mk
new file mode 100644
index 000000000..15d7e0624
--- /dev/null
+++ b/keyboards/jones/v03_1/keymaps/default_jp/rules.mk
@@ -0,0 +1 @@
TAP_DANCE_ENABLE = yes # Enable Tap Dance
diff --git a/keyboards/jones/v03_1/matrix.c b/keyboards/jones/v03_1/matrix.c
new file mode 100644
index 000000000..9f3e76f93
--- /dev/null
+++ b/keyboards/jones/v03_1/matrix.c
@@ -0,0 +1,99 @@
1/*
2Copyright 2012-2020 Jun Wako, Jack Humbert, Yiancar, Takeshi Nishio
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#include <stdint.h>
18#include <stdbool.h>
19#include "matrix.h"
20#include "quantum.h"
21
22#define ROW_SHIFTER ((uint16_t)1)
23
24static const pin_t row_pins[MATRIX_ROWS] = MATRIX_ROW_PINS;
25static const pin_t col_pins[MATRIX_COLS] = MATRIX_COL_PINS;
26
27static void select_row(uint8_t row) {
28 setPinOutput(row_pins[row]);
29 writePinLow(row_pins[row]);
30}
31
32static void unselect_row(uint8_t row) {
33 setPinInputHigh(row_pins[row]);
34}
35
36static void unselect_rows(void) {
37 for (uint8_t x = 0; x < MATRIX_ROWS; x++) {
38 setPinInputHigh(row_pins[x]);
39 }
40}
41
42static void init_pins(void) {
43 unselect_rows();
44 for (uint8_t x = 0; x < MATRIX_COLS; x++) {
45 setPinInputHigh(col_pins[x]);
46 }
47}
48
49static bool read_cols_on_row(matrix_row_t current_matrix[], uint8_t current_row) {
50 // Store last value of row prior to reading
51 matrix_row_t last_row_value = current_matrix[current_row];
52
53 // Clear data in matrix row
54 current_matrix[current_row] = 0;
55
56 // Select row and wait for row selecton to stabilize
57 select_row(current_row);
58 matrix_io_delay();
59
60 // For each col...
61 for (uint8_t col_index = 0; col_index < MATRIX_COLS; col_index++) {
62
63 // skip reading when index equals (= pin itself)
64 if (col_index != current_row) {
65 // Check col pin pin_state
66 if (readPin(col_pins[col_index]) == 0) {
67 // Pin LO, set col bit
68 current_matrix[current_row] |= (ROW_SHIFTER << col_index);
69 } else {
70 // Pin HI, clear col bit
71 current_matrix[current_row] &= ~(ROW_SHIFTER << col_index);
72 }
73 }
74 }
75
76 // Unselect row
77 unselect_row(current_row);
78
79 return (last_row_value != current_matrix[current_row]);
80}
81
82void matrix_init_custom(void) {
83 // initialize key pins
84 init_pins();
85
86 matrix_init_quantum();
87}
88
89bool matrix_scan_custom(matrix_row_t current_matrix[]) {
90 bool changed = false;
91
92 // Set row, read cols
93 for (uint8_t current_row = 0; current_row < MATRIX_ROWS; current_row++) {
94 changed |= read_cols_on_row(current_matrix, current_row);
95 }
96
97 matrix_scan_quantum();
98 return changed;
99}
diff --git a/keyboards/jones/v03_1/readme.md b/keyboards/jones/v03_1/readme.md
new file mode 100644
index 000000000..3cd7bb72e
--- /dev/null
+++ b/keyboards/jones/v03_1/readme.md
@@ -0,0 +1,24 @@
1# Jones v.0.3.1
2
3![Jones, ANSI style](https://github.com/jpskenn/Jones/raw/master/assets/IMG_2204.jpeg)
4
5![Jones, JP style](https://github.com/jpskenn/Jones/raw/master/assets/DSC_7189.jpeg)
6
7A 60% keyboard combined with Ortho-Linear and Row-staggered. It has gapless R2-R3 row.
8GH60 case compatible PCB and keyplate.
9
10* Keyboard Maintainer: [jpskenn](https://github.com/jpskenn)
11* Hardware Supported: Jones PCB, Keyplate
12* Hardware Availability: [GitHub](https://github.com/jpskenn/Jones), [BOOTH](https://jpskenn.booth.pm)
13
14Make example for this keyboard (after setting up your build environment):
15
16 make jones/v03_1:default
17
18Flashing example for this keyboard ([using the command line](https://docs.qmk.fm/#/newbs_flashing?id=flash-your-keyboard-from-the-command-line)):
19
20 make jones/v03_1:default:flash
21
22To reset the keyboard into bootloader mode, press the reset switch on the underside.
23
24See 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/jones/v03_1/rules.mk b/keyboards/jones/v03_1/rules.mk
new file mode 100644
index 000000000..07203872f
--- /dev/null
+++ b/keyboards/jones/v03_1/rules.mk
@@ -0,0 +1,29 @@
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 = no # Virtual DIP switch configuration
11MOUSEKEY_ENABLE = no # 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 = yes # Enable keyboard RGB underglow
21BLUETOOTH_ENABLE = no # Enable Bluetooth
22AUDIO_ENABLE = yes # Audio output
23
24ENCODER_ENABLE = yes # Rotary Encoder
25
26CUSTOM_MATRIX = lite # Custom matrix for "Round-Robin Matrix"
27SRC += matrix.c
28
29LTO_ENABLE = yes
diff --git a/keyboards/jones/v03_1/v03_1.c b/keyboards/jones/v03_1/v03_1.c
new file mode 100644
index 000000000..33ff0051a
--- /dev/null
+++ b/keyboards/jones/v03_1/v03_1.c
@@ -0,0 +1,27 @@
1/* Copyright 2020 Takeshi Nishio
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 "v03_1.h"
18
19#if defined(AUDIO_ENABLE) && defined(MUSIC_MAP)
20const uint8_t music_map[MATRIX_ROWS][MATRIX_COLS] = LAYOUT_all(
21 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67,
22 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52,
23 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
24 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
25 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11
26);
27#endif
diff --git a/keyboards/jones/v03_1/v03_1.h b/keyboards/jones/v03_1/v03_1.h
new file mode 100644
index 000000000..38f894c5d
--- /dev/null
+++ b/keyboards/jones/v03_1/v03_1.h
@@ -0,0 +1,105 @@
1/* Copyright 2020 Takeshi Nishio
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/*
22FULL 11x11 ROUND-ROBIN MATRIX for Reference
23{ KC_NO, k21, k31, k41, k51, k61, k71, k81, k91, ka1, kb1 }, \
24{ k12, KC_NO, k32, k42, k52, k62, k72, k82, k92, ka2, kb2 }, \
25{ k13, k23, KC_NO, k43, k53, k63, k73, k83, k93, ka3, kb3 }, \
26{ k14, k24, k34, KC_NO, k54, k64, k74, k84, k94, ka4, kb4 }, \
27{ k15, k25, k35, k45, KC_NO, k65, k75, k85, k95, ka5, kb5 }, \
28{ k16, k26, k36, k46, k56, KC_NO, k76, k86, k96, ka6, kb6 }, \
29{ k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
30{ k18, k28, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
31{ k19, k29, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
32{ k1a, k2a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, kba }, \
33{ k1b, k2b, k3b, k4b, k5b, k6b, k7b, k8b, k9b, kab, KC_NO } \
34*/
35
36/* This is a shortcut to help you visually see your layout.
37 *
38 * The first section contains all of the arguments representing the physical
39 * layout of the board and position of the keys.
40 *
41 * The second converts the arguments into a two-dimensional array which
42 * represents the switch matrix.
43 */
44#define LAYOUT_all( \
45 k17, k27, k37, k47, k57, k67, k76, k86, k96, ka6, kb6, k81, k91, ka1, kb1, \
46 k18, k38, k48, k58, k68, k78, k87, k97, ka7, kb7, k82, k92, ka2, kb2, \
47 k19, k39, k49, k59, k69, k79, k89, k98, ka8, kb8, k83, k93, ka3, kb3, \
48 k1a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, ka9, kb9, k84, k94, ka4, kb4, \
49 k1b, k2b, k3b, k4b, k6b, k8b, k9b, kab, k85, k95, ka5, kb5 \
50) \
51{ \
52 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k81, k91, ka1, kb1 }, \
53 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k82, k92, ka2, kb2 }, \
54 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k83, k93, ka3, kb3 }, \
55 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k84, k94, ka4, kb4 }, \
56 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k85, k95, ka5, kb5 }, \
57 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k76, k86, k96, ka6, kb6 }, \
58 { k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
59 { k18, KC_NO, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
60 { k19, KC_NO, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
61 { k1a, KC_NO, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, KC_NO }, \
62 { k1b, k2b, k3b, k4b, KC_NO, k6b, KC_NO, k8b, k9b, kab, KC_NO } \
63}
64
65#define LAYOUT_ansi( \
66 k17, k27, k37, k47, k57, k67, k76, k86, k96, ka6, kb6, k81, k91, ka1, kb1, \
67 k18, k38, k48, k58, k68, k78, k87, k97, ka7, kb7, k82, k92, ka2, kb2, \
68 k19, k39, k49, k59, k69, k79, k89, k98, ka8, kb8, k83, k93, kb3, \
69 k1a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, ka9, kb9, k84, k94, ka4, kb4, \
70 k1b, k2b, k3b, k4b, k6b, k8b, k9b, kab, k85, k95, ka5, kb5 \
71) \
72{ \
73 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k81, k91, ka1, kb1 }, \
74 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k82, k92, ka2, kb2 }, \
75 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k83, k93, KC_NO, kb3 }, \
76 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k84, k94, ka4, kb4 }, \
77 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k85, k95, ka5, kb5 }, \
78 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k76, k86, k96, ka6, kb6 }, \
79 { k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
80 { k18, KC_NO, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
81 { k19, KC_NO, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
82 { k1a, KC_NO, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, KC_NO }, \
83 { k1b, k2b, k3b, k4b, KC_NO, k6b, KC_NO, k8b, k9b, kab, KC_NO } \
84}
85
86#define LAYOUT_jp( \
87 k17, k27, k37, k47, k57, k67, k76, k86, k96, ka6, kb6, k81, k91, ka1, kb1, \
88 k18, k38, k48, k58, k68, k78, k87, k97, ka7, kb7, k82, ka2, kb2, \
89 k19, k39, k49, k59, k69, k79, k89, k98, ka8, kb8, k83, k93, ka3, kb3, \
90 k1a, k3a, k4a, k5a, k6a, k7a, k8a, k9a, ka9, kb9, k84, k94, ka4, kb4, \
91 k1b, k2b, k3b, k4b, k6b, k8b, k9b, kab, k85, k95, ka5, kb5 \
92) \
93{ \
94 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k81, k91, ka1, kb1 }, \
95 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k82, KC_NO, ka2, kb2 }, \
96 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k83, k93, ka3, kb3 }, \
97 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k84, k94, ka4, kb4 }, \
98 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k85, k95, ka5, kb5 }, \
99 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, k76, k86, k96, ka6, kb6 }, \
100 { k17, k27, k37, k47, k57, k67, KC_NO, k87, k97, ka7, kb7 }, \
101 { k18, KC_NO, k38, k48, k58, k68, k78, KC_NO, k98, ka8, kb8 }, \
102 { k19, KC_NO, k39, k49, k59, k69, k79, k89, KC_NO, ka9, kb9 }, \
103 { k1a, KC_NO, k3a, k4a, k5a, k6a, k7a, k8a, k9a, KC_NO, KC_NO }, \
104 { k1b, k2b, k3b, k4b, KC_NO, k6b, KC_NO, k8b, k9b, kab, KC_NO } \
105}