diff options
Diffstat (limited to 'keyboards/macro3')
-rw-r--r-- | keyboards/macro3/config.h | 25 | ||||
-rw-r--r-- | keyboards/macro3/info.json | 30 | ||||
-rw-r--r-- | keyboards/macro3/macro3.c | 2 | ||||
-rw-r--r-- | keyboards/macro3/macro3.h | 16 | ||||
-rw-r--r-- | keyboards/macro3/post_config.h | 2 | ||||
-rw-r--r-- | keyboards/macro3/rules.mk | 6 |
6 files changed, 25 insertions, 56 deletions
diff --git a/keyboards/macro3/config.h b/keyboards/macro3/config.h deleted file mode 100644 index bfd60418a7..0000000000 --- a/keyboards/macro3/config.h +++ /dev/null @@ -1,25 +0,0 @@ -/* Copyright 2020 David Philip Barr <@davidphilipbarr> - * Copyright 2021 @filterpaper - * SPDX-License-Identifier: GPL-2.0+ - */ - -#pragma once -#include "config_common.h" - -/* key matrix size */ -#define MATRIX_ROWS 2 -#define MATRIX_COLS 4 - -/* key matrix pins */ -#define DIRECT_PINS { \ - { D7, C6, D4, D1 }, \ - { B1, B4, B5, B3 } \ -} - -#define ENCODERS_PAD_A { D2, F7 } -#define ENCODERS_PAD_B { D3, F6 } - - -/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ -#define DEBOUNCE 5 - diff --git a/keyboards/macro3/info.json b/keyboards/macro3/info.json index b95ab110f3..780dfca303 100644 --- a/keyboards/macro3/info.json +++ b/keyboards/macro3/info.json @@ -8,21 +8,35 @@ "pid": "0x3388", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"}, + {"pin_a": "F7", "pin_b": "F6"} + ] + }, + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "matrix_pins": { + "direct": [ + ["D7", "C6", "D4", "D1"], + ["B1", "B4", "B5", "B3"] + ] + }, "layout_aliases": { "LAYOUT": "LAYOUT_ortho_2x4" }, "layouts": { "LAYOUT_ortho_2x4": { "layout": [ - {"x": 0, "y": 0}, - {"x": 1, "y": 0}, - {"x": 2, "y": 0}, - {"x": 3, "y": 0}, + {"x": 0, "y": 0, "matrix": [0, 0]}, + {"x": 1, "y": 0, "matrix": [0, 1]}, + {"x": 2, "y": 0, "matrix": [0, 2]}, + {"x": 3, "y": 0, "matrix": [0, 3]}, - {"x": 0, "y": 1}, - {"x": 1, "y": 1}, - {"x": 2, "y": 1}, - {"x": 3, "y": 1} + {"x": 0, "y": 1, "matrix": [1, 0]}, + {"x": 1, "y": 1, "matrix": [1, 1]}, + {"x": 2, "y": 1, "matrix": [1, 2]}, + {"x": 3, "y": 1, "matrix": [1, 3]} ] } } diff --git a/keyboards/macro3/macro3.c b/keyboards/macro3/macro3.c index 0937abfc83..54fce243ab 100644 --- a/keyboards/macro3/macro3.c +++ b/keyboards/macro3/macro3.c @@ -3,7 +3,7 @@ * SPDX-License-Identifier: GPL-2.0+ */ -#include "macro3.h" +#include "quantum.h" #ifdef ENCODER_ENABLE bool encoder_update_kb(uint8_t index, bool clockwise) { diff --git a/keyboards/macro3/macro3.h b/keyboards/macro3/macro3.h deleted file mode 100644 index 4a5071cbfe..0000000000 --- a/keyboards/macro3/macro3.h +++ /dev/null @@ -1,16 +0,0 @@ -/* Copyright 2020 David Philip Barr <@davidphilipbarr> - * Copyright 2021 @filterpaper - * SPDX-License-Identifier: GPL-2.0+ - */ - -#include "quantum.h" - -#define LAYOUT_ortho_2x4( \ - K00, K01, K02, K03, \ - K10, K11, K12, K13 \ -) \ -{ \ - { K00, K01, K02, K03 }, \ - { K10, K11, K12, K13 } \ -} - diff --git a/keyboards/macro3/post_config.h b/keyboards/macro3/post_config.h index 0f94fe19e1..4e2b6cf1b9 100644 --- a/keyboards/macro3/post_config.h +++ b/keyboards/macro3/post_config.h @@ -3,6 +3,8 @@ * SPDX-License-Identifier: GPL-2.0+ */ +#pragma once + /* Top right key */ #ifndef BOOTMAGIC_LITE_ROW # define BOOTMAGIC_LITE_ROW 0 diff --git a/keyboards/macro3/rules.mk b/keyboards/macro3/rules.mk index 77d9fdb410..b03b6fa905 100644 --- a/keyboards/macro3/rules.mk +++ b/keyboards/macro3/rules.mk @@ -1,9 +1,3 @@ -# MCU name -MCU = atmega32u4 - -# Bootloader selection -BOOTLOADER = atmel-dfu - # Build Options # change yes to no to disable # |