summaryrefslogtreecommitdiffstats
path: root/keyboards/matrix/abelx
diff options
context:
space:
mode:
authorlokher <lokher@gmail.com>2022-12-06 17:04:10 +0800
committerlokher <lokher@gmail.com>2022-12-06 17:04:10 +0800
commit27fc28fd2ff52e079a5bc58d6aaea4c752420615 (patch)
tree7ac943fb1ba4f430a7220efd18f66f6a77205c30 /keyboards/matrix/abelx
parente736133392fe6427cfb995da0787337189828272 (diff)
parent2709b6ed616f8012ff4cfd3ee69a822a8d188351 (diff)
Merge upstream master
Diffstat (limited to 'keyboards/matrix/abelx')
-rw-r--r--keyboards/matrix/abelx/config.h110
-rw-r--r--keyboards/matrix/abelx/keymaps/default/keymap.c41
-rw-r--r--keyboards/matrix/abelx/keymaps/iso/keymap.c39
3 files changed, 190 insertions, 0 deletions
diff --git a/keyboards/matrix/abelx/config.h b/keyboards/matrix/abelx/config.h
new file mode 100644
index 0000000000..06f9d31860
--- /dev/null
+++ b/keyboards/matrix/abelx/config.h
@@ -0,0 +1,110 @@
+/**
+ * config.h
+ *
+ * Copyright 2020 astro <yuleiz@gmail.com>
+ *
+ * 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
+
+/* key matrix size */
+#define MATRIX_ROWS 6
+#define MATRIX_COLS 16
+
+#define DEF_PIN(port, pin) (((port) << 8) | pin)
+#define GET_PORT(pp) (((pp) >> 8) & 0xFF)
+#define GET_PIN(pp) ((pp) & 0xFF)
+
+#define CUSTOM_MATRIX_ROW_PINS { \
+ DEF_PIN(TCA6424_PORT2, 7), \
+ DEF_PIN(TCA6424_PORT2, 6), \
+ DEF_PIN(TCA6424_PORT2, 0), \
+ DEF_PIN(TCA6424_PORT2, 2), \
+ DEF_PIN(TCA6424_PORT2, 4), \
+ DEF_PIN(TCA6424_PORT2, 5) }
+
+#define CUSTOM_MATRIX_COL_PINS { \
+ DEF_PIN(TCA6424_PORT2, 1), \
+ DEF_PIN(TCA6424_PORT1, 7), \
+ DEF_PIN(TCA6424_PORT1, 6), \
+ DEF_PIN(TCA6424_PORT1, 5), \
+ DEF_PIN(TCA6424_PORT1, 4), \
+ DEF_PIN(TCA6424_PORT1, 3), \
+ DEF_PIN(TCA6424_PORT1, 2), \
+ DEF_PIN(TCA6424_PORT1, 1), \
+ DEF_PIN(TCA6424_PORT1, 0), \
+ DEF_PIN(TCA6424_PORT0, 7), \
+ DEF_PIN(TCA6424_PORT0, 6), \
+ DEF_PIN(TCA6424_PORT0, 5), \
+ DEF_PIN(TCA6424_PORT0, 4), \
+ DEF_PIN(TCA6424_PORT0, 3), \
+ DEF_PIN(TCA6424_PORT0, 2), \
+ DEF_PIN(TCA6424_PORT0, 1) }
+
+#define ROW1_MASK 0x80
+#define ROW2_MASK 0x40
+#define ROW3_MASK 0x01
+#define ROW4_MASK 0x04
+#define ROW5_MASK 0x10
+#define ROW6_MASK 0x20
+#define ROW_PORT TCA6424_PORT2
+
+#define COL1_MASK 0x02
+#define COL2_MASK 0x80
+#define COL3_MASK 0x40
+#define COL4_MASK 0x20
+#define COL5_MASK 0x10
+#define COL6_MASK 0x08
+#define COL7_MASK 0x04
+#define COL8_MASK 0x02
+#define COL9_MASK 0x01
+#define COL10_MASK 0x80
+#define COL11_MASK 0x40
+#define COL12_MASK 0x20
+#define COL13_MASK 0x10
+#define COL14_MASK 0x08
+#define COL15_MASK 0x04
+#define COL16_MASK 0x02
+
+
+#define DIODE_DIRECTION COL2ROW
+#define DEBOUNCE 5
+
+// i2c setting
+#define USE_I2CV1
+#define I2C1_SCL 8
+#define I2C1_SDA 9
+#define I2C1_CLOCK_SPEED 400000
+#define I2C1_DUTY_CYCLE FAST_DUTY_CYCLE_2
+
+
+// rgb light setting
+#define RGBLED_NUM 9
+#define RGB_DI_PIN B4
+#define RGBLIGHT_EFFECT_BREATHING
+#define RGBLIGHT_EFFECT_RAINBOW_MOOD
+#define RGBLIGHT_EFFECT_RAINBOW_SWIRL
+#define RGBLIGHT_EFFECT_SNAKE
+#define RGBLIGHT_EFFECT_KNIGHT
+#define RGBLIGHT_EFFECT_CHRISTMAS
+#define RGBLIGHT_EFFECT_STATIC_GRADIENT
+#define RGBLIGHT_EFFECT_RGB_TEST
+#define RGBLIGHT_EFFECT_ALTERNATING
+#define RGBLIGHT_EFFECT_TWINKLE
+
+
+#define AW9523B_RGB_NUM 4
+
+#define EARLY_INIT_PERFORM_BOOTLOADER_JUMP FALSE
diff --git a/keyboards/matrix/abelx/keymaps/default/keymap.c b/keyboards/matrix/abelx/keymaps/default/keymap.c
new file mode 100644
index 0000000000..e4d2cd41f5
--- /dev/null
+++ b/keyboards/matrix/abelx/keymaps/default/keymap.c
@@ -0,0 +1,41 @@
+/**
+ * keymap.c
+ *
+ * Copyright 2020 astro <yuleiz@gmail.com>
+ *
+ * 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 QMK_KEYBOARD_H
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ [0]=LAYOUT_tkl_ansi(
+
+ KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SCRL, LT(1,KC_PAUS),
+
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP,
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN,
+ KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT,KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT),
+
+ [1]=LAYOUT_tkl_ansi(
+ KC_MUTE, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ KC_NUM, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, _______, _______, _______, _______, _______, _______, _______, _______,
+ QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_VOLU,
+ _______, _______, _______, KC_MPLY, _______, _______, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT),
+};
diff --git a/keyboards/matrix/abelx/keymaps/iso/keymap.c b/keyboards/matrix/abelx/keymaps/iso/keymap.c
new file mode 100644
index 0000000000..e006109905
--- /dev/null
+++ b/keyboards/matrix/abelx/keymaps/iso/keymap.c
@@ -0,0 +1,39 @@
+/**
+ * keymap.c
+ *
+ * Copyright 2020 astro <yuleiz@gmail.com>
+ *
+ * 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 QMK_KEYBOARD_H
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ [0]=LAYOUT_tkl_iso(
+ KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SCRL, LT(1,KC_PAUS),
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP,
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_DEL, KC_END, KC_PGDN,
+ KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT,
+ KC_LSFT, KC_LGUI, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT,KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT),
+
+ [1]=LAYOUT_tkl_iso(
+ KC_MUTE, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ KC_NUM, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, _______, _______, _______, _______, _______, _______, _______,
+ QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_VOLU,
+ _______, _______, _______, KC_MPLY, _______, _______, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT),
+};