diff options
Diffstat (limited to 'keyboards/mt')
59 files changed, 2521 insertions, 0 deletions
diff --git a/keyboards/mt/blocked65/blocked65.c b/keyboards/mt/blocked65/blocked65.c new file mode 100644 index 0000000000..81da8005b0 --- /dev/null +++ b/keyboards/mt/blocked65/blocked65.c @@ -0,0 +1 @@ +#include "blocked65.h" diff --git a/keyboards/mt/blocked65/blocked65.h b/keyboards/mt/blocked65/blocked65.h new file mode 100644 index 0000000000..09fe673a66 --- /dev/null +++ b/keyboards/mt/blocked65/blocked65.h @@ -0,0 +1,18 @@ +#pragma once +#include "quantum.h" + +// readability +#define _x_ KC_NO +#define LAYOUT_65_ansi_blocker( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, K2E, \ + K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E, \ + K40, K41, K42, K46, K4A, K4B, K4C, K4D, K4E \ +){ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, _x_, K2D, K2E }, \ + { K30, _x_, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E }, \ + { K40, K41, K42, _x_, _x_, _x_, K46, _x_, _x_, _x_, K4A, K4B, K4C, K4D, K4E }, \ +} diff --git a/keyboards/mt/blocked65/config.h b/keyboards/mt/blocked65/config.h new file mode 100644 index 0000000000..86e574feed --- /dev/null +++ b/keyboards/mt/blocked65/config.h @@ -0,0 +1,60 @@ +/* +Copyright 2019 Evy Dekkers + +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 0x5746 //WF +#define PRODUCT_ID 0x0001 //Blocked65 +#define DEVICE_VER 0x0001 +#define MANUFACTURER Dou +#define PRODUCT Blocked65 + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 15 + +// ROWS: Top to bottom, COLS: Left to right + +#define MATRIX_ROW_PINS { B0, B1, B2, B3, B7 } +#define MATRIX_COL_PINS { D0, D1, D2, D3, D5, D4, D6, D7, B4, F7, F6, F5, F4, F1, F0 } +#define UNUSED_PINS + +/* COL2ROW or ROW2COL */ +#define DIODE_DIRECTION ROW2COL + +/* define if matrix has ghost */ +//#define MATRIX_HAS_GHOST + +#define BACKLIGHT_PIN B6 +#define BACKLIGHT_LEVELS 6 + +/* Set 0 if debouncing isn't needed */ +#define DEBOUNCE 5 + +/* 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 + +/* Backlight configuration + */ +#define RGB_DI_PIN E2 +#define RGBLIGHT_ANIMATIONS +#define RGBLED_NUM 14 diff --git a/keyboards/mt/blocked65/info.json b/keyboards/mt/blocked65/info.json new file mode 100644 index 0000000000..aea7165abc --- /dev/null +++ b/keyboards/mt/blocked65/info.json @@ -0,0 +1,10 @@ +{ + "keyboard_name": "Wheatfield blocked 65% keyboard", + "url": "", + "maintainer": "qmk", + "layouts": { + "LAYOUT_65_ansi_blocker": { + "layout": [{"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"PrScr", "x":15, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Del", "x":15, "y":1}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"PgUp", "x":15, "y":2}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"label":"\u2191", "x":14, "y":3}, {"label":"PgDn", "x":15, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"Fn", "x":10, "y":4, "w":1.25}, {"label":"Alt", "x":11.25, "y":4, "w":1.25}, {"label":"\u2190", "x":13, "y":4}, {"label":"\u2193", "x":14, "y":4}, {"label":"\u2192", "x":15, "y":4}] + } + } +} diff --git a/keyboards/mt/blocked65/keymaps/default/keymap.c b/keyboards/mt/blocked65/keymaps/default/keymap.c new file mode 100644 index 0000000000..219dd2647e --- /dev/null +++ b/keyboards/mt/blocked65/keymaps/default/keymap.c @@ -0,0 +1,31 @@ +#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 layers { + _BL, + _FL +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [_BL] = LAYOUT_65_ansi_blocker( + KC_GESC, 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_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_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_PGUP, + 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FL), KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_FL] = LAYOUT_65_ansi_blocker( + KC_GRV, 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_DEL, KC_PSCR, + KC_TRNS, KC_NO, KC_UP, KC_NO, RGB_TOG, RGB_VAI, RGB_HUI, RGB_SAI, KC_INS, QK_BOOT, KC_PSCR, KC_SLCK, KC_PAUS, KC_BSLS, KC_SLCK, + KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, RGB_MOD, RGB_VAD, RGB_HUD, RGB_SAD, KC_NO, KC_NO, KC_F14, KC_F15, KC_INS, KC_HOME, + KC_LSFT, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, BL_TOGG, KC_NO, KC_MUTE, KC_VOLD, KC_VOLU, KC_NO, KC_RSFT, RGB_MOD, KC_END, + KC_LCTL, KC_LGUI, KC_LALT, QK_BOOT, KC_RALT, KC_TRNS, KC_HOME, BL_STEP, KC_END + ) + +}; diff --git a/keyboards/mt/blocked65/keymaps/via/keymap.c b/keyboards/mt/blocked65/keymaps/via/keymap.c new file mode 100644 index 0000000000..c7afb9f7b0 --- /dev/null +++ b/keyboards/mt/blocked65/keymaps/via/keymap.c @@ -0,0 +1,49 @@ +#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 layers { + _BL, + _FL, + _SL, + _LL +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [_BL] = LAYOUT_65_ansi_blocker( + KC_GESC, 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_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_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_PGUP, + 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FL), KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_FL] = LAYOUT_65_ansi_blocker( + KC_GRV, 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_DEL, KC_PSCR, + KC_TRNS, KC_NO, KC_UP, KC_NO, RGB_TOG, RGB_VAI, RGB_HUI, RGB_SAI, KC_INS, QK_BOOT, KC_PSCR, KC_SLCK, KC_PAUS, KC_BSLS, KC_SLCK, + KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, RGB_MOD, RGB_VAD, RGB_HUD, RGB_SAD, KC_NO, KC_NO, KC_F14, KC_F15, KC_INS, KC_HOME, + KC_LSFT, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, BL_TOGG, KC_NO, KC_MUTE, KC_VOLD, KC_VOLU, KC_NO, KC_RSFT, RGB_MOD, KC_END, + KC_LCTL, KC_LGUI, KC_LALT, QK_BOOT, KC_RALT, KC_TRNS, KC_HOME, BL_STEP, KC_END + ), + + [_SL] = LAYOUT_65_ansi_blocker( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + + [_LL] = LAYOUT_65_ansi_blocker( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) + +}; diff --git a/keyboards/mt/blocked65/keymaps/via/rules.mk b/keyboards/mt/blocked65/keymaps/via/rules.mk new file mode 100644 index 0000000000..1e5b99807c --- /dev/null +++ b/keyboards/mt/blocked65/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/mt/blocked65/readme.md b/keyboards/mt/blocked65/readme.md new file mode 100644 index 0000000000..71e3238390 --- /dev/null +++ b/keyboards/mt/blocked65/readme.md @@ -0,0 +1,13 @@ +# Wheatfield Blocked65% + +A 65% PCB sold via TaoBao, commonly sold as part of the Canoe clone referred to as Fanoe. + +* Keyboard Maintainer: QMK Community +* Hardware Supported: Wheatfield Blocked65% +* Hardware Availability: [taobao.com](https://item.taobao.com/item.htm?id=570827341563&spm=1101.1101.N.N.b124829) + +Make example for this keyboard (after setting up your build environment): + + make mt/blocked65: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/mt/blocked65/rules.mk b/keyboards/mt/blocked65/rules.mk new file mode 100644 index 0000000000..5dab5b3a15 --- /dev/null +++ b/keyboards/mt/blocked65/rules.mk @@ -0,0 +1,20 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = no # Enable N-Key Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output + +LAYOUTS = 65_ansi_blocker diff --git a/keyboards/mt/mt40/config.h b/keyboards/mt/mt40/config.h new file mode 100644 index 0000000000..6626b24f3a --- /dev/null +++ b/keyboards/mt/mt40/config.h @@ -0,0 +1,116 @@ +/* +Copyright 2017 REPLACE_WITH_YOUR_NAME + +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 0x20A0 +#define PRODUCT_ID 0x422D + +#define DEVICE_VER 0x0001 + +#define MANUFACTURER ThomasDehaeze +#define PRODUCT MT40 + +/* key matrix size */ +#define MATRIX_ROWS 7 +#define MATRIX_COLS 15 + +#define RGB_DI_PIN C0 +#define RGBLED_NUM 12 +#define RGBLIGHT_ANIMATIONS + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * +*/ +/* #define CC6 0x63 // C3 */ +/* #define CB6 0x37 // B7 */ +/* #define CC7 0x62 // C2 */ + +#define MATRIX_ROW_PINS { B0, B1, B2, B3, B4, B6, B7 } +#define MATRIX_COL_PINS { A0, A1, A2, A3, A4, A5, A6, A7, C7, C6, C5, C4, C3, C2, D7 } +/* #define UNUSED_PINS */ + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +#define BACKLIGHT_PIN D2 + +/* number of backlight levels */ +#define BACKLIGHT_LEVELS 3 + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +/* #define DEBOUNCE 5 */ + +/* define if matrix has ghost (lacks anti-ghosting diodes) */ +//#define MATRIX_HAS_GHOST + +/* 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 */ + +/* If defined, GRAVE_ESC will always act as ESC when CTRL is held. + * This is userful for the Windows task manager shortcut (ctrl+shift+esc). + */ +// #define GRAVE_ESC_CTRL_OVERRIDE + +/* + * Force NKRO + * + * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved + * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the + * makefile for this to work.) + * + * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N) + * until the next keyboard reset. + * + * NKRO may prevent your keystrokes from being detected in the BIOS, but it is + * fully operational during normal computer usage. + * + * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N) + * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by + * bootmagic, NKRO mode will always be enabled until it is toggled again during a + * power-up. + * + */ +//#define FORCE_NKRO + +/* + * 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/mt/mt40/info.json b/keyboards/mt/mt40/info.json new file mode 100644 index 0000000000..48a2b9233b --- /dev/null +++ b/keyboards/mt/mt40/info.json @@ -0,0 +1,10 @@ +{ + "keyboard_name": "MT40", + "url": "", + "maintainer": "qmk", + "layouts": { + "LAYOUT_planck_mit": { + "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":6, "y":0}, {"x":7, "y":0}, {"x":8, "y":0}, {"x":9, "y":0}, {"x":10, "y":0}, {"x":11, "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":6, "y":1}, {"x":7, "y":1}, {"x":8, "y":1}, {"x":9, "y":1}, {"x":10, "y":1}, {"x":11, "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":6, "y":2}, {"x":7, "y":2}, {"x":8, "y":2}, {"x":9, "y":2}, {"x":10, "y":2}, {"x":11, "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, "w":2}, {"x":7, "y":3}, {"x":8, "y":3}, {"x":9, "y":3}, {"x":10, "y":3}, {"x":11, "y":3}] + } + } +} diff --git a/keyboards/mt/mt40/keymaps/default/config.h b/keyboards/mt/mt40/keymaps/default/config.h new file mode 100644 index 0000000000..6c3e30ef7b --- /dev/null +++ b/keyboards/mt/mt40/keymaps/default/config.h @@ -0,0 +1,10 @@ +#pragma once + +// place overrides here + +#define TAPPING_TERM 200 + + +#define RGBLIGHT_HUE_STEP 12 +#define RGBLIGHT_SAT_STEP 15 +#define RGBLIGHT_VAL_STEP 18 diff --git a/keyboards/mt/mt40/keymaps/default/keymap.c b/keyboards/mt/mt40/keymaps/default/keymap.c new file mode 100644 index 0000000000..0feadbfb74 --- /dev/null +++ b/keyboards/mt/mt40/keymaps/default/keymap.c @@ -0,0 +1,76 @@ +/* Copyright 2017 REPLACE_WITH_YOUR_NAME + * + * 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 + +#define OOOOOOO KC_TRNS + +#define C_LCTL MT(MOD_LCTL, KC_QUOT) +#define C_RCTL MT(MOD_RCTL, KC_GRV) + +#define C_LGUI MT(MOD_LGUI, KC_LBRC) +#define C_RGUI MT(MOD_RGUI, KC_RBRC) + +#define C_ESC MT(MOD_LCTL, KC_ESC) +#define C_ENT MT(MOD_RCTL, KC_ENT) + + +/* + * ,-----------------------------------------------------------------------------------. + * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Esc | A | S | D | F | G | H | J | K | L | ; | " | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Brite| Ctrl | Alt | GUI |Lower | SPC |Raise | Left | Down | Up |Right | + * `-----------------------------------------------------------------------------------' + */ +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_planck_mit( + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + C_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, C_ENT, + KC_LSPO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSPC, + C_LCTL, C_LGUI, MOD_LALT, MO(3), MO(1), KC_SPC, MO(2), MO(4), MOD_RALT, C_RGUI, C_RCTL), + + [1] = LAYOUT_planck_mit( + _______, KC_F9, KC_F10, KC_F11, KC_F12, RGB_TOG, RGB_MOD, KC_P7, KC_P8, KC_P9, KC_PSLS, _______, + _______, KC_F5, KC_F6, KC_F7, KC_F8, RGB_VAD, RGB_VAI, KC_P4, KC_P5, KC_P6, KC_PAST, _______, + _______, KC_F1, KC_F2, KC_F3, KC_F4, BL_TOGG, BL_INC, KC_P1, KC_P2, KC_P3, KC_PMNS, KC_PGUP, + _______, _______, _______, _______, OOOOOOO, _______, KC_P0, KC_PDOT, KC_PENT, KC_PPLS, KC_PGDN), + + [2] = LAYOUT_planck_mit( + _______, _______, _______, _______, _______, _______, _______, KC_QUOT, KC_EQL, KC_LBRC, KC_RBRC, KC_NUBS, + KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, OOOOOOO, KC_HOME, KC_PGDOWN, KC_PGUP, KC_END), + + [3] = LAYOUT_planck_mit( + _______, _______, _______, _______, _______, _______, KC_COPY, KC_PGUP, _______, _______, KC_PASTE, KC_DEL, + _______, _______, _______, KC_PGDN, _______, _______, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, _______, _______, + _______, _______, KC_CUT, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, OOOOOOO, _______, _______, _______, _______, _______, _______, _______), + + [4] = LAYOUT_planck_mit( + _______, _______, _______, _______, _______, _______, _______, KC_ACL0, KC_ACL1, KC_ACL2, _______, _______, + KC_PSCR, KC_INS, KC_MUTE, KC_VOLD, KC_VOLU, _______, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, _______, _______, + KC_CAPS, _______, KC_MPLY, KC_MRWD, KC_MFFD, _______, _______, _______, KC_BTN1, KC_BTN2, _______, _______, + _______, _______, _______, _______, _______, _______, _______, OOOOOOO, _______, _______, _______), + + +}; + + + diff --git a/keyboards/mt/mt40/keymaps/default/readme.md b/keyboards/mt/mt40/keymaps/default/readme.md new file mode 100644 index 0000000000..033b75fa29 --- /dev/null +++ b/keyboards/mt/mt40/keymaps/default/readme.md @@ -0,0 +1,17 @@ +# Default Layout on a Planck Clone Keyboard + +## Base Layer +[Imgur](https://i.imgur.com/XivfDS0.png) + +## FN1 Layer - Numpad and Function keys +[Imgur](https://i.imgur.com/sXTYfAn.png) + +## FN2 Layer - Numbers and Symbols +[Imgur](https://i.imgur.com/Z4Nqp7g.png) + +## FN3 Layer - Vim +[Imgur](https://i.imgur.com/5whRGOx.png) + +## FN3 Layer - Multimedia +[Imgur](https://i.imgur.com/K0jfHIO.png) + diff --git a/keyboards/mt/mt40/mt40.c b/keyboards/mt/mt40/mt40.c new file mode 100644 index 0000000000..dd079e7d81 --- /dev/null +++ b/keyboards/mt/mt40/mt40.c @@ -0,0 +1,17 @@ +/* Copyright 2017 REPLACE_WITH_YOUR_NAME + * + * 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 "mt40.h" diff --git a/keyboards/mt/mt40/mt40.h b/keyboards/mt/mt40/mt40.h new file mode 100644 index 0000000000..dc0de22b28 --- /dev/null +++ b/keyboards/mt/mt40/mt40.h @@ -0,0 +1,42 @@ +/* Copyright 2017 REPLACE_WITH_YOUR_NAME + * + * 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 XXX KC_NO + +// This a shortcut to help you visually see your layout. +// The following is an example using the Planck MIT layout +// The first section contains all of the arguments +// The second converts the arguments into a two-dimensional array +#define LAYOUT_planck_mit( \ + k40, k31, k32, k33, k34, k35, k52, k5C, k6C, k62, k3A, k4E, \ + k30, k21, k22, k23, k24, k25, k53, k5D, k6D, k63, k2A, k2B, \ + k10, k11, k12, k13, k14, k15, k54, k5E, k6E, k64, k1A, k66, \ + k20, k00, k01, k02, k04, k05, k0B, k56, k58, k57, k59 \ +) { \ + { k00, k01, k02, XXX, k04, k05, XXX, XXX, XXX, XXX, XXX, k0B, XXX, XXX, XXX }, \ + { k10, k11, k12, k13, k14, k15, XXX, XXX, XXX, XXX, k1A, XXX, XXX, XXX, XXX }, \ + { k20, k21, k22, k23, k24, k25, XXX, XXX, XXX, XXX, k2A, k2B, XXX, XXX, XXX }, \ + { k30, k31, k32, k33, k34, k35, XXX, XXX, XXX, XXX, k3A, XXX, XXX, XXX, XXX }, \ + { k40, XXX, XXX, XXX, XXX, XXX, XXX, XXX, XXX, XXX, XXX, XXX, XXX, XXX, k4E }, \ + { XXX, XXX, k52, k53, k54, k05, k56, k57, k58, k59, XXX, XXX, k5C, k5D, k5E }, \ + { XXX, XXX, k62, k63, k64, XXX, k66, XXX, XXX, XXX, XXX, XXX, k6C, k6D, k6E } \ +} + +#define LAYOUT LAYOUT_planck_mit diff --git a/keyboards/mt/mt40/readme.md b/keyboards/mt/mt40/readme.md new file mode 100644 index 0000000000..632cefdb73 --- /dev/null +++ b/keyboards/mt/mt40/readme.md @@ -0,0 +1,19 @@ +# MT40 + +[MT40](https://i.imgur.com/0opsDkt.jpg) + +A 40% Ortholinear Keyboard + +* Keyboard Maintainer: QMK Community +* Hardware Supported: MT40 +* Hardware Availability: <https://world.taobao.com/item/548335974877.htm?fromSite=main&spm=a312a.7700824.w4002-6810221593.51.670e68a08mRh69> + +Make example for this keyboard (after setting up your build environment): + + make mt/mt40:default + +Flashing example for this keyboard ([after setting up the bootloadHID flashing environment](https://docs.qmk.fm/#/flashing_bootloadhid)) + + make mt/mt40:default:flash + +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/mt/mt40/rules.mk b/keyboards/mt/mt40/rules.mk new file mode 100644 index 0000000000..3024f40149 --- /dev/null +++ b/keyboards/mt/mt40/rules.mk @@ -0,0 +1,22 @@ +# MCU name +MCU = atmega32a + +# Bootloader selection +BOOTLOADER = bootloadhid + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = no # Enable N-Key Rollover +BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality +AUDIO_ENABLE = no # Audio output +RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight. +WS2812_DRIVER = i2c + +LAYOUTS = planck_mit +LAYOUTS_HAS_RGB = no diff --git a/keyboards/mt/mt64rgb/config.h b/keyboards/mt/mt64rgb/config.h new file mode 100644 index 0000000000..ea7659b471 --- /dev/null +++ b/keyboards/mt/mt64rgb/config.h @@ -0,0 +1,133 @@ +/* Copyright 2020 MT + * + * 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 0x4D54 // "MT" +#define PRODUCT_ID 0x0001 +#define DEVICE_VER 0x0001 +#define MANUFACTURER MT +#define PRODUCT MT64RGB + + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 14 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { D7, D6, D5, D3, D2 } +#define MATRIX_COL_PINS {B5, B6, C6, C7, F7, F6,F5, F4, F1, F0, B1, B2, B3, B7 } +#define UNUSED_PINS + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +#ifdef RGB_MATRIX_ENABLE +#define RGB_MATRIX_KEYPRESSES +#define RGB_MATRIX_FRAMEBUFFER_EFFECTS +#define RGB_MATRIX_STARTUP_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS +#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 160 +#define RGB_MATRIX_LED_PROCESS_LIMIT 20 +#define RGB_MATRIX_LED_FLUSH_LIMIT 26 +#define DRIVER_ADDR_1 0b1010000 + +#define DRIVER_COUNT 1 +#define DRIVER_LED_TOTAL 64 + + +// RGB Matrix Animation modes. Explicitly enabled +// For full list of effects, see: +// https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects +// # define ENABLE_RGB_MATRIX_ALPHAS_MODS +# define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN +# define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT +# define ENABLE_RGB_MATRIX_BREATHING +// # define ENABLE_RGB_MATRIX_BAND_SAT +// # define ENABLE_RGB_MATRIX_BAND_VAL +// # define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT +// # define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL +// # define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT +// # define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL +# define ENABLE_RGB_MATRIX_CYCLE_ALL +# define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT +# define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN +# define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON +# define ENABLE_RGB_MATRIX_CYCLE_OUT_IN +// # define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL +# define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL +# define ENABLE_RGB_MATRIX_CYCLE_SPIRAL +# define ENABLE_RGB_MATRIX_DUAL_BEACON +// # define ENABLE_RGB_MATRIX_RAINBOW_BEACON +# define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS +# define ENABLE_RGB_MATRIX_RAINDROPS +# define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS +# define ENABLE_RGB_MATRIX_HUE_BREATHING +# define ENABLE_RGB_MATRIX_HUE_PENDULUM +# define ENABLE_RGB_MATRIX_HUE_WAVE +# define ENABLE_RGB_MATRIX_PIXEL_RAIN +# define ENABLE_RGB_MATRIX_PIXEL_FLOW +# define ENABLE_RGB_MATRIX_PIXEL_FRACTAL +// enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined +// # define ENABLE_RGB_MATRIX_TYPING_HEATMAP +// # define ENABLE_RGB_MATRIX_DIGITAL_RAIN +// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE +// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE +// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS +// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS +// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS +# define ENABLE_RGB_MATRIX_SPLASH +# define ENABLE_RGB_MATRIX_MULTISPLASH +# define ENABLE_RGB_MATRIX_SOLID_SPLASH +# define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH + + +#endif + +#define RGB_DI_PIN B0 +#ifdef RGB_DI_PIN +#define RGBLIGHT_ANIMATIONS +#define RGBLED_NUM 18 +#define RGBLIGHT_HUE_STEP 5 +#define RGBLIGHT_SAT_STEP 5 +#define RGBLIGHT_VAL_STEP 5 +#define RGBLIGHT_SLEEP +#endif + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* 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 + +/* VIA related config */ +#define VIA_EEPROM_LAYOUT_OPTIONS_SIZE 2 diff --git a/keyboards/mt/mt64rgb/info.json b/keyboards/mt/mt64rgb/info.json new file mode 100644 index 0000000000..840863bc24 --- /dev/null +++ b/keyboards/mt/mt64rgb/info.json @@ -0,0 +1,10 @@ +{ + "keyboard_name": "mt64rgb", + "url": "", + "maintainer": "qmk", + "layouts": { + "LAYOUT_64_ansi": { + "layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"label":"Shift", "x":12, "y":3}, {"x":13, "y":3}, {"x":14, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"x":10, "y":4}, {"x":11, "y":4}, {"x":12, "y":4}, {"x":13, "y":4}, {"x":14, "y":4}] + } + } +} diff --git a/keyboards/mt/mt64rgb/keymaps/default/keymap.c b/keyboards/mt/mt64rgb/keymaps/default/keymap.c new file mode 100644 index 0000000000..84f3b1d35e --- /dev/null +++ b/keyboards/mt/mt64rgb/keymaps/default/keymap.c @@ -0,0 +1,46 @@ +/* Copyright 2020 MT + * + * 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_64_ansi( + KC_ESC, 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_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_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_DEL, + KC_LCTL, KC_LALT, KC_LWIN, KC_SPC, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT_64_ansi( + _______, 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_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, RGB_SPI, RGB_SPD, _______, _______,_______, _______, + _______, RGB_M_P, RGB_M_B, RGB_M_R, RGB_M_SW, RGB_M_SN, RGB_M_K, RGB_M_X, RGB_M_G, RGB_M_T, _______,_______,_______,_______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) +}; + +void rgb_matrix_indicators_user(void) { + if (layer_state_is(1)) { + rgb_matrix_set_color(77,0xFF, 0x80, 0x00); + } + if (host_keyboard_led_state().caps_lock) { + rgb_matrix_set_color(28, 0xFF, 0xFF, 0xFF); + } +} diff --git a/keyboards/mt/mt64rgb/keymaps/default/readme.md b/keyboards/mt/mt64rgb/keymaps/default/readme.md new file mode 100644 index 0000000000..5508f7df16 --- /dev/null +++ b/keyboards/mt/mt64rgb/keymaps/default/readme.md @@ -0,0 +1,3 @@ +# Default mt4rgb Layout + +This is the default layout that comes flashed on every mt64rgb. All key pins are shown in the file. diff --git a/keyboards/mt/mt64rgb/keymaps/via/keymap.c b/keyboards/mt/mt64rgb/keymaps/via/keymap.c new file mode 100644 index 0000000000..37c3c18259 --- /dev/null +++ b/keyboards/mt/mt64rgb/keymaps/via/keymap.c @@ -0,0 +1,55 @@ + /* Copyright 2020 MT<704340378@qq.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_64_ansi( + KC_ESC, 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_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_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_DEL, + KC_LCTL, KC_LALT, KC_LWIN, KC_SPC, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] =LAYOUT_64_ansi( + KC_GRV, 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_DEL, + KC_TRNS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, RGB_SAI, RGB_SAD, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, QK_BOOT, + KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BL_TOGG, BL_INC, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,RGB_VAI, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, RGB_TOG, KC_TRNS, RGB_MOD, RGB_HUI, RGB_VAD, RGB_HUD), + [2] = LAYOUT_64_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BL_DEC, BL_TOGG, BL_INC, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS), + [3] = LAYOUT_64_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BL_DEC, BL_TOGG, BL_INC, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS), +}; + +void rgb_matrix_indicators_user(void) { + if (layer_state_is(1)) { + rgb_matrix_set_color(77,0xFF, 0x80, 0x00); + } + if (host_keyboard_led_state().caps_lock) { + rgb_matrix_set_color(28, 0xFF, 0xFF, 0xFF); + } +} diff --git a/keyboards/mt/mt64rgb/keymaps/via/rules.mk b/keyboards/mt/mt64rgb/keymaps/via/rules.mk new file mode 100644 index 0000000000..ca9fed0e6b --- /dev/null +++ b/keyboards/mt/mt64rgb/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +LTO_ENABLE = yes +VIA_ENABLE = yes diff --git a/keyboards/mt/mt64rgb/mt64rgb.c b/keyboards/mt/mt64rgb/mt64rgb.c new file mode 100644 index 0000000000..f0c444e8fa --- /dev/null +++ b/keyboards/mt/mt64rgb/mt64rgb.c @@ -0,0 +1,116 @@ + /* Copyright 2020 MT + * + * 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 "mt64rgb.h" + +#ifdef RGB_MATRIX_ENABLE +const is31_led PROGMEM g_is31_leds[DRIVER_LED_TOTAL] = { + /* Refer to IS31 manual for these locations + * driver + * | R location + * | | G location + * | | | B location + * | | | | */ + + {0, A_1, B_1, C_1}, + {0, D_1, E_1, F_1}, + {0, G_1, H_1, I_1}, + {0, J_1, K_1, L_1}, + {0, A_6, B_6, C_6}, + {0, D_6, E_6, F_6}, + {0, G_6, H_6, I_6}, + {0, J_6, K_6, L_6}, + {0, A_11, B_11, C_11}, + {0, D_11, E_11, F_11}, + {0, G_11, H_11, I_11}, + {0, J_11, K_11, L_11}, + {0, A_16, B_16, C_16}, + {0, D_16, E_16, F_16}, + + {0, A_2, B_2, C_2}, + {0, D_2, E_2, F_2}, + {0, G_2, H_2, I_2}, + {0, J_2, K_2, L_2}, + {0, A_7, B_7, C_7}, + {0, D_7, E_7, F_7}, + {0, G_7, H_7, I_7}, + {0, J_7, K_7, L_7}, + {0, A_12, B_12, C_12}, + {0, D_12, E_12, F_12}, + {0, G_12, H_12, I_12}, + {0, J_12, K_12, L_12}, + {0, G_16, H_16, I_16}, + {0, J_16, K_16, L_16}, + + {0, A_3, B_3, C_3}, + {0, D_3, E_3, F_3}, + {0, G_3, H_3, I_3}, + {0, J_3, K_3, L_3}, + {0, A_8, B_8, C_8}, + {0, D_8, E_8, F_8}, + {0, G_8, H_8, I_8}, + {0, J_8, K_8, L_8}, + {0, A_13, B_13, C_13}, + {0, D_13, E_13, F_13}, + {0, G_13, H_13, I_13}, + {0, J_13, K_13, L_13}, + {0, A_15, B_15, C_15}, + + {0, A_4, B_4, C_4}, + {0, D_4, E_4, F_4}, + {0, G_4, H_4, I_4}, + {0, J_4, K_4, L_4}, + {0, A_9, B_9, C_9}, + {0, D_9, E_9, F_9}, + {0, G_9, H_9, I_9}, + {0, J_9, K_9, L_9}, + {0, A_14, B_14, C_14}, + {0, D_14, E_14, F_14}, + {0, G_14, H_14, I_14}, + {0, J_14, K_14, L_14}, + {0, D_15, E_15, F_15}, + {0, G_15, H_15, I_15}, + + {0, A_5, B_5, C_5}, + {0, D_5, E_5, F_5}, + {0, G_5, H_5, I_5}, + {0, J_5, K_5, L_5}, + {0, A_10, B_10, C_10}, + {0, D_10, E_10, F_10}, + {0, G_10, H_10, I_10}, + {0, J_10, K_10, L_10}, + {0, J_15, K_15, L_15} +}; + +led_config_t g_led_config = {{ + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13 }, + { 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27 }, + { 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40}, + { 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54 }, + { 55, 56, 57, 58, 59, 60, 61, 62, 63} +}, { + { 0, 0 }, { 16, 0 }, { 32, 0 }, { 48, 0 }, { 64, 0 }, { 80, 0 }, { 96, 0 }, { 112, 0 }, { 128, 0 }, { 144, 0 }, { 160, 0 }, { 176, 0 }, { 192, 0 }, { 216, 0 }, + { 4, 16 }, { 18, 16 }, { 34, 16 }, { 50, 16 }, { 66, 16 }, { 82, 16 }, { 98, 16 }, { 114, 16 }, { 130, 16 }, { 146, 16 }, { 162, 16 }, { 178, 16 }, { 194, 16 }, { 220, 16 }, + { 6, 32 }, { 20, 32 }, { 36, 32 }, { 52, 32 }, { 68, 32 }, { 84, 32 }, { 100, 32 }, { 116, 32 }, { 132, 32 }, { 148, 32 }, { 164, 32 }, { 180, 32 }, { 212, 32 }, + { 9, 48 }, { 27, 48 }, { 43, 48 }, { 59, 48 }, { 75, 48 }, { 91, 48 }, { 107, 48 }, { 123, 48 }, { 139, 48 }, { 155, 48 }, { 171, 48 }, { 187, 48 }, { 203, 48 }, { 219, 48 }, + { 2, 64 }, { 16, 64 }, { 32, 64 }, { 64, 64 }, { 114, 64 }, { 130, 64 }, { 146, 64 }, { 204, 64 }, { 224, 64 } +}, { + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 1, 4, 1, 1, 4, 4, 4, +}}; +#endif diff --git a/keyboards/mt/mt64rgb/mt64rgb.h b/keyboards/mt/mt64rgb/mt64rgb.h new file mode 100644 index 0000000000..dac98dfeb1 --- /dev/null +++ b/keyboards/mt/mt64rgb/mt64rgb.h @@ -0,0 +1,33 @@ + /* Copyright 2020 MT + * + * 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_64_ansi( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, K0B, K0C, K0D, \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1C, k1D, \ + k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2C, \ + k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3A, k3B, k3C, k3D, \ + k40, k41, k42, k45, k48, k4A, k4B, k4C, k4D \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, K0B, K0C, K0D}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1C, k1D}, \ + {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2C, KC_NO}, \ + {k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3A, k3B, k3C, k3D}, \ + {k40, k41, k42, KC_NO, KC_NO, k45, KC_NO, KC_NO,KC_NO, k48, k4A, k4B, k4C, k4D} \ +} diff --git a/keyboards/mt/mt64rgb/readme.md b/keyboards/mt/mt64rgb/readme.md new file mode 100644 index 0000000000..23fcd5ebe7 --- /dev/null +++ b/keyboards/mt/mt64rgb/readme.md @@ -0,0 +1,16 @@ +# mt64rgb + +![mt64rgb](https://i.imgur.com/kxGGUg9.jpg?1) + +A 60% keyboard PCB made by MT. +It supports an ANSI-based 64-key layout, with hotswap sockets and per-key RGB backlight. + +* Keyboard Maintainer: [MT](https://github.com/704340378) +* Hardware Supported: mt64rgb (atmega32u4) +* Hardware Availability: [麦田外设](https://shop110310565.taobao.com) + +Make example for this keyboard (after setting up your build environment): + + make mt/mt64rgb: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/mt/mt64rgb/rules.mk b/keyboards/mt/mt64rgb/rules.mk new file mode 100644 index 0000000000..56724f822a --- /dev/null +++ b/keyboards/mt/mt64rgb/rules.mk @@ -0,0 +1,25 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = yes # Enable N-Key Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +RGB_MATRIX_ENABLE = yes # Use RGB matrix +RGB_MATRIX_DRIVER = IS31FL3733 + +AUDIO_ENABLE = no # Audio output + +LAYOUTS = 64_ansi + +LTO_ENABLE = yes diff --git a/keyboards/mt/mt84/config.h b/keyboards/mt/mt84/config.h new file mode 100644 index 0000000000..bde8919ba7 --- /dev/null +++ b/keyboards/mt/mt84/config.h @@ -0,0 +1,136 @@ + /* Copyright 2020 MT <704340378@qq.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 + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x4D54 // "MT" +#define PRODUCT_ID 0x0002 +#define DEVICE_VER 0x0001 +#define MANUFACTURER MT +#define PRODUCT MT84 + + +/* key matrix size */ +#define MATRIX_ROWS 6 +#define MATRIX_COLS 15 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { D7, D6, D5, D3, D2, D4 } +#define MATRIX_COL_PINS {B5, B6, C6, C7, F7, F6,F5, F4, F1, F0, B1, B2, B3, B7, E6 } +#define UNUSED_PINS + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +#ifdef RGB_MATRIX_ENABLE + #define RGB_MATRIX_KEYPRESSES + #define RGB_MATRIX_FRAMEBUFFER_EFFECTS + #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 + #define RGB_MATRIX_STARTUP_MODE RGB_MATRIX_CYCLE_ALL + #define RGB_MATRIX_LED_PROCESS_LIMIT 20 + #define RGB_MATRIX_LED_FLUSH_LIMIT 26 + #define DRIVER_ADDR_1 0b1010000 + #define DRIVER_ADDR_2 0b1011111 + + + + #define DRIVER_COUNT 2 + #define DRIVER_1_LED_TOTAL 44 + #define DRIVER_2_LED_TOTAL 40 + #define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) + + // RGB Matrix Animation modes. Explicitly enabled + // For full list of effects, see: + // https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects + // # define ENABLE_RGB_MATRIX_ALPHAS_MODS +# define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN +# define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT +# define ENABLE_RGB_MATRIX_BREATHING + // # define ENABLE_RGB_MATRIX_BAND_SAT + // # define ENABLE_RGB_MATRIX_BAND_VAL + // # define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT + // # define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL + // # define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT + // # define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL +# define ENABLE_RGB_MATRIX_CYCLE_ALL +# define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT +# define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN +# define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON +# define ENABLE_RGB_MATRIX_CYCLE_OUT_IN + // # define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL +# define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL +# define ENABLE_RGB_MATRIX_CYCLE_SPIRAL +# define ENABLE_RGB_MATRIX_DUAL_BEACON + // # define ENABLE_RGB_MATRIX_RAINBOW_BEACON +# define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS +# define ENABLE_RGB_MATRIX_RAINDROPS +# define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS +# define ENABLE_RGB_MATRIX_HUE_BREATHING +# define ENABLE_RGB_MATRIX_HUE_PENDULUM +# define ENABLE_RGB_MATRIX_HUE_WAVE +# define ENABLE_RGB_MATRIX_PIXEL_RAIN +# define ENABLE_RGB_MATRIX_PIXEL_FLOW +# define ENABLE_RGB_MATRIX_PIXEL_FRACTAL + // enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined + // # define ENABLE_RGB_MATRIX_TYPING_HEATMAP + // # define ENABLE_RGB_MATRIX_DIGITAL_RAIN + // enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE + // # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE + // # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS + // # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS + // # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS +# define ENABLE_RGB_MATRIX_SPLASH +# define ENABLE_RGB_MATRIX_MULTISPLASH +# define ENABLE_RGB_MATRIX_SOLID_SPLASH +# define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH + +#endif + +#define RGB_DI_PIN B0 +#ifdef RGB_DI_PIN + // define RGBLIGHT_ANIMATIONS +# define RGBLIGHT_EFFECT_STATIC_GRADIENT +# define RGBLIGHT_EFFECT_RAINBOW_SWIRL +# define RGBLIGHT_EFFECT_BREATHING +# define RGBLED_NUM 18 +# define RGBLIGHT_HUE_STEP 8 +# define RGBLIGHT_SAT_STEP 8 +# define RGBLIGHT_VAL_STEP 8 +# define RGBLIGHT_SLEEP +#endif + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* 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 diff --git a/keyboards/mt/mt84/info.json b/keyboards/mt/mt84/info.json new file mode 100644 index 0000000000..aaded30962 --- /dev/null +++ b/keyboards/mt/mt84/info.json @@ -0,0 +1,10 @@ +{ + "keyboard_name": "mt84", + "url": "", + "maintainer": "qmk", + "layouts": { + "LAYOUT_75_ansi": { + "layout": [{"label":"Esc", "x":0, "y":0}, {"label":"F1", "x":1, "y":0}, {"label":"F2", "x":2, "y":0}, {"label":"F3", "x":3, "y":0}, {"label":"F4", "x":4, "y":0}, {"label":"F5", "x":5, "y":0}, {"label":"F6", "x":6, "y":0}, {"label":"F7", "x":7, "y":0}, {"label":"F8", "x":8, "y":0}, {"label":"F9", "x":9, "y":0}, {"label":"F10", "x":10, "y":0}, {"label":"F11", "x":11, "y":0}, {"label":"F12", "x":12, "y":0}, {"label":"PrtSc", "x":13, "y":0}, {"label":"Pause", "x":14, "y":0}, {"label":"Delete", "x":15, "y":0}, {"label":"~", "x":0, "y":1}, {"label":"!", "x":1, "y":1}, {"label":"@", "x":2, "y":1}, {"label":"#", "x":3, "y":1}, {"label":"$", "x":4, "y":1}, {"label":"%", "x":5, "y":1}, {"label":"^", "x":6, "y":1}, {"label":"&", "x":7, "y":1}, {"label":"*", "x":8, "y":1}, {"label":"(", "x":9, "y":1}, {"label":")", "x":10, "y":1}, {"label":"_", "x":11, "y":1}, {"label":"+", "x":12, "y":1}, {"label":"Backspace", "x":13, "y":1, "w":2}, {"label":"Home", "x":15, "y":1}, {"label":"Tab", "x":0, "y":2, "w":1.5}, {"label":"Q", "x":1.5, "y":2}, {"label":"W", "x":2.5, "y":2}, {"label":"E", "x":3.5, "y":2}, {"label":"R", "x":4.5, "y":2}, {"label":"T", "x":5.5, "y":2}, {"label":"Y", "x":6.5, "y":2}, {"label":"U", "x":7.5, "y":2}, {"label":"I", "x":8.5, "y":2}, {"label":"O", "x":9.5, "y":2}, {"label":"P", "x":10.5, "y":2}, {"label":"{", "x":11.5, "y":2}, {"label":"}", "x":12.5, "y":2}, {"label":"|", "x":13.5, "y":2, "w":1.5}, {"label":"Page Up", "x":15, "y":2}, {"label":"Caps Lock", "x":0, "y":3, "w":1.75}, {"label":"A", "x":1.75, "y":3}, {"label":"S", "x":2.75, "y":3}, {"label":"D", "x":3.75, "y":3}, {"label":"F", "x":4.75, "y":3}, {"label":"G", "x":5.75, "y":3}, {"label":"H", "x":6.75, "y":3}, {"label":"J", "x":7.75, "y":3}, {"label":"K", "x":8.75, "y":3}, {"label":"L", "x":9.75, "y":3}, {"label":":", "x":10.75, "y":3}, {"label":"\"", "x":11.75, "y":3}, {"label":"Enter", "x":12.75, "y":3, "w":2.25}, {"label":"Page Down", "x":15, "y":3}, {"label":"Shift", "x":0, "y":4, "w":2.25}, {"label":"Z", "x":2.25, "y":4}, {"label":"X", "x":3.25, "y":4}, {"label":"C", "x":4.25, "y":4}, {"label":"V", "x":5.25, "y":4}, {"label":"B", "x":6.25, "y":4}, {"label":"N", "x":7.25, "y":4}, {"label":"M", "x":8.25, "y":4}, {"label":"<", "x":9.25, "y":4}, {"label":">", "x":10.25, "y":4}, {"label":"?", "x":11.25, "y":4}, {"label":"Shift", "x":12.25, "y":4, "w":1.75}, {"label":"\u2191", "x":14, "y":4}, {"label":"End", "x":15, "y":4}, {"label":"Ctrl", "x":0, "y":5, "w":1.25}, {"label":"Win", "x":1.25, "y":5, "w":1.25}, {"label":"Alt", "x":2.5, "y":5, "w":1.25}, {"x":3.75, "y":5, "w":6.25}, {"label":"Alt", "x":10, "y":5}, {"label":"Fn", "x":11, "y":5}, {"label":"Ctrl", "x":12, "y":5}, {"label":"\u2190", "x":13, "y":5}, {"label":"\u2193", "x":14, "y":5}, {"label":"\u2192", "x":15, "y":5}] + } + } +} diff --git a/keyboards/mt/mt84/keymaps/default/config.h b/keyboards/mt/mt84/keymaps/default/config.h new file mode 100644 index 0000000000..dd687cad58 --- /dev/null +++ b/keyboards/mt/mt84/keymaps/default/config.h @@ -0,0 +1,19 @@ +/* Copyright 2021 QMK + * + * 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 LAYER_STATE_8BIT diff --git a/keyboards/mt/mt84/keymaps/default/keymap.c b/keyboards/mt/mt84/keymaps/default/keymap.c new file mode 100644 index 0000000000..bb7d5b447f --- /dev/null +++ b/keyboards/mt/mt84/keymaps/default/keymap.c @@ -0,0 +1,55 @@ + /* Copyright 2020 mt<704340378@qq.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 + + + +enum mt84_layers { + _DEFAULT, + _FN +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [_DEFAULT] = LAYOUT_75_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_PSCREEN, KC_PAUSE, KC_DELETE, + KC_GRAVE, 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_HOME, + 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_PGUP, + 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_PGDOWN, + 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_END, + KC_LCTL, KC_LALT, KC_LWIN, KC_SPC, MO(1), KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [_FN] = LAYOUT_75_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,_______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_TOG, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, RGB_SPI, RGB_SPD, _______, _______,_______, _______,_______, + _______, RGB_M_P, RGB_M_B, RGB_M_R, RGB_M_SW, RGB_M_SN, RGB_M_K, RGB_M_X, RGB_M_G, RGB_M_T, _______,_______,_______,_______, + _______, _______, _______, _______, KC_TRNS, _______, _______, _______, _______, _______ + ) +}; + +void rgb_matrix_indicators_user(void) { + led_t led_state = host_keyboard_led_state(); + switch (get_highest_layer(layer_state)) { + case _FN: + rgb_matrix_set_color(77,0xFF, 0x80, 0x00); + break; + } + if (led_state.caps_lock) { + rgb_matrix_set_color(46, 0xFF, 0xFF, 0xFF); + } +} diff --git a/keyboards/mt/mt84/keymaps/via/keymap.c b/keyboards/mt/mt84/keymaps/via/keymap.c new file mode 100644 index 0000000000..ca62790cde --- /dev/null +++ b/keyboards/mt/mt84/keymaps/via/keymap.c @@ -0,0 +1,48 @@ + /* Copyright 2020 MaiKong<704340378@qq.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] = { + + LAYOUT_75_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_PSCREEN, KC_PAUSE, KC_DELETE, + KC_GRAVE, 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_HOME, + 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_PGUP, + 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_PGDOWN, + 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_END, + KC_LCTL, KC_LALT, KC_LWIN, KC_SPC, MO(1), KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT), + LAYOUT_75_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS, + KC_TRNS, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, QK_BOOT, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BL_DEC, BL_TOGG, BL_INC, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS), + LAYOUT_75_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS), + LAYOUT_75_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS), +}; diff --git a/keyboards/mt/mt84/keymaps/via/rules.mk b/keyboards/mt/mt84/keymaps/via/rules.mk new file mode 100644 index 0000000000..ca9fed0e6b --- /dev/null +++ b/keyboards/mt/mt84/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +LTO_ENABLE = yes +VIA_ENABLE = yes diff --git a/keyboards/mt/mt84/mt84.c b/keyboards/mt/mt84/mt84.c new file mode 100644 index 0000000000..e15a1ff951 --- /dev/null +++ b/keyboards/mt/mt84/mt84.c @@ -0,0 +1,140 @@ + /* Copyright 2020 MT<704340378@qq.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 "mt84.h" + +#ifdef RGB_MATRIX_ENABLE +const is31_led PROGMEM g_is31_leds[DRIVER_LED_TOTAL] = { + /* Refer to IS31 manual for these locations + * driver + * | R location + * | | G location + * | | | B location + * | | | | */ + + {0, A_11, B_11, C_11}, + {0, D_11, E_11, F_11}, + {0, G_11, H_11, I_11}, + {0, J_11, K_11, L_11}, + {0, A_12, B_12, C_12}, + {0, D_12, E_12, F_12}, + {0, G_12, H_12, I_12}, + {0, J_12, K_12, L_12}, + {1, A_11, B_11, C_11}, + {1, D_11, E_11, F_11}, + {1, G_11, H_11, I_11}, + {1, J_11, K_11, L_11}, + {1, A_12, B_12, C_12}, + {1, D_12, E_12, F_12}, + {1, G_12, H_12, I_12}, + {1, J_12, K_12, L_12}, + + {0, A_1, B_1, C_1}, + {0, D_1, E_1, F_1}, + {0, G_1, H_1, I_1}, + {0, J_1, K_1, L_1}, + {0, A_6, B_6, C_6}, + {0, D_6, E_6, F_6}, + {0, G_6, H_6, I_6}, + {0, J_6, K_6, L_6}, + {1, A_1, B_1, C_1}, + {1, D_1, E_1, F_1}, + {1, G_1, H_1, I_1}, + {1, J_1, K_1, L_1}, + {1, A_6, B_6, C_6}, + {1, D_6, E_6, F_6}, + {1, G_6, H_6, I_6}, + + {0, A_2, B_2, C_2}, + {0, D_2, E_2, F_2}, + {0, G_2, H_2, I_2}, + {0, J_2, K_2, L_2}, + {0, A_7, B_7, C_7}, + {0, D_7, E_7, F_7}, + {0, G_7, H_7, I_7}, + {0, J_7, K_7, L_7}, + {1, A_2, B_2, C_2}, + {1, D_2, E_2, F_2}, + {1, G_2, H_2, I_2}, + {1, J_2, K_2, L_2}, + {1, A_7, B_7, C_7}, + {1, D_7, E_7, F_7}, + {1, G_7, H_7, I_7}, + + {0, A_3, B_3, C_3}, + {0, D_3, E_3, F_3}, + {0, G_3, H_3, I_3}, + {0, J_3, K_3, L_3}, + {0, A_8, B_8, C_8}, + {0, D_8, E_8, F_8}, + {0, G_8, H_8, I_8}, + {0, J_8, K_8, L_8}, + {1, A_3, B_3, C_3}, + {1, D_3, E_3, F_3}, + {1, G_3, H_3, I_3}, + {1, J_3, K_3, L_3}, + {1, A_8, B_8, C_8}, + {1, G_8, H_8, I_8}, + + {0, A_4, B_4, C_4}, + {0, D_4, E_4, F_4}, + {0, G_4, H_4, I_4}, + {0, J_4, K_4, L_4}, + {0, A_9, B_9, C_9}, + {0, D_9, E_9, F_9}, + {0, G_9, H_9, I_9}, + {0, J_9, K_9, L_9}, + {1, A_4, B_4, C_4}, + {1, D_4, E_4, F_4}, + {1, G_4, H_4, I_4}, + {1, J_4, K_4, L_4}, + {1, A_9, B_9, C_9}, + {1, G_9, H_9, I_9}, + + {0, A_5, B_5, C_5}, + {0, D_5, E_5, F_5}, + {0, G_5, H_5, I_5}, + {0, D_10, E_10, F_10}, + {1, D_5, E_5, F_5}, + {1, G_5, H_5, I_5}, + {1, J_5, K_5, L_5}, + {1, A_10, B_10, C_10}, + {1, D_10, E_10, F_10}, + {1, G_10, H_10, I_10} +}; + +led_config_t g_led_config = {{ + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 }, + { 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29 }, + { 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44 }, + { 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58 }, + { 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73 }, + {74, 75, 76, 77, 78, 79, 80, 81, 82, 83 } +}, { + { 0, 0 }, { 15, 0 }, { 30, 0 }, { 45, 0 }, { 60, 0 }, { 75, 0 }, { 90, 0 }, { 105, 0 }, { 120, 0 }, { 135, 0 }, { 150, 0 }, { 165, 0 }, { 180, 0 }, { 195, 0 }, { 210, 0 }, { 224, 0 }, + { 0, 13 }, { 15, 13 }, { 30, 13 }, { 45, 13 }, { 60, 13 }, { 75, 13 }, { 90, 13 }, { 105, 13 }, { 120, 13 }, { 135, 13 }, { 150, 13 }, { 165, 13 }, { 180, 13 }, { 205, 13 }, { 224, 13 }, + { 3, 26 }, { 18, 26 }, { 33, 26 }, { 48, 26 }, { 63, 26 }, { 78, 26 }, { 93, 26 }, { 108, 26 }, { 123, 26 }, { 138, 26 }, { 153, 26 }, { 168, 26 }, { 183, 26 }, { 205, 26 },{ 224, 26 }, + { 6, 39 }, { 20, 39 }, { 36, 39 }, { 52, 39 }, { 68, 39 }, { 84, 39 }, { 100, 39 }, { 116, 39 }, { 132, 39 }, { 148, 39 }, { 164, 39 }, { 180, 39 }, { 212, 39 }, { 224, 39 }, + { 9, 52 }, { 27, 52 }, { 43, 52 }, { 59, 52 }, { 75, 52 }, { 91, 52 }, { 107, 52 }, { 123, 52 }, { 139, 52 }, { 155, 52 }, { 171, 52 }, { 187, 52 }, { 212, 52 }, { 224, 52 }, +{ 2, 64 }, { 18, 64 }, { 33, 64 }, { 93, 64 }, { 150, 64 }, { 165, 64 }, { 180, 64 }, { 195, 64 }, { 210, 64 }, { 224, 64 } +}, { + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 1, 4, 1, 1, 1, 4, 4, 4, +}}; +#endif diff --git a/keyboards/mt/mt84/mt84.h b/keyboards/mt/mt84/mt84.h new file mode 100644 index 0000000000..d3de007c94 --- /dev/null +++ b/keyboards/mt/mt84/mt84.h @@ -0,0 +1,35 @@ + /* Copyright 2020 MaiKong<704340378@qq.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 + +#include "quantum.h" + +#define LAYOUT_75_ansi( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D, k0E, k4E, \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1C, k1D, k1E,\ + k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2C, k2D, k2E,\ + k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3A, k3B, k3C, k3E, \ + k40, k41, k42, k43, k44, k45, k46, k47, k48, k49, k4A, k4B, k4C, k4D, \ + k50, k51, k52, k55, k59, k5A, k5B, k5C, k5D, k5E \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D, k0E}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1C, k1D, k1E}, \ + {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2C, k2D, k2E}, \ + {k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3A, k3B, k3C, KC_NO, k3E}, \ + {k40, k41, k42, k43, k44, k45, k46, k47, k48, k49, k4A, k4B, k4C, k4D, k4E}, \ + {k50, k51, k52, KC_NO,KC_NO, k55, KC_NO,KC_NO,KC_NO, k59, k5A, k5B, k5C, k5D, k5E} \ +} diff --git a/keyboards/mt/mt84/readme.md b/keyboards/mt/mt84/readme.md new file mode 100644 index 0000000000..f26521ad6a --- /dev/null +++ b/keyboards/mt/mt84/readme.md @@ -0,0 +1,23 @@ +# Mt84rgb + +![Mt84rgb](https://i.imgur.com/2fJg3DDl.png) + +A 84% keyboard PCB made by MT. +It supports standard 84-key layout, with hotswap sockets and per-key RGB backlight. + + +* Keyboard Maintainer: [MT](https://github.com/704340378) +* Hardware Supported: mt84rgb (atmega32u4) +* Hardware Availability: [麦田外设](https://shop110310565.taobao.com) + +Make example for this keyboard (after setting up your build environment): + + make mt/mt84:default + +Flashing example for this keyboard: + + make mt/mt84:default:flash + +To put the board into bootloader mode, either press the reset button on the bottom the PCB or hold Space+B while plugging it in. + +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/mt/mt84/rules.mk b/keyboards/mt/mt84/rules.mk new file mode 100644 index 0000000000..0543099445 --- /dev/null +++ b/keyboards/mt/mt84/rules.mk @@ -0,0 +1,23 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = yes # Enable N-Key Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGB_MATRIX_ENABLE = yes # Use RGB Matrix +RGB_MATRIX_DRIVER = IS31FL3737 +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output +LTO_ENABLE = yes + +LAYOUTS = 75_ansi diff --git a/keyboards/mt/mt980/config.h b/keyboards/mt/mt980/config.h new file mode 100644 index 0000000000..ff6c5807df --- /dev/null +++ b/keyboards/mt/mt980/config.h @@ -0,0 +1,56 @@ +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0xFEED +#define PRODUCT_ID 0x6060 +#define DEVICE_VER 0x0001 +#define MANUFACTURER Wheat Field Peripherals +#define PRODUCT MT980 + +/* key matrix size */ +#define MATRIX_ROWS 12 +#define MATRIX_COLS 9 + +/* key matrix pins */ +#define MATRIX_ROW_PINS { B7, B3, B2, B1, B0, E6, F0, F1, F4, F5, F6, F7 } +#define MATRIX_COL_PINS { D0, D1, D2, D3, D5, D4, D6, D7, B4 } +#define UNUSED_PINS + +/* COL2ROW or ROW2COL */ +#define DIODE_DIRECTION ROW2COL + +#define LED_NUM_LOCK_PIN C6 +#define LED_CAPS_LOCK_PIN C7 +#define LED_SCROLL_LOCK_PIN B5 +#define LED_PIN_ON_STATE 0 + +/* number of backlight levels */ +#define BACKLIGHT_PIN B6 +#ifdef BACKLIGHT_PIN +#define BACKLIGHT_LEVELS 3 +#endif + +/* Set 0 if debouncing isn't needed */ +#define DEBOUNCE 5 + +/* 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 + +#define RGB_DI_PIN E2 +#ifdef RGB_DI_PIN +#define RGBLIGHT_ANIMATIONS +#define RGBLED_NUM 24 +#define RGBLIGHT_HUE_STEP 8 +#define RGBLIGHT_SAT_STEP 8 +#define RGBLIGHT_VAL_STEP 8 +#define RGBLIGHT_LIMIT_VAL 185 +#endif + +/* Place bootmagic key on Esc */ +#define BOOTMAGIC_LITE_ROW 5 +#define BOOTMAGIC_LITE_COLUMN 0 diff --git a/keyboards/mt/mt980/info.json b/keyboards/mt/mt980/info.json new file mode 100644 index 0000000000..be89ec8fc0 --- /dev/null +++ b/keyboards/mt/mt980/info.json @@ -0,0 +1,114 @@ +{ + "keyboard_name": "mt980", + "url": "https://shop110310565.taobao.com", + "maintainer": "walkerstop", + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"K50", "x":0, "y":0}, + {"label":"K52", "x":1.25, "y":0}, + {"label":"K53", "x":2.25, "y":0}, + {"label":"K54", "x":3.25, "y":0}, + {"label":"K55", "x":4.25, "y":0}, + {"label":"K57", "x":5.5, "y":0}, + {"label":"K58", "x":6.5, "y":0}, + {"label":"KB8", "x":7.5, "y":0}, + {"label":"KB7", "x":8.5, "y":0}, + {"label":"KB5", "x":9.75, "y":0}, + {"label":"KB4", "x":10.75, "y":0}, + {"label":"KB3", "x":11.75, "y":0}, + {"label":"KB6", "x":12.75, "y":0}, + {"label":"K51", "x":14, "y":0}, + {"label":"KB2", "x":15.5, "y":0}, + {"label":"KB1", "x":16.5, "y":0}, + {"label":"KB0", "x":17.5, "y":0}, + {"label":"K63", "x":18.5, "y":0}, + {"label":"K40", "x":0, "y":1.5}, + {"label":"K41", "x":1, "y":1.5}, + {"label":"K42", "x":2, "y":1.5}, + {"label":"K43", "x":3, "y":1.5}, + {"label":"K44", "x":4, "y":1.5}, + {"label":"K45", "x":5, "y":1.5}, + {"label":"K46", "x":6, "y":1.5}, + {"label":"K47", "x":7, "y":1.5}, + {"label":"K48", "x":8, "y":1.5}, + {"label":"KA8", "x":9, "y":1.5}, + {"label":"KA7", "x":10, "y":1.5}, + {"label":"KA5", "x":11, "y":1.5}, + {"label":"KA4", "x":12, "y":1.5}, + {"label":"KA3", "x":13, "y":1.5}, + {"label":"KA6", "x":14, "y":1.5}, + {"label":"KA2", "x":15.5, "y":1.5}, + {"label":"KA1", "x":16.5, "y":1.5}, + {"label":"KA0", "x":17.5, "y":1.5}, + {"label":"K64", "x":18.5, "y":1.5}, + {"label":"K30", "x":0, "y":2.5, "w":1.5}, + {"label":"K31", "x":1.5, "y":2.5}, + {"label":"K32", "x":2.5, "y":2.5}, + {"label":"K33", "x":3.5, "y":2.5}, + {"label":"K34", "x":4.5, "y":2.5}, + {"label":"K35", "x":5.5, "y":2.5}, + {"label":"K36", "x":6.5, "y":2.5}, + {"label":"K37", "x":7.5, "y":2.5}, + {"label":"K38", "x":8.5, "y":2.5}, + {"label":"K98", "x":9.5, "y":2.5}, + {"label":"K97", "x":10.5, "y":2.5}, + {"label":"K95", "x":11.5, "y":2.5}, + {"label":"K94", "x":12.5, "y":2.5}, + {"label":"K84", "x":13.5, "y":2.5, "w":1.5}, + {"label":"K96", "x":15.5, "y":2.5}, + {"label":"K92", "x":16.5, "y":2.5}, + {"label":"K91", "x":17.5, "y":2.5}, + {"label":"K90", "x":18.5, "y":2.5}, + {"label":"K20", "x":0, "y":3.5, "w":1.75}, + {"label":"K21", "x":1.75, "y":3.5}, + {"label":"K22", "x":2.75, "y":3.5}, + {"label":"K23", "x":3.75, "y":3.5}, + {"label":"K24", "x":4.75, "y":3.5}, + {"label":"K25", "x":5.75, "y":3.5}, + {"label":"K26", "x":6.75, "y":3.5}, + {"label":"K27", "x":7.75, "y":3.5}, + {"label":"K28", "x":8.75, "y":3.5}, + {"label":"K88", "x":9.75, "y":3.5}, + {"label":"K87", "x":10.75, "y":3.5}, + {"label":"K85", "x":11.75, "y":3.5}, + {"label":"K93", "x":12.75, "y":3.5, "w":2.25}, + {"label":"K86", "x":15.5, "y":3.5}, + {"label":"K82", "x":16.5, "y":3.5}, + {"label":"K81", "x":17.5, "y":3.5}, + {"label":"K80", "x":18.5, "y":3.5}, + {"label":"K10", "x":0, "y":4.5, "w":1.25}, + {"label":"K11", "x":1.25, "y":4.5}, + {"label":"K12", "x":2.25, "y":4.5}, + {"label":"K13", "x":3.25, "y":4.5}, + {"label":"K14", "x":4.25, "y":4.5}, + {"label":"K15", "x":5.25, "y":4.5}, + {"label":"K16", "x":6.25, "y":4.5}, + {"label":"K17", "x":7.25, "y":4.5}, + {"label":"K18", "x":8.25, "y":4.5}, + {"label":"K78", "x":9.25, "y":4.5}, + {"label":"K77", "x":10.25, "y":4.5}, + {"label":"K75", "x":11.25, "y":4.5}, + {"label":"K74", "x":12.25, "y":4.5, "w":1.75}, + {"label":"K73", "x":14.25, "y":4.75}, + {"label":"K76", "x":15.5, "y":4.5}, + {"label":"K72", "x":16.5, "y":4.5}, + {"label":"K71", "x":17.5, "y":4.5}, + {"label":"K70", "x":18.5, "y":4.5}, + {"label":"K00", "x":0, "y":5.5, "w":1.25}, + {"label":"K01", "x":1.25, "y":5.5}, + {"label":"K02", "x":2.25, "y":5.5, "w":1.25}, + {"label":"K06", "x":3.5, "y":5.5, "w":6.25}, + {"label":"K08", "x":9.75, "y":5.5}, + {"label":"K07", "x":10.75, "y":5.5}, + {"label":"K05", "x":11.75, "y":5.5, "w":1.25}, + {"label":"K04", "x":13.25, "y":5.75}, + {"label":"K03", "x":14.25, "y":5.75}, + {"label":"K66", "x":15.25, "y":5.75}, + {"label":"K62", "x":16.5, "y":5.5}, + {"label":"K61", "x":17.5, "y":5.5}, + {"label":"K60", "x":18.5, "y":5.5} + ] + } + } +} diff --git a/keyboards/mt/mt980/keymaps/default/keymap.c b/keyboards/mt/mt980/keymaps/default/keymap.c new file mode 100644 index 0000000000..97a3de64fd --- /dev/null +++ b/keyboards/mt/mt980/keymaps/default/keymap.c @@ -0,0 +1,21 @@ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT( + 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_NO, KC_INS, KC_PSCR, KC_PGUP, KC_PGDN, + 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_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + 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_P7, KC_P8, KC_P9, KC_PPLS, + 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_P4, KC_P5, KC_P6, KC_PPLS, + KC_LSFT, 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_P1, KC_P2, KC_P3, KC_PENT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT, KC_PENT), + + [1] = LAYOUT( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PAUSE, KC_SLCK, KC_HOME, KC_END, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_TOG, QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, RGB_RMOD, RGB_VAD, RGB_MOD, KC_TRNS, KC_TRNS, KC_TRNS) + +}; diff --git a/keyboards/mt/mt980/keymaps/walker/config.h b/keyboards/mt/mt980/keymaps/walker/config.h new file mode 100644 index 0000000000..0bd3959938 --- /dev/null +++ b/keyboards/mt/mt980/keymaps/walker/config.h @@ -0,0 +1,5 @@ +#pragma once + +#define TAPPING_TERM 200 +#define ONESHOT_TAP_TOGGLE 5 +#define ONESHOT_TIMEOUT 5000 diff --git a/keyboards/mt/mt980/keymaps/walker/keymap.c b/keyboards/mt/mt980/keymaps/walker/keymap.c new file mode 100644 index 0000000000..83a3fb8167 --- /dev/null +++ b/keyboards/mt/mt980/keymaps/walker/keymap.c @@ -0,0 +1,168 @@ +#include "mt980.h" + +bool numlock_on = true; + +typedef struct { + bool is_press_action; + int state; +} tap; + +enum { + SINGLE_TAP = 1, + SINGLE_HOLD = 2, + DOUBLE_TAP = 3, + DOUBLE_HOLD = 4, + TRIPLE_TAP = 5, + TRIPLE_HOLD = 6 +}; + +enum { + ALT_L1 = 0 +}; + +int cur_dance (qk_tap_dance_state_t *state); +void alt_finished (qk_tap_dance_state_t *state, void *user_data); +void alt_reset (qk_tap_dance_state_t *state, void *user_data); + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT( + 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_NO, KC_INS, KC_PSCR, KC_PGUP, KC_PGDN, + 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_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + 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_P7, KC_P8, KC_P9, KC_PPLS, + 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_P4, KC_P5, KC_P6, KC_PPLS, + KC_LSFT, 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_P1, KC_P2, KC_P3, KC_PENT, + KC_LCTL, KC_LGUI, TD(ALT_L1), KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT, KC_PENT), + + [1] = LAYOUT( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PAUSE, KC_SLCK, KC_HOME, KC_END, + KC_TRNS, 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_TOG, RESET, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TRNS, KC_TRNS, RGB_RMOD, RGB_VAD, RGB_MOD, KC_TRNS, KC_TRNS, KC_TRNS) + +}; + +int cur_dance (qk_tap_dance_state_t *state) { + if (state->count == 1) { + if (state->pressed) return SINGLE_HOLD; + else return SINGLE_TAP; + } + else if (state->count == 2) { + if (state->pressed) return DOUBLE_HOLD; + else return DOUBLE_TAP; + } + else if (state->count == 3) { + if (state->interrupted || !state->pressed) return TRIPLE_TAP; + else return TRIPLE_HOLD; + } + else return 8; +} + +static tap alttap_state = { + .is_press_action = true, + .state = 0 +}; + +void alt_finished (qk_tap_dance_state_t *state, void *user_data) { + alttap_state.state = cur_dance(state); + switch (alttap_state.state) { + case SINGLE_TAP: set_oneshot_layer(1, ONESHOT_START); clear_oneshot_layer_state(ONESHOT_PRESSED); break; + case SINGLE_HOLD: register_code(KC_LALT); break; + case DOUBLE_TAP: set_oneshot_layer(1, ONESHOT_START); set_oneshot_layer(1, ONESHOT_PRESSED); break; + case DOUBLE_HOLD: register_code(KC_LALT); layer_on(1); break; + } +} + +void alt_reset (qk_tap_dance_state_t *state, void *user_data) { + switch (alttap_state.state) { + case SINGLE_TAP: break; + case SINGLE_HOLD: unregister_code(KC_LALT); break; + case DOUBLE_TAP: break; + case DOUBLE_HOLD: layer_off(1); unregister_code(KC_LALT); break; + } + alttap_state.state = 0; +} + +qk_tap_dance_action_t tap_dance_actions[] = { + [ALT_L1] = ACTION_TAP_DANCE_FN_ADVANCED(NULL,alt_finished, alt_reset) +}; + +void led_set_keymap(uint8_t usb_led) { + if (usb_led & (1<<USB_LED_NUM_LOCK)) { + numlock_on = true; + } + else { + numlock_on = false; + } +} + +bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { + + switch (keycode) { + case KC_TRNS: + case KC_NO: + /* Always cancel one-shot layer when another key gets pressed */ + if (record->event.pressed && is_oneshot_layer_active()) + clear_oneshot_layer_state(ONESHOT_OTHER_KEY_PRESSED); + return true; + case RESET: + /* Don't allow reset from oneshot layer state */ + if (record->event.pressed && is_oneshot_layer_active()) { + clear_oneshot_layer_state(ONESHOT_OTHER_KEY_PRESSED); + return false; + } + return true; + case KC_PPLS: + if (!numlock_on) { + if (is_oneshot_layer_active() || layer_state & 0x2) { + if (record->event.pressed) + register_code(KC_HOME); + else + unregister_code(KC_HOME); + clear_oneshot_layer_state(ONESHOT_START); + } + else { + if (record->event.pressed) + register_code(KC_PGUP); + else + unregister_code(KC_PGUP); + } + return false; + } + return true; + case KC_PENT: + if (!numlock_on) { + if (is_oneshot_layer_active() || layer_state & 0x2) { + if (record->event.pressed) + register_code(KC_END); + else + unregister_code(KC_END); + clear_oneshot_layer_state(ONESHOT_START); + } + else { + if (record->event.pressed) + register_code(KC_PGDN); + else + unregister_code(KC_PGDN); + } + return false; + } + return true; + case KC_NLCK: + /* Shift + NumLock will be treated as shift-Insert */ + if ((keyboard_report->mods & MOD_BIT (KC_LSFT)) || (keyboard_report->mods & MOD_BIT (KC_RSFT))) { + if (record->event.pressed) { + register_code(KC_INS); + unregister_code(KC_INS); + } + return false; + } + else + return true; + default: + return true; + } + return true; +} diff --git a/keyboards/mt/mt980/keymaps/walker/rules.mk b/keyboards/mt/mt980/keymaps/walker/rules.mk new file mode 100644 index 0000000000..e5ddcae8d9 --- /dev/null +++ b/keyboards/mt/mt980/keymaps/walker/rules.mk @@ -0,0 +1 @@ +TAP_DANCE_ENABLE = yes diff --git a/keyboards/mt/mt980/mt980.c b/keyboards/mt/mt980/mt980.c new file mode 100644 index 0000000000..69f7cc491a --- /dev/null +++ b/keyboards/mt/mt980/mt980.c @@ -0,0 +1 @@ +#include "mt980.h" diff --git a/keyboards/mt/mt980/mt980.h b/keyboards/mt/mt980/mt980.h new file mode 100644 index 0000000000..d9804b3392 --- /dev/null +++ b/keyboards/mt/mt980/mt980.h @@ -0,0 +1,25 @@ +#pragma once + +#include "quantum.h" + +#define LAYOUT( \ + K050, K052, K053, K054, K055, K057, K058, K118, K117, K115, K114, K113, K116, K051, K112, K111, K110, K063, \ + K040, K041, K042, K043, K044, K045, K046, K047, K048, K108, K107, K105, K104, K103, K106, K102, K101, K100, K064, \ + K030, K031, K032, K033, K034, K035, K036, K037, K038, K098, K097, K095, K094, K084, K096, K092, K091, K090, \ + K020, K021, K022, K023, K024, K025, K026, K027, K028, K088, K087, K085, K093, K086, K082, K081, K080, \ + K010, K011, K012, K013, K014, K015, K016, K017, K018, K078, K077, K075, K074, K073, K076, K072, K071, K070, \ + K000, K001, K002, K006, K008, K007, K005, K004, K003, K066, K062, K061, K060 \ +) { \ + { K000, K001, K002, K003, K004, K005, K006, K007, K008 }, \ + { K010, K011, K012, K013, K014, K015, K016, K017, K018 }, \ + { K020, K021, K022, K023, K024, K025, K026, K027, K028 }, \ + { K030, K031, K032, K033, K034, K035, K036, K037, K038 }, \ + { K040, K041, K042, K043, K044, K045, K046, K047, K048 }, \ + { K050, K051, K052, K053, K054, K055, KC_NO, K057, K058 }, \ + { K060, K061, K062, K063, K064, KC_NO, K066, KC_NO, KC_NO}, \ + { K070, K071, K072, K073, K074, K075, K076, K077, K078 }, \ + { K080, K081, K082, KC_NO, K084, K085, K086, K087, K088 }, \ + { K090, K091, K092, K093, K094, K095, K096, K097, K098 }, \ + { K100, K101, K102, K103, K104, K105, K106, K107, K108 }, \ + { K110, K111, K112, K113, K114, K115, K116, K117, K118 } \ +} diff --git a/keyboards/mt/mt980/readme.md b/keyboards/mt/mt980/readme.md new file mode 100644 index 0000000000..5e702de714 --- /dev/null +++ b/keyboards/mt/mt980/readme.md @@ -0,0 +1,14 @@ +# mt980 + +A mechanical keyboard PCB in the same layout as the Leopold FC980M, sold by Wheat Field Peripherals on Taobao. This PCB requires soldering, except for the arrow cluster and the Escape key switches, which use Kailh hot swap sockets. + +Keyboard Maintainer: [walkerstop](https://github.com/walkerstop) +Hardware Supported: mt980 +Hardware Availability: Taobao store https://shop110310565.taobao.com + +Make example for this keyboard (after setting up your build environment): + + make mt/mt980: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/mt/mt980/rules.mk b/keyboards/mt/mt980/rules.mk new file mode 100644 index 0000000000..2ca5686493 --- /dev/null +++ b/keyboards/mt/mt980/rules.mk @@ -0,0 +1,19 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = no # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = yes # Enable N-Key Rollover +BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality +AUDIO_ENABLE = no +RGBLIGHT_ENABLE = yes +KEY_LOCK_ENABLE = no diff --git a/keyboards/mt/split75/config.h b/keyboards/mt/split75/config.h new file mode 100644 index 0000000000..63c9492c31 --- /dev/null +++ b/keyboards/mt/split75/config.h @@ -0,0 +1,21 @@ +#pragma once + +#define VENDOR_ID 0x594D +#define PRODUCT_ID 0x0001 +#define DEVICE_VER 0x0001 +#define MANUFACTURER YMDK +#define PRODUCT Split75 + +/* matrix size */ +#define MATRIX_ROWS 8 +#define MATRIX_COLS 14 + +#define LED_NUM_LOCK_PIN D0 +#define LED_CAPS_LOCK_PIN D1 +#define LED_SCROLL_LOCK_PIN D6 + +#define RGBLED_NUM 8 +#define RGBLIGHT_ANIMATIONS +#define RGBLIGHT_SLEEP + +#define BACKLIGHT_PIN D4 diff --git a/keyboards/mt/split75/info.json b/keyboards/mt/split75/info.json new file mode 100644 index 0000000000..1d0609a378 --- /dev/null +++ b/keyboards/mt/split75/info.json @@ -0,0 +1,13 @@ +{ + "keyboard_name": "split75", + "url": "", + "maintainer": "Michael L. Walker", + "layouts": { + "LAYOUT": { + "layout": [{"label":"ESC", "x":2.25, "y":0}, {"label":"F1", "x":3.25, "y":0}, {"label":"F2", "x":4.25, "y":0}, {"label":"F3", "x":5.25, "y":0}, {"label":"F4", "x":6.25, "y":0}, {"label":"F5", "x":7.25, "y":0}, {"label":"F6", "x":8.25, "y":0}, {"label":"F7", "x":10.25, "y":0}, {"label":"F8", "x":11.25, "y":0}, {"label":"F9", "x":12.25, "y":0}, {"label":"F10", "x":13.25, "y":0}, {"label":"F11", "x":14.25, "y":0}, {"label":"F12", "x":15.25, "y":0}, {"label":"Prt", "x":16.25, "y":0}, {"label":"Ins", "x":17.25, "y":0}, {"label":"Del", "x":18.25, "y":0}, {"label":"8", "x":0, "y":1}, {"label":"9", "x":1, "y":1}, {"label":"~", "x":2.25, "y":1}, {"label":"!", "x":3.25, "y":1}, {"label":"@", "x":4.25, "y":1}, {"label":"#", "x":5.25, "y":1}, {"label":"$", "x":6.25, "y":1}, {"label":"%", "x":7.25, "y":1}, {"label":"^", "x":8.25, "y":1}, {"label":"&", "x":10.25, "y":1}, {"label":"*", "x":11.25, "y":1}, {"label":"(", "x":12.25, "y":1}, {"label":")", "x":13.25, "y":1}, {"label":"_", "x":14.25, "y":1}, {"label":"+", "x":15.25, "y":1}, {"label":"Backspace", "x":16.25, "y":1, "w":2}, {"label":"Home", "x":18.25, "y":1}, {"label":"6", "x":0, "y":2}, {"label":"7", "x":1, "y":2}, {"label":"Tab", "x":2.25, "y":2, "w":1.5}, {"label":"Q", "x":3.75, "y":2}, {"label":"W", "x":4.75, "y":2}, {"label":"E", "x":5.75, "y":2}, {"label":"R", "x":6.75, "y":2}, {"label":"T", "x":7.75, "y":2}, {"label":"Y", "x":9.75, "y":2}, {"label":"U", "x":10.75, "y":2}, {"label":"I", "x":11.75, "y":2}, {"label":"O", "x":12.75, "y":2}, {"label":"P", "x":13.75, "y":2}, {"label":"{", "x":14.75, "y":2}, {"label":"}", "x":15.75, "y":2}, {"label":"|", "x":16.75, "y":2, "w":1.5}, {"label":"PgUp", "x":18.25, "y":2}, {"label":"4", "x":0, "y":3}, {"label":"5", "x":1, "y":3}, {"label":"Caps Lock", "x":2.25, "y":3, "w":1.75}, {"label":"A", "x":4, "y":3}, {"label":"S", "x":5, "y":3}, {"label":"D", "x":6, "y":3}, {"label":"F", "x":7, "y":3}, {"label":"G", "x":8, "y":3}, {"label":"H", "x":10, "y":3}, {"label":"J", "x":11, "y":3}, {"label":"K", "x":12, "y":3}, {"label":"L", "x":13, "y":3}, {"label":":", "x":14, "y":3}, {"label":"\"", "x":15, "y":3}, {"label":"Enter", "x":16, "y":3, "w":2.25}, {"label":"PgDn", "x":18.25, "y":3}, {"label":"2", "x":0, "y":4}, {"label":"3", "x":1, "y":4}, {"label":"Shift", "x":2.25, "y":4, "w":2.25}, {"label":"Z", "x":4.5, "y":4}, {"label":"X", "x":5.5, "y":4}, {"label":"C", "x":6.5, "y":4}, {"label":"V", "x":7.5, "y":4}, {"label":"B", "x":8.5, "y":4}, {"label":"N", "x":10.5, "y":4}, {"label":"M", "x":11.5, "y":4}, {"label":"<", "x":12.5, "y":4}, {"label":">", "x":13.5, "y":4}, {"label":"?", "x":14.5, "y":4}, {"label":"Shift", "x":15.5, "y":4, "w":1.75}, {"label":"\u2191", "x":17.25, "y":4}, {"label":"End", "x":18.25, "y":4}, {"label":"0", "x":0, "y":5}, {"label":"1", "x":1, "y":5}, {"label":"Ctrl", "x":2.25, "y":5, "w":1.25}, {"label":"Win", "x":3.5, "y":5, "w":1.25}, {"label":"Alt", "x":4.75, "y":5, "w":1.25}, {"x":6, "y":5, "w":2}, {"x":8, "y":5}, {"x":10, "y":5, "w":2.75}, {"label":"Alt", "x":12.75, "y":5, "w":1.25}, {"label":"Fn", "x":14, "y":5}, {"label":"Ctrl", "x":15, "y":5, "w":1.25}, {"label":"\u2190", "x":16.25, "y":5}, {"label":"\u2193", "x":17.25, "y":5}, {"label":"\u2192", "x":18.25, "y":5}] + }, + "LAYOUT_iso": { + "layout": [{"label":"ESC", "x":2.25, "y":0}, {"label":"F1", "x":3.25, "y":0}, {"label":"F2", "x":4.25, "y":0}, {"label":"F3", "x":5.25, "y":0}, {"label":"F4", "x":6.25, "y":0}, {"label":"F5", "x":7.25, "y":0}, {"label":"F6", "x":8.25, "y":0}, {"label":"F7", "x":10.25, "y":0}, {"label":"F8", "x":11.25, "y":0}, {"label":"F9", "x":12.25, "y":0}, {"label":"F10", "x":13.25, "y":0}, {"label":"F11", "x":14.25, "y":0}, {"label":"F12", "x":15.25, "y":0}, {"label":"Prt", "x":16.25, "y":0}, {"label":"Ins", "x":17.25, "y":0}, {"label":"Del", "x":18.25, "y":0}, {"label":"8", "x":0, "y":1}, {"label":"9", "x":1, "y":1}, {"label":"~", "x":2.25, "y":1}, {"label":"!", "x":3.25, "y":1}, {"label":"@", "x":4.25, "y":1}, {"label":"#", "x":5.25, "y":1}, {"label":"$", "x":6.25, "y":1}, {"label":"%", "x":7.25, "y":1}, {"label":"^", "x":8.25, "y":1}, {"label":"&", "x":10.25, "y":1}, {"label":"*", "x":11.25, "y":1}, {"label":"(", "x":12.25, "y":1}, {"label":")", "x":13.25, "y":1}, {"label":"_", "x":14.25, "y":1}, {"label":"+", "x":15.25, "y":1}, {"label":"Backspace", "x":16.25, "y":1, "w":2}, {"label":"Home", "x":18.25, "y":1}, {"label":"6", "x":0, "y":2}, {"label":"7", "x":1, "y":2}, {"label":"Tab", "x":2.25, "y":2, "w":1.5}, {"label":"Q", "x":3.75, "y":2}, {"label":"W", "x":4.75, "y":2}, {"label":"E", "x":5.75, "y":2}, {"label":"R", "x":6.75, "y":2}, {"label":"T", "x":7.75, "y":2}, {"label":"Y", "x":9.75, "y":2}, {"label":"U", "x":10.75, "y":2}, {"label":"I", "x":11.75, "y":2}, {"label":"O", "x":12.75, "y":2}, {"label":"P", "x":13.75, "y":2}, {"label":"{", "x":14.75, "y":2}, {"label":"}", "x":15.75, "y":2}, {"label":"PgUp", "x":18.25, "y":2}, {"label":"4", "x":0, "y":3}, {"label":"5", "x":1, "y":3}, {"label":"Caps Lock", "x":2.25, "y":3, "w":1.75}, {"label":"A", "x":4, "y":3}, {"label":"S", "x":5, "y":3}, {"label":"D", "x":6, "y":3}, {"label":"F", "x":7, "y":3}, {"label":"G", "x":8, "y":3}, {"label":"H", "x":10, "y":3}, {"label":"J", "x":11, "y":3}, {"label":"K", "x":12, "y":3}, {"label":"L", "x":13, "y":3}, {"label":":", "x":14, "y":3}, {"label":"\"", "x":15, "y":3}, {"label":"'", "x":16, "y":3}, {"label":"Enter", "x":17, "y":2, "w":1.25, "h":2}, {"label":"PgDn", "x":18.25, "y":3}, {"label":"2", "x":0, "y":4}, {"label":"3", "x":1, "y":4}, {"label":"Shift", "x":2.25, "y":4, "w":1.25}, {"label":"|", "x":3.5, "y":4, "w":1}, {"label":"Z", "x":4.5, "y":4}, {"label":"X", "x":5.5, "y":4}, {"label":"C", "x":6.5, "y":4}, {"label":"V", "x":7.5, "y":4}, {"label":"B", "x":8.5, "y":4}, {"label":"N", "x":10.5, "y":4}, {"label":"M", "x":11.5, "y":4}, {"label":"<", "x":12.5, "y":4}, {"label":">", "x":13.5, "y":4}, {"label":"?", "x":14.5, "y":4}, {"label":"Shift", "x":15.5, "y":4, "w":1.75}, {"label":"\u2191", "x":17.25, "y":4}, {"label":"End", "x":18.25, "y":4}, {"label":"0", "x":0, "y":5}, {"label":"1", "x":1, "y":5}, {"label":"Ctrl", "x":2.25, "y":5, "w":1.25}, {"label":"Win", "x":3.5, "y":5, "w":1.25}, {"label":"Alt", "x":4.75, "y":5, "w":1.25}, {"x":6, "y":5, "w":2}, {"x":8, "y":5}, {"x":10, "y":5, "w":2.75}, {"label":"Alt", "x":12.75, "y":5, "w":1.25}, {"label":"Fn", "x":14, "y":5}, {"label":"Ctrl", "x":15, "y":5, "w":1.25}, {"label":"\u2190", "x":16.25, "y":5}, {"label":"\u2193", "x":17.25, "y":5}, {"label":"\u2192", "x":18.25, "y":5}] + } + } +} diff --git a/keyboards/mt/split75/keymaps/art/keymap.c b/keyboards/mt/split75/keymaps/art/keymap.c new file mode 100644 index 0000000000..c10059bb7d --- /dev/null +++ b/keyboards/mt/split75/keymaps/art/keymap.c @@ -0,0 +1,267 @@ +#include <art.h> +#include <sendstring_workman_zxcvm.h> + +bool is_win = false; + +enum custom_keycodes { + keyboardSpecificKeyCode = NEW_SAFE_RANGE //not used atm +}; + +bool led_update_user(led_t led_state) { + writePin(CAPSLOCK_LED_PIN, led_state.caps_lock); + return false; +} + +void led_show_current_os(void) { + if (is_win) { + writePinHigh(NUMLOCK_LED_PIN); + wait_ms(50); + writePinLow(NUMLOCK_LED_PIN); + wait_ms(50); + writePinHigh(NUMLOCK_LED_PIN); + wait_ms(50); + writePinLow(NUMLOCK_LED_PIN); + wait_ms(50); + writePinHigh(NUMLOCK_LED_PIN); + wait_ms(50); + writePinLow(NUMLOCK_LED_PIN); + wait_ms(50); + } else { + writePinHigh(SCROLLLOCK_LED_PIN); + wait_ms(50); + writePinLow(SCROLLLOCK_LED_PIN); + wait_ms(50); + writePinHigh(SCROLLLOCK_LED_PIN); + wait_ms(50); + writePinLow(SCROLLLOCK_LED_PIN); + wait_ms(50); + writePinHigh(SCROLLLOCK_LED_PIN); + wait_ms(50); + writePinLow(SCROLLLOCK_LED_PIN); + wait_ms(50); + } +} + +void keyboard_pre_init_user(void) { + led_show_current_os(); + + layer_state_set_user(layer_state); +} + +layer_state_t layer_state_set_user(layer_state_t state) { + writePinLow(NUMLOCK_LED_PIN); + writePinLow(SCROLLLOCK_LED_PIN); + switch (get_highest_layer(state)) { + case MEDIA: + writePinHigh(SCROLLLOCK_LED_PIN); + case BASE: + writePinHigh(NUMLOCK_LED_PIN); + break; + case NUMPAD: + writePinHigh(SCROLLLOCK_LED_PIN); + break; + } + return state; +} + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* QWERTY ,-----------------------------------------. ,-----------------------------------------------------. + * | ESC | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 |Print| Ins | Home| + * ,-----------. |-----+-----+-----+-----+-----+-----+-----| |-----+-----+-----+-----+-----+-----+-----------+-----| + * | 8 | 9 | | ~ | 1 | 2 | 3 | 4 | 5 | 6 | | 7 | 8 | 9 | 0 | - | = | Backspac | Del | + * |-----+-----| |-----------------------------------------' ,--------------------------------------------------+-----| + * | 6 | 7 | | Tab | Q | W | E | R | T | | Y | U | I | O | P | [ | ] | \ | End | + * |-----+-----| |---------------------------------------. `--------------------------------------------------+-----| + * | 4 | 5 | | Caps | A | S | D | F | G | | H | J | K | L | ; | ' | Enter | PgUp| + * |-----+-----| |-----------------------------------------. `-------------------------------------------------+-----| + * | 2 | 3 | | Shift | Z | X | C | V | B | | N | M | , | . | / | Shift | Up | PgDn| + * |-----+-----| |-----------------------------------------' ,-------------------------------------------+-----+-----| + * | 0 | 1 | | Ctrl | GUI | Alt |Spac/MEDIA | BSPC| | NAV | Alt | NAV | Ctrl | Left| Down|Right| + * `-----------' `---------------------------------------' `-------------------------------------------------------' + */ + [QWERTY] = LAYOUT( +//--------------------------------Left Hand------------------------------------| |--------------------------------Right Hand------------------------------------------------ + 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, LT(CONFIG, KC_PSCR), KC_INS, KC_HOME, +KC_VOLD,KC_VOLU, KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQUAL, KC_BSPC, KC_DEL, +KC_MPRV,KC_MNXT, 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_END, +KC_HOME,KC_END, 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_ENTER, KC_PGUP, +DYN_MACRO_PLAY1,MO(STRINGS),KC_LSFT,KC_Z,KC_X,KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, LT(GIT,KC_SLSH), KC_RSFT, KC_UP, KC_PGDN, +DYN_REC_STOP,DYN_REC_START1,KC_LCTL, KC_LGUI, KC_LALT, LT(MEDIA,KC_SPC), LT(COMBOS,KC_BSPC), LT(NAV, KC_ENTER), KC_RALT, MO(LAYOUT_CHG),KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT + ), + + /* Base ,-----------------------------------------. ,-----------------------------------------------------. + * | ESC | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 |Print| Ins | Home| + * ,-----------. |-----+-----+-----+-----+-----+-----+-----| |-----+-----+-----+-----+-----+-----+-----------+-----| + * | 8 | 9 | | ~ | 1 | 2 | 3 | 4 | 5 | 6 | | 7 | 8 | 9 | 0 | - | = | Backspac | Del | + * |-----+-----| |-----------------------------------------' ,--------------------------------------------------+-----| + * | 6 | 7 | | Tab | Q | W | E | R | T | | Y | U | I | O | P | [ | ] | \ | End | + * |-----+-----| |---------------------------------------. `--------------------------------------------------+-----| + * | 4 | 5 | | Caps | A | S | D | F | G | | H | J | K | L | ; | ' | Enter | PgUp| + * |-----+-----| |-----------------------------------------. `-------------------------------------------------+-----| + * | 2 | 3 | | Shift | Z | X | C | V | B | | N | M | , | . | / | Shift | Up | PgDn| + * |-----+-----| |-----------------------------------------' ,-------------------------------------------+-----+-----| + * | 0 | 1 | | Ctrl | GUI | Alt | Space |Space| | Space | Alt |QW_ON| Ctrl | Left| Down|Right| + * `-----------' `---------------------------------------' `-------------------------------------------------------' + */ + [BASE] = LAYOUT( +//--------------------------------Left Hand-----------------------------------| |--------------------------------Right Hand------------------------------------------------ + 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, LT(CONFIG, KC_PSCR), KC_INS, KC_HOME, +KC_8, KC_9, KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQUAL, KC_BSPC, KC_DEL, +KC_6, KC_7, 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_END, +KC_4, KC_5, 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_ENTER, KC_PGUP, +KC_2, KC_3, 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_PGDN, +KC_0, KC_1, OS_CTRL, OS_WIN, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, MO(QWERTY_MOD), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT + ), + + [WORKMAN] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, KC_SCLN, _______, _______, _______, _______, +_______, _______, _______, KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I, _______, _______, _______, +_______, _______, _______, KC_Z, KC_X, KC_C, KC_V, KC_M, KC_K, KC_L, KC_COMM, KC_DOT, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, TO(QWERTY), _______, _______, _______, _______ + ), + + [NAV] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_8, KC_9, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_6, KC_7, _______, _______, KC_HOME, KC_UP, KC_END, KC_PGUP, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_4, KC_5, _______, _______, KC_LEFT, KC_DOWN, KC_RIGHT, KC_PGDOWN, _______, CTR_ALT, KC_RSFT, _______, _______, _______, _______, _______, +KC_2, KC_3, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_0, KC_1, _______, _______, _______, KC_DEL, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [MEDIA] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, KC_MPRV, KC_VOLU, KC_MNXT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, KC_VOLD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, KC_MUTE, KC_MPLY, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [COMBOS] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, SARCASM, _______, CTRL_CTV, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, CTRL_CAV, _______, _______, _______, CTRL_LCTV, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [STRINGS] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, TILD_BLOCK, PRESCRIPTION, _______, _______, FOURS, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, ADMINS, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [QWERTY_MOD] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, KC_MPRV, KC_VOLU, KC_MNXT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, KC_VOLD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, KC_MUTE, KC_MPLY, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, TO(QWERTY),_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [LAYOUT_CHG] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, CTL_ALT(KC_HOME), CTL_ALT(KC_UP), CTL_ALT(KC_END), CTL_ALT(KC_PGUP), _______, _______,_______, _______,_______,_______,_______, _______, _______, +_______, _______, _______, _______, CTL_ALT(KC_LEFT), CTL_ALT(KC_DOWN), CTL_ALT(KC_RIGHT), CTL_ALT(KC_PGDOWN), _______,_______,_______,_______,_______, _______, _______, _______, +_______, _______, TO(WORKMAN), _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +TO(NUMPAD), TO(NUMPAD), TO(BASE), _______, _______, _______, CTL_ALT(KC_BSPC), KC_LSFT, _______, _______, _______, _______, _______, _______ + ), + + [CONFIG] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +RGB_VAI, RGB_VAD, RGB_MODE_PLAIN, RGB_MODE_BREATHE, RGB_MODE_RAINBOW, RGB_MODE_SWIRL, RGB_MODE_SNAKE, RGB_MODE_KNIGHT, RGB_MODE_XMAS, RGB_MODE_GRADIENT, RGB_MODE_RGBTEST, XXXXXXX, XXXXXXX, _______, _______, _______, _______, +RGB_SAI, RGB_SAD, _______, _______, _______, _______, _______, _______, _______, _______, _______, TOG_OS, _______, _______, _______, _______, _______, +RGB_HUI, RGB_HUD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +RGB_MOD, RGB_RMOD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +RGB_TOG, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [NUMPAD] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_8, KC_9, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_6, KC_7, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_4, KC_5, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_2, KC_3, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +KC_0, KC_1, _______, _______, _______, _______, _______, _______, _______, TO(QWERTY),_______, _______, _______, _______ + ), + + [GIT] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, G_DIFF, G_RST, _______, G_BRCH, _______, G_FTCH, _______, G_P, _______, _______, _______, _______, _______, +_______, _______, _______, G_ADD, G_S, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +_______, _______, _______, _______, _______, G_C, _______, G_MERG, _______, G_LOG, _______, G_DEV, _______, _______, _______, _______, +_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [GIT_C] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, G_CHEC, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, G_COMM, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_BSPC, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + ), + + [GIT_S] = LAYOUT( +//--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, G_STSH, G_SHOW, G_STAT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, +XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_BSPC, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + ), + + /* ,-----------------------------------------. ,-----------------------------------------------------. + * | | | | | | | | | | | | | | | | | | + * ,-----------. |-----+-----+-----+-----+-----+-----+-----| |-----+-----+-----+-----+-----+-----+-----------+-----| + * | | | | | | | | | | | | | | | | | | | | + * |-----+-----| |-----------------------------------------' ,--------------------------------------------------+-----| + * | | | | | | | | | | | | | | | | | | | | + * |-----+-----| |---------------------------------------. `--------------------------------------------------+-----| + * | | | | | | | | | | | | | | | | | | | + * |-----+-----| |-----------------------------------------. `-------------------------------------------------+-----| + * | | | | | | | | | | | | | | | | | | | + * |-----+-----| |-----------------------------------------' ,-------------------------------------------+-----+-----| + * | | | | | | | | | | | | | | | | | + * `-----------' `---------------------------------------' `-------------------------------------------------------' + */ + // [] = LAYOUT( +// //--------------------------------Left Hand-----------------------------------------------| |--------------------------------Right Hand------------------------------------------------ + // _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, +// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + // ), +}; + +bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + + } + return true; +}
\ No newline at end of file diff --git a/keyboards/mt/split75/keymaps/art/rules.mk b/keyboards/mt/split75/keymaps/art/rules.mk new file mode 100644 index 0000000000..5f8cb68ad0 --- /dev/null +++ b/keyboards/mt/split75/keymaps/art/rules.mk @@ -0,0 +1 @@ +DYNAMIC_MACRO_ENABLE = yes
\ No newline at end of file diff --git a/keyboards/mt/split75/keymaps/default/keymap.c b/keyboards/mt/split75/keymaps/default/keymap.c new file mode 100644 index 0000000000..320aaeb5da --- /dev/null +++ b/keyboards/mt/split75/keymaps/default/keymap.c @@ -0,0 +1,32 @@ +#include QMK_KEYBOARD_H + +enum layer_names { + BASE +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* Base ,-----------------------------------------. ,-----------------------------------------------------. + * | ESC | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 |Print| Ins | Del | + * ,-----------. |-----+-----+-----+-----+-----+-----+-----| |-----+-----+-----+-----+-----+-----+-----------+-----| + * | 8 | 9 | | ~ | 1 | 2 | 3 | 4 | 5 | 6 | | 7 | 8 | 9 | 0 | - | = | Backspac | Home| + * |-----+-----| |-----------------------------------------' ,--------------------------------------------------+-----| + * | 6 | 7 | | Tab | Q | W | E | R | T | | Y | U | I | O | P | [ | ] | \ | PgUp| + * |-----+-----| |---------------------------------------. `--------------------------------------------------+-----| + * | 4 | 5 | | Caps | A | S | D | F | G | | H | J | K | L | ; | ' | Enter | PgDn| + * |-----+-----| |-----------------------------------------. `-------------------------------------------------+-----| + * | 2 | 3 | | Shift | Z | X | C | V | B | | N | M | , | . | / | Shift | Up | End | + * |-----+-----| |-----------------------------------------' ,-------------------------------------------+-----+-----| + * | 0 | 1 | | Ctrl | GUI | Alt | Space |Space| | Space | Alt | | Ctrl | Left| Down|Right| + * `-----------' `---------------------------------------' `-------------------------------------------------------' + */ + [BASE] = LAYOUT( +//--------------------------------Left Hand-----------------------------------| |--------------------------------Right Hand------------------------------------------------ + 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_INS, KC_DEL, +KC_8, KC_9, KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQUAL, KC_BSPC, KC_HOME, +KC_6, KC_7, 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_PGUP, +KC_4, KC_5, 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_ENTER, KC_PGDN, +KC_2, KC_3, 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_END, +KC_0, KC_1, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, _______,KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT + ) +}; diff --git a/keyboards/mt/split75/keymaps/iso/keymap.c b/keyboards/mt/split75/keymaps/iso/keymap.c new file mode 100644 index 0000000000..aca261b1d1 --- /dev/null +++ b/keyboards/mt/split75/keymaps/iso/keymap.c @@ -0,0 +1,48 @@ +/* Copyright 2020 Johannes Krude + * + * 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 + +enum layer_names { + BASE +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* Base ,-----------------------------------------. ,-----------------------------------------------------. + * | ESC | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 |Print| Ins | Del | + * ,-----------. |-----+-----+-----+-----+-----+-----+-----| |-----+-----+-----+-----+-----+-----+-----------+-----| + * | 8 | 9 | | ~ | 1 | 2 | 3 | 4 | 5 | 6 | | 7 | 8 | 9 | 0 | - | = | Backspac | Home| + * |-----+-----| |-----------------------------------------' ,--------------------------------------------------+-----| + * | 6 | 7 | | Tab | Q | W | E | R | T | | Y | U | I | O | P | [ | ] | | PgUp| + * |-----+-----| |---------------------------------------. `------------------------------------------+ Enter +-----| + * | 4 | 5 | | Caps | A | S | D | F | G | | H | J | K | L | ; | ' | # | | PgDn| + * |-----+-----| |-----------------------------------------. `-------------------------------------------------+-----| + * | 2 | 3 | | Shift | > | Z | X | C | V | B | | N | M | , | . | / | Shift | Up | End | + * |-----+-----| |-----------------------------------------' ,-------------------------------------------+-----+-----| + * | 0 | 1 | | Ctrl | GUI | Alt | Space |Space| | Space | Alt | APP | Ctrl | Left| Down|Right| + * `-----------' `---------------------------------------' `-------------------------------------------------------' + */ + [BASE] = LAYOUT_iso( +//--------------------------------Left Hand-----------------------------------| |--------------------------------Right Hand------------------------------------------------ + 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_INS, KC_DEL, +KC_8, KC_9, KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQUAL, KC_BSPC, KC_HOME, +KC_6, KC_7, 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_PGUP, +KC_4, KC_5, 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_NUHS, KC_ENTER, KC_PGDN, +KC_2, KC_3, KC_LSFT, KC_NUBS, 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_END, +KC_0, KC_1, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_APP ,KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT + ) +}; diff --git a/keyboards/mt/split75/matrix.c b/keyboards/mt/split75/matrix.c new file mode 100644 index 0000000000..9e86bfc376 --- /dev/null +++ b/keyboards/mt/split75/matrix.c @@ -0,0 +1,155 @@ +/* +Copyright 2017 Luiz Ribeiro <luizribeiro@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 <string.h> +#include <stdio.h> +#include "quantum.h" +#include "i2c_master.h" +#include "split75.h" + +#define RIGHT_HALF + + +void matrix_set_row_status(uint8_t row); + + +#if defined(RIGHT_HALF) +#define I2C_TIMEOUT 10 +#define MCP23018_TWI_ADDRESS 0b0100000 +#define TW_READ 1 +#define TW_WRITE 0 +#define TWI_ADDR_WRITE ( (MCP23018_TWI_ADDRESS<<1) | TW_WRITE ) +#define TWI_ADDR_READ ( (MCP23018_TWI_ADDRESS<<1) | TW_READ ) +#define IODIRA 0x00 // i/o direction register +#define IODIRB 0x01 +#define IODIRA 0x00 // i/o direction register +#define IODIRB 0x01 +#define GPPUA 0x0C // GPIO pull-up resistor register +#define GPPUB 0x0D +#define GPIOA 0x12 // general purpose i/o port register (write modifies OLAT) +#define GPIOB 0x13 +#define OLATA 0x14 // output latch register +#define OLATB 0x15 +#define MCP_ROWS_START 8 + +static uint8_t mcp23018_init(void) { + uint8_t ret; + uint8_t data[3]; + // set pin direction + // - unused : input : 1 + // - input : input : 1 + // - driving : output : 0 + data[0] = IODIRA; + data[1] = 0b00000000; // IODIRA + data[2] = (0b11111111); // IODIRB + + ret = i2c_transmit(TWI_ADDR_WRITE, (uint8_t *)data, 3, I2C_TIMEOUT); + if (ret) goto out; // make sure we got an ACK + + // set pull-up + // - unused : on : 1 + // - input : on : 1 + // - driving : off : 0 + data[0] = GPPUA; + data[1] = 0b00000000; // IODIRA + data[2] = (0b11111111); // IODIRB + + ret = i2c_transmit(TWI_ADDR_WRITE, (uint8_t *)data, 3, I2C_TIMEOUT); + if (ret) goto out; // make sure we got an ACK + + // set logical value (doesn't matter on inputs) + // - unused : hi-Z : 1 + // - input : hi-Z : 1 + // - driving : hi-Z : 1 + data[0] = OLATA; + data[1] = 0b11111111; // IODIRA + data[2] = (0b11111111); // IODIRB + + ret = i2c_transmit(TWI_ADDR_WRITE, (uint8_t *)data, 3, I2C_TIMEOUT); + +out: + return ret; +} +#endif + +void matrix_init_custom(void) { + // Set rows as output starting high + DDRB = 0xFF; + PORTB = 0xFF; + + // Set columns as inputs with pull-up enabled + DDRA = 0x00; + PORTA = 0xFF; + + // Initialize i2c communication + i2c_init(); + +#if defined(RIGHT_HALF) + // Initialize the chip on the other half + mcp23018_init(); +#endif + +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool matrix_has_changed = false; + + for (uint8_t row = 0; row < MATRIX_ROWS; row++) { + // Store last value of row prior to reading + matrix_row_t last_row_value = current_matrix[row]; + + matrix_row_t cols = 0; + // Select the row to scan + matrix_set_row_status(row); + + matrix_io_delay(); + //Set the local row + +#if defined(RIGHT_HALF) + // Initialize to 0x7F in case I2C read fails, + // as 0x75 would be no keys pressed + uint8_t data = 0x7F; + // Receive the columns from right half + i2c_receive(TWI_ADDR_WRITE, &data, 1, I2C_TIMEOUT); +#endif + + cols |= ((~(PINA | 0x80)) & 0x7F); +#if defined(RIGHT_HALF) + cols |= (((~(data | 0x80)) & 0x7F) << 7); +#endif + + current_matrix[row] = cols; + matrix_has_changed |= (last_row_value != current_matrix[row]); + } + + return matrix_has_changed; +} + +void matrix_set_row_status(uint8_t row) { +#if defined(RIGHT_HALF) + uint8_t txdata[3]; + + //Set the remote row on port A + txdata[0] = (GPIOA); + txdata[1] = ( 0xFF & ~(1<<row) ); + i2c_transmit(TWI_ADDR_WRITE, (uint8_t *)txdata, 2, I2C_TIMEOUT); +#endif + + //Set the local row on port B + DDRB = (1 << row); + PORTB = ~(1 << row); +} diff --git a/keyboards/mt/split75/readme.md b/keyboards/mt/split75/readme.md new file mode 100644 index 0000000000..360ad55239 --- /dev/null +++ b/keyboards/mt/split75/readme.md @@ -0,0 +1,28 @@ +# split75 + +![split75](https://i1.wp.com/mechboards.co.uk/wp-content/uploads/2019/10/HTB1qf0aSOLaK1RjSZFxq6ymPFXae.jpg) + +This is a port of the QMK firmware for the split75 keyboard, also known as the ve.a taobao split clone. It runs on +ps2avrGB firmware, like the [ps2avrGB keyboard](https://www.keyclack.com/product/gb-ps2avrgb/) or the ones sold +by [Winkeyless](http://winkeyless.kr/product/ps2avrgb-parts/). + +Original work performed by Michael L. Walker, all credit goes to him. I've tidied up the keymap (removed 3 extra keys), a couple of functions, info.json and this Readme. + +* Keyboard Maintainer: [Michael L. Walker](https://github.com/walkerstop) +* Hardware Availability: https://a.aliexpress.com/_BT9raf https://item.taobao.com/item.htm?id=556970472669&toSite=main + +Make example for this keyboard (after setting up your build environment): + + make mt/split75:default + +Flashing example for this keyboard ([after setting up the bootloadHID flashing environment](https://docs.qmk.fm/#/flashing_bootloadhid)) + + make mt/split75:default:flash + +or + + bootloadHID -r split75_default.hex + +**Reset Key**: Hold down the key located at 3rd left position in the bottom row, commonly programmed as Left Control while plugging in the keyboard. + +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/mt/split75/rules.mk b/keyboards/mt/split75/rules.mk new file mode 100644 index 0000000000..4aed5ab586 --- /dev/null +++ b/keyboards/mt/split75/rules.mk @@ -0,0 +1,22 @@ +# MCU name +MCU = atmega32a + +# Bootloader selection +BOOTLOADER = bootloadhid + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +WS2812_DRIVER = i2c + +# custom matrix setup +CUSTOM_MATRIX = lite +SRC = matrix.c +QUANTUM_LIB_SRC += i2c_master.c diff --git a/keyboards/mt/split75/split75.c b/keyboards/mt/split75/split75.c new file mode 100644 index 0000000000..b8a3fe6c28 --- /dev/null +++ b/keyboards/mt/split75/split75.c @@ -0,0 +1 @@ +#include "split75.h" diff --git a/keyboards/mt/split75/split75.h b/keyboards/mt/split75/split75.h new file mode 100644 index 0000000000..93da3e7b83 --- /dev/null +++ b/keyboards/mt/split75/split75.h @@ -0,0 +1,47 @@ +#pragma once + +#include "quantum.h" + +// Number of keys in rows +// 0 + 7 / 9 +// 2 + 7 / 8 +// 2 + 6 / 9 +// 2 + 6 / 8 +// 2 + 6 / 8 +// 2 + 5 / 7 + +#define LAYOUT( \ + K05, K15, K25, K35, K45, K55, K65, K75, K85, K95, K105, K115, K125, K135, K86, K87, \ + K47, K46, K04, K14, K24, K34, K44, K54, K64, K74, K84, K94, K104, K114, K124, K96, K97, \ + K37, K36, K03, K13, K23, K33, K43, K53, K73, K83, K93, K103, K113, K123, K133, K106, K107, \ + K27, K26, K02, K12, K22, K32, K42, K52, K72, K82, K92, K102, K112, K122, K116, K117, \ + K17, K16, K01, K21, K31, K41, K51, K61, K71, K81, K91, K101, K111, K131, K126, K127, \ + K07, K06, K00, K10, K20, K30, K40, K70, K100, K110, K120, K130, K136, K137 \ +){ \ + { K00, K10, K20, K30, K40, KC_NO, KC_NO, K70, KC_NO, KC_NO, K100, K110, K120, K130 }, \ + { K01, KC_NO, K21, K31, K41, K51, K61, K71, K81, K91, K101, K111, KC_NO, K131 }, \ + { K02, K12, K22, K32, K42, K52, KC_NO, K72, K82, K92, K102, K112, K122, }, \ + { K03, K13, K23, K33, K43, K53, KC_NO, K73, K83, K93, K103, K113, K123, K133 }, \ + { K04, K14, K24, K34, K44, K54, K64, K74, K84, K94, K104, K114, K124, }, \ + { K05, K15, K25, K35, K45, K55, K65, K75, K85, K95, K105, K115, K125, K135 }, \ + { K06, K16, K26, K36, K46, KC_NO, KC_NO, KC_NO, K86, K96, K106, K116, K126, K136 }, \ + { K07, K17, K27, K37, K47, KC_NO, KC_NO, KC_NO, K87, K97, K107, K117, K127, K137 } \ +} + +#define LAYOUT_iso( \ + K05, K15, K25, K35, K45, K55, K65, K75, K85, K95, K105, K115, K125, K135, K86, K87, \ + K47, K46, K04, K14, K24, K34, K44, K54, K64, K74, K84, K94, K104, K114, K124, K96, K97, \ + K37, K36, K03, K13, K23, K33, K43, K53, K73, K83, K93, K103, K113, K123, K133, K107, \ + K27, K26, K02, K12, K22, K32, K42, K52, K72, K82, K92, K102, K112, K122, K132, K116, K117, \ + K17, K16, K01, K11, K21, K31, K41, K51, K61, K71, K81, K91, K101, K111, K131, K126, K127, \ + K07, K06, K00, K10, K20, K30, K40, K70, K100, K110, K120, K130, K136, K137 \ +){ \ + { K00, K10, K20, K30, K40, KC_NO, KC_NO, K70, KC_NO, KC_NO, K100, K110, K120, K130 }, \ + { K01, K11, K21, K31, K41, K51, K61, K71, K81, K91, K101, K111, KC_NO, K131 }, \ + { K02, K12, K22, K32, K42, K52, KC_NO, K72, K82, K92, K102, K112, K122, K132 }, \ + { K03, K13, K23, K33, K43, K53, KC_NO, K73, K83, K93, K103, K113, K123, K133 }, \ + { K04, K14, K24, K34, K44, K54, K64, K74, K84, K94, K104, K114, K124, }, \ + { K05, K15, K25, K35, K45, K55, K65, K75, K85, K95, K105, K115, K125, K135 }, \ + { K06, K16, K26, K36, K46, KC_NO, KC_NO, KC_NO, K86, K96, KC_NO, K116, K126, K136 }, \ + { K07, K17, K27, K37, K47, KC_NO, KC_NO, KC_NO, K87, K97, K107, K117, K127, K137 } \ +} |