From 76cc7fe109d66c1e0ac16b27b2f691e7d55792d3 Mon Sep 17 00:00:00 2001 From: Ryan Date: Sat, 11 Mar 2023 00:32:05 +1100 Subject: Move matrix config to info.json, part 6 (#20019) --- keyboards/chocofly/v1/config.h | 9 --------- keyboards/chocofly/v1/info.json | 5 +++++ 2 files changed, 5 insertions(+), 9 deletions(-) delete mode 100644 keyboards/chocofly/v1/config.h (limited to 'keyboards/chocofly') diff --git a/keyboards/chocofly/v1/config.h b/keyboards/chocofly/v1/config.h deleted file mode 100644 index a1886ffafa..0000000000 --- a/keyboards/chocofly/v1/config.h +++ /dev/null @@ -1,9 +0,0 @@ -// Copyright 2022 Vitaly Volkov (@vlkv) -// SPDX-License-Identifier: GPL-2.0-or-later - -#pragma once - -#define MATRIX_ROW_PINS { D1, D0, D4, C6, D7, E6, B4, B5 } -#define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2, B6 } - -#define DIODE_DIRECTION COL2ROW diff --git a/keyboards/chocofly/v1/info.json b/keyboards/chocofly/v1/info.json index ab4fde45e6..e7578ae942 100644 --- a/keyboards/chocofly/v1/info.json +++ b/keyboards/chocofly/v1/info.json @@ -8,6 +8,11 @@ "pid": "0x1001", "device_version": "0.0.1" }, + "matrix_pins": { + "cols": ["F4", "F5", "F6", "F7", "B1", "B3", "B2", "B6"], + "rows": ["D1", "D0", "D4", "C6", "D7", "E6", "B4", "B5"] + }, + "diode_direction": "COL2ROW", "encoder": { "rotary": [ {"pin_a": "D3", "pin_b": "D2", "resolution": 2} -- cgit v1.2.3 From 9dbee3e23d28e5f61384bbb5650505a572022341 Mon Sep 17 00:00:00 2001 From: Ryan Date: Thu, 16 Mar 2023 20:18:33 +1100 Subject: Remove useless "ifdef KEYBOARD_*" (#20078) Co-authored-by: Nick Brassel --- keyboards/chocofly/chocofly.c | 2 +- keyboards/chocofly/chocofly.h | 10 ---------- keyboards/chocofly/v1/v1.c | 4 ---- keyboards/chocofly/v1/v1.h | 2 -- 4 files changed, 1 insertion(+), 17 deletions(-) delete mode 100644 keyboards/chocofly/chocofly.h delete mode 100644 keyboards/chocofly/v1/v1.c (limited to 'keyboards/chocofly') diff --git a/keyboards/chocofly/chocofly.c b/keyboards/chocofly/chocofly.c index 8ae38602ab..0f00afe2f9 100644 --- a/keyboards/chocofly/chocofly.c +++ b/keyboards/chocofly/chocofly.c @@ -1,7 +1,7 @@ // Copyright 2022 Vitaly Volkov (@vlkv) // SPDX-License-Identifier: GPL-2.0-or-later -#include "chocofly.h" +#include "quantum.h" #ifdef ENCODER_ENABLE bool encoder_update_kb(uint8_t index, bool clockwise) { diff --git a/keyboards/chocofly/chocofly.h b/keyboards/chocofly/chocofly.h deleted file mode 100644 index 7d94774625..0000000000 --- a/keyboards/chocofly/chocofly.h +++ /dev/null @@ -1,10 +0,0 @@ -// Copyright 2022 Vitaly Volkov (@vlkv) -// SPDX-License-Identifier: GPL-2.0-or-later - -#pragma once - -#ifdef KEYBOARD_chocofly_v1 - #include "v1.h" -#endif - -#include "quantum.h" diff --git a/keyboards/chocofly/v1/v1.c b/keyboards/chocofly/v1/v1.c deleted file mode 100644 index 6c142b7453..0000000000 --- a/keyboards/chocofly/v1/v1.c +++ /dev/null @@ -1,4 +0,0 @@ -// Copyright 2022 Vitaly Volkov (@vlkv) -// SPDX-License-Identifier: GPL-2.0-or-later - -#include "v1.h" diff --git a/keyboards/chocofly/v1/v1.h b/keyboards/chocofly/v1/v1.h index 5f07f6c325..bf3c93f8be 100644 --- a/keyboards/chocofly/v1/v1.h +++ b/keyboards/chocofly/v1/v1.h @@ -3,8 +3,6 @@ #pragma once -#include "chocofly.h" - #include "quantum.h" #define K__ KC_NO -- cgit v1.2.3 From 36ab0c0aaa613fe0946e10133315b071c0d87012 Mon Sep 17 00:00:00 2001 From: jack <0x6A73@pm.me> Date: Mon, 3 Apr 2023 10:18:17 -0600 Subject: Add core/fallback encoder behaviour (#20320) --- keyboards/chocofly/chocofly.c | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 keyboards/chocofly/chocofly.c (limited to 'keyboards/chocofly') diff --git a/keyboards/chocofly/chocofly.c b/keyboards/chocofly/chocofly.c deleted file mode 100644 index 0f00afe2f9..0000000000 --- a/keyboards/chocofly/chocofly.c +++ /dev/null @@ -1,16 +0,0 @@ -// Copyright 2022 Vitaly Volkov (@vlkv) -// SPDX-License-Identifier: GPL-2.0-or-later - -#include "quantum.h" - -#ifdef ENCODER_ENABLE -bool encoder_update_kb(uint8_t index, bool clockwise) { - if (!encoder_update_user(index, clockwise)) { return false; } - if (clockwise) { - tap_code(KC_VOLU); - } else { - tap_code(KC_VOLD); - } - return false; -} -#endif -- cgit v1.2.3 From 5bd68e3695a82ff504c358c33445b4530c2a327f Mon Sep 17 00:00:00 2001 From: Ryan Date: Wed, 12 Apr 2023 13:42:51 +1000 Subject: Move single `LAYOUT`s to data driven (#20365) --- keyboards/chocofly/v1/info.json | 130 +++++++++++++++++++++------------------- keyboards/chocofly/v1/v1.h | 26 -------- 2 files changed, 69 insertions(+), 87 deletions(-) delete mode 100644 keyboards/chocofly/v1/v1.h (limited to 'keyboards/chocofly') diff --git a/keyboards/chocofly/v1/info.json b/keyboards/chocofly/v1/info.json index e7578ae942..f811a6b14b 100644 --- a/keyboards/chocofly/v1/info.json +++ b/keyboards/chocofly/v1/info.json @@ -23,71 +23,79 @@ "layouts": { "LAYOUT": { "layout": [ - { "label": "F1", "matrix": [0, 0], "x": 0, "y": 0.375 }, - { "label": "F2", "matrix": [1, 0], "x": 1, "y": 0.375 }, - { "label": "F3", "matrix": [0, 1], "x": 2, "y": 0.125 }, - { "label": "F4", "matrix": [1, 1], "x": 3, "y": 0 }, - { "label": "F5", "matrix": [0, 2], "x": 4, "y": 0.125 }, - { "label": "F6", "matrix": [1, 2], "x": 5, "y": 0.25 }, - { "label": "F7", "matrix": [1, 5], "x": 11.5, "y": 0.25 }, - { "label": "F8", "matrix": [0, 5], "x": 12.5, "y": 0.125 }, - { "label": "F9", "matrix": [1, 6], "x": 13.5, "y": 0 }, - { "label": "F10", "matrix": [0, 6], "x": 14.5, "y": 0.125 }, - { "label": "F11", "matrix": [1, 7], "x": 15.5, "y": 0.375 }, - { "label": "F12", "matrix": [0, 7], "x": 16.5, "y": 0.375 }, + {"matrix": [0, 0], "x": 0, "y": 0.375}, + {"matrix": [1, 0], "x": 1, "y": 0.375}, + {"matrix": [0, 1], "x": 2, "y": 0.125}, + {"matrix": [1, 1], "x": 3, "y": 0}, + {"matrix": [0, 2], "x": 4, "y": 0.125}, + {"matrix": [1, 2], "x": 5, "y": 0.25}, - { "label": "Tab", "matrix": [2, 0], "x": 0, "y": 1.375 }, - { "label": "Q", "matrix": [3, 0], "x": 1, "y": 1.375 }, - { "label": "W", "matrix": [2, 1], "x": 2, "y": 1.125 }, - { "label": "E", "matrix": [3, 1], "x": 3, "y": 1 }, - { "label": "R", "matrix": [2, 2], "x": 4, "y": 1.125 }, - { "label": "T", "matrix": [3, 2], "x": 5, "y": 1.25 }, - { "label": "Y", "matrix": [3, 5], "x": 11.5, "y": 1.25 }, - { "label": "U", "matrix": [2, 5], "x": 12.5, "y": 1.125 }, - { "label": "I", "matrix": [3, 6], "x": 13.5, "y": 1 }, - { "label": "O", "matrix": [2, 6], "x": 14.5, "y": 1.125 }, - { "label": "P", "matrix": [3, 7], "x": 15.5, "y": 1.375 }, - { "label": "[{", "matrix": [2, 7], "x": 16.5, "y": 1.375 }, + {"matrix": [1, 5], "x": 11.5, "y": 0.25}, + {"matrix": [0, 5], "x": 12.5, "y": 0.125}, + {"matrix": [1, 6], "x": 13.5, "y": 0}, + {"matrix": [0, 6], "x": 14.5, "y": 0.125}, + {"matrix": [1, 7], "x": 15.5, "y": 0.375}, + {"matrix": [0, 7], "x": 16.5, "y": 0.375}, - { "label": "\\|", "matrix": [4, 0], "x": 0, "y": 2.375 }, - { "label": "A", "matrix": [5, 0], "x": 1, "y": 2.375 }, - { "label": "S", "matrix": [4, 1], "x": 2, "y": 2.125 }, - { "label": "D", "matrix": [5, 1], "x": 3, "y": 2 }, - { "label": "F", "matrix": [4, 2], "x": 4, "y": 2.125 }, - { "label": "G", "matrix": [5, 2], "x": 5, "y": 2.25 }, - { "label": "Mute", "matrix": [1, 3], "x": 6.5, "y": 2.375 }, - { "label": "H", "matrix": [5, 5], "x": 11.5, "y": 2.25 }, - { "label": "J", "matrix": [4, 5], "x": 12.5, "y": 2.125 }, - { "label": "K", "matrix": [5, 6], "x": 13.5, "y": 2 }, - { "label": "L", "matrix": [4, 6], "x": 14.5, "y": 2.125 }, - { "label": ";:", "matrix": [5, 7], "x": 15.5, "y": 2.375 }, - { "label": "'\"", "matrix": [4, 7], "x": 16.5, "y": 2.375 }, + {"matrix": [2, 0], "x": 0, "y": 1.375}, + {"matrix": [3, 0], "x": 1, "y": 1.375}, + {"matrix": [2, 1], "x": 2, "y": 1.125}, + {"matrix": [3, 1], "x": 3, "y": 1}, + {"matrix": [2, 2], "x": 4, "y": 1.125}, + {"matrix": [3, 2], "x": 5, "y": 1.25}, - { "label": "Ctrl", "matrix": [6, 0], "x": 0, "y": 3.375 }, - { "label": "Z", "matrix": [7, 0], "x": 1, "y": 3.375 }, - { "label": "X", "matrix": [6, 1], "x": 2, "y": 3.125 }, - { "label": "C", "matrix": [7, 1], "x": 3, "y": 3 }, - { "label": "V", "matrix": [6, 2], "x": 4, "y": 3.125 }, - { "label": "B", "matrix": [7, 2], "x": 5, "y": 3.25 }, - { "label": "`~", "matrix": [3, 3], "x": 6.25, "y": 3.375 }, - { "label": "Insert", "matrix": [2, 3], "x": 7.25, "y": 3.625 }, - { "label": "Print Screen", "matrix": [2, 4], "x": 9.25, "y": 3.625 }, - { "label": "]}", "matrix": [3, 4], "x": 10.25, "y": 3.375 }, - { "label": "N", "matrix": [7, 5], "x": 11.5, "y": 3.25 }, - { "label": "M", "matrix": [6, 5], "x": 12.5, "y": 3.125 }, - { "label": ",<", "matrix": [7, 6], "x": 13.5, "y": 3 }, - { "label": ".>", "matrix": [6, 6], "x": 14.5, "y": 3.125 }, - { "label": "/?", "matrix": [7, 7], "x": 15.5, "y": 3.375 }, - { "label": "Ctrl", "matrix": [6, 7], "x": 16.5, "y": 3.375 }, + {"matrix": [3, 5], "x": 11.5, "y": 1.25}, + {"matrix": [2, 5], "x": 12.5, "y": 1.125}, + {"matrix": [3, 6], "x": 13.5, "y": 1}, + {"matrix": [2, 6], "x": 14.5, "y": 1.125}, + {"matrix": [3, 7], "x": 15.5, "y": 1.375}, + {"matrix": [2, 7], "x": 16.5, "y": 1.375}, - { "label": "GUI", "matrix": [7, 3], "x": 3.5, "y": 4.125 }, - { "label": "Shift", "matrix": [6, 3], "x": 4.75, "y": 4.25 }, - { "label": "Space", "matrix": [5, 3], "x": 6, "y": 4.375 }, - { "label": "Alt", "matrix": [4, 3], "x": 7, "y": 4.625 }, - { "label": "Alt", "matrix": [4, 4], "x": 9.5, "y": 4.625 }, - { "label": "Fn", "matrix": [5, 4], "x": 10.5, "y": 4.375 }, - { "label": "Shift", "matrix": [6, 4], "x": 11.75, "y": 4.25 }, - { "label": "GUI", "matrix": [7, 4], "x": 13, "y": 4.125 } + {"matrix": [4, 0], "x": 0, "y": 2.375}, + {"matrix": [5, 0], "x": 1, "y": 2.375}, + {"matrix": [4, 1], "x": 2, "y": 2.125}, + {"matrix": [5, 1], "x": 3, "y": 2}, + {"matrix": [4, 2], "x": 4, "y": 2.125}, + {"matrix": [5, 2], "x": 5, "y": 2.25}, + + {"matrix": [1, 3], "x": 6.5, "y": 2.375}, + + {"matrix": [5, 5], "x": 11.5, "y": 2.25}, + {"matrix": [4, 5], "x": 12.5, "y": 2.125}, + {"matrix": [5, 6], "x": 13.5, "y": 2}, + {"matrix": [4, 6], "x": 14.5, "y": 2.125}, + {"matrix": [5, 7], "x": 15.5, "y": 2.375}, + {"matrix": [4, 7], "x": 16.5, "y": 2.375}, + + {"matrix": [6, 0], "x": 0, "y": 3.375}, + {"matrix": [7, 0], "x": 1, "y": 3.375}, + {"matrix": [6, 1], "x": 2, "y": 3.125}, + {"matrix": [7, 1], "x": 3, "y": 3}, + {"matrix": [6, 2], "x": 4, "y": 3.125}, + {"matrix": [7, 2], "x": 5, "y": 3.25}, + + {"matrix": [3, 3], "x": 6.25, "y": 3.375}, + {"matrix": [2, 3], "x": 7.25, "y": 3.625}, + + {"matrix": [2, 4], "x": 9.25, "y": 3.625}, + {"matrix": [3, 4], "x": 10.25, "y": 3.375}, + + {"matrix": [7, 5], "x": 11.5, "y": 3.25}, + {"matrix": [6, 5], "x": 12.5, "y": 3.125}, + {"matrix": [7, 6], "x": 13.5, "y": 3}, + {"matrix": [6, 6], "x": 14.5, "y": 3.125}, + {"matrix": [7, 7], "x": 15.5, "y": 3.375}, + {"matrix": [6, 7], "x": 16.5, "y": 3.375}, + + {"matrix": [7, 3], "x": 3.5, "y": 4.125}, + {"matrix": [6, 3], "x": 4.75, "y": 4.25}, + {"matrix": [5, 3], "x": 6, "y": 4.375}, + {"matrix": [4, 3], "x": 7, "y": 4.625}, + + {"matrix": [4, 4], "x": 9.5, "y": 4.625}, + {"matrix": [5, 4], "x": 10.5, "y": 4.375}, + {"matrix": [6, 4], "x": 11.75, "y": 4.25}, + {"matrix": [7, 4], "x": 13, "y": 4.125} ] } } diff --git a/keyboards/chocofly/v1/v1.h b/keyboards/chocofly/v1/v1.h deleted file mode 100644 index bf3c93f8be..0000000000 --- a/keyboards/chocofly/v1/v1.h +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright 2022 Vitaly Volkov (@vlkv) -// SPDX-License-Identifier: GPL-2.0-or-later - -#pragma once - -#include "quantum.h" - -#define K__ KC_NO - -#define LAYOUT( \ - K01, K07, K02, K08, K03, K09, K11, K04, K12, K05, K13, K06, \ - K14, K22, K15, K23, K16, K24, K27, K19, K28, K20, K29, K21, \ - K30, K38, K31, K39, K32, K40, K10, K43, K35, K44, K36, K45, K37, \ - K46, K54, K47, K55, K48, K56, K25, K17, K18, K26, K59, K51, K60, K52, K61, K53, \ - K57, K49, K41, K33, K34, K42, K50, K58 \ -) \ -{ \ - { K01, K02, K03, K__, K__, K04, K05, K06}, \ - { K07, K08, K09, K10, K__, K11, K12, K13}, \ - { K14, K15, K16, K17, K18, K19, K20, K21}, \ - { K22, K23, K24, K25, K26, K27, K28, K29}, \ - { K30, K31, K32, K33, K34, K35, K36, K37}, \ - { K38, K39, K40, K41, K42, K43, K44, K45}, \ - { K46, K47, K48, K49, K50, K51, K52, K53}, \ - { K54, K55, K56, K57, K58, K59, K60, K61} \ -} -- cgit v1.2.3