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/chavdai40/rev2/config.h | 6 ------ keyboards/chavdai40/rev2/info.json | 5 +++++ 2 files changed, 5 insertions(+), 6 deletions(-) (limited to 'keyboards/chavdai40/rev2') diff --git a/keyboards/chavdai40/rev2/config.h b/keyboards/chavdai40/rev2/config.h index c6f7884275..277219f16d 100644 --- a/keyboards/chavdai40/rev2/config.h +++ b/keyboards/chavdai40/rev2/config.h @@ -22,9 +22,3 @@ /* usb power settings */ #define USB_MAX_POWER_CONSUMPTION 100 - -#define MATRIX_ROW_PINS { A0, A15, B5, B6 } -#define MATRIX_COL_PINS { B7, B4, B3, A8, B1, B0, A7, A6, A5, A4, A3, A2, A1 } - -/* COL2ROW, ROW2COL*/ -#define DIODE_DIRECTION COL2ROW diff --git a/keyboards/chavdai40/rev2/info.json b/keyboards/chavdai40/rev2/info.json index 5ffacfd303..3216cb565d 100644 --- a/keyboards/chavdai40/rev2/info.json +++ b/keyboards/chavdai40/rev2/info.json @@ -3,6 +3,11 @@ "usb": { "device_version": "0.0.2" }, + "matrix_pins": { + "cols": ["B7", "B4", "B3", "A8", "B1", "B0", "A7", "A6", "A5", "A4", "A3", "A2", "A1"], + "rows": ["A0", "A15", "B5", "B6"] + }, + "diode_direction": "COL2ROW", "processor": "STM32F042", "bootloader": "stm32-dfu" } -- cgit v1.2.3 From 02ccc50e6085a9d0a4f38f252960e2d14ffe4d1f Mon Sep 17 00:00:00 2001 From: Ryan Date: Fri, 17 Mar 2023 14:02:04 +1100 Subject: Remove more empty headers (#20155) --- keyboards/chavdai40/rev2/rev2.c | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 keyboards/chavdai40/rev2/rev2.c (limited to 'keyboards/chavdai40/rev2') diff --git a/keyboards/chavdai40/rev2/rev2.c b/keyboards/chavdai40/rev2/rev2.c deleted file mode 100644 index 6bd488c299..0000000000 --- a/keyboards/chavdai40/rev2/rev2.c +++ /dev/null @@ -1,16 +0,0 @@ -/* Copyright 2020 t-miyajima - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -#include "rev2.h" -- cgit v1.2.3 From f111bea3cda240b7c54bff2e12b5043b7b0797f7 Mon Sep 17 00:00:00 2001 From: Ryan Date: Tue, 25 Apr 2023 02:38:35 +1000 Subject: Move miscellaneous layouts to data driven (#20516) --- keyboards/chavdai40/rev2/info.json | 104 ++++++++++++++++++++++++++++++++++++- keyboards/chavdai40/rev2/rev2.h | 49 ----------------- 2 files changed, 103 insertions(+), 50 deletions(-) delete mode 100644 keyboards/chavdai40/rev2/rev2.h (limited to 'keyboards/chavdai40/rev2') diff --git a/keyboards/chavdai40/rev2/info.json b/keyboards/chavdai40/rev2/info.json index 3216cb565d..97cd474fa0 100644 --- a/keyboards/chavdai40/rev2/info.json +++ b/keyboards/chavdai40/rev2/info.json @@ -9,5 +9,107 @@ }, "diode_direction": "COL2ROW", "processor": "STM32F042", - "bootloader": "stm32-dfu" + "bootloader": "stm32-dfu", + "layouts": { + "LAYOUT_42key": { + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0, "w": 1.5}, + {"matrix": [0, 1], "x": 1.5, "y": 0}, + {"matrix": [0, 2], "x": 2.5, "y": 0}, + {"matrix": [0, 3], "x": 3.5, "y": 0}, + {"matrix": [0, 4], "x": 4.5, "y": 0}, + {"matrix": [0, 5], "x": 5.5, "y": 0}, + {"matrix": [0, 6], "x": 6.5, "y": 0}, + {"matrix": [0, 7], "x": 7.5, "y": 0}, + {"matrix": [0, 8], "x": 8.5, "y": 0}, + {"matrix": [0, 9], "x": 9.5, "y": 0}, + {"matrix": [0, 10], "x": 10.5, "y": 0}, + {"matrix": [0, 11], "x": 11.5, "y": 0}, + {"matrix": [0, 12], "x": 12.5, "y": 0, "w": 1.5}, + + {"matrix": [1, 0], "x": 0, "y": 1, "w": 1.75}, + {"matrix": [1, 1], "x": 1.75, "y": 1}, + {"matrix": [1, 2], "x": 2.75, "y": 1}, + {"matrix": [1, 3], "x": 3.75, "y": 1}, + {"matrix": [1, 4], "x": 4.75, "y": 1}, + {"matrix": [1, 5], "x": 5.75, "y": 1}, + {"matrix": [1, 6], "x": 6.75, "y": 1}, + {"matrix": [1, 7], "x": 7.75, "y": 1}, + {"matrix": [1, 8], "x": 8.75, "y": 1}, + {"matrix": [1, 9], "x": 9.75, "y": 1}, + {"matrix": [1, 10], "x": 10.75, "y": 1}, + {"matrix": [1, 11], "x": 11.75, "y": 1, "w": 2.25}, + + {"matrix": [2, 0], "x": 0, "y": 2, "w": 2.25}, + {"matrix": [2, 1], "x": 2.25, "y": 2}, + {"matrix": [2, 2], "x": 3.25, "y": 2}, + {"matrix": [2, 3], "x": 4.25, "y": 2}, + {"matrix": [2, 4], "x": 5.25, "y": 2}, + {"matrix": [2, 5], "x": 6.25, "y": 2}, + {"matrix": [2, 6], "x": 7.25, "y": 2}, + {"matrix": [2, 7], "x": 8.25, "y": 2}, + {"matrix": [2, 8], "x": 9.25, "y": 2}, + {"matrix": [2, 9], "x": 10.25, "y": 2}, + {"matrix": [2, 10], "x": 11.25, "y": 2, "w": 1.25}, + {"matrix": [2, 11], "x": 12.5, "y": 2, "w": 1.25}, + + {"matrix": [3, 0], "x": 1.38, "y": 3, "w": 1.25}, + {"matrix": [3, 1], "x": 2.63, "y": 3, "w": 1.25}, + {"matrix": [3, 5], "x": 3.88, "y": 3, "w": 6.25}, + {"matrix": [3, 9], "x": 10.13, "y": 3, "w": 1.25}, + {"matrix": [3, 10], "x": 11.38, "y": 3, "w": 1.25} + ] + }, + "LAYOUT_44key": { + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0, "w": 1.5}, + {"matrix": [0, 1], "x": 1.5, "y": 0}, + {"matrix": [0, 2], "x": 2.5, "y": 0}, + {"matrix": [0, 3], "x": 3.5, "y": 0}, + {"matrix": [0, 4], "x": 4.5, "y": 0}, + {"matrix": [0, 5], "x": 5.5, "y": 0}, + {"matrix": [0, 6], "x": 6.5, "y": 0}, + {"matrix": [0, 7], "x": 7.5, "y": 0}, + {"matrix": [0, 8], "x": 8.5, "y": 0}, + {"matrix": [0, 9], "x": 9.5, "y": 0}, + {"matrix": [0, 10], "x": 10.5, "y": 0}, + {"matrix": [0, 11], "x": 11.5, "y": 0}, + {"matrix": [0, 12], "x": 12.5, "y": 0, "w": 1.5}, + + {"matrix": [1, 0], "x": 0, "y": 1, "w": 1.75}, + {"matrix": [1, 1], "x": 1.75, "y": 1}, + {"matrix": [1, 2], "x": 2.75, "y": 1}, + {"matrix": [1, 3], "x": 3.75, "y": 1}, + {"matrix": [1, 4], "x": 4.75, "y": 1}, + {"matrix": [1, 5], "x": 5.75, "y": 1}, + {"matrix": [1, 6], "x": 6.75, "y": 1}, + {"matrix": [1, 7], "x": 7.75, "y": 1}, + {"matrix": [1, 8], "x": 8.75, "y": 1}, + {"matrix": [1, 9], "x": 9.75, "y": 1}, + {"matrix": [1, 10], "x": 10.75, "y": 1}, + {"matrix": [1, 11], "x": 11.75, "y": 1, "w": 2.25}, + + {"matrix": [2, 0], "x": 0, "y": 2, "w": 2.25}, + {"matrix": [2, 1], "x": 2.25, "y": 2}, + {"matrix": [2, 2], "x": 3.25, "y": 2}, + {"matrix": [2, 3], "x": 4.25, "y": 2}, + {"matrix": [2, 4], "x": 5.25, "y": 2}, + {"matrix": [2, 5], "x": 6.25, "y": 2}, + {"matrix": [2, 6], "x": 7.25, "y": 2}, + {"matrix": [2, 7], "x": 8.25, "y": 2}, + {"matrix": [2, 8], "x": 9.25, "y": 2}, + {"matrix": [2, 9], "x": 10.25, "y": 2}, + {"matrix": [2, 10], "x": 11.25, "y": 2, "w": 1.25}, + {"matrix": [2, 11], "x": 12.5, "y": 2, "w": 1.25}, + + {"matrix": [3, 0], "x": 1.38, "y": 3, "w": 1.25}, + {"matrix": [3, 1], "x": 2.63, "y": 3, "w": 1.25}, + {"matrix": [3, 3], "x": 3.88, "y": 3, "w": 2.25}, + {"matrix": [3, 5], "x": 6.13, "y": 3, "w": 2.75}, + {"matrix": [3, 8], "x": 8.88, "y": 3, "w": 1.25}, + {"matrix": [3, 9], "x": 10.13, "y": 3, "w": 1.25}, + {"matrix": [3, 10], "x": 11.38, "y": 3, "w": 1.25} + ] + } + } } diff --git a/keyboards/chavdai40/rev2/rev2.h b/keyboards/chavdai40/rev2/rev2.h deleted file mode 100644 index c5899e24bc..0000000000 --- a/keyboards/chavdai40/rev2/rev2.h +++ /dev/null @@ -1,49 +0,0 @@ -/* Copyright 2020 t-miyajima - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - - -#pragma once - -#include "quantum.h" - -#define XXX KC_NO - -// This a shortcut to help you visually see your layout. - -#define LAYOUT_44key( \ - k01, k02, k03, k04, k05, k06, k07, k08, k09, k10, 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 \ -) { \ - { k01, k02, k03, k04, k05, k06, k07, k08, k09, k10, k11, k12, k13 }, \ - { k14, k15, k16, k17, k18, k19, k20, k21, k22, k23, k24, k25, XXX }, \ - { k26, k27, k28, k29, k30, k31, k32, k33, k34, k35, k36, k37, XXX }, \ - { k38, k39, XXX, k40, XXX, k41, XXX, XXX, k42, k43, k44, XXX, XXX } \ -} - -#define LAYOUT_42key( \ - k01, k02, k03, k04, k05, k06, k07, k08, k09, k10, 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, k41, k43, k44 \ -) { \ - { k01, k02, k03, k04, k05, k06, k07, k08, k09, k10, k11, k12, k13 }, \ - { k14, k15, k16, k17, k18, k19, k20, k21, k22, k23, k24, k25, XXX }, \ - { k26, k27, k28, k29, k30, k31, k32, k33, k34, k35, k36, k37, XXX }, \ - { k38, k39, XXX, XXX, XXX, k41, XXX, XXX, XXX, k43, k44, XXX, XXX } \ -} - -- cgit v1.2.3 From 2944e938703e2049bb6262a0ab31e701d27e8ab3 Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 1 May 2023 17:37:12 +1000 Subject: Move `USB_MAX_POWER_CONSUMPTION` to data driven (#20648) --- keyboards/chavdai40/rev2/config.h | 3 --- keyboards/chavdai40/rev2/info.json | 3 ++- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'keyboards/chavdai40/rev2') diff --git a/keyboards/chavdai40/rev2/config.h b/keyboards/chavdai40/rev2/config.h index 277219f16d..8f5f5496a2 100644 --- a/keyboards/chavdai40/rev2/config.h +++ b/keyboards/chavdai40/rev2/config.h @@ -19,6 +19,3 @@ #define EARLY_INIT_PERFORM_BOOTLOADER_JUMP FALSE - -/* usb power settings */ -#define USB_MAX_POWER_CONSUMPTION 100 diff --git a/keyboards/chavdai40/rev2/info.json b/keyboards/chavdai40/rev2/info.json index 97cd474fa0..acefcabdc7 100644 --- a/keyboards/chavdai40/rev2/info.json +++ b/keyboards/chavdai40/rev2/info.json @@ -1,7 +1,8 @@ { "keyboard_name": "Chavdai40 rev2", "usb": { - "device_version": "0.0.2" + "device_version": "0.0.2", + "max_power": 100 }, "matrix_pins": { "cols": ["B7", "B4", "B3", "A8", "B1", "B0", "A7", "A6", "A5", "A4", "A3", "A2", "A1"], -- cgit v1.2.3