all repos — qmk-userspace @ 0a82225ed742c440026f71453b817b1bfda6bfee

custom layouts for qmk keyboards

various tweaks

updated copyright
removed TTY(7)..TTY(12), but don't know what to do with the remaining empty space.
added mousekeys, will see if it is useful or not.
optimized numlock indicator (i have no clue why i did it through hsv)
added replies to comments from future me :)
la-ninpre aaoth@aaoth.xyz
Fri, 12 Jul 2024 18:42:06 +0300
commit

0a82225ed742c440026f71453b817b1bfda6bfee

parent

7ff9d1b94f354066398a5925a91f5fc2d5c7a839

M keyboards/keychron/v1/ansi/keymaps/lbr/keymap.ckeyboards/keychron/v1/ansi/keymaps/lbr/keymap.c

@@ -1,14 +1,18 @@

-/* Copyright 2023 la-ninpre <aaoth@aaoth.xyz> */ +/* Copyright 2023, 2024 la-ninpre <aaoth@aaoth.xyz> */ #include QMK_KEYBOARD_H /* ideas: * - figure out tap dance, may be useful * - is nkro needed? - * - is spacebar ok to change layers? i thought it is the biggest button, so it'll be easier to use. - * - do i really need more than 6 ttys? + * + is spacebar ok to change layers? i thought it is the biggest button, so it'll be easier to use. + * pretty much okay, not so convenient in games, but it is fine. + * + do i really need more than 6 ttys? + * no, removed * - i don't use the media keys yet, maybe replace them with smth more useful - * - maybe numpad isn't that useful to have it so easily accessible, but some symbols would benefit from that + * + maybe numpad isn't that useful to have it so easily accessible, but some symbols would benefit from that + * numpad is nice, useful for blender + * - are mousekeys useful? added so that i can click with keyboard x) */ // switch to tty on linux, TTY(1) => Ctrl+Alt+F1

@@ -29,12 +33,12 @@ KC_ESC, 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_END,

KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_LCTL, KC_LGUI, KC_LALT, LT(EXTR,KC_SPC), KC_RALT, KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT), [EXTR] = LAYOUT_ansi_82( - _______, TTY(1), TTY(2), TTY(3), TTY(4), TTY(5), TTY(6), TTY(7), TTY(8), TTY(9), TTY(10), TTY(11), TTY(12), MO(MGCK), KC_PSCR, + _______, TTY(1), TTY(2), TTY(3), TTY(4), TTY(5), TTY(6), _______, _______, _______, _______, _______, _______, MO(MGCK), KC_PSCR, _______, 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_P7, KC_P8, KC_P9, KC_PPLS, KC_PEQL, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_PMNS, KC_PAST, _______, KC_NUM, - _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, KC_PSLS, _______, _______, - _______, _______, _______, _______, KC_P0, KC_PDOT, KC_APP, _______, _______, _______), + _______, _______, _______, _______, KC_WH_U, _______, _______, KC_P7, KC_P8, KC_P9, KC_PPLS, KC_PEQL, _______, _______, _______, + _______, _______, KC_BTN1, KC_BTN2, KC_BTN3, _______, _______, KC_P4, KC_P5, KC_P6, KC_PMNS, KC_PAST, _______, KC_NUM, + _______, _______, _______, _______, KC_WH_D, _______, _______, KC_P1, KC_P2, KC_P3, KC_PSLS, _______, KC_MS_U, + _______, _______, _______, _______, KC_P0, KC_PDOT, KC_APP, KC_MS_L, KC_MS_D, KC_MS_R), [MGCK] = LAYOUT_ansi_82( QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, EE_CLR, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,

@@ -63,21 +67,19 @@

// top-right key for numpad status #define IND_NUMPAD 14 #define IND_CAPSLK 0 -#define IND_COLOUR 0x00, 0xbf, 0xcc +#define IND_COLOUR 0xcc, 0x33, 0x33 bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { if(rgb_matrix_is_enabled()){ led_t led_state = host_keyboard_led_state(); - HSV hsv = {IND_COLOUR}; - RGB rgb = hsv_to_rgb(hsv); if(led_state.num_lock){ - rgb_matrix_set_color(IND_NUMPAD, rgb.r, rgb.g, rgb.b); + rgb_matrix_set_color(IND_NUMPAD, IND_COLOUR); }else{ rgb_matrix_set_color(IND_NUMPAD, RGB_BLACK); } if(led_state.caps_lock){ - rgb_matrix_set_color(IND_CAPSLK, rgb.r, rgb.g, rgb.b); + rgb_matrix_set_color(IND_CAPSLK, IND_COLOUR); }else{ rgb_matrix_set_color(IND_CAPSLK, RGB_BLACK); }
M keyboards/keychron/v1/ansi/keymaps/lbr/rules.mkkeyboards/keychron/v1/ansi/keymaps/lbr/rules.mk

@@ -1,9 +1,9 @@

DIPSWITCH_ENABLE = yes RGB_MATRIX_ENABLE = yes +MOUSEKEY_ENABLE = yes # optimizations LTO_ENABLE = yes -MOUSEKEY_ENABLE = no SPACE_CADET_ENABLE = no GRAVE_ESC_ENABLE = no SEND_STRING_ENABLE = no