From a968d2253d7ccbb9b876eb4e5af7ab91785107f3 Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Mon, 17 Aug 2020 16:40:46 +0800 Subject: [PATCH 01/13] added SQUARE.X keyboard from the iNETT Studio --- keyboards/inett_studio/sqx/config.h | 55 +++ keyboards/inett_studio/sqx/info.json | 33 ++ .../inett_studio/sqx/keymaps/default/keymap.c | 17 + .../inett_studio/sqx/keymaps/default/rules.mk | 1 + .../inett_studio/sqx/keymaps/hotswap/config.h | 11 + .../inett_studio/sqx/keymaps/hotswap/keymap.c | 17 + .../inett_studio/sqx/keymaps/hotswap/rules.mk | 1 + .../sqx/keymaps/hotswap_via/config.h | 11 + .../sqx/keymaps/hotswap_via/keymap.c | 17 + .../sqx/keymaps/hotswap_via/rules.mk | 3 + .../inett_studio/sqx/keymaps/via/keymap.c | 17 + .../inett_studio/sqx/keymaps/via/rules.mk | 3 + keyboards/inett_studio/sqx/readme.md | 13 + keyboards/inett_studio/sqx/rules.mk | 30 ++ keyboards/inett_studio/sqx/sqx.c | 316 ++++++++++++++++++ keyboards/inett_studio/sqx/sqx.h | 114 +++++++ 16 files changed, 659 insertions(+) create mode 100644 keyboards/inett_studio/sqx/config.h create mode 100644 keyboards/inett_studio/sqx/info.json create mode 100644 keyboards/inett_studio/sqx/keymaps/default/keymap.c create mode 100644 keyboards/inett_studio/sqx/keymaps/default/rules.mk create mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap/config.h create mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap/keymap.c create mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk create mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h create mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c create mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk create mode 100644 keyboards/inett_studio/sqx/keymaps/via/keymap.c create mode 100644 keyboards/inett_studio/sqx/keymaps/via/rules.mk create mode 100644 keyboards/inett_studio/sqx/readme.md create mode 100644 keyboards/inett_studio/sqx/rules.mk create mode 100644 keyboards/inett_studio/sqx/sqx.c create mode 100644 keyboards/inett_studio/sqx/sqx.h diff --git a/keyboards/inett_studio/sqx/config.h b/keyboards/inett_studio/sqx/config.h new file mode 100644 index 000000000000..d96e8f8a5dda --- /dev/null +++ b/keyboards/inett_studio/sqx/config.h @@ -0,0 +1,55 @@ +/** + * config.h + * + */ +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x694E //'iN' +#define PRODUCT_ID 0x5336 //'S6' +#define DEVICE_VER 0x0001 +#define MANUFACTURER iNETT Studio +#define PRODUCT SQUARE.X +#define DESCRIPTION 60% keyboard from the Square series + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 14 +#define MATRIX_ROW_PINS { F0, F1, F4, B7, D6} +#define MATRIX_COL_PINS { C7, C6, B6, B5, B4, F7, F6, F5, E6, B0, D2, D4, D5, D3 } +#define UNUSED_PINS +#define DIODE_DIRECTION ROW2COL + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* + * Feature disable options + * These options are also useful to firmware size reduction. + */ + +/* disable debug print */ +//#define NO_DEBUG + +/* disable print */ +//#define NO_PRINT + + +//rgb light setting +#define RGBLIGHT_LIMIT_VAL 128 +#define RGBLED_NUM 18 +#define RGB_DI_PIN D7 +#define RGBLIGHT_ANIMATIONS +#define RGBLIGHT_HUE_STEP 8 +#define RGBLIGHT_SAT_STEP 8 +#define RGBLIGHT_VAL_STEP 8 + +//rgb matrix setting +#define DRIVER_1_LED_TOTAL 36 +#define DRIVER_2_LED_TOTAL 36 +#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_COUNT 2 +#define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/info.json b/keyboards/inett_studio/sqx/info.json new file mode 100644 index 000000000000..2970b05fb519 --- /dev/null +++ b/keyboards/inett_studio/sqx/info.json @@ -0,0 +1,33 @@ +{ + "keyboard_name": "sqx", + "url": "", + "maintainer": "qmk", + "width": 15, + "height": 5, + "layouts": { + "LAYOUT_60_wkl": { + "key_count":61, + "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.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":"Fn", "x":14, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.5}, {"label":"Win", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Win", "x":12.5, "y":4}, {"label":"Ctrl", "x":13.5, "y":4, "w":1.5}] + }, + "LAYOUT_60_ansi": { + "key_count":61, + "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.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":2.75}, {"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":"Alt", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}] + }, + "LAYOUT_60_hhkb": { + "key_count":60, + "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":"|", "x":13, "y":0}, {"label":"~", "x":14, "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":"Backspace", "x":13.5, "y":1, "w":1.5}, {"label":"Control", "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.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":"Fn", "x":14, "y":3}, {"label":"Win", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Win", "x":12.5, "y":4}] + }, + "LAYOUT_60_iso": { + "key_count":62, + "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":12, "y":0}, {"x":13, "y":0, "w":2}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.75, "y":1, "w":1.25, "h":2}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2}, {"x":0, "y":3, "w":1.25}, {"x":1.25, "y":3}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":2.75}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":1.25}, {"x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"x":10, "y":4, "w":1.25}, {"x":11.25, "y":4, "w":1.25}, {"x":12.5, "y":4, "w":1.25}, {"x":13.75, "y":4, "w":1.25}] + }, + "LAYOUT_60_ansi_split_bs_rshift": { + "key_count":63, + "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":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.5, "y":1, "w":1.5}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2, "w":2.25}, {"x":0, "y":3, "w":2.25}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":1.25}, {"x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"x":10, "y":4, "w":1.25}, {"x":11.25, "y":4, "w":1.25}, {"x":12.5, "y":4, "w":1.25}, {"x":13.75, "y":4, "w":1.25}] + }, + "LAYOUT_60_wkl_split_bs": { + "key_count":62, + "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":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.5, "y":1, "w":1.5}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2, "w":2.25}, {"x":0, "y":3, "w":2.25}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.5}, {"x":1.5, "y":4}, {"x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"x":11, "y":4, "w":1.5}, {"x":12.5, "y":4}, {"x":13.5, "y":4, "w":1.5}] + } + } + } diff --git a/keyboards/inett_studio/sqx/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/keymaps/default/keymap.c new file mode 100644 index 000000000000..48a6e2669e1b --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/default/keymap.c @@ -0,0 +1,17 @@ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_ansi_split_bs_rshift( + 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_DEL, 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, MO(1), + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT,KC_RGUI, TG(1),KC_RCTL), + + [1] = LAYOUT_60_ansi_split_bs_rshift( + _______, 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, + RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______,_______,TG(0),_______), +}; diff --git a/keyboards/inett_studio/sqx/keymaps/default/rules.mk b/keyboards/inett_studio/sqx/keymaps/default/rules.mk new file mode 100644 index 000000000000..1e3cebb14515 --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/default/rules.mk @@ -0,0 +1 @@ +RGBLIGHT_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap/config.h b/keyboards/inett_studio/sqx/keymaps/hotswap/config.h new file mode 100644 index 000000000000..c61062064b3a --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/hotswap/config.h @@ -0,0 +1,11 @@ +#pragma once + +#define SQX_HS + +#undef DRIVER_1_LED_TOTAL +#define DRIVER_1_LED_TOTAL 33 +#undef DRIVER_2_LED_TOTAL +#define DRIVER_2_LED_TOTAL 31 + +#undef DRIVER_LED_TOTAL +#define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap/keymap.c b/keyboards/inett_studio/sqx/keymaps/hotswap/keymap.c new file mode 100644 index 000000000000..4d42f99c3807 --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/hotswap/keymap.c @@ -0,0 +1,17 @@ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_wkl_split_bs_rshift( + 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_DEL, 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_END, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1),KC_RCTL), + + [1] = LAYOUT_60_wkl_split_bs_rshift( + _______, 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, + RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______,_______,_______), +}; diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk b/keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk new file mode 100644 index 000000000000..1e3cebb14515 --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk @@ -0,0 +1 @@ +RGBLIGHT_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h b/keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h new file mode 100644 index 000000000000..c61062064b3a --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h @@ -0,0 +1,11 @@ +#pragma once + +#define SQX_HS + +#undef DRIVER_1_LED_TOTAL +#define DRIVER_1_LED_TOTAL 33 +#undef DRIVER_2_LED_TOTAL +#define DRIVER_2_LED_TOTAL 31 + +#undef DRIVER_LED_TOTAL +#define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c b/keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c new file mode 100644 index 000000000000..33d4c607605d --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c @@ -0,0 +1,17 @@ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_ansi_split_bs_rshift( + 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_DEL, 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, MO(1), + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT,KC_RGUI, TG(1),KC_RCTL), + + [1] = LAYOUT_60_ansi_split_bs_rshift( + _______, 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, + RESET, RGB_TOG,RGB_MOD,_______,BL_TOGG,BL_STEP,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______,_______, TG(0),_______), +}; diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk b/keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk new file mode 100644 index 000000000000..5e60b284ccdb --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk @@ -0,0 +1,3 @@ +RGBLIGHT_ENABLE = yes +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/keymaps/via/keymap.c new file mode 100644 index 000000000000..2802cf5ea26e --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/via/keymap.c @@ -0,0 +1,17 @@ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_ansi_split_bs_rshift( + 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_DEL, 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, MO(1), + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT,KC_RGUI, TG(1),KC_RCTL), + + [1] = LAYOUT_60_ansi_split_bs_rshift( + _______, 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, + RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______,_______, TG(0),_______), +}; diff --git a/keyboards/inett_studio/sqx/keymaps/via/rules.mk b/keyboards/inett_studio/sqx/keymaps/via/rules.mk new file mode 100644 index 000000000000..5e60b284ccdb --- /dev/null +++ b/keyboards/inett_studio/sqx/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +RGBLIGHT_ENABLE = yes +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/readme.md b/keyboards/inett_studio/sqx/readme.md new file mode 100644 index 000000000000..57335286c9a2 --- /dev/null +++ b/keyboards/inett_studio/sqx/readme.md @@ -0,0 +1,13 @@ +# SQUARE.X keyboard from the iNETT Studio + +An 60% keybaord from the iNETT studio's square series + +Keyboard Maintainer: [astro](https://github.com/yulei) +Hardware Supported: SQX Keyboard +Hardware Availability: [GH GB](https://geekhack.org/index.php?topic=107062.0) + +Make example for this keyboard (after setting up your build environment): + + make inett_studio/sqx: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/inett_studio/sqx/rules.mk b/keyboards/inett_studio/sqx/rules.mk new file mode 100644 index 000000000000..c65447eea297 --- /dev/null +++ b/keyboards/inett_studio/sqx/rules.mk @@ -0,0 +1,30 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +# Teensy halfkay +# Pro Micro caterina +# Atmel DFU atmel-dfu +# LUFA DFU lufa-dfu +# QMK DFU qmk-dfu +# ATmega32A bootloadHID +# ATmega328P USBasp +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +UNICODE_ENABLE = no # Unicode +RGBLIGHT_ENABLE = no # Use RGB underglow light +RGB_MATRIX_ENABLE = yes # Use RGB per key light + +LAYOUTS = 60_ansi 60_hhkb 60_iso 60_ansi_split_bs_rshift diff --git a/keyboards/inett_studio/sqx/sqx.c b/keyboards/inett_studio/sqx/sqx.c new file mode 100644 index 000000000000..b0da380e53dd --- /dev/null +++ b/keyboards/inett_studio/sqx/sqx.c @@ -0,0 +1,316 @@ +/** + * @file sqx.c + */ + +#include "sqx.h" + +#ifdef RGB_MATRIX_ENABLE +#ifndef SQX_HS +const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { +/* Refer to IS31 manual for these locations + * driver + * | R location + * | | G location + * | | | B location + * | | | | */ +// left CA + {0, C1_1, C3_2, C4_2}, + {0, C1_2, C2_2, C4_3}, + {0, C1_3, C2_3, C3_3}, + {0, C1_4, C2_4, C3_4}, + {0, C1_5, C2_5, C3_5}, + {0, C1_6, C2_6, C3_6}, + {0, C1_7, C2_7, C3_7}, + {0, C1_8, C2_8, C3_8}, + + {0, C5_1, C4_1, C6_1}, + {0, C5_8, C4_8, C6_8}, + + {0, C9_1, C8_1, C7_1}, + {0, C9_2, C8_2, C7_2}, + {0, C9_3, C8_3, C7_3}, + {0, C9_4, C8_4, C7_4}, + {0, C9_5, C8_5, C7_5}, + {0, C9_6, C8_6, C7_6}, + {0, C9_7, C8_7, C6_6}, + {0, C9_8, C7_7, C6_7}, +// left CB + {0, C1_9, C3_10, C4_10}, + {0, C1_10, C2_10, C4_11}, + {0, C1_11, C2_11, C3_11}, + {0, C1_12, C2_12, C3_12}, + {0, C1_13, C2_13, C3_13}, + {0, C1_14, C2_14, C3_14}, + {0, C1_15, C2_15, C3_15}, + {0, C1_16, C2_16, C3_16}, + + {0, C5_9, C4_9, C6_9}, + {0, C5_16, C4_16, C6_16}, + + {0, C9_9, C8_9, C7_9}, + {0, C9_10, C8_10, C7_10}, + {0, C9_11, C8_11, C7_11}, + {0, C9_12, C8_12, C7_12}, + {0, C9_13, C8_13, C7_13}, + {0, C9_14, C8_14, C7_14}, + {0, C9_15, C8_15, C6_14}, + {0, C9_16, C7_15, C6_15}, + +// right CA + {1, C1_1, C3_2, C4_2}, + {1, C1_2, C2_2, C4_3}, + {1, C1_3, C2_3, C3_3}, + {1, C1_4, C2_4, C3_4}, + {1, C1_5, C2_5, C3_5}, + {1, C1_6, C2_6, C3_6}, + {1, C1_7, C2_7, C3_7}, + {1, C1_8, C2_8, C3_8}, + + {1, C5_1, C4_1, C6_1}, + {1, C5_8, C4_8, C6_8}, + + {1, C9_1, C8_1, C7_1}, + {1, C9_2, C8_2, C7_2}, + {1, C9_3, C8_3, C7_3}, + {1, C9_4, C8_4, C7_4}, + {1, C9_5, C8_5, C7_5}, + {1, C9_6, C8_6, C7_6}, + {1, C9_7, C8_7, C6_6}, + {1, C9_8, C7_7, C6_7}, +// right CB + {1, C1_9, C3_10, C4_10}, + {1, C1_10, C2_10, C4_11}, + {1, C1_11, C2_11, C3_11}, + {1, C1_12, C2_12, C3_12}, + {1, C1_13, C2_13, C3_13}, + {1, C1_14, C2_14, C3_14}, + {1, C1_15, C2_15, C3_15}, + {1, C1_16, C2_16, C3_16}, + + {1, C5_9, C4_9, C6_9}, + {1, C5_16, C4_16, C6_16}, + + {1, C9_9, C8_9, C7_9}, + {1, C9_10, C8_10, C7_10}, + {1, C9_11, C8_11, C7_11}, + {1, C9_12, C8_12, C7_12}, + {1, C9_13, C8_13, C7_13}, + {1, C9_14, C8_14, C7_14}, + {1, C9_15, C8_15, C6_14}, + {1, C9_16, C7_15, C6_15}, +}; + +led_config_t g_led_config = { + { + { 0, 1, 2, 3, 4, 5, 6, 36, 37, 38, 39, 40, 41, 42}, + { 8, 9, 10, 11, 12, 13, 7, 45, 46, 47, 48, 49, 50, 51}, + { 26,27, 18, 14, 15, 16, 17, 54, 55, 56, 57, 58, 59, 53}, + { 29,30, 31, 19, 20, 21, 22, 23, 62, 63, 64, 65, 66, 61}, + { 35,34, 33, NO_LED, NO_LED, NO_LED, 24, 44, NO_LED, NO_LED, 68, 69, 70, 71}, + }, + { + { 32, 32},{ 48, 48},{ 64, 48},{ 80, 48},{ 96, 48},{112, 48},{ 96, 64},{ 96, 64}, + { 0, 32},{ 16, 32}, + { 0, 48},{ 0, 48},{ 16, 48},{ 32, 48},{ 64, 64},{ 32, 64},{ 16, 64},{ 0, 64}, + { 0, 0},{ 16, 0},{ 32, 0},{ 48, 0},{ 64, 0},{ 80, 0},{ 96, 0},{ 96, 16}, + { 0, 16},{ 16, 16}, + { 32, 16},{ 48, 16},{ 64, 16},{ 80, 16},{ 48, 32},{ 64, 32},{ 80, 32},{ 96, 32}, + + {128, 0},{144, 0},{160, 0},{176, 0},{192, 0},{208, 0},{216, 0},{224, 0}, + {112, 0},{128, 16}, + {144, 16},{160, 16},{176, 16},{192, 16},{208, 16},{224, 16},{224, 32},{216, 32}, + {128, 32},{144, 32},{160, 32},{176, 32},{192, 32},{208, 32},{208, 48},{224, 48}, + {128, 48},{144, 48}, + {160, 48},{176, 48},{192, 48},{142, 64},{160, 64},{176, 64},{208, 64},{224, 64} + }, + { + 4, 4, 4, 4, 4, 4, 4, 4, + 1, 4, + 4, 4, 1, 1, 1, 4, 4, 4, + + 1, 4, 4, 4, 4, 4, 4, 4, + 1, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + + 4, 4, 4, 4, 4, 4, 1, 1, + 4, 4, + 4, 4, 4, 4, 4, 1, 1, 1, + + 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, + 4, 4, 4, 4, 1, 1, 1, 1, + } +}; +#else +const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { +/* Refer to IS31 manual for these locations + * driver + * | R location + * | | G location + * | | | B location + * | | | | */ +// left CA + {0, C1_1, C3_2, C4_2}, + {0, C1_2, C2_2, C4_3}, + {0, C1_3, C2_3, C3_3}, + {0, C1_4, C2_4, C3_4}, + {0, C1_5, C2_5, C3_5}, + {0, C1_6, C2_6, C3_6}, + {0, C1_7, C2_7, C3_7}, + {0, C1_8, C2_8, C3_8}, + + {0, C5_1, C4_1, C6_1}, + {0, C5_8, C4_8, C6_8}, + + {0, C9_1, C8_1, C7_1}, + {0, C9_2, C8_2, C7_2}, + {0, C9_3, C8_3, C7_3}, + {0, C9_4, C8_4, C7_4}, + {0, C9_5, C8_5, C7_5}, + {0, C9_6, C8_6, C7_6}, + {0, C9_7, C8_7, C6_6}, + {0, C9_8, C7_7, C6_7}, +// left CB + {0, C1_9, C3_10, C4_10}, + {0, C1_10, C2_10, C4_11}, + {0, C1_11, C2_11, C3_11}, + {0, C1_12, C2_12, C3_12}, + {0, C1_13, C2_13, C3_13}, + {0, C1_14, C2_14, C3_14}, + {0, C1_15, C2_15, C3_15}, + {0, C1_16, C2_16, C3_16}, + + //{0, C5_9, C4_9, C6_9}, + //{0, C5_16, C4_16, C6_16}, + + {0, C9_9, C8_9, C7_9}, + {0, C9_10, C8_10, C7_10}, + //{0, C9_11, C8_11, C7_11}, + {0, C9_12, C8_12, C7_12}, + {0, C9_13, C8_13, C7_13}, + {0, C9_14, C8_14, C7_14}, + {0, C9_15, C8_15, C6_14}, + {0, C9_16, C7_15, C6_15}, + +// right CA + {1, C1_1, C3_2, C4_2}, + {1, C1_2, C2_2, C4_3}, + {1, C1_3, C2_3, C3_3}, + {1, C1_4, C2_4, C3_4}, + {1, C1_5, C2_5, C3_5}, + {1, C1_6, C2_6, C3_6}, + {1, C1_7, C2_7, C3_7}, + {1, C1_8, C2_8, C3_8}, + + //{1, C5_1, C4_1, C6_1}, + //{1, C5_8, C4_8, C6_8}, + + {1, C9_1, C8_1, C7_1}, + {1, C9_2, C8_2, C7_2}, + {1, C9_3, C8_3, C7_3}, + {1, C9_4, C8_4, C7_4}, + {1, C9_5, C8_5, C7_5}, + {1, C9_6, C8_6, C7_6}, + {1, C9_7, C8_7, C6_6}, + {1, C9_8, C7_7, C6_7}, +// right CB + {1, C1_9, C3_10, C4_10}, + {1, C1_10, C2_10, C4_11}, + {1, C1_11, C2_11, C3_11}, + {1, C1_12, C2_12, C3_12}, + {1, C1_13, C2_13, C3_13}, + //{1, C1_14, C2_14, C3_14}, + {1, C1_15, C2_15, C3_15}, + {1, C1_16, C2_16, C3_16}, + + //{1, C5_9, C4_9, C6_9}, + //{1, C5_16, C4_16, C6_16}, + + {1, C9_9, C8_9, C7_9}, + {1, C9_10, C8_10, C7_10}, + {1, C9_11, C8_11, C7_11}, + {1, C9_12, C8_12, C7_12}, + {1, C9_13, C8_13, C7_13}, + {1, C9_14, C8_14, C7_14}, + {1, C9_15, C8_15, C6_14}, + {1, C9_16, C7_15, C6_15}, +}; + +led_config_t g_led_config = { + { + { 0, 1, 2, 3, 4, 5, 6, 34, 35, 36, 37, 38, 39, 40}, + { 8, 9, 10, 11, 12, 13, 7, 48, 41, 42, 43, 44, 45, 46}, + { 26, 25, 18, 14, 15, 16, 17, 49, 50, 51, 52, 53, NO_LED, 47}, + { 27, NO_LED, 28, 19, 20, 21, 22, 23, 56, 55, 57, 58, 59, 54}, + { 32, 31, 30, 29, NO_LED, NO_LED, 24, 33, NO_LED, NO_LED, 60, 61, 62, 63}, + }, + { + { 0, 0},{ 16, 0},{ 32, 0},{ 48, 0},{ 64, 0},{ 80, 0},{ 96, 0},{ 96, 16}, + { 0, 16},{ 16, 16}, + { 32, 16},{ 48, 16},{ 64, 16},{ 80, 16},{ 64, 32},{ 80, 32},{ 96, 32},{112, 32}, + + { 48, 32},{ 48, 48},{ 64, 48},{ 80, 48},{ 96, 48},{112, 48},{112, 64},{ 32, 32}, + { 16, 32},{ 16, 48}, { 32, 48},{ 64, 64},{ 40, 64},{ 20, 64},{ 0, 64}, + + {112, 0},{128, 0},{144, 0},{160, 0},{176, 0},{192, 0},{208, 0},{224, 0}, + {128, 16},{144, 16},{160, 16},{176, 16},{192, 16},{216, 16},{216, 32},{112, 16}, + + {128, 32},{144, 32},{160, 32},{176, 32},{192, 32}, {224, 48},{144, 48}, + {128, 48},{160, 48},{176, 48},{192, 48},{160, 64},{180, 64},{200, 64},{224, 64} + }, + { + 1, 4, 4, 4, 4, 4, 4, 4, + 1, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + + 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 4, 1, 1, 1, 1, + + 4, 4, 4, 4, 4, 4, 1, 1, + 4, 4, 4, 4, 4, 1, 1, 4, + + 4, 4, 4, 4, 4, 1, 4, + 4, 4, 4, 1, 1, 1, 1, 1, + } +}; +#endif + +#endif //RGB_MATRIX_ENABLE + +bool process_record_kb(uint16_t keycode, keyrecord_t *record) { + if (record->event.pressed) { + switch(keycode) { + #ifdef RGBLIGHT_ENABLE + #ifdef RGB_MATRIX_ENABLE + case KC_F16: // toggle rgb matrix + rgb_matrix_toggle(); + return false; + case KC_F17: + rgb_matrix_step(); + return false; + case KC_F18: + rgb_matrix_increase_hue(); + return false; + case KC_F20: + rgb_matrix_decrease_hue(); + return false; + case KC_F21: + rgb_matrix_increase_sat(); + return false; + case KC_F22: + rgb_matrix_decrease_sat(); + return false; + case KC_F23: + rgb_matrix_increase_val(); + return false; + case KC_F24: + rgb_matrix_decrease_val(); + return false; + #endif + #endif + default: + break; + } + } + return true; +} diff --git a/keyboards/inett_studio/sqx/sqx.h b/keyboards/inett_studio/sqx/sqx.h new file mode 100644 index 000000000000..acbc1840a580 --- /dev/null +++ b/keyboards/inett_studio/sqx/sqx.h @@ -0,0 +1,114 @@ +/** + * @file sqx.h + * + */ +#pragma once + +#include "quantum.h" + +// This a shortcut to help you visually see your layout. +// The first section contains all of the arguements +// The second converts the arguments into a two-dimensional array +#define LAYOUT_60_ansi( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, \ + k40, k42, k43, k47, k48, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, KC_NO, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, KC_NO}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, k48, k49, k4a, k4b} \ +} + +#define LAYOUT_60_iso( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, \ + k20, 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,\ + k40, k42, k43, k47, k48, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, KC_NO, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, KC_NO}, \ + {k20, 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}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, k48, k49, k4a, k4b} \ +} + +#define LAYOUT_60_wkl( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, KC_NO, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ +} + +#define LAYOUT_60_hhkb( \ + 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, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k42, k43, k47, k49, k4a \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ + {KC_NO, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, KC_NO} \ +} +#define LAYOUT_60_wkl_split_bs( \ + 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, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ +} + +#define LAYOUT_60_ansi_split_bs_rshift( \ + 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, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k48, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, k48, k49, k4a, k4b} \ +} + +#define LAYOUT_60_wkl_split_bs_rshift( \ + 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, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ +} From b98865130e26117609be08ebc71cf9625b4b8ccf Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Wed, 19 Aug 2020 12:10:04 +0800 Subject: [PATCH 02/13] split to two sub directories --- keyboards/inett_studio/sqx/hotswap/config.h | 55 ++++++ keyboards/inett_studio/sqx/hotswap/hotswap.c | 178 ++++++++++++++++++ keyboards/inett_studio/sqx/hotswap/hotswap.h | 25 +++ keyboards/inett_studio/sqx/hotswap/info.json | 13 ++ .../keymaps/default}/keymap.c | 0 .../sqx/hotswap/keymaps/via/keymap.c | 31 +++ .../sqx/hotswap/keymaps/via/rules.mk | 1 + .../inett_studio/sqx/{ => hotswap}/readme.md | 2 +- keyboards/inett_studio/sqx/hotswap/rules.mk | 29 +++ .../inett_studio/sqx/keymaps/default/rules.mk | 1 - .../inett_studio/sqx/keymaps/hotswap/config.h | 11 -- .../inett_studio/sqx/keymaps/hotswap/rules.mk | 1 - .../sqx/keymaps/hotswap_via/config.h | 11 -- .../sqx/keymaps/hotswap_via/keymap.c | 17 -- .../sqx/keymaps/hotswap_via/rules.mk | 3 - .../inett_studio/sqx/keymaps/via/rules.mk | 3 - .../inett_studio/sqx/{ => universal}/config.h | 0 .../sqx/{ => universal}/info.json | 0 .../{ => universal}/keymaps/default/keymap.c | 0 .../sqx/{ => universal}/keymaps/via/keymap.c | 14 ++ .../sqx/universal/keymaps/via/rules.mk | 1 + .../inett_studio/sqx/universal/readme.md | 13 ++ .../inett_studio/sqx/{ => universal}/rules.mk | 4 +- .../sqx/{sqx.c => universal/universal.c} | 139 +------------- .../sqx/{sqx.h => universal/universal.h} | 2 +- 25 files changed, 366 insertions(+), 188 deletions(-) create mode 100644 keyboards/inett_studio/sqx/hotswap/config.h create mode 100644 keyboards/inett_studio/sqx/hotswap/hotswap.c create mode 100644 keyboards/inett_studio/sqx/hotswap/hotswap.h create mode 100644 keyboards/inett_studio/sqx/hotswap/info.json rename keyboards/inett_studio/sqx/{keymaps/hotswap => hotswap/keymaps/default}/keymap.c (100%) create mode 100644 keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c create mode 100644 keyboards/inett_studio/sqx/hotswap/keymaps/via/rules.mk rename keyboards/inett_studio/sqx/{ => hotswap}/readme.md (93%) create mode 100644 keyboards/inett_studio/sqx/hotswap/rules.mk delete mode 100644 keyboards/inett_studio/sqx/keymaps/default/rules.mk delete mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap/config.h delete mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk delete mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h delete mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c delete mode 100644 keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk delete mode 100644 keyboards/inett_studio/sqx/keymaps/via/rules.mk rename keyboards/inett_studio/sqx/{ => universal}/config.h (100%) rename keyboards/inett_studio/sqx/{ => universal}/info.json (100%) rename keyboards/inett_studio/sqx/{ => universal}/keymaps/default/keymap.c (100%) rename keyboards/inett_studio/sqx/{ => universal}/keymaps/via/keymap.c (51%) create mode 100644 keyboards/inett_studio/sqx/universal/keymaps/via/rules.mk create mode 100644 keyboards/inett_studio/sqx/universal/readme.md rename keyboards/inett_studio/sqx/{ => universal}/rules.mk (89%) rename keyboards/inett_studio/sqx/{sqx.c => universal/universal.c} (56%) rename keyboards/inett_studio/sqx/{sqx.h => universal/universal.h} (99%) diff --git a/keyboards/inett_studio/sqx/hotswap/config.h b/keyboards/inett_studio/sqx/hotswap/config.h new file mode 100644 index 000000000000..008a9091561e --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/config.h @@ -0,0 +1,55 @@ +/** + * config.h + * + */ +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x694E //'iN' +#define PRODUCT_ID 0x5336 //'S6' +#define DEVICE_VER 0x0001 +#define MANUFACTURER iNETT Studio +#define PRODUCT SQUARE.X +#define DESCRIPTION 60% keyboard from the Square series + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 14 +#define MATRIX_ROW_PINS { F0, F1, F4, B7, D6} +#define MATRIX_COL_PINS { C7, C6, B6, B5, B4, F7, F6, F5, E6, B0, D2, D4, D5, D3 } +#define UNUSED_PINS +#define DIODE_DIRECTION ROW2COL + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* + * Feature disable options + * These options are also useful to firmware size reduction. + */ + +/* disable debug print */ +//#define NO_DEBUG + +/* disable print */ +//#define NO_PRINT + + +//rgb light setting +#define RGBLIGHT_LIMIT_VAL 128 +#define RGBLED_NUM 18 +#define RGB_DI_PIN D7 +#define RGBLIGHT_ANIMATIONS +#define RGBLIGHT_HUE_STEP 8 +#define RGBLIGHT_SAT_STEP 8 +#define RGBLIGHT_VAL_STEP 8 + +//rgb matrix setting +#define DRIVER_1_LED_TOTAL 33 +#define DRIVER_2_LED_TOTAL 31 +#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_COUNT 2 +#define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c new file mode 100644 index 000000000000..6439dc3ec2fb --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -0,0 +1,178 @@ +/** + * @file hotswap.c + */ + +#include "hotswap.h" + +#ifdef RGB_MATRIX_ENABLE +const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { +/* Refer to IS31 manual for these locations + * driver + * | R location + * | | G location + * | | | B location + * | | | | */ +// left CA + {0, C1_1, C3_2, C4_2}, + {0, C1_2, C2_2, C4_3}, + {0, C1_3, C2_3, C3_3}, + {0, C1_4, C2_4, C3_4}, + {0, C1_5, C2_5, C3_5}, + {0, C1_6, C2_6, C3_6}, + {0, C1_7, C2_7, C3_7}, + {0, C1_8, C2_8, C3_8}, + + {0, C5_1, C4_1, C6_1}, + {0, C5_8, C4_8, C6_8}, + + {0, C9_1, C8_1, C7_1}, + {0, C9_2, C8_2, C7_2}, + {0, C9_3, C8_3, C7_3}, + {0, C9_4, C8_4, C7_4}, + {0, C9_5, C8_5, C7_5}, + {0, C9_6, C8_6, C7_6}, + {0, C9_7, C8_7, C6_6}, + {0, C9_8, C7_7, C6_7}, +// left CB + {0, C1_9, C3_10, C4_10}, + {0, C1_10, C2_10, C4_11}, + {0, C1_11, C2_11, C3_11}, + {0, C1_12, C2_12, C3_12}, + {0, C1_13, C2_13, C3_13}, + {0, C1_14, C2_14, C3_14}, + {0, C1_15, C2_15, C3_15}, + {0, C1_16, C2_16, C3_16}, + + //{0, C5_9, C4_9, C6_9}, + //{0, C5_16, C4_16, C6_16}, + + {0, C9_9, C8_9, C7_9}, + {0, C9_10, C8_10, C7_10}, + //{0, C9_11, C8_11, C7_11}, + {0, C9_12, C8_12, C7_12}, + {0, C9_13, C8_13, C7_13}, + {0, C9_14, C8_14, C7_14}, + {0, C9_15, C8_15, C6_14}, + {0, C9_16, C7_15, C6_15}, + +// right CA + {1, C1_1, C3_2, C4_2}, + {1, C1_2, C2_2, C4_3}, + {1, C1_3, C2_3, C3_3}, + {1, C1_4, C2_4, C3_4}, + {1, C1_5, C2_5, C3_5}, + {1, C1_6, C2_6, C3_6}, + {1, C1_7, C2_7, C3_7}, + {1, C1_8, C2_8, C3_8}, + + //{1, C5_1, C4_1, C6_1}, + //{1, C5_8, C4_8, C6_8}, + + {1, C9_1, C8_1, C7_1}, + {1, C9_2, C8_2, C7_2}, + {1, C9_3, C8_3, C7_3}, + {1, C9_4, C8_4, C7_4}, + {1, C9_5, C8_5, C7_5}, + {1, C9_6, C8_6, C7_6}, + {1, C9_7, C8_7, C6_6}, + {1, C9_8, C7_7, C6_7}, +// right CB + {1, C1_9, C3_10, C4_10}, + {1, C1_10, C2_10, C4_11}, + {1, C1_11, C2_11, C3_11}, + {1, C1_12, C2_12, C3_12}, + {1, C1_13, C2_13, C3_13}, + //{1, C1_14, C2_14, C3_14}, + {1, C1_15, C2_15, C3_15}, + {1, C1_16, C2_16, C3_16}, + + //{1, C5_9, C4_9, C6_9}, + //{1, C5_16, C4_16, C6_16}, + + {1, C9_9, C8_9, C7_9}, + {1, C9_10, C8_10, C7_10}, + {1, C9_11, C8_11, C7_11}, + {1, C9_12, C8_12, C7_12}, + {1, C9_13, C8_13, C7_13}, + {1, C9_14, C8_14, C7_14}, + {1, C9_15, C8_15, C6_14}, + {1, C9_16, C7_15, C6_15}, +}; + +led_config_t g_led_config = { + { + { 0, 1, 2, 3, 4, 5, 6, 34, 35, 36, 37, 38, 39, 40}, + { 8, 9, 10, 11, 12, 13, 7, 48, 41, 42, 43, 44, 45, 46}, + { 26, 25, 18, 14, 15, 16, 17, 49, 50, 51, 52, 53, NO_LED, 47}, + { 27, NO_LED, 28, 19, 20, 21, 22, 23, 56, 55, 57, 58, 59, 54}, + { 32, 31, 30, 29, NO_LED, NO_LED, 24, 33, NO_LED, NO_LED, 60, 61, 62, 63}, + }, + { + { 0, 0},{ 16, 0},{ 32, 0},{ 48, 0},{ 64, 0},{ 80, 0},{ 96, 0},{ 96, 16}, + { 0, 16},{ 16, 16}, + { 32, 16},{ 48, 16},{ 64, 16},{ 80, 16},{ 64, 32},{ 80, 32},{ 96, 32},{112, 32}, + + { 48, 32},{ 48, 48},{ 64, 48},{ 80, 48},{ 96, 48},{112, 48},{112, 64},{ 32, 32}, + { 16, 32},{ 16, 48}, { 32, 48},{ 64, 64},{ 40, 64},{ 20, 64},{ 0, 64}, + + {112, 0},{128, 0},{144, 0},{160, 0},{176, 0},{192, 0},{208, 0},{224, 0}, + {128, 16},{144, 16},{160, 16},{176, 16},{192, 16},{216, 16},{216, 32},{112, 16}, + + {128, 32},{144, 32},{160, 32},{176, 32},{192, 32}, {224, 48},{144, 48}, + {128, 48},{160, 48},{176, 48},{192, 48},{160, 64},{180, 64},{200, 64},{224, 64} + }, + { + 1, 4, 4, 4, 4, 4, 4, 4, + 1, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + + 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 4, 1, 1, 1, 1, + + 4, 4, 4, 4, 4, 4, 1, 1, + 4, 4, 4, 4, 4, 1, 1, 4, + + 4, 4, 4, 4, 4, 1, 4, + 4, 4, 4, 1, 1, 1, 1, 1, + } +}; + +#endif //RGB_MATRIX_ENABLE + +bool process_record_kb(uint16_t keycode, keyrecord_t *record) { + if (record->event.pressed) { + switch(keycode) { + #ifdef RGBLIGHT_ENABLE + #ifdef RGB_MATRIX_ENABLE + case KC_F16: // toggle rgb matrix + rgb_matrix_toggle(); + return false; + case KC_F17: + rgb_matrix_step(); + return false; + case KC_F18: + rgb_matrix_increase_hue(); + return false; + case KC_F20: + rgb_matrix_decrease_hue(); + return false; + case KC_F21: + rgb_matrix_increase_sat(); + return false; + case KC_F22: + rgb_matrix_decrease_sat(); + return false; + case KC_F23: + rgb_matrix_increase_val(); + return false; + case KC_F24: + rgb_matrix_decrease_val(); + return false; + #endif + #endif + default: + break; + } + } + return true; +} diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h new file mode 100644 index 000000000000..d044a141af9d --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -0,0 +1,25 @@ +/** + * @file hotswap.h + * + */ +#pragma once + +#include "quantum.h" + +// This a shortcut to help you visually see your layout. +// The first section contains all of the arguements +// The second converts the arguments into a two-dimensional array +#define LAYOUT_60_wkl_split_bs_rshift( \ + 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, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ + {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ + {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ + {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ +} diff --git a/keyboards/inett_studio/sqx/hotswap/info.json b/keyboards/inett_studio/sqx/hotswap/info.json new file mode 100644 index 000000000000..1d6e9b462bbf --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/info.json @@ -0,0 +1,13 @@ +{ + "keyboard_name": "sqx", + "url": "", + "maintainer": "qmk", + "width": 15, + "height": 5, + "layouts": { + "LAYOUT_60_wkl_split_bs_rshift": { + "key_count":62, + "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":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.5, "y":1, "w":1.5}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2, "w":2.25}, {"x":0, "y":3, "w":2.25}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.5}, {"x":1.5, "y":4}, {"x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"x":11, "y":4, "w":1.5}, {"x":12.5, "y":4}, {"x":13.5, "y":4, "w":1.5}] + } + } + } diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c similarity index 100% rename from keyboards/inett_studio/sqx/keymaps/hotswap/keymap.c rename to keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c new file mode 100644 index 000000000000..852112afbb47 --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c @@ -0,0 +1,31 @@ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_wkl_split_bs_rshift( + 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_DEL, 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, MO(1), + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, TG(1),KC_RCTL), + + [1] = LAYOUT_60_wkl_split_bs_rshift( + _______, 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, + RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______, TG(0),_______), + + [2] = LAYOUT_60_wkl_split_bs_rshift( + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______, TG(0),_______), + + [3] = LAYOUT_60_wkl_split_bs_rshift( + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______, TG(0),_______), +}; diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/via/rules.mk b/keyboards/inett_studio/sqx/hotswap/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/readme.md b/keyboards/inett_studio/sqx/hotswap/readme.md similarity index 93% rename from keyboards/inett_studio/sqx/readme.md rename to keyboards/inett_studio/sqx/hotswap/readme.md index 57335286c9a2..34c858ac9b72 100644 --- a/keyboards/inett_studio/sqx/readme.md +++ b/keyboards/inett_studio/sqx/hotswap/readme.md @@ -8,6 +8,6 @@ Hardware Availability: [GH GB](https://geekhack.org/index.php?topic=107062.0) Make example for this keyboard (after setting up your build environment): - make inett_studio/sqx:default + make inett_studio/sqx/hotswap: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/inett_studio/sqx/hotswap/rules.mk b/keyboards/inett_studio/sqx/hotswap/rules.mk new file mode 100644 index 000000000000..6784d6d2cc96 --- /dev/null +++ b/keyboards/inett_studio/sqx/hotswap/rules.mk @@ -0,0 +1,29 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +# Teensy halfkay +# Pro Micro caterina +# Atmel DFU atmel-dfu +# LUFA DFU lufa-dfu +# QMK DFU qmk-dfu +# ATmega32A bootloadHID +# ATmega328P USBasp +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +UNICODE_ENABLE = no # Unicode +RGBLIGHT_ENABLE = yes # Use RGB underglow light +RGB_MATRIX_ENABLE = yes # Use RGB per key light +LTO_ENABLE = yes # Reducing firmware size diff --git a/keyboards/inett_studio/sqx/keymaps/default/rules.mk b/keyboards/inett_studio/sqx/keymaps/default/rules.mk deleted file mode 100644 index 1e3cebb14515..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/default/rules.mk +++ /dev/null @@ -1 +0,0 @@ -RGBLIGHT_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap/config.h b/keyboards/inett_studio/sqx/keymaps/hotswap/config.h deleted file mode 100644 index c61062064b3a..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/hotswap/config.h +++ /dev/null @@ -1,11 +0,0 @@ -#pragma once - -#define SQX_HS - -#undef DRIVER_1_LED_TOTAL -#define DRIVER_1_LED_TOTAL 33 -#undef DRIVER_2_LED_TOTAL -#define DRIVER_2_LED_TOTAL 31 - -#undef DRIVER_LED_TOTAL -#define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk b/keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk deleted file mode 100644 index 1e3cebb14515..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/hotswap/rules.mk +++ /dev/null @@ -1 +0,0 @@ -RGBLIGHT_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h b/keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h deleted file mode 100644 index c61062064b3a..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/hotswap_via/config.h +++ /dev/null @@ -1,11 +0,0 @@ -#pragma once - -#define SQX_HS - -#undef DRIVER_1_LED_TOTAL -#define DRIVER_1_LED_TOTAL 33 -#undef DRIVER_2_LED_TOTAL -#define DRIVER_2_LED_TOTAL 31 - -#undef DRIVER_LED_TOTAL -#define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c b/keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c deleted file mode 100644 index 33d4c607605d..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/hotswap_via/keymap.c +++ /dev/null @@ -1,17 +0,0 @@ -#include QMK_KEYBOARD_H - -const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [0] = LAYOUT_60_ansi_split_bs_rshift( - 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_DEL, 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, MO(1), - KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT,KC_RGUI, TG(1),KC_RCTL), - - [1] = LAYOUT_60_ansi_split_bs_rshift( - _______, 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, - RESET, RGB_TOG,RGB_MOD,_______,BL_TOGG,BL_STEP,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, - _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, - _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, - _______,_______,_______, _______, _______,_______, TG(0),_______), -}; diff --git a/keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk b/keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk deleted file mode 100644 index 5e60b284ccdb..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/hotswap_via/rules.mk +++ /dev/null @@ -1,3 +0,0 @@ -RGBLIGHT_ENABLE = yes -VIA_ENABLE = yes -LTO_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/keymaps/via/rules.mk b/keyboards/inett_studio/sqx/keymaps/via/rules.mk deleted file mode 100644 index 5e60b284ccdb..000000000000 --- a/keyboards/inett_studio/sqx/keymaps/via/rules.mk +++ /dev/null @@ -1,3 +0,0 @@ -RGBLIGHT_ENABLE = yes -VIA_ENABLE = yes -LTO_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/config.h b/keyboards/inett_studio/sqx/universal/config.h similarity index 100% rename from keyboards/inett_studio/sqx/config.h rename to keyboards/inett_studio/sqx/universal/config.h diff --git a/keyboards/inett_studio/sqx/info.json b/keyboards/inett_studio/sqx/universal/info.json similarity index 100% rename from keyboards/inett_studio/sqx/info.json rename to keyboards/inett_studio/sqx/universal/info.json diff --git a/keyboards/inett_studio/sqx/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c similarity index 100% rename from keyboards/inett_studio/sqx/keymaps/default/keymap.c rename to keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c diff --git a/keyboards/inett_studio/sqx/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c similarity index 51% rename from keyboards/inett_studio/sqx/keymaps/via/keymap.c rename to keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c index 2802cf5ea26e..26d63626d918 100644 --- a/keyboards/inett_studio/sqx/keymaps/via/keymap.c +++ b/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c @@ -14,4 +14,18 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______,_______, TG(0),_______), + + [2] = LAYOUT_60_ansi_split_bs_rshift( + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______,_______, TG(0),_______), + + [3] = LAYOUT_60_ansi_split_bs_rshift( + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, + _______,_______,_______, _______, _______,_______, TG(0),_______), }; diff --git a/keyboards/inett_studio/sqx/universal/keymaps/via/rules.mk b/keyboards/inett_studio/sqx/universal/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/inett_studio/sqx/universal/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/inett_studio/sqx/universal/readme.md b/keyboards/inett_studio/sqx/universal/readme.md new file mode 100644 index 000000000000..37fc31310e25 --- /dev/null +++ b/keyboards/inett_studio/sqx/universal/readme.md @@ -0,0 +1,13 @@ +# SQUARE.X keyboard from the iNETT Studio + +An 60% keybaord from the iNETT studio's square series + +Keyboard Maintainer: [astro](https://github.com/yulei) +Hardware Supported: SQX Keyboard +Hardware Availability: [GH GB](https://geekhack.org/index.php?topic=107062.0) + +Make example for this keyboard (after setting up your build environment): + + make inett_studio/sqx/universal: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/inett_studio/sqx/rules.mk b/keyboards/inett_studio/sqx/universal/rules.mk similarity index 89% rename from keyboards/inett_studio/sqx/rules.mk rename to keyboards/inett_studio/sqx/universal/rules.mk index c65447eea297..3a7771e2d2de 100644 --- a/keyboards/inett_studio/sqx/rules.mk +++ b/keyboards/inett_studio/sqx/universal/rules.mk @@ -24,7 +24,7 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work NKRO_ENABLE = yes # USB Nkey Rollover UNICODE_ENABLE = no # Unicode -RGBLIGHT_ENABLE = no # Use RGB underglow light +RGBLIGHT_ENABLE = yes # Use RGB underglow light RGB_MATRIX_ENABLE = yes # Use RGB per key light -LAYOUTS = 60_ansi 60_hhkb 60_iso 60_ansi_split_bs_rshift +LTO_ENABLE = yes # Reducing firmware size diff --git a/keyboards/inett_studio/sqx/sqx.c b/keyboards/inett_studio/sqx/universal/universal.c similarity index 56% rename from keyboards/inett_studio/sqx/sqx.c rename to keyboards/inett_studio/sqx/universal/universal.c index b0da380e53dd..5cf9aae4c2f4 100644 --- a/keyboards/inett_studio/sqx/sqx.c +++ b/keyboards/inett_studio/sqx/universal/universal.c @@ -1,11 +1,10 @@ /** - * @file sqx.c + * @file universal.c */ -#include "sqx.h" +#include "universal.h" #ifdef RGB_MATRIX_ENABLE -#ifndef SQX_HS const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { /* Refer to IS31 manual for these locations * driver @@ -141,140 +140,6 @@ led_config_t g_led_config = { 4, 4, 4, 4, 1, 1, 1, 1, } }; -#else -const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { -/* Refer to IS31 manual for these locations - * driver - * | R location - * | | G location - * | | | B location - * | | | | */ -// left CA - {0, C1_1, C3_2, C4_2}, - {0, C1_2, C2_2, C4_3}, - {0, C1_3, C2_3, C3_3}, - {0, C1_4, C2_4, C3_4}, - {0, C1_5, C2_5, C3_5}, - {0, C1_6, C2_6, C3_6}, - {0, C1_7, C2_7, C3_7}, - {0, C1_8, C2_8, C3_8}, - - {0, C5_1, C4_1, C6_1}, - {0, C5_8, C4_8, C6_8}, - - {0, C9_1, C8_1, C7_1}, - {0, C9_2, C8_2, C7_2}, - {0, C9_3, C8_3, C7_3}, - {0, C9_4, C8_4, C7_4}, - {0, C9_5, C8_5, C7_5}, - {0, C9_6, C8_6, C7_6}, - {0, C9_7, C8_7, C6_6}, - {0, C9_8, C7_7, C6_7}, -// left CB - {0, C1_9, C3_10, C4_10}, - {0, C1_10, C2_10, C4_11}, - {0, C1_11, C2_11, C3_11}, - {0, C1_12, C2_12, C3_12}, - {0, C1_13, C2_13, C3_13}, - {0, C1_14, C2_14, C3_14}, - {0, C1_15, C2_15, C3_15}, - {0, C1_16, C2_16, C3_16}, - - //{0, C5_9, C4_9, C6_9}, - //{0, C5_16, C4_16, C6_16}, - - {0, C9_9, C8_9, C7_9}, - {0, C9_10, C8_10, C7_10}, - //{0, C9_11, C8_11, C7_11}, - {0, C9_12, C8_12, C7_12}, - {0, C9_13, C8_13, C7_13}, - {0, C9_14, C8_14, C7_14}, - {0, C9_15, C8_15, C6_14}, - {0, C9_16, C7_15, C6_15}, - -// right CA - {1, C1_1, C3_2, C4_2}, - {1, C1_2, C2_2, C4_3}, - {1, C1_3, C2_3, C3_3}, - {1, C1_4, C2_4, C3_4}, - {1, C1_5, C2_5, C3_5}, - {1, C1_6, C2_6, C3_6}, - {1, C1_7, C2_7, C3_7}, - {1, C1_8, C2_8, C3_8}, - - //{1, C5_1, C4_1, C6_1}, - //{1, C5_8, C4_8, C6_8}, - - {1, C9_1, C8_1, C7_1}, - {1, C9_2, C8_2, C7_2}, - {1, C9_3, C8_3, C7_3}, - {1, C9_4, C8_4, C7_4}, - {1, C9_5, C8_5, C7_5}, - {1, C9_6, C8_6, C7_6}, - {1, C9_7, C8_7, C6_6}, - {1, C9_8, C7_7, C6_7}, -// right CB - {1, C1_9, C3_10, C4_10}, - {1, C1_10, C2_10, C4_11}, - {1, C1_11, C2_11, C3_11}, - {1, C1_12, C2_12, C3_12}, - {1, C1_13, C2_13, C3_13}, - //{1, C1_14, C2_14, C3_14}, - {1, C1_15, C2_15, C3_15}, - {1, C1_16, C2_16, C3_16}, - - //{1, C5_9, C4_9, C6_9}, - //{1, C5_16, C4_16, C6_16}, - - {1, C9_9, C8_9, C7_9}, - {1, C9_10, C8_10, C7_10}, - {1, C9_11, C8_11, C7_11}, - {1, C9_12, C8_12, C7_12}, - {1, C9_13, C8_13, C7_13}, - {1, C9_14, C8_14, C7_14}, - {1, C9_15, C8_15, C6_14}, - {1, C9_16, C7_15, C6_15}, -}; - -led_config_t g_led_config = { - { - { 0, 1, 2, 3, 4, 5, 6, 34, 35, 36, 37, 38, 39, 40}, - { 8, 9, 10, 11, 12, 13, 7, 48, 41, 42, 43, 44, 45, 46}, - { 26, 25, 18, 14, 15, 16, 17, 49, 50, 51, 52, 53, NO_LED, 47}, - { 27, NO_LED, 28, 19, 20, 21, 22, 23, 56, 55, 57, 58, 59, 54}, - { 32, 31, 30, 29, NO_LED, NO_LED, 24, 33, NO_LED, NO_LED, 60, 61, 62, 63}, - }, - { - { 0, 0},{ 16, 0},{ 32, 0},{ 48, 0},{ 64, 0},{ 80, 0},{ 96, 0},{ 96, 16}, - { 0, 16},{ 16, 16}, - { 32, 16},{ 48, 16},{ 64, 16},{ 80, 16},{ 64, 32},{ 80, 32},{ 96, 32},{112, 32}, - - { 48, 32},{ 48, 48},{ 64, 48},{ 80, 48},{ 96, 48},{112, 48},{112, 64},{ 32, 32}, - { 16, 32},{ 16, 48}, { 32, 48},{ 64, 64},{ 40, 64},{ 20, 64},{ 0, 64}, - - {112, 0},{128, 0},{144, 0},{160, 0},{176, 0},{192, 0},{208, 0},{224, 0}, - {128, 16},{144, 16},{160, 16},{176, 16},{192, 16},{216, 16},{216, 32},{112, 16}, - - {128, 32},{144, 32},{160, 32},{176, 32},{192, 32}, {224, 48},{144, 48}, - {128, 48},{160, 48},{176, 48},{192, 48},{160, 64},{180, 64},{200, 64},{224, 64} - }, - { - 1, 4, 4, 4, 4, 4, 4, 4, - 1, 4, - 4, 4, 4, 4, 4, 4, 4, 4, - - 4, 4, 4, 4, 4, 4, 4, 1, - 1, 1, 4, 1, 1, 1, 1, - - 4, 4, 4, 4, 4, 4, 1, 1, - 4, 4, 4, 4, 4, 1, 1, 4, - - 4, 4, 4, 4, 4, 1, 4, - 4, 4, 4, 1, 1, 1, 1, 1, - } -}; -#endif - #endif //RGB_MATRIX_ENABLE bool process_record_kb(uint16_t keycode, keyrecord_t *record) { diff --git a/keyboards/inett_studio/sqx/sqx.h b/keyboards/inett_studio/sqx/universal/universal.h similarity index 99% rename from keyboards/inett_studio/sqx/sqx.h rename to keyboards/inett_studio/sqx/universal/universal.h index acbc1840a580..b0faaeb3746b 100644 --- a/keyboards/inett_studio/sqx/sqx.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -1,5 +1,5 @@ /** - * @file sqx.h + * @file universal.h * */ #pragma once From 92bef9b8f8f97adf46b190d0c527684baf933e46 Mon Sep 17 00:00:00 2001 From: yulei Date: Wed, 19 Aug 2020 18:00:10 +0800 Subject: [PATCH 03/13] Apply suggestions from code review Co-authored-by: James Young <18669334+noroadsleft@users.noreply.github.com> --- keyboards/inett_studio/sqx/hotswap/config.h | 1 - keyboards/inett_studio/sqx/hotswap/hotswap.h | 2 +- keyboards/inett_studio/sqx/hotswap/info.json | 3 +-- .../sqx/hotswap/keymaps/default/keymap.c | 4 ++-- .../sqx/hotswap/keymaps/via/keymap.c | 8 +++---- keyboards/inett_studio/sqx/hotswap/readme.md | 10 ++++----- keyboards/inett_studio/sqx/hotswap/rules.mk | 22 ++++++++----------- keyboards/inett_studio/sqx/universal/config.h | 1 - .../inett_studio/sqx/universal/info.json | 12 +++------- .../inett_studio/sqx/universal/readme.md | 10 ++++----- keyboards/inett_studio/sqx/universal/rules.mk | 19 +++++----------- .../inett_studio/sqx/universal/universal.h | 17 +------------- 12 files changed, 37 insertions(+), 72 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/config.h b/keyboards/inett_studio/sqx/hotswap/config.h index 008a9091561e..cd41bb3c2e6b 100644 --- a/keyboards/inett_studio/sqx/hotswap/config.h +++ b/keyboards/inett_studio/sqx/hotswap/config.h @@ -12,7 +12,6 @@ #define DEVICE_VER 0x0001 #define MANUFACTURER iNETT Studio #define PRODUCT SQUARE.X -#define DESCRIPTION 60% keyboard from the Square series /* key matrix size */ #define MATRIX_ROWS 5 diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h index d044a141af9d..6d0b0621e50c 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.h +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -9,7 +9,7 @@ // This a shortcut to help you visually see your layout. // The first section contains all of the arguements // The second converts the arguments into a two-dimensional array -#define LAYOUT_60_wkl_split_bs_rshift( \ +#define LAYOUT_60_tsangan_hhkb( \ 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, k1e, \ k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ diff --git a/keyboards/inett_studio/sqx/hotswap/info.json b/keyboards/inett_studio/sqx/hotswap/info.json index 1d6e9b462bbf..7180422c3de4 100644 --- a/keyboards/inett_studio/sqx/hotswap/info.json +++ b/keyboards/inett_studio/sqx/hotswap/info.json @@ -5,8 +5,7 @@ "width": 15, "height": 5, "layouts": { - "LAYOUT_60_wkl_split_bs_rshift": { - "key_count":62, + "LAYOUT_60_tsangan_hhkb": { "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":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.5, "y":1, "w":1.5}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2, "w":2.25}, {"x":0, "y":3, "w":2.25}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.5}, {"x":1.5, "y":4}, {"x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"x":11, "y":4, "w":1.5}, {"x":12.5, "y":4}, {"x":13.5, "y":4, "w":1.5}] } } diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c index 4d42f99c3807..8f39a4beea45 100644 --- a/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c @@ -1,14 +1,14 @@ #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [0] = LAYOUT_60_wkl_split_bs_rshift( + [0] = LAYOUT_60_tsangan_hhkb( 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_DEL, 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_END, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1),KC_RCTL), - [1] = LAYOUT_60_wkl_split_bs_rshift( + [1] = LAYOUT_60_tsangan_hhkb( _______, 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, RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c index 852112afbb47..9f19c728282c 100644 --- a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c @@ -1,28 +1,28 @@ #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [0] = LAYOUT_60_wkl_split_bs_rshift( + [0] = LAYOUT_60_tsangan_hhkb( 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_DEL, 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, MO(1), KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, TG(1),KC_RCTL), - [1] = LAYOUT_60_wkl_split_bs_rshift( + [1] = LAYOUT_60_tsangan_hhkb( _______, 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, RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______, TG(0),_______), - [2] = LAYOUT_60_wkl_split_bs_rshift( + [2] = LAYOUT_60_tsangan_hhkb( _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______, TG(0),_______), - [3] = LAYOUT_60_wkl_split_bs_rshift( + [3] = LAYOUT_60_tsangan_hhkb( _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, diff --git a/keyboards/inett_studio/sqx/hotswap/readme.md b/keyboards/inett_studio/sqx/hotswap/readme.md index 34c858ac9b72..faf5cc6a6ef4 100644 --- a/keyboards/inett_studio/sqx/hotswap/readme.md +++ b/keyboards/inett_studio/sqx/hotswap/readme.md @@ -1,10 +1,10 @@ -# SQUARE.X keyboard from the iNETT Studio +# iNETT Studio SQUARE.X hotswap -An 60% keybaord from the iNETT studio's square series +A 60% keyboard from the iNETT Studio's SQUARE series. -Keyboard Maintainer: [astro](https://github.com/yulei) -Hardware Supported: SQX Keyboard -Hardware Availability: [GH GB](https://geekhack.org/index.php?topic=107062.0) +* Keyboard Maintainer: [astro](https://github.com/yulei) +* Hardware Supported: SQUARE.X hotswap +* Hardware Availability: [Geekhack Group Buy](https://geekhack.org/index.php?topic=107062.0) Make example for this keyboard (after setting up your build environment): diff --git a/keyboards/inett_studio/sqx/hotswap/rules.mk b/keyboards/inett_studio/sqx/hotswap/rules.mk index 6784d6d2cc96..e7d4e39db928 100644 --- a/keyboards/inett_studio/sqx/hotswap/rules.mk +++ b/keyboards/inett_studio/sqx/hotswap/rules.mk @@ -2,28 +2,24 @@ MCU = atmega32u4 # Bootloader selection -# Teensy halfkay -# Pro Micro caterina -# Atmel DFU atmel-dfu -# LUFA DFU lufa-dfu -# QMK DFU qmk-dfu -# ATmega32A bootloadHID -# ATmega328P USBasp BOOTLOADER = atmel-dfu # Build Options # change yes to no to disable # -BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration MOUSEKEY_ENABLE = no # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control +EXTRAKEY_ENABLE = yes # Audio control and System control CONSOLE_ENABLE = no # Console for debug COMMAND_ENABLE = no # Commands for debug and configuration # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work -NKRO_ENABLE = yes # USB Nkey Rollover -UNICODE_ENABLE = no # Unicode -RGBLIGHT_ENABLE = yes # Use RGB underglow light +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow RGB_MATRIX_ENABLE = yes # Use RGB per key light -LTO_ENABLE = yes # Reducing firmware size +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output + +LTO_ENABLE = yes # Reducing firmware size diff --git a/keyboards/inett_studio/sqx/universal/config.h b/keyboards/inett_studio/sqx/universal/config.h index d96e8f8a5dda..091bb46b13e9 100644 --- a/keyboards/inett_studio/sqx/universal/config.h +++ b/keyboards/inett_studio/sqx/universal/config.h @@ -12,7 +12,6 @@ #define DEVICE_VER 0x0001 #define MANUFACTURER iNETT Studio #define PRODUCT SQUARE.X -#define DESCRIPTION 60% keyboard from the Square series /* key matrix size */ #define MATRIX_ROWS 5 diff --git a/keyboards/inett_studio/sqx/universal/info.json b/keyboards/inett_studio/sqx/universal/info.json index 2970b05fb519..d0956b68028b 100644 --- a/keyboards/inett_studio/sqx/universal/info.json +++ b/keyboards/inett_studio/sqx/universal/info.json @@ -5,28 +5,22 @@ "width": 15, "height": 5, "layouts": { - "LAYOUT_60_wkl": { - "key_count":61, + "LAYOUT_60_ansi_tsangan_split_rshift": { "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.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":"Fn", "x":14, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.5}, {"label":"Win", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Win", "x":12.5, "y":4}, {"label":"Ctrl", "x":13.5, "y":4, "w":1.5}] }, "LAYOUT_60_ansi": { - "key_count":61, "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.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":2.75}, {"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":"Alt", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}] }, "LAYOUT_60_hhkb": { - "key_count":60, "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":"|", "x":13, "y":0}, {"label":"~", "x":14, "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":"Backspace", "x":13.5, "y":1, "w":1.5}, {"label":"Control", "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.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":"Fn", "x":14, "y":3}, {"label":"Win", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Win", "x":12.5, "y":4}] }, "LAYOUT_60_iso": { - "key_count":62, - "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":12, "y":0}, {"x":13, "y":0, "w":2}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.75, "y":1, "w":1.25, "h":2}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2}, {"x":0, "y":3, "w":1.25}, {"x":1.25, "y":3}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":2.75}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":1.25}, {"x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"x":10, "y":4, "w":1.25}, {"x":11.25, "y":4, "w":1.25}, {"x":12.5, "y":4, "w":1.25}, {"x":13.75, "y":4, "w":1.25}] + "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":12, "y":0}, {"x":13, "y":0, "w":2}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2}, {"x":13.75, "y":1, "w":1.25, "h":2}, {"x":0, "y":3, "w":1.25}, {"x":1.25, "y":3}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":2.75}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":1.25}, {"x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"x":10, "y":4, "w":1.25}, {"x":11.25, "y":4, "w":1.25}, {"x":12.5, "y":4, "w":1.25}, {"x":13.75, "y":4, "w":1.25}] }, "LAYOUT_60_ansi_split_bs_rshift": { - "key_count":63, "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":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.5, "y":1, "w":1.5}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2, "w":2.25}, {"x":0, "y":3, "w":2.25}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":1.25}, {"x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"x":10, "y":4, "w":1.25}, {"x":11.25, "y":4, "w":1.25}, {"x":12.5, "y":4, "w":1.25}, {"x":13.75, "y":4, "w":1.25}] }, - "LAYOUT_60_wkl_split_bs": { - "key_count":62, + "LAYOUT_60_tsangan_hhkb": { "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":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"x":0, "y":1, "w":1.5}, {"x":1.5, "y":1}, {"x":2.5, "y":1}, {"x":3.5, "y":1}, {"x":4.5, "y":1}, {"x":5.5, "y":1}, {"x":6.5, "y":1}, {"x":7.5, "y":1}, {"x":8.5, "y":1}, {"x":9.5, "y":1}, {"x":10.5, "y":1}, {"x":11.5, "y":1}, {"x":12.5, "y":1}, {"x":13.5, "y":1, "w":1.5}, {"x":0, "y":2, "w":1.75}, {"x":1.75, "y":2}, {"x":2.75, "y":2}, {"x":3.75, "y":2}, {"x":4.75, "y":2}, {"x":5.75, "y":2}, {"x":6.75, "y":2}, {"x":7.75, "y":2}, {"x":8.75, "y":2}, {"x":9.75, "y":2}, {"x":10.75, "y":2}, {"x":11.75, "y":2}, {"x":12.75, "y":2, "w":2.25}, {"x":0, "y":3, "w":2.25}, {"x":2.25, "y":3}, {"x":3.25, "y":3}, {"x":4.25, "y":3}, {"x":5.25, "y":3}, {"x":6.25, "y":3}, {"x":7.25, "y":3}, {"x":8.25, "y":3}, {"x":9.25, "y":3}, {"x":10.25, "y":3}, {"x":11.25, "y":3}, {"x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.5}, {"x":1.5, "y":4}, {"x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"x":11, "y":4, "w":1.5}, {"x":12.5, "y":4}, {"x":13.5, "y":4, "w":1.5}] } } diff --git a/keyboards/inett_studio/sqx/universal/readme.md b/keyboards/inett_studio/sqx/universal/readme.md index 37fc31310e25..0a09b9c7dd25 100644 --- a/keyboards/inett_studio/sqx/universal/readme.md +++ b/keyboards/inett_studio/sqx/universal/readme.md @@ -1,10 +1,10 @@ -# SQUARE.X keyboard from the iNETT Studio +# iNETT Studio SQUARE.X universal -An 60% keybaord from the iNETT studio's square series +A 60% keyboard from the iNETT Studio's SQUARE series. -Keyboard Maintainer: [astro](https://github.com/yulei) -Hardware Supported: SQX Keyboard -Hardware Availability: [GH GB](https://geekhack.org/index.php?topic=107062.0) +* Keyboard Maintainer: [astro](https://github.com/yulei) +* Hardware Supported: SQUARE.X universal +* Hardware Availability: [Geekhack Group Buy](https://geekhack.org/index.php?topic=107062.0) Make example for this keyboard (after setting up your build environment): diff --git a/keyboards/inett_studio/sqx/universal/rules.mk b/keyboards/inett_studio/sqx/universal/rules.mk index 3a7771e2d2de..8fcfac5c0a78 100644 --- a/keyboards/inett_studio/sqx/universal/rules.mk +++ b/keyboards/inett_studio/sqx/universal/rules.mk @@ -2,29 +2,22 @@ MCU = atmega32u4 # Bootloader selection -# Teensy halfkay -# Pro Micro caterina -# Atmel DFU atmel-dfu -# LUFA DFU lufa-dfu -# QMK DFU qmk-dfu -# ATmega32A bootloadHID -# ATmega328P USBasp BOOTLOADER = atmel-dfu # Build Options # change yes to no to disable # -BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration MOUSEKEY_ENABLE = no # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control +EXTRAKEY_ENABLE = yes # Audio control and System control CONSOLE_ENABLE = no # Console for debug COMMAND_ENABLE = no # Commands for debug and configuration # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work -NKRO_ENABLE = yes # USB Nkey Rollover -UNICODE_ENABLE = no # Unicode -RGBLIGHT_ENABLE = yes # Use RGB underglow light +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow RGB_MATRIX_ENABLE = yes # Use RGB per key light -LTO_ENABLE = yes # Reducing firmware size +LTO_ENABLE = yes # Reducing firmware size diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index b0faaeb3746b..907ed3af05e7 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -68,7 +68,7 @@ {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ {KC_NO, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, KC_NO} \ } -#define LAYOUT_60_wkl_split_bs( \ +#define LAYOUT_60_tsangan_hhkb( \ 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, k1e, \ k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ @@ -97,18 +97,3 @@ {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, k48, k49, k4a, k4b} \ } - -#define LAYOUT_60_wkl_split_bs_rshift( \ - 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, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ - k40, k42, k43, k47, k49, k4a, k4b \ -) \ -{ \ - {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ - {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e}, \ - {k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, KC_NO, k2e}, \ - {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ - {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ -} From df0bed04be4a80bc2db45181a97809303effb0ab Mon Sep 17 00:00:00 2001 From: yulei Date: Thu, 20 Aug 2020 11:44:10 +0800 Subject: [PATCH 04/13] Update keyboards/inett_studio/sqx/universal/universal.h Co-authored-by: James Young <18669334+noroadsleft@users.noreply.github.com> --- keyboards/inett_studio/sqx/universal/universal.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index 907ed3af05e7..5e3a148956cc 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -39,7 +39,7 @@ {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, k48, k49, k4a, k4b} \ } -#define LAYOUT_60_wkl( \ +#define LAYOUT_60_ansi_tsangan_split_rshift( \ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ From 34d798ed6c4e6c14eb85617997ddac03db3d51d5 Mon Sep 17 00:00:00 2001 From: yulei Date: Mon, 24 Aug 2020 10:00:37 +0800 Subject: [PATCH 05/13] Apply suggestions from code review Co-authored-by: James Young <18669334+noroadsleft@users.noreply.github.com> --- keyboards/inett_studio/sqx/hotswap/rules.mk | 2 ++ keyboards/inett_studio/sqx/universal/rules.mk | 2 ++ 2 files changed, 4 insertions(+) diff --git a/keyboards/inett_studio/sqx/hotswap/rules.mk b/keyboards/inett_studio/sqx/hotswap/rules.mk index e7d4e39db928..80968787d512 100644 --- a/keyboards/inett_studio/sqx/hotswap/rules.mk +++ b/keyboards/inett_studio/sqx/hotswap/rules.mk @@ -23,3 +23,5 @@ BLUETOOTH_ENABLE = no # Enable Bluetooth AUDIO_ENABLE = no # Audio output LTO_ENABLE = yes # Reducing firmware size + +LAYOUTS = 60_tsangan_hhkb diff --git a/keyboards/inett_studio/sqx/universal/rules.mk b/keyboards/inett_studio/sqx/universal/rules.mk index 8fcfac5c0a78..cf3a64ba9fec 100644 --- a/keyboards/inett_studio/sqx/universal/rules.mk +++ b/keyboards/inett_studio/sqx/universal/rules.mk @@ -21,3 +21,5 @@ RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow RGB_MATRIX_ENABLE = yes # Use RGB per key light LTO_ENABLE = yes # Reducing firmware size + +LAYOUTS = 60_ansi 60_hhkb 60_iso 60_ansi_split_bs_rshift 60_tsangan_hhkb From 241329d96d15aeb98864d9488b32bc3c1103e54d Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Mon, 24 Aug 2020 10:52:44 +0800 Subject: [PATCH 06/13] update the matrix control keycodes settings --- keyboards/inett_studio/sqx/hotswap/hotswap.c | 22 ++++---- keyboards/inett_studio/sqx/hotswap/hotswap.h | 35 ++++++++++++ .../inett_studio/sqx/universal/universal.c | 56 +++++++++---------- .../inett_studio/sqx/universal/universal.h | 36 ++++++++++++ 4 files changed, 108 insertions(+), 41 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c index 6439dc3ec2fb..9698105a28a4 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.c +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -142,34 +142,32 @@ led_config_t g_led_config = { bool process_record_kb(uint16_t keycode, keyrecord_t *record) { if (record->event.pressed) { switch(keycode) { - #ifdef RGBLIGHT_ENABLE - #ifdef RGB_MATRIX_ENABLE - case KC_F16: // toggle rgb matrix +#if USE_DEFAULT_MATRIX_KEYCODES + case RGB_MATRIX_TOGGLE: // toggle rgb matrix rgb_matrix_toggle(); return false; - case KC_F17: + case RGB_MATRIX_STEP: rgb_matrix_step(); return false; - case KC_F18: + case RGB_MATRIX_INC_HUE: rgb_matrix_increase_hue(); return false; - case KC_F20: + case RGB_MATRIX_DEC_HUE: rgb_matrix_decrease_hue(); return false; - case KC_F21: + case RGB_MATRIX_INC_SAT: rgb_matrix_increase_sat(); return false; - case KC_F22: + case RGB_MATRIX_DEC_SAT: rgb_matrix_decrease_sat(); return false; - case KC_F23: + case RGB_MATRIX_INC_VAL: rgb_matrix_increase_val(); return false; - case KC_F24: + case RGB_MATRIX_DEC_VAL: rgb_matrix_decrease_val(); return false; - #endif - #endif +#endif default: break; } diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h index 6d0b0621e50c..ffe13dedd461 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.h +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -23,3 +23,38 @@ {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ } + +#ifdef RGBLIGHT_ENABLE + #ifdef RGB_MATRIX_ENABLE + #ifndef USE_DEFAULT_MATRIX_KEYCODES + #define USE_DEFAULT_MATRIX_KEYCODES 1 + #endif + #endif +#endif + +#if USE_DEFAULT_MATRIX_KEYCODES + #ifndef RGB_MATRIX_TOGGLE + #define RGB_MATRIX_TOGGLE KC_F16 + #endif + #ifndef RGB_MATRIX_STEP + #define RGB_MATRIX_STEP KC_F17 + #endif + #ifndef RGB_MATRIX_INC_HUE + #define RGB_MATRIX_INC_HUE KC_F18 + #endif + #ifndef RGB_MATRIX_DEC_HUE + #define RGB_MATRIX_DEC_HUE KC_F19 + #endif + #ifndef RGB_MATRIX_INC_SAT + #define RGB_MATRIX_INC_SAT KC_F20 + #endif + #ifndef RGB_MATRIX_DEC_SAT + #define RGB_MATRIX_DEC_SAT KC_F21 + #endif + #ifndef RGB_MATRIX_INC_VAL + #define RGB_MATRIX_INC_VAL KC_F22 + #endif + #ifndef RGB_MATRIX_DEC_VAL + #define RGB_MATRIX_DEC_VAL KC_F23 + #endif +#endif diff --git a/keyboards/inett_studio/sqx/universal/universal.c b/keyboards/inett_studio/sqx/universal/universal.c index 5cf9aae4c2f4..3b48acd466c7 100644 --- a/keyboards/inett_studio/sqx/universal/universal.c +++ b/keyboards/inett_studio/sqx/universal/universal.c @@ -145,35 +145,33 @@ led_config_t g_led_config = { bool process_record_kb(uint16_t keycode, keyrecord_t *record) { if (record->event.pressed) { switch(keycode) { - #ifdef RGBLIGHT_ENABLE - #ifdef RGB_MATRIX_ENABLE - case KC_F16: // toggle rgb matrix - rgb_matrix_toggle(); - return false; - case KC_F17: - rgb_matrix_step(); - return false; - case KC_F18: - rgb_matrix_increase_hue(); - return false; - case KC_F20: - rgb_matrix_decrease_hue(); - return false; - case KC_F21: - rgb_matrix_increase_sat(); - return false; - case KC_F22: - rgb_matrix_decrease_sat(); - return false; - case KC_F23: - rgb_matrix_increase_val(); - return false; - case KC_F24: - rgb_matrix_decrease_val(); - return false; - #endif - #endif - default: +#if USE_DEFAULT_MATRIX_KEYCODES + case RGB_MATRIX_TOGGLE: // toggle rgb matrix + rgb_matrix_toggle(); + return false; + case RGB_MATRIX_STEP: + rgb_matrix_step(); + return false; + case RGB_MATRIX_INC_HUE: + rgb_matrix_increase_hue(); + return false; + case RGB_MATRIX_DEC_HUE: + rgb_matrix_decrease_hue(); + return false; + case RGB_MATRIX_INC_SAT: + rgb_matrix_increase_sat(); + return false; + case RGB_MATRIX_DEC_SAT: + rgb_matrix_decrease_sat(); + return false; + case RGB_MATRIX_INC_VAL: + rgb_matrix_increase_val(); + return false; + case RGB_MATRIX_DEC_VAL: + rgb_matrix_decrease_val(); + return false; +#endif + default: break; } } diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index 5e3a148956cc..b39967a6dc06 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -97,3 +97,39 @@ {k30, KC_NO, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, k48, k49, k4a, k4b} \ } + + +#ifdef RGBLIGHT_ENABLE + #ifdef RGB_MATRIX_ENABLE + #ifndef USE_DEFAULT_MATRIX_KEYCODES + #define USE_DEFAULT_MATRIX_KEYCODES 1 + #endif + #endif +#endif + +#if USE_DEFAULT_MATRIX_KEYCODES + #ifndef RGB_MATRIX_TOGGLE + #define RGB_MATRIX_TOGGLE KC_F16 + #endif + #ifndef RGB_MATRIX_STEP + #define RGB_MATRIX_STEP KC_F17 + #endif + #ifndef RGB_MATRIX_INC_HUE + #define RGB_MATRIX_INC_HUE KC_F18 + #endif + #ifndef RGB_MATRIX_DEC_HUE + #define RGB_MATRIX_DEC_HUE KC_F19 + #endif + #ifndef RGB_MATRIX_INC_SAT + #define RGB_MATRIX_INC_SAT KC_F20 + #endif + #ifndef RGB_MATRIX_DEC_SAT + #define RGB_MATRIX_DEC_SAT KC_F21 + #endif + #ifndef RGB_MATRIX_INC_VAL + #define RGB_MATRIX_INC_VAL KC_F22 + #endif + #ifndef RGB_MATRIX_DEC_VAL + #define RGB_MATRIX_DEC_VAL KC_F23 + #endif +#endif From 2cf4ba727e29b0e3f3072208ccf304c0e739b6eb Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Mon, 24 Aug 2020 13:59:32 +0800 Subject: [PATCH 07/13] use the offical macro to the rgb matrix control --- keyboards/inett_studio/sqx/hotswap/config.h | 5 ++ keyboards/inett_studio/sqx/hotswap/hotswap.c | 50 ++++++++++--------- keyboards/inett_studio/sqx/hotswap/hotswap.h | 10 +--- keyboards/inett_studio/sqx/universal/config.h | 5 ++ .../inett_studio/sqx/universal/universal.c | 2 + .../inett_studio/sqx/universal/universal.h | 10 +--- 6 files changed, 40 insertions(+), 42 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/config.h b/keyboards/inett_studio/sqx/hotswap/config.h index cd41bb3c2e6b..d18d48ad476c 100644 --- a/keyboards/inett_studio/sqx/hotswap/config.h +++ b/keyboards/inett_studio/sqx/hotswap/config.h @@ -52,3 +52,8 @@ #define DRIVER_ADDR_2 0b1110111 #define DRIVER_COUNT 2 #define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) + +#define USE_CUSTOM_MATRIX_KEYCODES 1 +#if USE_CUSTOM_MATRIX_KEYCODES + #define RGB_MATRIX_DISABLE_KEYCODES +#endif diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c index 9698105a28a4..ae2affdd318f 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.c +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -143,30 +143,32 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) { if (record->event.pressed) { switch(keycode) { #if USE_DEFAULT_MATRIX_KEYCODES - case RGB_MATRIX_TOGGLE: // toggle rgb matrix - rgb_matrix_toggle(); - return false; - case RGB_MATRIX_STEP: - rgb_matrix_step(); - return false; - case RGB_MATRIX_INC_HUE: - rgb_matrix_increase_hue(); - return false; - case RGB_MATRIX_DEC_HUE: - rgb_matrix_decrease_hue(); - return false; - case RGB_MATRIX_INC_SAT: - rgb_matrix_increase_sat(); - return false; - case RGB_MATRIX_DEC_SAT: - rgb_matrix_decrease_sat(); - return false; - case RGB_MATRIX_INC_VAL: - rgb_matrix_increase_val(); - return false; - case RGB_MATRIX_DEC_VAL: - rgb_matrix_decrease_val(); - return false; + #ifdef RGB_MATRIX_ENABLE + case RGB_MATRIX_TOGGLE: // toggle rgb matrix + rgb_matrix_toggle(); + return false; + case RGB_MATRIX_STEP: + rgb_matrix_step(); + return false; + case RGB_MATRIX_INC_HUE: + rgb_matrix_increase_hue(); + return false; + case RGB_MATRIX_DEC_HUE: + rgb_matrix_decrease_hue(); + return false; + case RGB_MATRIX_INC_SAT: + rgb_matrix_increase_sat(); + return false; + case RGB_MATRIX_DEC_SAT: + rgb_matrix_decrease_sat(); + return false; + case RGB_MATRIX_INC_VAL: + rgb_matrix_increase_val(); + return false; + case RGB_MATRIX_DEC_VAL: + rgb_matrix_decrease_val(); + return false; + #endif #endif default: break; diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h index ffe13dedd461..ad57a5743d9f 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.h +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -24,15 +24,7 @@ {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ } -#ifdef RGBLIGHT_ENABLE - #ifdef RGB_MATRIX_ENABLE - #ifndef USE_DEFAULT_MATRIX_KEYCODES - #define USE_DEFAULT_MATRIX_KEYCODES 1 - #endif - #endif -#endif - -#if USE_DEFAULT_MATRIX_KEYCODES +#if USE_CUSTOM_MATRIX_KEYCODES #ifndef RGB_MATRIX_TOGGLE #define RGB_MATRIX_TOGGLE KC_F16 #endif diff --git a/keyboards/inett_studio/sqx/universal/config.h b/keyboards/inett_studio/sqx/universal/config.h index 091bb46b13e9..b80ea676b48f 100644 --- a/keyboards/inett_studio/sqx/universal/config.h +++ b/keyboards/inett_studio/sqx/universal/config.h @@ -52,3 +52,8 @@ #define DRIVER_ADDR_2 0b1110111 #define DRIVER_COUNT 2 #define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) + +#define USE_CUSTOM_MATRIX_KEYCODES 1 +#if USE_CUSTOM_MATRIX_KEYCODES + #define RGB_MATRIX_DISABLE_KEYCODES +#endif diff --git a/keyboards/inett_studio/sqx/universal/universal.c b/keyboards/inett_studio/sqx/universal/universal.c index 3b48acd466c7..4a812aa8f8d8 100644 --- a/keyboards/inett_studio/sqx/universal/universal.c +++ b/keyboards/inett_studio/sqx/universal/universal.c @@ -146,6 +146,7 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) { if (record->event.pressed) { switch(keycode) { #if USE_DEFAULT_MATRIX_KEYCODES + #ifdef RGB_MATRIX_ENABLE case RGB_MATRIX_TOGGLE: // toggle rgb matrix rgb_matrix_toggle(); return false; @@ -170,6 +171,7 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) { case RGB_MATRIX_DEC_VAL: rgb_matrix_decrease_val(); return false; + #endif #endif default: break; diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index b39967a6dc06..ee964676d2f4 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -99,15 +99,7 @@ } -#ifdef RGBLIGHT_ENABLE - #ifdef RGB_MATRIX_ENABLE - #ifndef USE_DEFAULT_MATRIX_KEYCODES - #define USE_DEFAULT_MATRIX_KEYCODES 1 - #endif - #endif -#endif - -#if USE_DEFAULT_MATRIX_KEYCODES +#if USE_CUSTOM_MATRIX_KEYCODES #ifndef RGB_MATRIX_TOGGLE #define RGB_MATRIX_TOGGLE KC_F16 #endif From be19de08b55cc04034a3e3ef219d33065ffd4ff4 Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Sat, 29 Aug 2020 20:11:31 +0800 Subject: [PATCH 08/13] fixed led position issue --- keyboards/inett_studio/sqx/hotswap/hotswap.c | 34 ++++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c index ae2affdd318f..d8e1e1f4ebc0 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.c +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -22,12 +22,12 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { {0, C1_7, C2_7, C3_7}, {0, C1_8, C2_8, C3_8}, - {0, C5_1, C4_1, C6_1}, - {0, C5_8, C4_8, C6_8}, + //{0, C5_1, C4_1, C6_1}, + //{0, C5_8, C4_8, C6_8}, {0, C9_1, C8_1, C7_1}, {0, C9_2, C8_2, C7_2}, - {0, C9_3, C8_3, C7_3}, + //{0, C9_3, C8_3, C7_3}, {0, C9_4, C8_4, C7_4}, {0, C9_5, C8_5, C7_5}, {0, C9_6, C8_6, C7_6}, @@ -43,12 +43,12 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { {0, C1_15, C2_15, C3_15}, {0, C1_16, C2_16, C3_16}, - //{0, C5_9, C4_9, C6_9}, - //{0, C5_16, C4_16, C6_16}, + {0, C5_9, C4_9, C6_9}, + {0, C5_16, C4_16, C6_16}, {0, C9_9, C8_9, C7_9}, {0, C9_10, C8_10, C7_10}, - //{0, C9_11, C8_11, C7_11}, + {0, C9_11, C8_11, C7_11}, {0, C9_12, C8_12, C7_12}, {0, C9_13, C8_13, C7_13}, {0, C9_14, C8_14, C7_14}, @@ -101,20 +101,20 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { led_config_t g_led_config = { { - { 0, 1, 2, 3, 4, 5, 6, 34, 35, 36, 37, 38, 39, 40}, - { 8, 9, 10, 11, 12, 13, 7, 48, 41, 42, 43, 44, 45, 46}, - { 26, 25, 18, 14, 15, 16, 17, 49, 50, 51, 52, 53, NO_LED, 47}, - { 27, NO_LED, 28, 19, 20, 21, 22, 23, 56, 55, 57, 58, 59, 54}, - { 32, 31, 30, 29, NO_LED, NO_LED, 24, 33, NO_LED, NO_LED, 60, 61, 62, 63}, + { 18, 19, 20, 21, 22, 23, 24, 16, 17, 36, 37, 38, 39, 40}, + { 26, 27, 28, 29, 30, 31, 25, 48, 41, 42, 43, 44, 45, 46}, + { 8, 7, 0, 32, 33, 34, 35, 49, 50, 51, 52, 53, NO_LED, 47}, + { 9, NO_LED, 10, 1, 2, 3, 4, 5, 56, 55, 57, 58, 59, 54}, + { 14, 13, 12, 11, NO_LED, NO_LED, 6, 15, NO_LED, NO_LED, 60, 61, 62, 63}, }, { + { 48, 32},{ 48, 48},{ 64, 48},{ 80, 48},{ 96, 48},{112, 48},{112, 64},{ 32, 32}, + { 16, 32},{ 16, 48}, { 32, 48},{ 64, 64},{ 40, 64},{ 20, 64},{ 0, 64}, + { 0, 0},{ 16, 0},{ 32, 0},{ 48, 0},{ 64, 0},{ 80, 0},{ 96, 0},{ 96, 16}, { 0, 16},{ 16, 16}, { 32, 16},{ 48, 16},{ 64, 16},{ 80, 16},{ 64, 32},{ 80, 32},{ 96, 32},{112, 32}, - { 48, 32},{ 48, 48},{ 64, 48},{ 80, 48},{ 96, 48},{112, 48},{112, 64},{ 32, 32}, - { 16, 32},{ 16, 48}, { 32, 48},{ 64, 64},{ 40, 64},{ 20, 64},{ 0, 64}, - {112, 0},{128, 0},{144, 0},{160, 0},{176, 0},{192, 0},{208, 0},{224, 0}, {128, 16},{144, 16},{160, 16},{176, 16},{192, 16},{216, 16},{216, 32},{112, 16}, @@ -122,13 +122,13 @@ led_config_t g_led_config = { {128, 48},{160, 48},{176, 48},{192, 48},{160, 64},{180, 64},{200, 64},{224, 64} }, { + 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 4, 1, 1, 1, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, - 4, 4, 4, 4, 4, 4, 4, 1, - 1, 1, 4, 1, 1, 1, 1, - 4, 4, 4, 4, 4, 4, 1, 1, 4, 4, 4, 4, 4, 1, 1, 4, From ca2938482a448cf7ab8e5e32706e4292532af050 Mon Sep 17 00:00:00 2001 From: yulei Date: Mon, 31 Aug 2020 09:45:08 +0800 Subject: [PATCH 09/13] Apply suggestions from code review Co-authored-by: Drashna Jaelre --- keyboards/inett_studio/sqx/hotswap/config.h | 3 +- keyboards/inett_studio/sqx/hotswap/hotswap.c | 3 +- keyboards/inett_studio/sqx/hotswap/hotswap.h | 50 +++++++++---------- keyboards/inett_studio/sqx/universal/config.h | 5 +- .../inett_studio/sqx/universal/universal.c | 4 +- .../inett_studio/sqx/universal/universal.h | 50 +++++++++---------- 6 files changed, 55 insertions(+), 60 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/config.h b/keyboards/inett_studio/sqx/hotswap/config.h index d18d48ad476c..e698f9efc8cc 100644 --- a/keyboards/inett_studio/sqx/hotswap/config.h +++ b/keyboards/inett_studio/sqx/hotswap/config.h @@ -53,7 +53,6 @@ #define DRIVER_COUNT 2 #define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) -#define USE_CUSTOM_MATRIX_KEYCODES 1 -#if USE_CUSTOM_MATRIX_KEYCODES +#if defined(RGB_MATRIX_ENABLE) && defined(RGBLIGHT_ENABLE) #define RGB_MATRIX_DISABLE_KEYCODES #endif diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c index d8e1e1f4ebc0..ba42f7c85093 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.c +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -142,8 +142,7 @@ led_config_t g_led_config = { bool process_record_kb(uint16_t keycode, keyrecord_t *record) { if (record->event.pressed) { switch(keycode) { -#if USE_DEFAULT_MATRIX_KEYCODES - #ifdef RGB_MATRIX_ENABLE +#if defined(RGB_MATRIX_DISABLE_KEYCODES) case RGB_MATRIX_TOGGLE: // toggle rgb matrix rgb_matrix_toggle(); return false; diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h index ad57a5743d9f..ad1e1410dcd6 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.h +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -24,29 +24,29 @@ {k40, k42, k43, KC_NO, KC_NO, KC_NO, k47, k07, KC_NO, KC_NO, KC_NO, k49, k4a, k4b} \ } -#if USE_CUSTOM_MATRIX_KEYCODES - #ifndef RGB_MATRIX_TOGGLE - #define RGB_MATRIX_TOGGLE KC_F16 - #endif - #ifndef RGB_MATRIX_STEP - #define RGB_MATRIX_STEP KC_F17 - #endif - #ifndef RGB_MATRIX_INC_HUE - #define RGB_MATRIX_INC_HUE KC_F18 - #endif - #ifndef RGB_MATRIX_DEC_HUE - #define RGB_MATRIX_DEC_HUE KC_F19 - #endif - #ifndef RGB_MATRIX_INC_SAT - #define RGB_MATRIX_INC_SAT KC_F20 - #endif - #ifndef RGB_MATRIX_DEC_SAT - #define RGB_MATRIX_DEC_SAT KC_F21 - #endif - #ifndef RGB_MATRIX_INC_VAL - #define RGB_MATRIX_INC_VAL KC_F22 - #endif - #ifndef RGB_MATRIX_DEC_VAL - #define RGB_MATRIX_DEC_VAL KC_F23 - #endif +#if defined(RGB_MATRIX_DISABLE_KEYCODES) +# ifndef RGB_MATRIX_TOGGLE +# define RGB_MATRIX_TOGGLE KC_F16 +# endif +# ifndef RGB_MATRIX_STEP +# define RGB_MATRIX_STEP KC_F17 +# endif +# ifndef RGB_MATRIX_INC_HUE +# define RGB_MATRIX_INC_HUE KC_F18 +# endif +# ifndef RGB_MATRIX_DEC_HUE +# define RGB_MATRIX_DEC_HUE KC_F19 +# endif +# ifndef RGB_MATRIX_INC_SAT +# define RGB_MATRIX_INC_SAT KC_F20 +# endif +# ifndef RGB_MATRIX_DEC_SAT +# define RGB_MATRIX_DEC_SAT KC_F21 +# endif +# ifndef RGB_MATRIX_INC_VAL +# define RGB_MATRIX_INC_VAL KC_F22 +# endif +# ifndef RGB_MATRIX_DEC_VAL +# define RGB_MATRIX_DEC_VAL KC_F23 +# endif #endif diff --git a/keyboards/inett_studio/sqx/universal/config.h b/keyboards/inett_studio/sqx/universal/config.h index b80ea676b48f..fff043c9893e 100644 --- a/keyboards/inett_studio/sqx/universal/config.h +++ b/keyboards/inett_studio/sqx/universal/config.h @@ -53,7 +53,6 @@ #define DRIVER_COUNT 2 #define DRIVER_LED_TOTAL (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) -#define USE_CUSTOM_MATRIX_KEYCODES 1 -#if USE_CUSTOM_MATRIX_KEYCODES - #define RGB_MATRIX_DISABLE_KEYCODES +#if defined(RGB_MATRIX_ENABLE) && defined(RGBLIGHT_ENABLE) +# define RGB_MATRIX_DISABLE_KEYCODES #endif diff --git a/keyboards/inett_studio/sqx/universal/universal.c b/keyboards/inett_studio/sqx/universal/universal.c index 4a812aa8f8d8..f6b7d9f70557 100644 --- a/keyboards/inett_studio/sqx/universal/universal.c +++ b/keyboards/inett_studio/sqx/universal/universal.c @@ -145,8 +145,7 @@ led_config_t g_led_config = { bool process_record_kb(uint16_t keycode, keyrecord_t *record) { if (record->event.pressed) { switch(keycode) { -#if USE_DEFAULT_MATRIX_KEYCODES - #ifdef RGB_MATRIX_ENABLE +#if defined(RGB_MATRIX_DISABLE_KEYCODES) case RGB_MATRIX_TOGGLE: // toggle rgb matrix rgb_matrix_toggle(); return false; @@ -171,7 +170,6 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) { case RGB_MATRIX_DEC_VAL: rgb_matrix_decrease_val(); return false; - #endif #endif default: break; diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index ee964676d2f4..f662a760f104 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -99,29 +99,29 @@ } -#if USE_CUSTOM_MATRIX_KEYCODES - #ifndef RGB_MATRIX_TOGGLE - #define RGB_MATRIX_TOGGLE KC_F16 - #endif - #ifndef RGB_MATRIX_STEP - #define RGB_MATRIX_STEP KC_F17 - #endif - #ifndef RGB_MATRIX_INC_HUE - #define RGB_MATRIX_INC_HUE KC_F18 - #endif - #ifndef RGB_MATRIX_DEC_HUE - #define RGB_MATRIX_DEC_HUE KC_F19 - #endif - #ifndef RGB_MATRIX_INC_SAT - #define RGB_MATRIX_INC_SAT KC_F20 - #endif - #ifndef RGB_MATRIX_DEC_SAT - #define RGB_MATRIX_DEC_SAT KC_F21 - #endif - #ifndef RGB_MATRIX_INC_VAL - #define RGB_MATRIX_INC_VAL KC_F22 - #endif - #ifndef RGB_MATRIX_DEC_VAL - #define RGB_MATRIX_DEC_VAL KC_F23 - #endif +#if defined(RGB_MATRIX_DISABLE_KEYCODES) +# ifndef RGB_MATRIX_TOGGLE +# define RGB_MATRIX_TOGGLE KC_F16 +# endif +# ifndef RGB_MATRIX_STEP +# define RGB_MATRIX_STEP KC_F17 +# endif +# ifndef RGB_MATRIX_INC_HUE +# define RGB_MATRIX_INC_HUE KC_F18 +# endif +# ifndef RGB_MATRIX_DEC_HUE +# define RGB_MATRIX_DEC_HUE KC_F19 +# endif +# ifndef RGB_MATRIX_INC_SAT +# define RGB_MATRIX_INC_SAT KC_F20 +# endif +# ifndef RGB_MATRIX_DEC_SAT +# define RGB_MATRIX_DEC_SAT KC_F21 +# endif +# ifndef RGB_MATRIX_INC_VAL +# define RGB_MATRIX_INC_VAL KC_F22 +# endif +# ifndef RGB_MATRIX_DEC_VAL +# define RGB_MATRIX_DEC_VAL KC_F23 +# endif #endif From 14f2078e5ae6725f73ab6a3ff63ca72099c88d24 Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Mon, 31 Aug 2020 11:32:32 +0800 Subject: [PATCH 10/13] removed the redundant #endif --- keyboards/inett_studio/sqx/hotswap/hotswap.c | 1 - 1 file changed, 1 deletion(-) diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c index ba42f7c85093..0cd0027dcd8f 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.c +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -167,7 +167,6 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) { case RGB_MATRIX_DEC_VAL: rgb_matrix_decrease_val(); return false; - #endif #endif default: break; From 60fc75b5bdc64456691580905738fb7a4a52f155 Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Sun, 6 Sep 2020 16:54:36 +0800 Subject: [PATCH 11/13] update default keymap --- keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c | 2 +- keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c | 2 +- keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c | 2 +- keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c index 8f39a4beea45..96344d90430d 100644 --- a/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c @@ -10,7 +10,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [1] = LAYOUT_60_tsangan_hhkb( _______, 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, - RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + RESET, RGB_TOG,RGB_MOD,_______, KC_F16, KC_F17,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______,_______,_______), diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c index 9f19c728282c..b95620567539 100644 --- a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c @@ -10,7 +10,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [1] = LAYOUT_60_tsangan_hhkb( _______, 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, - RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + RESET, RGB_TOG,RGB_MOD,_______, KC_F16, KC_F17,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______, TG(0),_______), diff --git a/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c index 48a6e2669e1b..905813d979a9 100644 --- a/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c +++ b/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c @@ -10,7 +10,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [1] = LAYOUT_60_ansi_split_bs_rshift( _______, 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, - RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + RESET, RGB_TOG,RGB_MOD,_______, KC_F16, KC_F17,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______,_______,TG(0),_______), diff --git a/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c index 26d63626d918..b5337182f606 100644 --- a/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c +++ b/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c @@ -10,7 +10,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [1] = LAYOUT_60_ansi_split_bs_rshift( _______, 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, - RESET, RGB_TOG,RGB_MOD,_______, KC_F13, KC_F14,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, + RESET, RGB_TOG,RGB_MOD,_______, KC_F16, KC_F17,_______,_______,_______,_______,_______,KC_PGUP,KC_PGDN,_______, _______, _______,_______,_______,_______,_______,KC_LEFT,KC_DOWN, KC_UP,KC_RIGHT,KC_HOME, KC_END,_______, _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______,_______, _______, _______,_______, TG(0),_______), From 0b921f581d45aefd3d65217432e1495ad83943aa Mon Sep 17 00:00:00 2001 From: yulei Date: Wed, 9 Sep 2020 15:22:11 +0800 Subject: [PATCH 12/13] Apply suggestions from code review Co-authored-by: James Young <18669334+noroadsleft@users.noreply.github.com> --- keyboards/inett_studio/sqx/hotswap/hotswap.h | 8 ++-- .../inett_studio/sqx/universal/universal.h | 48 +++++++++---------- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h index ad1e1410dcd6..c1668b19e3ca 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.h +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -11,10 +11,10 @@ // The second converts the arguments into a two-dimensional array #define LAYOUT_60_tsangan_hhkb( \ 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, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ - k40, k42, k43, k47, k49, k4a, k4b \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index f662a760f104..31ad86e29697 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -11,10 +11,10 @@ // The second converts the arguments into a two-dimensional array #define LAYOUT_60_ansi( \ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, \ - k40, k42, k43, k47, k48, k49, k4a, k4b \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, \ + k40, k42, k43, k47, k48, k49, k4a, k4b \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, KC_NO, k0e}, \ @@ -26,10 +26,10 @@ #define LAYOUT_60_iso( \ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, \ - k20, 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,\ - k40, k42, k43, k47, k48, k49, k4a, k4b \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, \ + k20, 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, \ + k40, k42, k43, k47, k48, k49, k4a, k4b \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, KC_NO, k0e}, \ @@ -41,10 +41,10 @@ #define LAYOUT_60_ansi_tsangan_split_rshift( \ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0e, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ - k40, k42, k43, k47, k49, k4a, k4b \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, KC_NO, k0e}, \ @@ -56,10 +56,10 @@ #define LAYOUT_60_hhkb( \ 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, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ - k42, k43, k47, k49, k4a \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k42, k43, k47, k49, k4a \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ @@ -70,10 +70,10 @@ } #define LAYOUT_60_tsangan_hhkb( \ 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, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ - k40, k42, k43, k47, k49, k4a, k4b \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k49, k4a, k4b \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ @@ -85,10 +85,10 @@ #define LAYOUT_60_ansi_split_bs_rshift( \ 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, k1e, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ - k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ - k40, k42, k43, k47, k48, k49, k4a, k4b \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1e, \ + k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2e, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ + k40, k42, k43, k47, k48, k49, k4a, k4b \ ) \ { \ {k00, k01, k02, k03, k04, k05, k06, k08, k09, k0a, k0b, k0c, k0d, k0e}, \ From d734e9c38e6033c266a122fcb0a13f0aa3666824 Mon Sep 17 00:00:00 2001 From: Lei Yu Date: Wed, 9 Sep 2020 15:47:49 +0800 Subject: [PATCH 13/13] add license header --- keyboards/inett_studio/sqx/hotswap/config.h | 14 ++++++++++++++ keyboards/inett_studio/sqx/hotswap/hotswap.c | 15 +++++++++++++++ keyboards/inett_studio/sqx/hotswap/hotswap.h | 14 ++++++++++++++ .../sqx/hotswap/keymaps/default/keymap.c | 17 +++++++++++++++++ .../sqx/hotswap/keymaps/via/keymap.c | 17 +++++++++++++++++ keyboards/inett_studio/sqx/universal/config.h | 14 ++++++++++++++ .../sqx/universal/keymaps/default/keymap.c | 17 +++++++++++++++++ .../sqx/universal/keymaps/via/keymap.c | 17 +++++++++++++++++ .../inett_studio/sqx/universal/universal.c | 15 +++++++++++++++ .../inett_studio/sqx/universal/universal.h | 14 ++++++++++++++ 10 files changed, 154 insertions(+) diff --git a/keyboards/inett_studio/sqx/hotswap/config.h b/keyboards/inett_studio/sqx/hotswap/config.h index e698f9efc8cc..a59ad3e7e3f6 100644 --- a/keyboards/inett_studio/sqx/hotswap/config.h +++ b/keyboards/inett_studio/sqx/hotswap/config.h @@ -1,6 +1,20 @@ /** * config.h * + Copyright 2020 astro + + 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 . */ #pragma once diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.c b/keyboards/inett_studio/sqx/hotswap/hotswap.c index 0cd0027dcd8f..773b0b0b0a78 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.c +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.c @@ -1,5 +1,20 @@ /** * @file hotswap.c + * + Copyright 2020 astro + + 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 . */ #include "hotswap.h" diff --git a/keyboards/inett_studio/sqx/hotswap/hotswap.h b/keyboards/inett_studio/sqx/hotswap/hotswap.h index c1668b19e3ca..b879f7aaaf89 100644 --- a/keyboards/inett_studio/sqx/hotswap/hotswap.h +++ b/keyboards/inett_studio/sqx/hotswap/hotswap.h @@ -1,6 +1,20 @@ /** * @file hotswap.h * + Copyright 2020 astro + + 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 . */ #pragma once diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c index 96344d90430d..0e814cc98cb9 100644 --- a/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/default/keymap.c @@ -1,3 +1,20 @@ +/* +Copyright 2020 astro + +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 . +*/ + #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { diff --git a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c index b95620567539..d9258169fa66 100644 --- a/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c +++ b/keyboards/inett_studio/sqx/hotswap/keymaps/via/keymap.c @@ -1,3 +1,20 @@ +/* +Copyright 2020 astro + +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 . +*/ + #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { diff --git a/keyboards/inett_studio/sqx/universal/config.h b/keyboards/inett_studio/sqx/universal/config.h index fff043c9893e..a4a5b42c4d6e 100644 --- a/keyboards/inett_studio/sqx/universal/config.h +++ b/keyboards/inett_studio/sqx/universal/config.h @@ -1,6 +1,20 @@ /** * config.h * + Copyright 2020 astro + + 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 . */ #pragma once diff --git a/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c b/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c index 905813d979a9..bd2869e247d6 100644 --- a/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c +++ b/keyboards/inett_studio/sqx/universal/keymaps/default/keymap.c @@ -1,3 +1,20 @@ +/* +Copyright 2020 astro + +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 . +*/ + #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { diff --git a/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c b/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c index b5337182f606..c58090d9d724 100644 --- a/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c +++ b/keyboards/inett_studio/sqx/universal/keymaps/via/keymap.c @@ -1,3 +1,20 @@ +/* +Copyright 2020 astro + +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 . +*/ + #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { diff --git a/keyboards/inett_studio/sqx/universal/universal.c b/keyboards/inett_studio/sqx/universal/universal.c index f6b7d9f70557..f0f7f88f7a53 100644 --- a/keyboards/inett_studio/sqx/universal/universal.c +++ b/keyboards/inett_studio/sqx/universal/universal.c @@ -1,5 +1,20 @@ /** * @file universal.c + * + Copyright 2020 astro + + 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 . */ #include "universal.h" diff --git a/keyboards/inett_studio/sqx/universal/universal.h b/keyboards/inett_studio/sqx/universal/universal.h index 31ad86e29697..b2df37ecc4be 100644 --- a/keyboards/inett_studio/sqx/universal/universal.h +++ b/keyboards/inett_studio/sqx/universal/universal.h @@ -1,6 +1,20 @@ /** * @file universal.h * + Copyright 2020 astro + + 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 . */ #pragma once