summaryrefslogtreecommitdiff
path: root/keyboards/kinesis/kint2pp/kint2pp.c
diff options
context:
space:
mode:
authorMichael Stapelberg <stapelberg@users.noreply.github.com>2020-07-27 20:44:05 +0200
committerGitHub <noreply@github.com>2020-07-27 11:44:05 -0700
commit5cbac94d08257a6149c5717d7f25efab7af9c0fa (patch)
tree53248fcae9cb29da470a56d67b7c926657289d9a /keyboards/kinesis/kint2pp/kint2pp.c
parente937fc451379d773184068fd07b9f0a2aaaa6784 (diff)
[Keyboard] add support for the kinT kinesis keyboard controller (kint2pp variant) (#9687)
* branch keyboards/kinesis/kint2pp from keyboards/kinesis/stapelberg Changes will be made in the next commit * [Keyboard] update wiring for kinT (kint2pp variant) * add QMK plumbing * Apply zvecr’s suggestions from code review * Update keyboards/kinesis/kint2pp/config.h * Update keyboards/kinesis/kint2pp/config.h * remove superfluous config.h include
Diffstat (limited to 'keyboards/kinesis/kint2pp/kint2pp.c')
-rw-r--r--keyboards/kinesis/kint2pp/kint2pp.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/keyboards/kinesis/kint2pp/kint2pp.c b/keyboards/kinesis/kint2pp/kint2pp.c
new file mode 100644
index 0000000000..7e2b4348c5
--- /dev/null
+++ b/keyboards/kinesis/kint2pp/kint2pp.c
@@ -0,0 +1,26 @@
+#include "kint2pp.h"
+
+void matrix_init_kb(void) {
+ led_init_ports();
+
+
+ matrix_init_user();
+}
+void led_init_ports() {
+ // * Set our LED pins as output
+ setPinOutput(C3); // Keypad LED
+ setPinOutput(C4); // ScrLock LED
+ setPinOutput(C5); // NumLock LED
+ setPinOutput(C1); // CapsLock LED
+}
+
+bool led_update_kb(led_t led_state) {
+ bool res = led_update_user(led_state);
+ if(res) {
+ writePin(C3, !led_state.compose);
+ writePin(C4, !led_state.scroll_lock);
+ writePin(C5, !led_state.num_lock);
+ writePin(C1, !led_state.caps_lock);
+ }
+ return res;
+}