1
0
Fork 0

Initial commit of rules and keymaps.

FossilOrigin-Name: 9c5fff3dba86c01b5502ad9316ddc26095ee61f7222f536f459b37e7970ce392
This commit is contained in:
mahlon 2024-12-02 03:25:28 +00:00
parent d3e1debbbb
commit 1e5d24cb4f
5 changed files with 151 additions and 0 deletions

View file

@ -0,0 +1,101 @@
#define TAPPING_TOGGLE 2
#define SECURE_IDLE_TIMEOUT 60000*5
#define GRAVE_ESC_ALT_OVERRIDE
#define GRAVE_ESC_CTRL_OVERRIDE
#include QMK_KEYBOARD_H
/*
* OVERRIDES
*/
// Send the 'delete' keystroke with 'shift-backspace'
const key_override_t delete_key_override = ko_make_basic(MOD_MASK_SHIFT, KC_BSPC, KC_DEL);
// LCTL + RCTL == Lock and unlock keyboard usage
const key_override_t keyboard_lock_override = ko_make_basic(MOD_BIT(KC_LCTL), KC_RCTL, QK_SECURE_TOGGLE);
// CTRL-MACRO-PLAY records instead.
const key_override_t macro_record_one_override = ko_make_basic(MOD_MASK_CTRL, DM_PLY1, DM_REC1);
const key_override_t macro_record_two_override = ko_make_basic(MOD_MASK_CTRL, DM_PLY2, DM_REC2);
const key_override_t *key_overrides[] = {
&delete_key_override,
&keyboard_lock_override,
&macro_record_one_override,
&macro_record_two_override
};
/*
enum keycodes {
KC_CYCLE_LAYERS = QK_USER,
};
// 1st layer on the cycle
#define LAYER_CYCLE_START 0
// Last layer on the cycle
#define LAYER_CYCLE_END 1
// Add the behaviour of this new keycode
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case KC_CYCLE_LAYERS:
// Our logic will happen on presses, nothing is done on releases
if (!record->event.pressed) {
// We've already handled the keycode (doing nothing), let QMK know so no further code is run unnecessarily
return false;
}
uint8_t current_layer = get_highest_layer(layer_state);
// Check if we are within the range, if not quit
if (current_layer > LAYER_CYCLE_END || current_layer < LAYER_CYCLE_START) {
return false;
}
uint8_t next_layer = current_layer + 1;
if (next_layer > LAYER_CYCLE_END) {
next_layer = LAYER_CYCLE_START;
}
layer_move(next_layer);
return false;
// Process other keycodes normally
default:
return true;
}
}
*/
enum layers {
_BASE,
_FN1,
_FN2
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_BASE] = LAYOUT_ansi_61(
QK_GESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC,
KC_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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, TT(_FN1), TT(_FN2), KC_RCTL),
[_FN1] = LAYOUT_ansi_61(
_______, 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_HOME, KC_INS, KC_PGUP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, KC_DEL, KC_END, KC_PGDN, _______, _______, _______, _______, _______, KC_UP, _______, _______, _______,
_______, KC_PSCR, KC_SCRL, KC_PAUS, _______, _______, _______, _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______,
_______, _______, _______, _______, _______, _______, _______, _______),
[_FN2] = LAYOUT_ansi_61(
_______, KC_BRID, KC_BRIU, KC_NO, KC_NO, RGB_VAD, RGB_VAI, KC_MPRV, KC_MPLY, KC_MNXT, KC_MUTE, KC_VOLD, KC_VOLU, RGB_MOD,
RGB_TOG, RGB_MOD, RGB_VAI, RGB_HUI, RGB_SAI, RGB_SPI, _______, _______, _______, _______, _______, DM_PLY1, DM_PLY2, DM_RSTP,
_______, RGB_RMOD, RGB_VAD, RGB_HUD, RGB_SAD, RGB_SPD, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, QK_LOCK, _______, _______, _______)
};

View file

@ -0,0 +1,6 @@
DYNAMIC_MACRO_ENABLE = yes
KEY_LOCK_ENABLE = yes
KEY_OVERRIDE_ENABLE = yes
SECURE_ENABLE = yes
VIA_ENABLE = yes