#include QMK_KEYBOARD_H
#include "pvinis.h"
#include "mousekey.h"
enum {
MOUSE = 8,
};
enum {
NONE = 30,
TD_LAYR, };
#define AP_SLCK ALLM(KC_S)
#define AP_XCOD ALLM(KC_X)
#define AP_MSGR ALLM(KC_M)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LR_BASE] = LAYOUT_ergodox_pretty_wrapper(
TD_3FLS, _______, _______, _______, _______, _______, KC_LALT, _______, _______, _______, _______, _______, _______, _______,
KC_TAB , _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
PV_ESCC, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_ENT ,
KC_LSFT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_RSFT,
_______, _______, _______, KC_LGUI, SYMBOL , SYSCTL , KC_RALT, _______, _______, _______,
QWERTY , CARPALX, _______, _______,
_______, _______,
KC_BSPC, _______, _______, _______, _______, KC_SPC
),
[LR_QWERTY] = LAYOUT_ergodox_pretty_wrapper(
_______, ________________NUMBERS_L__________________, _______, KC_MINS, ________________NUMBERS_R__________________, KC_EQL ,
_______, _________________QWERTY_L1_________________, KC_LBRC, KC_RBRC, _________________QWERTY_R1_________________, _______,
_______, _____________MOD_QWERTY_L2_________________, _____________MOD_QWERTY_R2_________________, _______,
_______, _________________QWERTY_L3_________________, KC_LPRN, KC_RPRN, _________________QWERTY_R3_________________, _______,
_______, KC_GRV, _______, _______, _______, _______, _______, _______, KC_QUOT , _______,
_______, _______, _______, _______,
_______, _______,
_______, _______, _______, _______, _______, _______
),
[LR_CARPALX] = LAYOUT_ergodox_pretty_wrapper(
_______, ________________NUMBERS_L__________________, _______, _______, ________________NUMBERS_R__________________, _______,
_______, ________________CARPALX_L1_________________, _______, _______, ________________CARPALX_R1_________________, _______,
_______, ________________CARPALX_L2_________________, ________________CARPALX_R2_________________, _______,
_______, ________________CARPALX_L3_________________, _______, _______, ________________CARPALX_R3_________________, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______,
_______, _______, _______, _______, _______, _______
),
[LR_SYMBOL] = LAYOUT_ergodox_pretty_wrapper(
_______, ______________________F_L__________________, KC_F11 , KC_F12 , ______________________F_R__________________, _______,
_______, _________________SYMBOL_L1_________________, _______, _______, _________________SYMBOL_R1_________________, _______,
_______, _________________SYMBOL_L2_________________, _________________SYMBOL_R2_________________, _______,
_______, _________________SYMBOL_L3_________________, _______, _______, _________________SYMBOL_R3_________________, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______,
_______, _______, _______, _______, _______, _______
),
[LR_SYSCTL] = LAYOUT_ergodox_pretty_wrapper(
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _________________SYSCTL_R1_________________, _______,
_______, _______, _______, _______, _______, _______, _________________SYSCTL_R2_________________, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _________________SYSCTL_R3_________________, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______,
_______, _______, _______, _______, _______, _______
),
[LR_KBCTL] = LAYOUT_ergodox_pretty_wrapper(
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, __________________KBCTL_R1_________________, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, __________________KBCTL_R2_________________, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, __________________KBCTL_R3_________________, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
),
[MOUSE] = LAYOUT_ergodox_pretty(
KC_TRNS ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO
,KC_NO
,KC_NO ,KC_NO ,KC_TRNS
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_MS_U ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_MS_L ,KC_MS_D ,KC_MS_R ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO
,KC_NO
,KC_NO ,KC_NO ,KC_NO
),
};
void keyboard_post_init_user_keymap(void) {
ergodox_led_all_on();
for (int i = LED_BRIGHTNESS_HI; i > LED_BRIGHTNESS_LO; i--) {
ergodox_led_all_set(i);
wait_ms(5);
}
wait_ms(1000);
for (int i = LED_BRIGHTNESS_LO; i > 0; i--) {
ergodox_led_all_set(i);
wait_ms(10);
}
ergodox_led_all_off();
ergodox_led_all_set(LED_BRIGHTNESS_HI);
}
uint32_t layer_state_set_user_keymap(uint32_t state) {
ergodox_right_led_1_off();
ergodox_right_led_2_off();
ergodox_right_led_3_off();
switch (biton32(state)) {
case LR_SYSCTL:
ergodox_right_led_3_on(); break;
case LR_KBCTL:
ergodox_right_led_1_on(); break;
case LR_SYMBOL:
ergodox_right_led_2_on(); break;
default:
break;
}
return state;
}