mirror of
https://github.com/Keychron/qmk_firmware.git
synced 2024-12-30 21:38:01 +06:00
Merge remote-tracking branch 'origin/master' into develop
This commit is contained in:
commit
2445c1435a
109
keyboards/keebio/sinc/keymaps/lickel/keymap.c
Normal file
109
keyboards/keebio/sinc/keymaps/lickel/keymap.c
Normal file
@ -0,0 +1,109 @@
|
|||||||
|
/* Copyright 2021 @ Adam Lickel
|
||||||
|
*
|
||||||
|
* This program is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include QMK_KEYBOARD_H
|
||||||
|
|
||||||
|
enum custom_keycodes {
|
||||||
|
#ifdef VIA_ENABLE
|
||||||
|
KC_MISSION_CONTROL = USER00,
|
||||||
|
#else
|
||||||
|
KC_MISSION_CONTROL = SAFE_RANGE,
|
||||||
|
#endif
|
||||||
|
KC_LAUNCHPAD
|
||||||
|
};
|
||||||
|
|
||||||
|
#define KC_MCTL KC_MISSION_CONTROL
|
||||||
|
#define KC_LPAD KC_LAUNCHPAD
|
||||||
|
|
||||||
|
// clang-format off
|
||||||
|
|
||||||
|
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||||
|
[0] = LAYOUT_80_with_macro(
|
||||||
|
KC_MUTE, KC_ESC, KC_BRID, KC_BRIU, KC_MCTL, KC_LPAD, RGB_VAD, RGB_VAI, KC_MPRV, KC_MPLY, KC_MNXT, KC_MUTE, KC_VOLD, KC_VOLU, KC_DEL, KC_MPLY,
|
||||||
|
KC_F1, KC_F2, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_BSPC, KC_HOME,
|
||||||
|
KC_F3, KC_F4, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_PGUP,
|
||||||
|
KC_F5, KC_F6, 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_PGDN,
|
||||||
|
KC_F7, KC_F8, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END,
|
||||||
|
KC_F9, KC_F10, KC_LCTL, KC_LALT, KC_LGUI, MO(1), KC_SPC, KC_SPC, MO(1), KC_SPC, KC_RGUI, KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT
|
||||||
|
),
|
||||||
|
[1] = LAYOUT_80_with_macro(
|
||||||
|
_______, _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, RGB_TOG, RGB_MOD, RGB_VAI, RGB_HUI, RGB_SAI, RGB_SPI, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, RGB_RMOD,RGB_VAD, RGB_HUD, RGB_SAD, RGB_SPD, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||||
|
),
|
||||||
|
[2] = LAYOUT_80_with_macro(
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||||
|
),
|
||||||
|
[3] = LAYOUT_80_with_macro(
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||||
|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||||
|
)
|
||||||
|
};
|
||||||
|
|
||||||
|
// clang-format on
|
||||||
|
|
||||||
|
bool encoder_update_user(uint8_t index, bool clockwise) {
|
||||||
|
if (index == 0) {
|
||||||
|
if (clockwise) {
|
||||||
|
tap_code(KC_PGDN);
|
||||||
|
} else {
|
||||||
|
tap_code(KC_PGUP);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
} else if (index == 1) {
|
||||||
|
if (clockwise) {
|
||||||
|
tap_code(KC_VOLU);
|
||||||
|
} else {
|
||||||
|
tap_code(KC_VOLD);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
|
switch (keycode) {
|
||||||
|
case KC_MISSION_CONTROL:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
host_consumer_send(0x29F);
|
||||||
|
} else {
|
||||||
|
host_consumer_send(0);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case KC_LAUNCHPAD:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
host_consumer_send(0x2A0);
|
||||||
|
} else {
|
||||||
|
host_consumer_send(0);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
default:
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
18
keyboards/keebio/sinc/keymaps/lickel/readme.md
Normal file
18
keyboards/keebio/sinc/keymaps/lickel/readme.md
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
# lickel's Sinc keymap
|
||||||
|
|
||||||
|
- Via support is enabled by default
|
||||||
|
- Function Row is optimized for macOS
|
||||||
|
- RGB controls mimic the stock Keychron Q1 layout
|
||||||
|
- F3 opens Mission Control and F4 opens Launchpad
|
||||||
|
- Left macros are: F1->F10
|
||||||
|
- Right macros are: Play, Home, Pg Up, Pg Dn, End, Right
|
||||||
|
|
||||||
|
![Layout](https://i.imgur.com/uQnzMSe.png)
|
||||||
|
|
||||||
|
([KLE](http://www.keyboard-layout-editor.com/#/gists/e0350d8914cac3166abcca6abfd093b7))
|
||||||
|
|
||||||
|
## Changelog
|
||||||
|
|
||||||
|
### 11/27/2021 - 1.0
|
||||||
|
|
||||||
|
- Initial release
|
2
keyboards/keebio/sinc/keymaps/lickel/rules.mk
Normal file
2
keyboards/keebio/sinc/keymaps/lickel/rules.mk
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
VIA_ENABLE = yes
|
||||||
|
LTO_ENABLE = yes
|
Loading…
Reference in New Issue
Block a user