From 6f386ca6ae82be9212700dbfeb73517d077bef5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 28 Jan 2019 09:04:47 +0100 Subject: Change how desktop commands work --- keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c | 8 ++++---- keyboards/whitefox/keymaps/konstantin/keymap.c | 4 ++-- users/konstantin/konstantin.c | 12 ++++++++++++ users/konstantin/konstantin.h | 7 +++++++ users/konstantin/tap_dance.c | 2 +- users/konstantin/tap_dance.h | 6 ++---- 6 files changed, 28 insertions(+), 11 deletions(-) diff --git a/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c b/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c index fa324be9a1..707515abb4 100644 --- a/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c +++ b/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c @@ -58,7 +58,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┤ * │ │Mut│VoD│VoU│Ply│Prv│Nxt│MW←│MW→│M4 │M5 │ │ │ * └─────┬──┴┬──┴──┬┴───┴───┴───┴───┴───┴───┴──┬┴───┴┬───┬─┴───┘ - * │ │ │ MW↓ │MAcl2│ │ + * │DPR│DstNA│ MW↓ │MAcl2│ │ * └───┴─────┴───────────────────────────┴─────┴───┘ */ [L_FN] = LAYOUT( @@ -66,7 +66,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, KC_HOME, KC_UP, KC_END, KC_PGUP, _______, _______, _______, _______, KC_BTN1, KC_MS_U, KC_BTN2, KC_BTN3, KC_DEL, _______, KC_LEFT, KC_DOWN, KC_RGHT, KC_PGDN, _______, _______, _______, KC_WH_U, KC_MS_L, KC_MS_D, KC_MS_R, _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, KC_MPLY, KC_MPRV, KC_MNXT, KC_WH_L, KC_WH_R, KC_BTN4, KC_BTN5, _______, _______, - XXXXXXX, _______, _______, KC_WH_D, KC_ACL2, _______, XXXXXXX + XXXXXXX, DST_P_R, DST_N_A, KC_WH_D, KC_ACL2, _______, XXXXXXX ), /* RCtrl layer @@ -79,7 +79,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┤ * │ │ │ │ │ │ │ │ │ │ │ │ │ │ * └─────┬──┴┬──┴──┬┴───┴───┴───┴───┴───┴───┴──┬┴───┴┬───┬─┴───┘ - * │Dst│Dstp←│ │Dstp→│ │ + * │DtR│DstA │ │ │ │ * └───┴─────┴───────────────────────────┴─────┴───┘ */ [L_RCTRL] = LAYOUT( @@ -87,6 +87,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, TOP, MV_UP, BOTTOM, PRV_TAB, _______, _______, _______, _______, _______, _______, _______, _______, CLEAR, _______, MV_LEFT, MV_DOWN, MV_RGHT, NXT_TAB, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - XXXXXXX, DESKTOP, DSKTP_L, _______, DSKTP_R, _______, XXXXXXX + XXXXXXX, DST_RMV, DST_ADD, _______, _______, _______, XXXXXXX ), }; diff --git a/keyboards/whitefox/keymaps/konstantin/keymap.c b/keyboards/whitefox/keymaps/konstantin/keymap.c index e37097361a..a56d0a43e4 100644 --- a/keyboards/whitefox/keymaps/konstantin/keymap.c +++ b/keyboards/whitefox/keymaps/konstantin/keymap.c @@ -33,7 +33,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┤ * │ │MA0│MA2│MW←│MW→│ │ │ │VoD│VoU│Mut│ App │PgU│Btm│ * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬─┬───┼───┼───┤ - * │ │Dstp│Dst←│ MW↓ │Dst→│ │ │Hom│PgD│End│ + * │ │DtPR│DtNA│ MW↓ │ │ │ │Hom│PgD│End│ * └────┴────┴────┴────────────────────────┴────┴────┘ └───┴───┴───┘ */ [L_FN] = LAYOUT_truefox( \ @@ -41,7 +41,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, UC_MOD, _______, KC_MSTP, KC_MPLY, KC_MPRV, KC_MNXT, CLEAR, KC_INS, \ _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, TOP, \ _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, KC_APP, KC_PGUP, BOTTOM, \ - _______, DESKTOP, DSKTP_L, KC_WH_D, DSKTP_R, _______, KC_HOME, KC_PGDN, KC_END \ + _______, DST_P_R, DST_N_A, KC_WH_D, _______, _______, KC_HOME, KC_PGDN, KC_END \ ), /* Numpad layer diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index 47596279c3..bf92a503e6 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -28,6 +28,18 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { } return false; + case DST_P_R: + (record->event.pressed ? register_code16 : unregister_code16)( + (get_mods() & MOD_MASK_CTRL) ? DST_RMV : DST_PRV + ); + return false; + + case DST_N_A: + (record->event.pressed ? register_code16 : unregister_code16)( + (get_mods() & MOD_MASK_CTRL) ? DST_ADD : DST_NXT + ); + return false; + #ifdef LAYER_FN static bool fn_lock; diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index f67f9f1b7e..3ca4f401e0 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -23,6 +23,11 @@ #define PRV_TAB LCTL(KC_PGUP) #define NXT_TAB LCTL(KC_PGDN) +#define DST_ADD LCTL(LGUI(KC_D)) +#define DST_RMV LCTL(LGUI(KC_F4)) +#define DST_PRV LCTL(LGUI(KC_LEFT)) +#define DST_NXT LCTL(LGUI(KC_RGHT)) + #define LCT_CPS LCTL_T(KC_CAPS) #ifdef SEND_STRING_CLEAN @@ -37,6 +42,8 @@ enum keycodes_user { CLEAR = SAFE_RANGE, + DST_P_R, + DST_N_A, #ifdef LAYER_NUMPAD NUMPAD, #endif diff --git a/users/konstantin/tap_dance.c b/users/konstantin/tap_dance.c index b13f33c024..e3f1729467 100644 --- a/users/konstantin/tap_dance.c +++ b/users/konstantin/tap_dance.c @@ -82,7 +82,7 @@ void td_lsft_fn_reset(qk_tap_dance_state_t *state, void *user_data) { } qk_tap_dance_action_t tap_dance_actions[] = { - [TD_DESKTOP] = ACTION_TAP_DANCE_DOUBLE(LCTL(LGUI(KC_D)), LCTL(LGUI(KC_F4))), // Add/close virtual desktop + [TD_DST_A_R] = ACTION_TAP_DANCE_DOUBLE(DST_ADD, DST_RMV), [TD_RAL_LAL] = ACTION_TAP_DANCE_DOUBLE_MODS(KC_RALT, KC_LALT), [TD_RAL_RGU] = ACTION_TAP_DANCE_DOUBLE_MODS(KC_RALT, KC_RGUI), diff --git a/users/konstantin/tap_dance.h b/users/konstantin/tap_dance.h index 922a635141..1757e9b113 100644 --- a/users/konstantin/tap_dance.h +++ b/users/konstantin/tap_dance.h @@ -2,9 +2,7 @@ #include "quantum.h" -#define DESKTOP TD(TD_DESKTOP) -#define DSKTP_L LCTL(LGUI(KC_LEFT)) -#define DSKTP_R LCTL(LGUI(KC_RGHT)) +#define DST_A_R TD(TD_DST_A_R) #define RAL_LAL TD(TD_RAL_LAL) #define RAL_RGU TD(TD_RAL_RGU) @@ -14,7 +12,7 @@ #define LSFT_FN TD(TD_LSFT_FN) enum tap_dance { - TD_DESKTOP, + TD_DST_A_R, TD_RAL_LAL, TD_RAL_RGU, -- cgit v1.2.3 From 6695c874fb8660989a129691bbffc6225be67362 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 28 Jan 2019 09:05:35 +0100 Subject: Add DST_MOD_MASK as a config option --- users/konstantin/konstantin.c | 4 ++-- users/konstantin/konstantin.h | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index bf92a503e6..5861574cba 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -30,13 +30,13 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { case DST_P_R: (record->event.pressed ? register_code16 : unregister_code16)( - (get_mods() & MOD_MASK_CTRL) ? DST_RMV : DST_PRV + (get_mods() & DST_MOD_MASK) ? DST_RMV : DST_PRV ); return false; case DST_N_A: (record->event.pressed ? register_code16 : unregister_code16)( - (get_mods() & MOD_MASK_CTRL) ? DST_ADD : DST_NXT + (get_mods() & DST_MOD_MASK) ? DST_ADD : DST_NXT ); return false; diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index 3ca4f401e0..a649e4f79d 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -27,6 +27,9 @@ #define DST_RMV LCTL(LGUI(KC_F4)) #define DST_PRV LCTL(LGUI(KC_LEFT)) #define DST_NXT LCTL(LGUI(KC_RGHT)) +#ifndef DST_MOD_MASK + #define DST_MOD_MASK MOD_MASK_CTRL +#endif #define LCT_CPS LCTL_T(KC_CAPS) -- cgit v1.2.3 From f2543c3b9b63433f8f5f7aec9531f7ebddcce4fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Tue, 29 Jan 2019 00:37:10 +0100 Subject: =?UTF-8?q?DST=5FRMV=20=E2=86=92=20DST=5FREM?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c | 2 +- users/konstantin/konstantin.c | 2 +- users/konstantin/konstantin.h | 2 +- users/konstantin/tap_dance.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c b/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c index 707515abb4..b1e8bf0581 100644 --- a/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c +++ b/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c @@ -87,6 +87,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, TOP, MV_UP, BOTTOM, PRV_TAB, _______, _______, _______, _______, _______, _______, _______, _______, CLEAR, _______, MV_LEFT, MV_DOWN, MV_RGHT, NXT_TAB, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - XXXXXXX, DST_RMV, DST_ADD, _______, _______, _______, XXXXXXX + XXXXXXX, DST_REM, DST_ADD, _______, _______, _______, XXXXXXX ), }; diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index 5861574cba..686ff32ecc 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -30,7 +30,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { case DST_P_R: (record->event.pressed ? register_code16 : unregister_code16)( - (get_mods() & DST_MOD_MASK) ? DST_RMV : DST_PRV + (get_mods() & DST_MOD_MASK) ? DST_REM : DST_PRV ); return false; diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index a649e4f79d..48bd26cd59 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -24,7 +24,7 @@ #define NXT_TAB LCTL(KC_PGDN) #define DST_ADD LCTL(LGUI(KC_D)) -#define DST_RMV LCTL(LGUI(KC_F4)) +#define DST_REM LCTL(LGUI(KC_F4)) #define DST_PRV LCTL(LGUI(KC_LEFT)) #define DST_NXT LCTL(LGUI(KC_RGHT)) #ifndef DST_MOD_MASK diff --git a/users/konstantin/tap_dance.c b/users/konstantin/tap_dance.c index e3f1729467..81f2d42e1f 100644 --- a/users/konstantin/tap_dance.c +++ b/users/konstantin/tap_dance.c @@ -82,7 +82,7 @@ void td_lsft_fn_reset(qk_tap_dance_state_t *state, void *user_data) { } qk_tap_dance_action_t tap_dance_actions[] = { - [TD_DST_A_R] = ACTION_TAP_DANCE_DOUBLE(DST_ADD, DST_RMV), + [TD_DST_A_R] = ACTION_TAP_DANCE_DOUBLE(DST_ADD, DST_REM), [TD_RAL_LAL] = ACTION_TAP_DANCE_DOUBLE_MODS(KC_RALT, KC_LALT), [TD_RAL_RGU] = ACTION_TAP_DANCE_DOUBLE_MODS(KC_RALT, KC_RGUI), -- cgit v1.2.3 From 012c5ef9bdccc8d752481c3c1d35a0ef47b075c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Thu, 31 Jan 2019 16:02:24 +0100 Subject: Update custom SEND_STRING --- users/konstantin/konstantin.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index 48bd26cd59..989854c2e6 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -35,11 +35,11 @@ #ifdef SEND_STRING_CLEAN #undef SEND_STRING - #define SEND_STRING(...) { \ - uint8_t ss_mods = get_mods(); \ - clear_mods(); \ - send_string_P(PSTR(__VA_ARGS__)); \ - set_mods(ss_mods); \ + #define SEND_STRING(string) { \ + uint8_t ss_mods = get_mods(); \ + clear_mods(); \ + send_string_P(PSTR(string)); \ + set_mods(ss_mods); \ } #endif -- cgit v1.2.3 From db1ace5426ab08842cec23e0da190ab222de6088 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Fri, 11 Jan 2019 07:55:47 +0100 Subject: Add melody96:konstantin keymap --- keyboards/melody96/keymaps/konstantin/config.h | 3 ++ keyboards/melody96/keymaps/konstantin/keymap.c | 52 ++++++++++++++++++++++++++ keyboards/melody96/keymaps/konstantin/rules.mk | 1 + 3 files changed, 56 insertions(+) create mode 100644 keyboards/melody96/keymaps/konstantin/config.h create mode 100644 keyboards/melody96/keymaps/konstantin/keymap.c create mode 100644 keyboards/melody96/keymaps/konstantin/rules.mk diff --git a/keyboards/melody96/keymaps/konstantin/config.h b/keyboards/melody96/keymaps/konstantin/config.h new file mode 100644 index 0000000000..4b511eb848 --- /dev/null +++ b/keyboards/melody96/keymaps/konstantin/config.h @@ -0,0 +1,3 @@ +#pragma once + +#define LAYER_FN diff --git a/keyboards/melody96/keymaps/konstantin/keymap.c b/keyboards/melody96/keymaps/konstantin/keymap.c new file mode 100644 index 0000000000..df93cd702b --- /dev/null +++ b/keyboards/melody96/keymaps/konstantin/keymap.c @@ -0,0 +1,52 @@ +#include QMK_KEYBOARD_H +#include "konstantin.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base layer + * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐ + * │Esc│F1 │F2 │F3 │F4 │F5 │F6 │F7 │F8 │F9 │F10│F11│F12│PSc│Ins│Hom│End│PgU│PgD│ + * ├───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┤ + * │ ` │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ - │ = │ \ │Del│NLk│P/ │P* │P- │ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┼───┼───┼───┼───┤ + * │ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │Bspc │P7 │P8 │P9 │ │ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤P+ │ + * │FnCaps│ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ Enter │P4 │P5 │P6 │ │ + * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┼───┼───┼───┤ + * │LSft│RAG│ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │RShift│ ↑ │P1 │P2 │P3 │ │ + * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┼───┼───┤PEn│ + * │LCtl│LGui│LAlt│ Space │RAlGu│RCtrl│ ← │ ↓ │ → │P0 │P. │ │ + * └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┴───┴───┴───┘ + */ + [L_BASE] = LAYOUT( \ + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_INS, KC_HOME, KC_END, KC_PGUP, KC_PGDN, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, KC_DEL, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSPC, KC_P7, KC_P8, KC_P9, XXXXXXX, + FN_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_P4, KC_P5, KC_P6, KC_PPLS, + KC_LSFT, RAL_RGU, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, XXXXXXX, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, RAL_RGU, XXXXXXX, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT, KC_PENT + ), + + /* Function layer + * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐ + * │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + * ├───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┤ + * │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┼───┼───┼───┼───┤ + * │ M4 │M2 │M↑ │M1 │M3 │M5 │ │ │ │ │ │ │ │Clear│ │ │ │ │ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤ │ + * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │ │ │ │ │ + * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┼───┼───┼───┤ + * │ │ │MA0│MA2│MW←│MW→│ │ │ │VoD│VoU│Mut│ │PgU│ │ │ │ │ + * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┼───┼───┤ │ + * │ │DtPR│DtNA│ MW↓ │ │ App │Hom│PgD│End│ │ │ │ + * └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┴───┴───┴───┘ + */ + [L_FN] = LAYOUT( \ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, _______, _______, _______, _______, _______, _______, CLEAR, _______, _______, _______, XXXXXXX, + _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, KC_PGUP, _______, _______, _______, XXXXXXX, + _______, DST_P_R, DST_N_A, KC_WH_D, _______, XXXXXXX, KC_APP, KC_HOME, KC_PGDN, KC_END, _______, _______, _______ + ), +}; diff --git a/keyboards/melody96/keymaps/konstantin/rules.mk b/keyboards/melody96/keymaps/konstantin/rules.mk new file mode 100644 index 0000000000..7b30c0beff --- /dev/null +++ b/keyboards/melody96/keymaps/konstantin/rules.mk @@ -0,0 +1 @@ +BACKLIGHT_ENABLE = no -- cgit v1.2.3 From ef189da2439d8f0cf20a83756400a38310c1caeb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Sat, 9 Feb 2019 21:45:25 +0100 Subject: Move feature flags from userspace into keyboard rules --- keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk | 9 +++++++++ keyboards/melody96/keymaps/konstantin/rules.mk | 9 +++++++++ keyboards/whitefox/keymaps/konstantin/rules.mk | 9 +++++++++ users/konstantin/rules.mk | 9 --------- 4 files changed, 27 insertions(+), 9 deletions(-) diff --git a/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk b/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk index a45a631dc0..38ccda621a 100644 --- a/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk +++ b/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk @@ -1,2 +1,11 @@ +BOOTMAGIC_ENABLE = no +COMMAND_ENABLE = yes +CONSOLE_ENABLE = yes +EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = yes +NKRO_ENABLE = yes +TAP_DANCE_ENABLE = yes +UNICODE_ENABLE = yes + BACKLIGHT_ENABLE = no RGBLIGHT_ENABLE = no diff --git a/keyboards/melody96/keymaps/konstantin/rules.mk b/keyboards/melody96/keymaps/konstantin/rules.mk index 7b30c0beff..c1d4c9a037 100644 --- a/keyboards/melody96/keymaps/konstantin/rules.mk +++ b/keyboards/melody96/keymaps/konstantin/rules.mk @@ -1 +1,10 @@ +BOOTMAGIC_ENABLE = no +COMMAND_ENABLE = yes +CONSOLE_ENABLE = no +EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = yes +NKRO_ENABLE = yes +TAP_DANCE_ENABLE = yes +UNICODE_ENABLE = yes + BACKLIGHT_ENABLE = no diff --git a/keyboards/whitefox/keymaps/konstantin/rules.mk b/keyboards/whitefox/keymaps/konstantin/rules.mk index 1302f14ca8..14a29380ce 100644 --- a/keyboards/whitefox/keymaps/konstantin/rules.mk +++ b/keyboards/whitefox/keymaps/konstantin/rules.mk @@ -1,2 +1,11 @@ +BOOTMAGIC_ENABLE = no +COMMAND_ENABLE = yes +CONSOLE_ENABLE = yes +EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = yes +NKRO_ENABLE = yes +TAP_DANCE_ENABLE = yes +UNICODE_ENABLE = yes + BACKLIGHT_ENABLE = no VISUALIZER_ENABLE = no diff --git a/users/konstantin/rules.mk b/users/konstantin/rules.mk index d2522b9523..4af256e1eb 100644 --- a/users/konstantin/rules.mk +++ b/users/konstantin/rules.mk @@ -1,12 +1,3 @@ -BOOTMAGIC_ENABLE = no -COMMAND_ENABLE = yes -CONSOLE_ENABLE = yes -EXTRAKEY_ENABLE = yes -MOUSEKEY_ENABLE = yes -NKRO_ENABLE = yes -TAP_DANCE_ENABLE = yes -UNICODE_ENABLE = yes - SRC += konstantin.c ifeq ($(strip $(TAP_DANCE_ENABLE)), yes) SRC += tap_dance.c -- cgit v1.2.3 From ea23035c53162ee88ca02533d49cb931fdce3bb2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 11 Feb 2019 22:03:14 +0100 Subject: Use "Vo-", "Vo+" instead of "VoD", "VoU" in keymap comments --- keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c | 2 +- keyboards/melody96/keymaps/konstantin/keymap.c | 2 +- keyboards/whitefox/keymaps/konstantin/keymap.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c b/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c index b1e8bf0581..3404cc4e49 100644 --- a/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c +++ b/keyboards/kbdfans/kbd6x/keymaps/konstantin/keymap.c @@ -56,7 +56,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┤ * │ │ ← │ ↓ │ → │PgD│ │ │ │MW↑│M← │M↓ │M→ │ │ * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┤ - * │ │Mut│VoD│VoU│Ply│Prv│Nxt│MW←│MW→│M4 │M5 │ │ │ + * │ │Mut│Vo-│Vo+│Ply│Prv│Nxt│MW←│MW→│M4 │M5 │ │ │ * └─────┬──┴┬──┴──┬┴───┴───┴───┴───┴───┴───┴──┬┴───┴┬───┬─┴───┘ * │DPR│DstNA│ MW↓ │MAcl2│ │ * └───┴─────┴───────────────────────────┴─────┴───┘ diff --git a/keyboards/melody96/keymaps/konstantin/keymap.c b/keyboards/melody96/keymaps/konstantin/keymap.c index df93cd702b..2f05e288b0 100644 --- a/keyboards/melody96/keymaps/konstantin/keymap.c +++ b/keyboards/melody96/keymaps/konstantin/keymap.c @@ -36,7 +36,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤ │ * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │ │ │ │ │ * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┼───┼───┼───┤ - * │ │ │MA0│MA2│MW←│MW→│ │ │ │VoD│VoU│Mut│ │PgU│ │ │ │ │ + * │ │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ │PgU│ │ │ │ │ * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┼───┼───┤ │ * │ │DtPR│DtNA│ MW↓ │ │ App │Hom│PgD│End│ │ │ │ * └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┴───┴───┴───┘ diff --git a/keyboards/whitefox/keymaps/konstantin/keymap.c b/keyboards/whitefox/keymaps/konstantin/keymap.c index a56d0a43e4..494300f2d6 100644 --- a/keyboards/whitefox/keymaps/konstantin/keymap.c +++ b/keyboards/whitefox/keymaps/konstantin/keymap.c @@ -31,7 +31,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┤ * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │Top│ * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┤ - * │ │MA0│MA2│MW←│MW→│ │ │ │VoD│VoU│Mut│ App │PgU│Btm│ + * │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ App │PgU│Btm│ * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬─┬───┼───┼───┤ * │ │DtPR│DtNA│ MW↓ │ │ │ │Hom│PgD│End│ * └────┴────┴────┴────────────────────────┴────┴────┘ └───┴───┴───┘ -- cgit v1.2.3 From d163b22dfbb4a9092e3b7fc2b18a679e03080a58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 11 Feb 2019 22:04:59 +0100 Subject: Add RGB controls and numpad Unicode to Melody96 keymap --- keyboards/melody96/keymaps/konstantin/keymap.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/keyboards/melody96/keymaps/konstantin/keymap.c b/keyboards/melody96/keymaps/konstantin/keymap.c index 2f05e288b0..11b687b55e 100644 --- a/keyboards/melody96/keymaps/konstantin/keymap.c +++ b/keyboards/melody96/keymaps/konstantin/keymap.c @@ -30,23 +30,23 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐ * │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ * ├───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┤ - * │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + * │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │RTg│ ÷ │ × │ − │ * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┼───┼───┼───┼───┤ - * │ M4 │M2 │M↑ │M1 │M3 │M5 │ │ │ │ │ │ │ │Clear│ │ │ │ │ + * │ M4 │M2 │M↑ │M1 │M3 │M5 │ │ │ │ │ │ │ │Clear│RH+│RS+│RV+│ │ * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤ │ - * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │ │ │ │ │ + * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │RH-│RS-│RV-│ │ * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┼───┼───┼───┤ - * │ │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ │PgU│ │ │ │ │ - * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┼───┼───┤ │ - * │ │DtPR│DtNA│ MW↓ │ │ App │Hom│PgD│End│ │ │ │ + * │ │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ │PgU│RMB│RMK│RMG│ │ + * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┼───┼───┤RMP│ + * │ │DtPR│DtNA│ MW↓ │ │ App │Hom│PgD│End│RMR│RMF│ │ * └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┴───┴───┴───┘ */ [L_FN] = LAYOUT( \ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, _______, _______, _______, _______, _______, _______, CLEAR, _______, _______, _______, XXXXXXX, - _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, KC_PGUP, _______, _______, _______, XXXXXXX, - _______, DST_P_R, DST_N_A, KC_WH_D, _______, XXXXXXX, KC_APP, KC_HOME, KC_PGDN, KC_END, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_TOG, DIVIDE, TIMES, MINUS, + KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, _______, _______, _______, _______, _______, _______, CLEAR, RGB_HUI, RGB_SAI, RGB_VAI, XXXXXXX, + _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_SAD, RGB_VAD, _______, + _______, _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, KC_PGUP, RGB_M_B, RGB_M_K, RGB_M_G, XXXXXXX, + _______, DST_P_R, DST_N_A, KC_WH_D, _______, XXXXXXX, KC_APP, KC_HOME, KC_PGDN, KC_END, RGB_RMOD,RGB_MOD, RGB_M_P ), }; -- cgit v1.2.3 From 2f07627a5dd38ab1370804f4feb1972250928803 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 11 Feb 2019 22:41:51 +0100 Subject: Add RGB_SET keycode to Melody96 and RGB files to userspace --- keyboards/melody96/keymaps/konstantin/keymap.c | 23 +++++++++++++++++++---- users/konstantin/konstantin.h | 3 +++ users/konstantin/rgb.c | 3 +++ users/konstantin/rgb.h | 17 +++++++++++++++++ users/konstantin/rules.mk | 3 +++ 5 files changed, 45 insertions(+), 4 deletions(-) create mode 100644 users/konstantin/rgb.c create mode 100644 users/konstantin/rgb.h diff --git a/keyboards/melody96/keymaps/konstantin/keymap.c b/keyboards/melody96/keymaps/konstantin/keymap.c index 11b687b55e..4df856f8fb 100644 --- a/keyboards/melody96/keymaps/konstantin/keymap.c +++ b/keyboards/melody96/keymaps/konstantin/keymap.c @@ -1,6 +1,21 @@ #include QMK_KEYBOARD_H #include "konstantin.h" +enum keycodes_keymap { + RGB_SET = RANGE_KEYMAP, +}; + +bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case RGB_SET: + rgblight_sethsv(GODSPEED_BLUE.h, GODSPEED_BLUE.s, GODSPEED_BLUE.v); + return false; + + default: + return true; + } +} + const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Base layer * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐ @@ -32,8 +47,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┤ * │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │RTg│ ÷ │ × │ − │ * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┼───┼───┼───┼───┤ - * │ M4 │M2 │M↑ │M1 │M3 │M5 │ │ │ │ │ │ │ │Clear│RH+│RS+│RV+│ │ - * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤ │ + * │ M4 │M2 │M↑ │M1 │M3 │M5 │ │UCM│ │ │ │ │ │Clear│RH+│RS+│RV+│ │ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤RSt│ * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │RH-│RS-│RV-│ │ * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┼───┼───┼───┤ * │ │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ │PgU│RMB│RMK│RMG│ │ @@ -44,8 +59,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [L_FN] = LAYOUT( \ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_TOG, DIVIDE, TIMES, MINUS, - KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, _______, _______, _______, _______, _______, _______, CLEAR, RGB_HUI, RGB_SAI, RGB_VAI, XXXXXXX, - _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_SAD, RGB_VAD, _______, + KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, UC_MOD, _______, _______, _______, _______, _______, CLEAR, RGB_HUI, RGB_SAI, RGB_VAI, XXXXXXX, + _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_SAD, RGB_VAD, RGB_SET, _______, _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, KC_PGUP, RGB_M_B, RGB_M_K, RGB_M_G, XXXXXXX, _______, DST_P_R, DST_N_A, KC_WH_D, _______, XXXXXXX, KC_APP, KC_HOME, KC_PGDN, KC_END, RGB_RMOD,RGB_MOD, RGB_M_P ), diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index 989854c2e6..d8b00c4c89 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -1,6 +1,9 @@ #pragma once #include "quantum.h" +#if defined(RGBLIGHT_ENABLE) || defined(RGBMATRIX_ENABLE) + #include "rgb.h" +#endif #ifdef TAP_DANCE_ENABLE #include "tap_dance.h" #endif diff --git a/users/konstantin/rgb.c b/users/konstantin/rgb.c new file mode 100644 index 0000000000..a09057d282 --- /dev/null +++ b/users/konstantin/rgb.c @@ -0,0 +1,3 @@ +#include "rgb.h" + +const hsv_t GODSPEED_BLUE = { .h = 214, .s = 17, .v = 73 }; diff --git a/users/konstantin/rgb.h b/users/konstantin/rgb.h new file mode 100644 index 0000000000..2ea10c67a7 --- /dev/null +++ b/users/konstantin/rgb.h @@ -0,0 +1,17 @@ +#pragma once + +#include "quantum.h" + +typedef struct { + uint16_t h; + uint8_t s; + uint8_t v; +} hsv_t; + +typedef struct { + uint8_t r; + uint8_t g; + uint8_t b; +} rgb_t; + +extern const hsv_t GODSPEED_BLUE; diff --git a/users/konstantin/rules.mk b/users/konstantin/rules.mk index 4af256e1eb..8913e57558 100644 --- a/users/konstantin/rules.mk +++ b/users/konstantin/rules.mk @@ -1,4 +1,7 @@ SRC += konstantin.c +ifneq (,$(filter yes,$(RGBLIGHT_ENABLE) $(RGB_MATRIX_ENABLE))) # if either is yes + SRC += rgb.c +endif ifeq ($(strip $(TAP_DANCE_ENABLE)), yes) SRC += tap_dance.c endif -- cgit v1.2.3 From ddb0f39ebf317c7a23c69ed45efb1882746a01b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 11 Feb 2019 23:21:41 +0100 Subject: Generate UNICODE and UNICODEMAP constants using macros --- users/konstantin/konstantin.h | 2 +- users/konstantin/rules.mk | 3 +++ users/konstantin/unicode.c | 7 +++++++ users/konstantin/unicode.h | 37 ++++++++++++++++++++++++++++++------- 4 files changed, 41 insertions(+), 8 deletions(-) create mode 100644 users/konstantin/unicode.c diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index d8b00c4c89..c32d674e8c 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -7,7 +7,7 @@ #ifdef TAP_DANCE_ENABLE #include "tap_dance.h" #endif -#ifdef UNICODE_ENABLE +#if defined(UNICODE_ENABLE) || defined(UNICODEMAP_ENABLE) #include "unicode.h" #endif diff --git a/users/konstantin/rules.mk b/users/konstantin/rules.mk index 8913e57558..6bda030fb0 100644 --- a/users/konstantin/rules.mk +++ b/users/konstantin/rules.mk @@ -5,5 +5,8 @@ endif ifeq ($(strip $(TAP_DANCE_ENABLE)), yes) SRC += tap_dance.c endif +ifneq (,$(filter yes,$(UNICODE_ENABLE) $(UNICODEMAP_ENABLE))) # if either is yes + SRC += unicode.c +endif EXTRAFLAGS += -flto diff --git a/users/konstantin/unicode.c b/users/konstantin/unicode.c new file mode 100644 index 0000000000..3b6164bc51 --- /dev/null +++ b/users/konstantin/unicode.c @@ -0,0 +1,7 @@ +#include "unicode.h" + +#ifdef UNICODEMAP_ENABLE + const uint32_t PROGMEM unicode_map[] = { + FOREACH_UNICODE(X_ENTRY) + }; +#endif diff --git a/users/konstantin/unicode.h b/users/konstantin/unicode.h index 09af7e1c7f..d76f2a1700 100644 --- a/users/konstantin/unicode.h +++ b/users/konstantin/unicode.h @@ -2,10 +2,33 @@ #include "quantum.h" -#define COMMA UC(0x002C) -#define L_PAREN UC(0x0028) -#define R_PAREN UC(0x0029) -#define EQUALS UC(0x003D) -#define TIMES UC(0x00D7) -#define DIVIDE UC(0x00F7) -#define MINUS UC(0x2212) +#define FOREACH_UNICODE(M) \ + M(COMMA, 0x002C) \ + M(L_PAREN, 0x0028) \ + M(R_PAREN, 0x0029) \ + M(EQUALS, 0x003D) \ + M(TIMES, 0x00D7) \ + M(DIVIDE, 0x00F7) \ + M(MINUS, 0x2212) + +#define UC_KEYCODE(name, code) name = UC(code), + +#define X_NAME(name, code) X_ ## name, +#define X_ENTRY(name, code) [X_ ## name] = code, +#define X_KEYCODE(name, code) name = X(X_ ## name), + +#if defined(UNICODE_ENABLE) + enum unicode_keycodes { + FOREACH_UNICODE(UC_KEYCODE) + }; +#elif defined(UNICODEMAP_ENABLE) + enum unicode_names { + FOREACH_UNICODE(X_NAME) + }; + + extern const uint32_t PROGMEM unicode_map[]; + + enum unicode_keycodes { + FOREACH_UNICODE(X_KEYCODE) + }; +#endif -- cgit v1.2.3 From 7b11d740eaad1aade1a8d1914aab54f2720ab7ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Tue, 12 Feb 2019 00:18:52 +0100 Subject: Avoid collisions with X_* send string constants --- users/konstantin/unicode.c | 2 +- users/konstantin/unicode.h | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/users/konstantin/unicode.c b/users/konstantin/unicode.c index 3b6164bc51..44b5be6c91 100644 --- a/users/konstantin/unicode.c +++ b/users/konstantin/unicode.c @@ -2,6 +2,6 @@ #ifdef UNICODEMAP_ENABLE const uint32_t PROGMEM unicode_map[] = { - FOREACH_UNICODE(X_ENTRY) + FOREACH_UNICODE(UCM_ENTRY) }; #endif diff --git a/users/konstantin/unicode.h b/users/konstantin/unicode.h index d76f2a1700..6bb908e0e2 100644 --- a/users/konstantin/unicode.h +++ b/users/konstantin/unicode.h @@ -13,9 +13,9 @@ #define UC_KEYCODE(name, code) name = UC(code), -#define X_NAME(name, code) X_ ## name, -#define X_ENTRY(name, code) [X_ ## name] = code, -#define X_KEYCODE(name, code) name = X(X_ ## name), +#define UCM_NAME(name, code) UCM_ ## name, +#define UCM_ENTRY(name, code) [UCM_ ## name] = code, +#define UCM_KEYCODE(name, code) name = X(UCM_ ## name), #if defined(UNICODE_ENABLE) enum unicode_keycodes { @@ -23,12 +23,12 @@ }; #elif defined(UNICODEMAP_ENABLE) enum unicode_names { - FOREACH_UNICODE(X_NAME) + FOREACH_UNICODE(UCM_NAME) }; extern const uint32_t PROGMEM unicode_map[]; enum unicode_keycodes { - FOREACH_UNICODE(X_KEYCODE) + FOREACH_UNICODE(UCM_KEYCODE) }; #endif -- cgit v1.2.3 From 5a41c06cd7dcf04f5a27ac9b2fa95399c65367d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 18 Feb 2019 05:01:24 +0100 Subject: Switch to UNICODEMAP in keyboard rules --- keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk | 16 ++++++++-------- keyboards/melody96/keymaps/konstantin/rules.mk | 16 ++++++++-------- keyboards/whitefox/keymaps/konstantin/rules.mk | 16 ++++++++-------- 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk b/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk index 38ccda621a..4e485bf766 100644 --- a/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk +++ b/keyboards/kbdfans/kbd6x/keymaps/konstantin/rules.mk @@ -1,11 +1,11 @@ -BOOTMAGIC_ENABLE = no -COMMAND_ENABLE = yes -CONSOLE_ENABLE = yes -EXTRAKEY_ENABLE = yes -MOUSEKEY_ENABLE = yes -NKRO_ENABLE = yes -TAP_DANCE_ENABLE = yes -UNICODE_ENABLE = yes +BOOTMAGIC_ENABLE = no +COMMAND_ENABLE = yes +CONSOLE_ENABLE = yes +EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = yes +NKRO_ENABLE = yes +TAP_DANCE_ENABLE = yes +UNICODEMAP_ENABLE = yes BACKLIGHT_ENABLE = no RGBLIGHT_ENABLE = no diff --git a/keyboards/melody96/keymaps/konstantin/rules.mk b/keyboards/melody96/keymaps/konstantin/rules.mk index c1d4c9a037..47a859d089 100644 --- a/keyboards/melody96/keymaps/konstantin/rules.mk +++ b/keyboards/melody96/keymaps/konstantin/rules.mk @@ -1,10 +1,10 @@ -BOOTMAGIC_ENABLE = no -COMMAND_ENABLE = yes -CONSOLE_ENABLE = no -EXTRAKEY_ENABLE = yes -MOUSEKEY_ENABLE = yes -NKRO_ENABLE = yes -TAP_DANCE_ENABLE = yes -UNICODE_ENABLE = yes +BOOTMAGIC_ENABLE = no +COMMAND_ENABLE = yes +CONSOLE_ENABLE = no +EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = yes +NKRO_ENABLE = yes +TAP_DANCE_ENABLE = yes +UNICODEMAP_ENABLE = yes BACKLIGHT_ENABLE = no diff --git a/keyboards/whitefox/keymaps/konstantin/rules.mk b/keyboards/whitefox/keymaps/konstantin/rules.mk index 14a29380ce..625ef346c8 100644 --- a/keyboards/whitefox/keymaps/konstantin/rules.mk +++ b/keyboards/whitefox/keymaps/konstantin/rules.mk @@ -1,11 +1,11 @@ -BOOTMAGIC_ENABLE = no -COMMAND_ENABLE = yes -CONSOLE_ENABLE = yes -EXTRAKEY_ENABLE = yes -MOUSEKEY_ENABLE = yes -NKRO_ENABLE = yes -TAP_DANCE_ENABLE = yes -UNICODE_ENABLE = yes +BOOTMAGIC_ENABLE = no +COMMAND_ENABLE = yes +CONSOLE_ENABLE = yes +EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = yes +NKRO_ENABLE = yes +TAP_DANCE_ENABLE = yes +UNICODEMAP_ENABLE = yes BACKLIGHT_ENABLE = no VISUALIZER_ENABLE = no -- cgit v1.2.3 From bd43df53bdf0009a152251582a05046bbefb0858 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Sat, 16 Feb 2019 15:26:14 +0100 Subject: Use two spaces before inline comments --- users/konstantin/konstantin.c | 4 ++-- users/konstantin/rgb.h | 12 ++++++------ users/konstantin/tap_dance.c | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index 686ff32ecc..239252d9c1 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -6,7 +6,7 @@ static void toggle_numpad(void) { bool numpad_on = IS_LAYER_ON(L_NUMPAD); bool num_lock_on = IS_HOST_LED_ON(USB_LED_NUM_LOCK); if (num_lock_on != numpad_on) { - tap_code(KC_NLCK); // Toggle Num Lock to match layer state + tap_code(KC_NLCK); // Toggle Num Lock to match layer state } } #endif @@ -45,7 +45,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { case FN_FNLK: if (record->event.pressed && record->tap.count == TAPPING_TOGGLE) { - fn_lock = !IS_LAYER_ON(L_FN); // Fn layer will be toggled after this + fn_lock = !IS_LAYER_ON(L_FN); // Fn layer will be toggled after this } return true; #endif diff --git a/users/konstantin/rgb.h b/users/konstantin/rgb.h index 2ea10c67a7..e296cf12e7 100644 --- a/users/konstantin/rgb.h +++ b/users/konstantin/rgb.h @@ -3,15 +3,15 @@ #include "quantum.h" typedef struct { - uint16_t h; - uint8_t s; - uint8_t v; + uint16_t h; // 0–360 + uint8_t s; // 0–255 + uint8_t v; // 0–255 } hsv_t; typedef struct { - uint8_t r; - uint8_t g; - uint8_t b; + uint8_t r; // 0–255 + uint8_t g; // 0–255 + uint8_t b; // 0–255 } rgb_t; extern const hsv_t GODSPEED_BLUE; diff --git a/users/konstantin/tap_dance.c b/users/konstantin/tap_dance.c index 81f2d42e1f..dffaeb2066 100644 --- a/users/konstantin/tap_dance.c +++ b/users/konstantin/tap_dance.c @@ -30,7 +30,7 @@ void td_double_mods_reset(qk_tap_dance_state_t *state, void *user_data) { } struct { - bool fn_on; // Layer state when tap dance started + bool fn_on; // Layer state when tap dance started bool started; } td_fn_rctrl_data; -- cgit v1.2.3 From be65a0cc7921a0f6a6397bd7682720b5bd7d9128 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Sat, 16 Feb 2019 18:03:59 +0100 Subject: Add _keymap versions of other custom Quantum functions Not added: eeconfig_update_keymap, eeconfig_read_keymap --- users/konstantin/konstantin.c | 80 ++++++++++++++++++++++++++++++++++++++++--- users/konstantin/konstantin.h | 12 +++++++ 2 files changed, 87 insertions(+), 5 deletions(-) diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index 239252d9c1..f5c59f9eb1 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -1,5 +1,45 @@ #include "konstantin.h" +__attribute__((weak)) +void keyboard_pre_init_keymap(void) {} + +void keyboard_pre_init_user(void) { + keyboard_pre_init_keymap(); +} + +__attribute__((weak)) +void eeconfig_init_keymap(void) {} + +void eeconfig_init_user(void) { + eeconfig_init_keymap(); +} + +__attribute__((weak)) +void matrix_init_keymap(void) {} + +void matrix_init_user(void) { + matrix_init_keymap(); +} + +__attribute__((weak)) +void keyboard_post_init_keymap(void) {} + +void keyboard_post_init_user(void) { + keyboard_post_init_keymap(); +} + +__attribute__((weak)) +void matrix_scan_keymap(void) {} + +void matrix_scan_user(void) { + matrix_scan_keymap(); +} + +__attribute__((weak)) +bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { + return true; +} + #ifdef LAYER_NUMPAD static void toggle_numpad(void) { layer_invert(L_NUMPAD); @@ -11,11 +51,6 @@ static void toggle_numpad(void) { } #endif -__attribute__((weak)) -bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { - return true; -} - bool process_record_user(uint16_t keycode, keyrecord_t *record) { if (!process_record_keymap(keycode, record)) { return false; @@ -88,3 +123,38 @@ uint32_t layer_state_set_keymap(uint32_t state) { uint32_t layer_state_set_user(uint32_t state) { return layer_state_set_keymap(state); } + +__attribute__((weak)) +void led_set_keymap(uint8_t usb_led) {} + +void led_set_user(uint8_t usb_led) { + led_set_keymap(usb_led); +} + +__attribute__((weak)) +void suspend_power_down_keymap(void) {} + +void suspend_power_down_user(void) { + suspend_power_down_keymap(); +} + +__attribute__((weak)) +void suspend_wakeup_init_keymap(void) {} + +void suspend_wakeup_init_user(void) { + suspend_wakeup_init_keymap(); +} + +__attribute__((weak)) +void startup_keymap(void) {} + +void startup_user(void) { // Currently not called anywhere + startup_keymap(); +} + +__attribute__((weak)) +void shutdown_keymap(void) {} + +void shutdown_user(void) { + shutdown_keymap(); +} diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index c32d674e8c..db90c4ef69 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -69,5 +69,17 @@ enum layers_user { L_RANGE_KEYMAP, }; +void keyboard_pre_init_keymap(void); +void eeconfig_init_keymap(void); +void matrix_init_keymap(void); +void keyboard_post_init_keymap(void); + +void matrix_scan_keymap(void); bool process_record_keymap(uint16_t keycode, keyrecord_t *record); uint32_t layer_state_set_keymap(uint32_t state); +void led_set_keymap(uint8_t usb_led); + +void suspend_power_down_keymap(void); +void suspend_wakeup_init_keymap(void); +void startup_keymap(void); +void shutdown_keymap(void); -- cgit v1.2.3 From 784e2af062a9ef0c6d1a4ef7fcc20df79ad4fab1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Sat, 16 Feb 2019 18:05:01 +0100 Subject: Make toggle_numpad a nested function in process_record_user --- users/konstantin/konstantin.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index f5c59f9eb1..a567d9166f 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -40,22 +40,21 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { return true; } -#ifdef LAYER_NUMPAD -static void toggle_numpad(void) { - layer_invert(L_NUMPAD); - bool numpad_on = IS_LAYER_ON(L_NUMPAD); - bool num_lock_on = IS_HOST_LED_ON(USB_LED_NUM_LOCK); - if (num_lock_on != numpad_on) { - tap_code(KC_NLCK); // Toggle Num Lock to match layer state - } -} -#endif - bool process_record_user(uint16_t keycode, keyrecord_t *record) { if (!process_record_keymap(keycode, record)) { return false; } +#ifdef LAYER_NUMPAD + void toggle_numpad(void) { + layer_invert(L_NUMPAD); + bool numpad = IS_LAYER_ON(L_NUMPAD), num_lock = IS_HOST_LED_ON(USB_LED_NUM_LOCK); + if (num_lock != numpad) { + tap_code(KC_NLCK); // Toggle Num Lock to match layer state + } + } +#endif + switch (keycode) { case CLEAR: if (record->event.pressed) { -- cgit v1.2.3 From f09a237a07f2a3a341f6c6972d2f87eec3235254 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Mon, 18 Feb 2019 00:44:31 +0100 Subject: Remove most _keymap and _user definitions in userspace Some keyboards misuse _user functions by defining them in the base files instead of the corresponding _kb functions (especially led_set_user and matrix_init_user). Until this is fixed (#5148), I've removed definitions in my userspace that could cause linking collisions. --- users/konstantin/konstantin.c | 49 ------------------------------------------- users/konstantin/konstantin.h | 8 ------- 2 files changed, 57 deletions(-) diff --git a/users/konstantin/konstantin.c b/users/konstantin/konstantin.c index a567d9166f..a8f2a5f2c9 100644 --- a/users/konstantin/konstantin.c +++ b/users/konstantin/konstantin.c @@ -14,13 +14,6 @@ void eeconfig_init_user(void) { eeconfig_init_keymap(); } -__attribute__((weak)) -void matrix_init_keymap(void) {} - -void matrix_init_user(void) { - matrix_init_keymap(); -} - __attribute__((weak)) void keyboard_post_init_keymap(void) {} @@ -28,13 +21,6 @@ void keyboard_post_init_user(void) { keyboard_post_init_keymap(); } -__attribute__((weak)) -void matrix_scan_keymap(void) {} - -void matrix_scan_user(void) { - matrix_scan_keymap(); -} - __attribute__((weak)) bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { return true; @@ -122,38 +108,3 @@ uint32_t layer_state_set_keymap(uint32_t state) { uint32_t layer_state_set_user(uint32_t state) { return layer_state_set_keymap(state); } - -__attribute__((weak)) -void led_set_keymap(uint8_t usb_led) {} - -void led_set_user(uint8_t usb_led) { - led_set_keymap(usb_led); -} - -__attribute__((weak)) -void suspend_power_down_keymap(void) {} - -void suspend_power_down_user(void) { - suspend_power_down_keymap(); -} - -__attribute__((weak)) -void suspend_wakeup_init_keymap(void) {} - -void suspend_wakeup_init_user(void) { - suspend_wakeup_init_keymap(); -} - -__attribute__((weak)) -void startup_keymap(void) {} - -void startup_user(void) { // Currently not called anywhere - startup_keymap(); -} - -__attribute__((weak)) -void shutdown_keymap(void) {} - -void shutdown_user(void) { - shutdown_keymap(); -} diff --git a/users/konstantin/konstantin.h b/users/konstantin/konstantin.h index db90c4ef69..d4e0e18991 100644 --- a/users/konstantin/konstantin.h +++ b/users/konstantin/konstantin.h @@ -71,15 +71,7 @@ enum layers_user { void keyboard_pre_init_keymap(void); void eeconfig_init_keymap(void); -void matrix_init_keymap(void); void keyboard_post_init_keymap(void); -void matrix_scan_keymap(void); bool process_record_keymap(uint16_t keycode, keyrecord_t *record); uint32_t layer_state_set_keymap(uint32_t state); -void led_set_keymap(uint8_t usb_led); - -void suspend_power_down_keymap(void); -void suspend_wakeup_init_keymap(void); -void startup_keymap(void); -void shutdown_keymap(void); -- cgit v1.2.3 From 8e0dfdfb5307e8b0abb2f6030c9147cfd12964c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Sat, 16 Feb 2019 18:26:27 +0100 Subject: Set Melody96 underglow color to Godspeed blue on EEPROM reset --- keyboards/melody96/keymaps/konstantin/keymap.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/keyboards/melody96/keymaps/konstantin/keymap.c b/keyboards/melody96/keymaps/konstantin/keymap.c index 4df856f8fb..ab876f2f2f 100644 --- a/keyboards/melody96/keymaps/konstantin/keymap.c +++ b/keyboards/melody96/keymaps/konstantin/keymap.c @@ -1,6 +1,10 @@ #include QMK_KEYBOARD_H #include "konstantin.h" +void eeconfig_init_keymap(void) { + rgblight_sethsv(GODSPEED_BLUE.h, GODSPEED_BLUE.s, GODSPEED_BLUE.v); +} + enum keycodes_keymap { RGB_SET = RANGE_KEYMAP, }; -- cgit v1.2.3 From de2e03650bd4d6056513991d4481679e246667bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20=C4=90or=C4=91evi=C4=87?= Date: Sat, 16 Feb 2019 17:26:39 +0100 Subject: Update GODSPEED_BLUE values and RGB mode keys --- keyboards/melody96/keymaps/konstantin/keymap.c | 6 +++--- users/konstantin/rgb.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/keyboards/melody96/keymaps/konstantin/keymap.c b/keyboards/melody96/keymaps/konstantin/keymap.c index ab876f2f2f..02d84d693a 100644 --- a/keyboards/melody96/keymaps/konstantin/keymap.c +++ b/keyboards/melody96/keymaps/konstantin/keymap.c @@ -55,9 +55,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┼───┼───┤RSt│ * │ │M← │M↓ │M→ │MW↑│ │ │ │ │ │ │ │ │RH-│RS-│RV-│ │ * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┼───┼───┼───┤ - * │ │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ │PgU│RMB│RMK│RMG│ │ + * │ │ │MA0│MA2│MW←│MW→│ │ │ │Vo-│Vo+│Mut│ │PgU│RMR│RMS│RMB│ │ * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┼───┼───┤RMP│ - * │ │DtPR│DtNA│ MW↓ │ │ App │Hom│PgD│End│RMR│RMF│ │ + * │ │DtPR│DtNA│ MW↓ │ │ App │Hom│PgD│End│RM-│RM+│ │ * └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┴───┴───┴───┘ */ [L_FN] = LAYOUT( \ @@ -65,7 +65,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_TOG, DIVIDE, TIMES, MINUS, KC_BTN4, KC_BTN2, KC_MS_U, KC_BTN1, KC_BTN3, KC_BTN5, _______, UC_MOD, _______, _______, _______, _______, _______, CLEAR, RGB_HUI, RGB_SAI, RGB_VAI, XXXXXXX, _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_SAD, RGB_VAD, RGB_SET, - _______, _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, KC_PGUP, RGB_M_B, RGB_M_K, RGB_M_G, XXXXXXX, + _______, _______, KC_ACL0, KC_ACL2, KC_WH_L, KC_WH_R, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, KC_PGUP, RGB_M_R, RGB_M_SN,RGB_M_B, XXXXXXX, _______, DST_P_R, DST_N_A, KC_WH_D, _______, XXXXXXX, KC_APP, KC_HOME, KC_PGDN, KC_END, RGB_RMOD,RGB_MOD, RGB_M_P ), }; diff --git a/users/konstantin/rgb.c b/users/konstantin/rgb.c index a09057d282..b69123be05 100644 --- a/users/konstantin/rgb.c +++ b/users/konstantin/rgb.c @@ -1,3 +1,3 @@ #include "rgb.h" -const hsv_t GODSPEED_BLUE = { .h = 214, .s = 17, .v = 73 }; +const hsv_t GOD