aboutsummaryrefslogtreecommitdiff
path: root/keyboards/handwired/z150
diff options
context:
space:
mode:
authorJoel Challis <git@zvecr.com>2024-06-25 03:25:05 +0100
committerGitHub <noreply@github.com>2024-06-25 03:25:05 +0100
commita2176f6a039b5f92ba4cb473f7a2de560b57dd86 (patch)
treed463c13b44a4139b619c2b3e4a9abab929bd1465 /keyboards/handwired/z150
parent751482580ed992acdbafc262c281e5d179cebe69 (diff)
downloadqmk_firmware-a2176f6a039b5f92ba4cb473f7a2de560b57dd86.tar.gz
qmk_firmware-a2176f6a039b5f92ba4cb473f7a2de560b57dd86.zip
Migrate `led_update_kb` implementations to DD (#23985)
Diffstat (limited to 'keyboards/handwired/z150')
-rw-r--r--keyboards/handwired/z150/config.h38
-rw-r--r--keyboards/handwired/z150/keyboard.json6
-rw-r--r--keyboards/handwired/z150/z150.c39
3 files changed, 6 insertions, 77 deletions
diff --git a/keyboards/handwired/z150/config.h b/keyboards/handwired/z150/config.h
deleted file mode 100644
index 7a054266ea..0000000000
--- a/keyboards/handwired/z150/config.h
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
-Copyright 2020 DmNosachev
-
-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 <http://www.gnu.org/licenses/>.
-*/
-
-#pragma once
-
-#define NUM_LOCK_LED_PIN B5
-#define SCROLL_LOCK_LED_PIN B4
-#define CAPS_LOCK_LED_PIN B3
-
-/*
- * Feature disable options
- * These options are also useful to firmware size reduction.
- */
-
-/* disable debug print */
-//#define NO_DEBUG
-
-/* disable print */
-//#define NO_PRINT
-
-/* disable action features */
-//#define NO_ACTION_LAYER
-//#define NO_ACTION_TAPPING
-//#define NO_ACTION_ONESHOT
diff --git a/keyboards/handwired/z150/keyboard.json b/keyboards/handwired/z150/keyboard.json
index 0658bb5233..38c92a6537 100644
--- a/keyboards/handwired/z150/keyboard.json
+++ b/keyboards/handwired/z150/keyboard.json
@@ -16,6 +16,12 @@
"mousekey": true,
"nkro": false
},
+ "indicators": {
+ "caps_lock": "B3",
+ "num_lock": "B5",
+ "scroll_lock": "B4",
+ "on_state": 0
+ },
"matrix_pins": {
"cols": ["B11", "B10", "B1", "B0", "A7", "A6", "A5", "A4"],
"rows": ["B13", "B14", "B15", "A8", "A9", "A3", "A10", "A1", "A2", "A15", "A0"]
diff --git a/keyboards/handwired/z150/z150.c b/keyboards/handwired/z150/z150.c
deleted file mode 100644
index ab6709eed7..0000000000
--- a/keyboards/handwired/z150/z150.c
+++ /dev/null
@@ -1,39 +0,0 @@
-/* Copyright 2020 DmNosachev
- *
- * 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 <http://www.gnu.org/licenses/>.
- */
-
-#include "quantum.h"
-
-void matrix_init_kb(void) {
- gpio_set_pin_output(NUM_LOCK_LED_PIN);
- gpio_set_pin_output(CAPS_LOCK_LED_PIN);
- gpio_set_pin_output(SCROLL_LOCK_LED_PIN);
-
- gpio_write_pin_low(NUM_LOCK_LED_PIN);
- gpio_write_pin_low(CAPS_LOCK_LED_PIN);
- gpio_write_pin_low(SCROLL_LOCK_LED_PIN);
-
- matrix_init_user();
-}
-
-bool led_update_kb(led_t led_state) {
- bool res = led_update_user(led_state);
- if(res) {
- gpio_write_pin(NUM_LOCK_LED_PIN, !led_state.num_lock);
- gpio_write_pin(CAPS_LOCK_LED_PIN, !led_state.caps_lock);
- gpio_write_pin(SCROLL_LOCK_LED_PIN, !led_state.scroll_lock);
- }
- return res;
-}