summaryrefslogtreecommitdiff
path: root/keyboards/flxlb
diff options
context:
space:
mode:
authorcccywj <33842880+cccywj@users.noreply.github.com>2021-05-13 19:48:04 -0700
committerGitHub <noreply@github.com>2021-05-13 19:48:04 -0700
commitba66b63fe583b505cdbcbe290a8efdbd3e6067b2 (patch)
tree600c961300024a98d58ceaf83f640b42fe731378 /keyboards/flxlb
parenteddd6aa1130ac71b3aeeed7a311a275f27dc2de0 (diff)
[Keyboard] Add fluxlab zplit keyboard (#12396)
Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
Diffstat (limited to 'keyboards/flxlb')
-rw-r--r--keyboards/flxlb/zplit/config.h90
-rw-r--r--keyboards/flxlb/zplit/info.json12
-rw-r--r--keyboards/flxlb/zplit/keymaps/via/config.h28
-rw-r--r--keyboards/flxlb/zplit/keymaps/via/keymap.c80
-rw-r--r--keyboards/flxlb/zplit/readme.md13
-rw-r--r--keyboards/flxlb/zplit/rules.mk24
-rw-r--r--keyboards/flxlb/zplit/zplit.c17
-rw-r--r--keyboards/flxlb/zplit/zplit.h37
8 files changed, 301 insertions, 0 deletions
diff --git a/keyboards/flxlb/zplit/config.h b/keyboards/flxlb/zplit/config.h
new file mode 100644
index 0000000000..83fe084844
--- /dev/null
+++ b/keyboards/flxlb/zplit/config.h
@@ -0,0 +1,90 @@
+/*
+Copyright 2021 fluxlab
+Copyright 2015 Jack Humbert
+
+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
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0x7076
+#define PRODUCT_ID 0x0001
+#define DEVICE_VER 0x0001
+#define MANUFACTURER fluxlab
+#define PRODUCT zplit
+
+/* key matrix size */
+// Rows are doubled-up
+#define MATRIX_ROWS 8
+#define MATRIX_COLS 6
+
+// wiring of each half
+#define MATRIX_ROW_PINS { D4, F5, F4, F1 }
+#define MATRIX_COL_PINS { B2, B3, D6, D7, B4, B5 }
+// #define MATRIX_COL_PINS { B6, B2, B3, B1, F7, F6 } //uncomment this line and comment line above if you need to reverse left-to-right key order
+
+#define DIODE_DIRECTION COL2ROW
+
+/* define if matrix has ghost */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+// #define BACKLIGHT_LEVELS 3
+
+/* Set 0 if debouncing isn't needed */
+#define DEBOUNCE 5
+
+/* configuration for split keyboard */
+#define SOFT_SERIAL_PIN D0
+#define SELECT_SOFT_SERIAL_SPEED 1
+// #define USE_I2C
+#define SPLIT_USB_DETECT
+#define SPLIT_USB_TIMEOUT 500
+
+#define ENCODERS_PAD_A { B0 }
+#define ENCODERS_PAD_B { D2 }
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/* ws2812 RGB LED */
+#define RGB_DI_PIN D3
+#define RGBLED_NUM 16
+#define RGBLIGHT_LED_MAP { 0, 1, 2, 3, 4, 5, 6, 7, 15, 14, 13, 12, 11, 10, 9, 8}
+#define RGBLED_SPLIT { 8, 8 }
+#define RGBLIGHT_SPLIT
+#define RGBLIGHT_ANIMATIONS
+
+/*
+ * 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
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
diff --git a/keyboards/flxlb/zplit/info.json b/keyboards/flxlb/zplit/info.json
new file mode 100644
index 0000000000..7cf3f0078a
--- /dev/null
+++ b/keyboards/flxlb/zplit/info.json
@@ -0,0 +1,12 @@
+{
+ "keyboard_name": "zplit",
+ "url": "https://github.com/cccywj/qmk_firmware",
+ "maintainer": "flxlb",
+ "width": 13,
+ "height": 4,
+ "layouts": {
+ "LAYOUT": {
+ "layout": [{"x":0, "y":0}, {"x":1, "y":0}, {"x":2, "y":0}, {"x":3, "y":0}, {"x":4, "y":0}, {"x":5, "y":0}, {"x":7, "y":0}, {"x":8, "y":0}, {"x":9, "y":0}, {"x":10, "y":0}, {"x":11, "y":0}, {"x":12, "y":0}, {"x":0, "y":1}, {"x":1, "y":1}, {"x":2, "y":1}, {"x":3, "y":1}, {"x":4, "y":1}, {"x":5, "y":1}, {"x":7, "y":1}, {"x":8, "y":1}, {"x":9, "y":1}, {"x":10, "y":1}, {"x":11, "y":1}, {"x":12, "y":1}, {"x":0, "y":2}, {"x":1, "y":2}, {"x":2, "y":2}, {"x":3, "y":2}, {"x":4, "y":2}, {"x":5, "y":2}, {"x":7, "y":2}, {"x":8, "y":2}, {"x":9, "y":2}, {"x":10, "y":2}, {"x":11, "y":2}, {"x":12, "y":2}, {"x":0, "y":3}, {"x":1, "y":3}, {"x":2, "y":3}, {"x":3, "y":3}, {"x":4, "y":3}, {"x":5, "y":3}, {"x":7, "y":3}, {"x":8, "y":3}, {"x":9, "y":3}, {"x":10, "y":3}, {"x":11, "y":3}, {"x":12, "y":3}]
+ }
+ }
+}
diff --git a/keyboards/flxlb/zplit/keymaps/via/config.h b/keyboards/flxlb/zplit/keymaps/via/config.h
new file mode 100644
index 0000000000..a157047f7a
--- /dev/null
+++ b/keyboards/flxlb/zplit/keymaps/via/config.h
@@ -0,0 +1,28 @@
+/*
+This is the c configuration file for the keymap
+
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+Copyright 2015 Jack Humbert
+
+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 USE_I2C
+
+/* Select hand configuration */
+#define MASTER_LEFT
+// #define MASTER_RIGHT
+// #define EE_HANDS
diff --git a/keyboards/flxlb/zplit/keymaps/via/keymap.c b/keyboards/flxlb/zplit/keymaps/via/keymap.c
new file mode 100644
index 0000000000..7f92c80e29
--- /dev/null
+++ b/keyboards/flxlb/zplit/keymaps/via/keymap.c
@@ -0,0 +1,80 @@
+/* Copyright 2021 FluxLab
+ *
+ * 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
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+enum custom_layers {
+ _QWERTY,
+ _LOWER,
+ _RAISE,
+ _ADJUST,
+};
+
+#define LOWER MO(_LOWER)
+#define RAISE MO(_RAISE)
+#define ADJUST MO(_ADJUST)
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+/* Qwerty */
+[_QWERTY] = LAYOUT(
+ KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_MUTE,
+ KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, 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_LCTL, KC_LGUI, KC_LALT, KC_DEL, LOWER, KC_SPC, KC_BSPC, RAISE, KC_LBRC, KC_RBRC, KC_QUOT, KC_MINS
+),
+
+/* Lower */
+[_LOWER] = LAYOUT(
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, _______,
+ _______, _______, _______, KC_UP, _______, _______, _______, KC_4, KC_5, KC_6, _______, _______,
+ _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______,KC_1,KC_2,KC_3, KC_BSLS, _______,
+ _______, _______, _______, _______, LOWER, _______, _______, KC_0,KC_0, KC_DOT, KC_BSLS,KC_EQL
+),
+
+/* Raise */
+[_RAISE] = LAYOUT(
+ KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,
+ RGB_HUI, RGB_SAI, RGB_VAI, RGB_MOD, _______, RGB_TOG, _______, _______, _______, _______, _______, _______,
+ RGB_HUD, RGB_SAD, RGB_VAD, RGB_RMOD, _______, RGB_TOG, _______, _______, _______, _______, KC_UP, _______,
+ _______, _______, _______, _______, _______, _______, _______, RAISE, _______, KC_LEFT, KC_DOWN, KC_RGHT
+),
+
+/* Adjust (Lower + Raise) */
+[_ADJUST] = LAYOUT(
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
+)
+
+
+};
+
+layer_state_t layer_state_set_user(layer_state_t state) {
+ return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
+}
+
+void encoder_update_user(uint8_t index, bool clockwise) {
+ if (clockwise) {
+ tap_code(KC_VOLD);
+ } else {
+ tap_code(KC_VOLU);
+ }
+}
diff --git a/keyboards/flxlb/zplit/readme.md b/keyboards/flxlb/zplit/readme.md
new file mode 100644
index 0000000000..e5f88c9df5
--- /dev/null
+++ b/keyboards/flxlb/zplit/readme.md
@@ -0,0 +1,13 @@
+# fluxlab zplit
+
+![zplit](https://i.imgur.com/eN4aSG1l.png)
+
+Zplit is a 40% split keyboard inspired by the Zlant and similar to Zinc. It has a symmetrical layout to provide a more natural typing experience.
+
+* Keyboard Maintainer: [flxlb](https://flxlb.ca)
+
+Make example for this keyboard (after setting up your build environment):
+
+ make flxlb/zplit:default
+
+See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
diff --git a/keyboards/flxlb/zplit/rules.mk b/keyboards/flxlb/zplit/rules.mk
new file mode 100644
index 0000000000..121bba1dfc
--- /dev/null
+++ b/keyboards/flxlb/zplit/rules.mk
@@ -0,0 +1,24 @@
+# MCU name
+MCU = atmega32u4
+
+# Bootloader selection
+BOOTLOADER = atmel-dfu
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration
+MOUSEKEY_ENABLE = no # Mouse keys
+EXTRAKEY_ENABLE = yes # Audio control and System control
+CONSOLE_ENABLE = no # Console for debug
+COMMAND_ENABLE = yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE = no # USB Nkey Rollover
+BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
+RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
+BLUETOOTH_ENABLE = no # Enable Bluetooth
+AUDIO_ENABLE = no # Audio output
+ENCODER_ENABLE = yes
+SPLIT_KEYBOARD = yes
diff --git a/keyboards/flxlb/zplit/zplit.c b/keyboards/flxlb/zplit/zplit.c
new file mode 100644
index 0000000000..25956640a7
--- /dev/null
+++ b/keyboards/flxlb/zplit/zplit.c
@@ -0,0 +1,17 @@
+/* Copyright 2021 FluxLab
+ *
+ * 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 "zplit.h"
diff --git a/keyboards/flxlb/zplit/zplit.h b/keyboards/flxlb/zplit/zplit.h
new file mode 100644
index 0000000000..6a90efa8af
--- /dev/null
+++ b/keyboards/flxlb/zplit/zplit.h
@@ -0,0 +1,37 @@
+ /* Copyright 2021 FluxLab
+ *
+ * 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
+
+#include "quantum.h"
+
+
+#define LAYOUT( \
+ L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
+ L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
+ L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
+ L30, L31, L32, L33, L34, L35, R30, R31, R32, R33, R34, R35 \
+ ) \
+ { \
+ { L00, L01, L02, L03, L04, L05 }, \
+ { L10, L11, L12, L13, L14, L15 }, \
+ { L20, L21, L22, L23, L24, L25 }, \
+ { L30, L31, L32, L33, L34, L35 }, \
+ { R05, R04, R03, R02, R01, R00 }, \
+ { R15, R14, R13, R12, R11, R10 }, \
+ { R25, R24, R23, R22, R21, R20 }, \
+ { R35, R34, R33, R32, R31, R30 } \
+ }