From b68d8fe82eac0be9ca8862fdf94ae4bfbbb0735e Mon Sep 17 00:00:00 2001 From: Pavlos Vinieratos Date: Tue, 14 May 2019 21:02:22 +0200 Subject: [PATCH] [Keymap] Pvinis master (#5843) * trying to make my global keymap * refactoring the old keymap using userspace * getting there * move readme and remove community layout * use pragma once instead of ifndefs * just make iris work * iris decent * better naming * add some modifiers on the home row * use symbol and sysctl layers * fix up * a bit faster * add < and > on symbol layer * apparently im not using z all that much.. * okok * fix up stuff * led init is back * bring back led indicators * Update keyboards/ergotravel/keymaps/pvinis/config.h Co-Authored-By: noroadsleft <18669334+noroadsleft@users.noreply.github.com> * not needed * not needed * delete these for now, until I use the userspace code * remove katamari from here. made a new pr for it * lower case * drashna suggestion :) * move files to correct place * fix missing command --- keyboards/ergodox_ez/keymaps/pvinis/keymap.c | 330 ++++++++++++ .../ergodox_ez/keymaps/pvinis/readme.md | 0 keyboards/ergodox_ez/keymaps/pvinis/rules.mk | 1 + keyboards/keebio/iris/keymaps/pvinis/config.h | 24 + keyboards/keebio/iris/keymaps/pvinis/keymap.c | 122 +++++ keyboards/keebio/iris/keymaps/pvinis/rules.mk | 2 + layouts/community/ergodox/pvinis/Changelog.md | 7 - layouts/community/ergodox/pvinis/keymap.c | 475 ------------------ layouts/community/ergodox/pvinis/rules.mk | 7 - quantum/audio/song_list.h | 33 +- users/pvinis/config.h | 9 + users/pvinis/pvinis.c | 79 +++ users/pvinis/pvinis.h | 152 ++++++ users/pvinis/rules.mk | 15 + 14 files changed, 750 insertions(+), 506 deletions(-) create mode 100644 keyboards/ergodox_ez/keymaps/pvinis/keymap.c rename layouts/community/ergodox/pvinis/Readme.md => keyboards/ergodox_ez/keymaps/pvinis/readme.md (100%) create mode 100644 keyboards/ergodox_ez/keymaps/pvinis/rules.mk create mode 100644 keyboards/keebio/iris/keymaps/pvinis/config.h create mode 100644 keyboards/keebio/iris/keymaps/pvinis/keymap.c create mode 100644 keyboards/keebio/iris/keymaps/pvinis/rules.mk delete mode 100644 layouts/community/ergodox/pvinis/Changelog.md delete mode 100644 layouts/community/ergodox/pvinis/keymap.c delete mode 100644 layouts/community/ergodox/pvinis/rules.mk create mode 100644 users/pvinis/config.h create mode 100644 users/pvinis/pvinis.c create mode 100644 users/pvinis/pvinis.h create mode 100644 users/pvinis/rules.mk diff --git a/keyboards/ergodox_ez/keymaps/pvinis/keymap.c b/keyboards/ergodox_ez/keymaps/pvinis/keymap.c new file mode 100644 index 0000000000..9943886e2b --- /dev/null +++ b/keyboards/ergodox_ez/keymaps/pvinis/keymap.c @@ -0,0 +1,330 @@ +// pvinis ergodox ez +// ,------------------------------------. ,------------------------------------. +// | | | | | | | | | | | | | | | | +// |------+----+----+----+----+---------| |----+----+----+----+----+----+------| +// | | | | | | | | | | | | | | | | +// |------+----+----+----x----x----| | | |----x----x----+----+----+------| +// | | | | | | |----| |----| | | | | | | +// |------+----+----+----x----x----| | | |----x----x----+----+----+------| +// | | | | | | | | | | | | | | | | +// `------+----+----+----+----+---------' `---------+----+----+----+----+------' +// | | | | | | | | | | | | +// `------------------------' `------------------------' +// ,---------. ,---------. +// | | | | | | +// ,----+----+----| |----+----+----. +// | | | | | | | | +// | | |----| |----| | | +// | | | | | | | | +// `--------------' `--------------' + + +#include QMK_KEYBOARD_H +#include "pvinis.h" +#include "mousekey.h" + + +// layers +enum { + MOUSE = 8, +}; + +// extra keys +enum { + NONE = 30, + TD_LAYR, // SYSCTL and MOUSE layer switch +}; + +// application selection +// this is sending ctrl-alt-gui-, and this is picked up by hammerspoon +#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] = { + // ,------------------------------------. ,------------------------------------. + // |4xFLSH| | | | | |Opt | | | | | | | | | + // |------+----+----+----+----+---------| |----+----+----+----+----+----+------| + // | Tab | | | | | | | | | | | | | | | + // |------+----+----+----x----x----| | | |----x----x----+----+----+------| + // |EscCtl| | | | | |----| |----| | | | | | Ent | + // |------+----+----+----x----x----| | | |----x----x----+----+----+------| + // |LShift| | | | | | | | | | | | | |RShift| + // `------+----+----+----+----+---------' `---------+----+----+----+----+------' + // | | | | |Cmd | | | | | | | + // `------------------------' `------------------------' + // ,---------. ,---------. + // |QWER| | | | | + // ,----+----+----| |----+----+----. + // | Ba | L | | | | | | + // | ck |Shi |----| |----| |Spc | + // | spc| ft | | | | | | + // `--------------' `--------------' + [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 + ), + + // ,------------------------------------. ,------------------------------------. + // | | NUMBERS_L | | | - | NUMBERS_R | = | + // |------+----+----+----+----+---------| |----+----+----+----+----+----+------| + // | | | [ | | ] | | | + // |------+ | | | | +------| + // | | QWERTY_L |----| |----| QWERTY_R | | + // |------+ | ( | | ) | +------| + // | | | | | | | | + // `------+----+----+----+----+---------' `---------+----+----+----+----+------' + // | | ` | | | | | | | | ' | | + // `------------------------' `------------------------' + // ,---------. ,---------. + // | | | | | | + // ,----+----+----| |----+----+----. + // | | | | | | | | + // | | |----| |----| | | + // | | | | | | | | + // `--------------' `--------------' + // See `users/pvinis/pvinis.h` + [LR_QWERTY] = LAYOUT_ergodox_pretty_wrapper( + _______, ________________NUMBERS_L__________________, _______, KC_MINS, ________________NUMBERS_R__________________, KC_EQL , + _______, _________________QWERTY_L1_________________, KC_LBRC, KC_RBRC, _________________QWERTY_R1_________________, _______, + _______, _________________QWERTY_L2_________________, _________________QWERTY_R2_________________, _______, + _______, _________________QWERTY_L3_________________, KC_LPRN, KC_RPRN, _________________QWERTY_R3_________________, _______, + _______, KC_GRV, _______, _______, _______, _______, _______, _______, KC_QUOT , _______, + _______, _______, _______, _______, + _______, _______, + _______, _______, _______, _______, _______, _______ + ), + + // ,------------------------------------. ,------------------------------------. + // | | NUMBERS_L | | | | NUMBERS_R | | + // |------+----+----+----+----+---------| |----+----+----+----+----+----+------| + // | | | | | | | | + // |------+ | | | | +------| + // | | CARPALX_L |----| |----| CARPALX_R | | + // |------+ | | | | +------| + // | | | | | | | | + // `------+----+----+----+----+---------' `---------+----+----+----+----+------' + // | | | | | | | | | | | | + // `------------------------' `------------------------' + // ,---------. ,---------. + // | | | | | | + // ,----+----+----| |----+----+----. + // | | | | | | | | + // | | |----| |----| | | + // | | | | | | | | + // `--------------' `--------------' + // See `users/pvinis/pvinis.h` + [LR_CARPALX] = LAYOUT_ergodox_pretty_wrapper( + _______, ________________NUMBERS_L__________________, _______, _______, ________________NUMBERS_R__________________, _______, + _______, ________________CARPALX_L1_________________, _______, _______, ________________CARPALX_R1_________________, _______, + _______, ________________CARPALX_L2_________________, ________________CARPALX_R2_________________, _______, + _______, ________________CARPALX_L3_________________, _______, _______, ________________CARPALX_R3_________________, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, + _______, _______, _______, _______, _______, _______ + ), + + // See `users/pvinis/pvinis.h` + [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_________________, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, + _______, _______, _______, _______, _______, _______ + ), + + // See `users/pvinis/pvinis.h` + [LR_SYSCTL] = LAYOUT_ergodox_pretty_wrapper( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _________________SYSCTL_R1_________________, _______, + _______, _______, _______, _______, _______, _______, _________________SYSCTL_R2_________________, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _________________SYSCTL_R3_________________, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + + _______, _______, _______, _______, + _______, _______, + _______, _______, _______, _______, _______, _______ + ), + + // See `users/pvinis/pvinis.h` + [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 + * a keymap to control my system. + * + * ,--------------------------------------------------. ,--------------------------------------------------. + * | ^ | | | | | | | | | | | | | | | + * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| + * | | | | | | | | | | | | MsUp | | | | + * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| + * | | | | | | |------| |------| |MsLeft| MsDn |MsRght| | | + * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| + * | | | | | | | | | | | | | | | | + * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' + * | | | | | | | | | | | | + * `----------------------------------' `----------------------------------' + * ,-------------. ,-------------. + * | | | | |MidClk| + * ,------|------|------| |------+------+------. + * | | | | | |Left |Right | + * | | |------| |------| Click| Click| + * | | | ^ | | | | | + * `--------------------' `--------------------' + */ + [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 + ), +}; + + +// keyboard initialization +void keyboard_post_init_user_local(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(); + + // restore default brightness for future use + ergodox_led_all_set(LED_BRIGHTNESS_HI); +} + +// light up leds based on the layer +uint32_t layer_state_set_user_local(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(); // blue + break; + case LR_KBCTL: + ergodox_right_led_1_on(); // red + break; + case LR_SYMBOL: + ergodox_right_led_2_on(); // green + break; + default: break; + } + return state; +} + +// extra keys +// const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) { + // switch (id) { + // } + // return MACRO_NONE; +// } + +// tap dances + +// flash keyboard on 4x tap, with leds +// void flash_each_tap(qk_tap_dance_state_t *state, void *user_data) { +// switch (state->count) { +// case 1: +// ergodox_right_led_3_on(); +// break; +// case 2: +// ergodox_right_led_2_on(); +// break; +// case 3: +// ergodox_right_led_1_on(); +// break; +// case 4: +// ergodox_right_led_3_off(); +// wait_ms(50); +// ergodox_right_led_2_off(); +// wait_ms(50); +// ergodox_right_led_1_off(); +// break; +// } +// } + +// void flash_dance_finished(qk_tap_dance_state_t *state, void *user_data) { +// if (state->count >= 4) { +// reset_keyboard(); +// reset_tap_dance(state); +// } +// } + +// void flash_dance_reset(qk_tap_dance_state_t *state, void *user_data) { +// ergodox_right_led_1_off(); +// wait_ms(50); +// ergodox_right_led_2_off(); +// wait_ms(50); +// ergodox_right_led_3_off(); +// } + +// SYSCTL on first tap, MOUSE ON second tap +// void layers_dance_finished(qk_tap_dance_state_t *state, void *user_data) { +// uint8_t layer = biton32(layer_state); + +// switch(state->count) { +// case 1: +// switch(layer) { +// case LR_SYSCTL: +// layer_off(LR_SYSCTL); +// break; +// case MOUSE: +// layer_off(MOUSE); +// break; +// default: +// layer_on(LR_SYSCTL); +// break; +// } +// break; +// case 2: +// layer_on(MOUSE); +// break; +// } +// } + +// qk_tap_dance_action_t tap_dance_actions[] = { + // [TD_FLSH] = ACTION_TAP_DANCE_FN_ADVANCED( flash_each_tap, flash_dance_finished, flash_dance_reset ), + // [TD_LAYR] = ACTION_TAP_DANCE_FN_ADVANCED( NULL, layers_dance_finished, NULL ), +// }; diff --git a/layouts/community/ergodox/pvinis/Readme.md b/keyboards/ergodox_ez/keymaps/pvinis/readme.md similarity index 100% rename from layouts/community/ergodox/pvinis/Readme.md rename to keyboards/ergodox_ez/keymaps/pvinis/readme.md diff --git a/keyboards/ergodox_ez/keymaps/pvinis/rules.mk b/keyboards/ergodox_ez/keymaps/pvinis/rules.mk new file mode 100644 index 0000000000..e5ddcae8d9 --- /dev/null +++ b/keyboards/ergodox_ez/keymaps/pvinis/rules.mk @@ -0,0 +1 @@ +TAP_DANCE_ENABLE = yes diff --git a/keyboards/keebio/iris/keymaps/pvinis/config.h b/keyboards/keebio/iris/keymaps/pvinis/config.h new file mode 100644 index 0000000000..7a7beb0b87 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/pvinis/config.h @@ -0,0 +1,24 @@ +#pragma once + + +#ifdef PRODUCT +#undef PRODUCT +#define PRODUCT Iris Keyboard - pvinis +#endif // PRODUCT + + +// Use I2C or Serial, not both +#define USE_SERIAL +// #define USE_I2C + + +// Select hand configuration +#define MASTER_LEFT +// #define MASTER_RIGHT +// #define EE_HANDS + + +// choose pin to use for audio. c6 is the one iris uses. +#ifdef AUDIO_ENABLE +#define C6_AUDIO +#endif // AUDIO_ENABLE diff --git a/keyboards/keebio/iris/keymaps/pvinis/keymap.c b/keyboards/keebio/iris/keymaps/pvinis/keymap.c new file mode 100644 index 0000000000..fb9e4adcf8 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/pvinis/keymap.c @@ -0,0 +1,122 @@ +// pvinis iris +// ,-----------------------------. ,-----------------------------. +// | | | | | | | | | | | | | | +// |----+----+----+----+----+----| |----+----+----+----+----+----| +// | | | | | | | | | | | | | | +// |----+----+----+----x----x----| |----x----x----+----+----+----| +// | | | | | | | | | | | | | | +// |----+----+----+----x----x----+----. ,----|----x----x----+----+----+----| +// | | | | | | | | | | | | | | | | +// `-------------------+----+----+----/ \----+----+----+-------------------' +// | | | | | | | | +// `----+---------' `--------------' + + +#include QMK_KEYBOARD_H +#include "pvinis.h" +//#include "iris.h" +//#include "action_layer.h" +//#include "eeconfig.h" + +#ifdef AUDIO_ENABLE + #include "audio.h" +#endif + +#ifdef AUDIO_ENABLE + //#define STARTUP_SONG SONG(SONIC_RING) +#endif + +#ifdef AUDIO_ENABLE +float tone_sonic[][2] = SONG(IN_LIKE_FLINT); +float tone_1[][2] = SONG(QWERTY_SOUND); +float tone_2[][2] = SONG(OLD_SPICE); +float tone_3[][2] = SONG(OVERWATCH_THEME); +float tone_4[][2] = SONG(QWERTY_SOUND); +#endif + + + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + // ,-----------------------------. ,-----------------------------. + // | | | | | |QWER| | | | | | | | + // |----+----+----+----+----+----| |----+----+----+----+----+----| + // |Tab | | | | |CARP| | | | | | |Del | + // |----+----+----+----x----x----| |----x----x----+----+----+----| + // |EscC| | | | | | | | | | | |Ent | + // |----+----+----+----x----x----+----. ,----|----x----x----+----+----+----| + // |LSft| | | | | |Home| |End | | | | | |Rsft| + // `-------------------+----+----+----/ \----+----+----+-------------------' + // |Cmd |LOWR|Bspc| |Spc |RASE|RAlt| + // `----+---------' `--------------' + [LR_BASE] = LAYOUT_wrapper( + _______, _______, _______, _______, _______, QWERTY , _______, _______, _______, _______, _______, _______, + KC_TAB , _______, _______, _______, _______, CARPALX, _______, _______, _______, _______, _______, KC_DEL , + PV_ESCC, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_ENT , + KC_LSFT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_RSFT, + KC_LGUI, SYMBOL , KC_BSPC, KC_SPC , SYSCTL , KC_RALT + ), + + // ,-----------------------------. ,-----------------------------. + // | | NUMBERS_L | | NUMBERS_R | | + // |----+----+----+----+----+----| |----+----+----+----+----+----| + // | | | | | | + // |----+ | | +----| + // | | QWERTY_L | | QWERTY_R | | + // |----+ +----. ,----| +----| + // | | | | | | | | + // `-------------------+----+----+----/ \----+----+----+-------------------' + // | | | | | | | | + // `----+---------' `--------------' + [LR_QWERTY] = LAYOUT_wrapper( + _______, ________________NUMBERS_L__________________, ________________NUMBERS_R__________________, _______, + _______, _________________QWERTY_L1_________________, _________________QWERTY_R1_________________, _______, + _______, _____________MOD_QWERTY_L2_________________, _____________MOD_QWERTY_R2_________________, _______, + _______, _________________QWERTY_L3_________________, _______, _______, _________________QWERTY_R3_________________, _______, + _______, _______, _______, _______, _______, _______ + ), + + // ,-----------------------------. ,-----------------------------. + // | | NUMBERS_L | | NUMBERS_R | | + // |----+----+----+----+----+----| |----+----+----+----+----+----| + // | | | | | | + // |----+ | | +----| + // | | CARPALX_L | | CARPALX_R | | + // |----+ +----. ,----| +----| + // | | | | | | | | + // `-------------------+----+----+----/ \----+----+----+-------------------' + // | | | | | | | | + // `----+---------' `--------------' + [LR_CARPALX] = LAYOUT_wrapper( + _______, ________________NUMBERS_L__________________, ________________NUMBERS_R__________________, _______, + _______, ________________CARPALX_L1_________________, ________________CARPALX_R1_________________, _______, + _______, ________________CARPALX_L2_________________, ________________CARPALX_R2_________________, _______, + _______, ________________CARPALX_L3_________________, _______, _______, ________________CARPALX_R3_________________, _______, + _______, _______, _______, _______, _______, _______ + ), + + [LR_SYMBOL] = LAYOUT_wrapper( + KC_F12 , ______________________F_L__________________, ______________________F_R__________________, KC_F11 , + _______, _________________SYMBOL_L1_________________, _________________SYMBOL_R1_________________, _______, + _______, _________________SYMBOL_L2_________________, _________________SYMBOL_R2_________________, _______, + _______, _________________SYMBOL_L3_________________, _______, _______, _________________SYMBOL_R3_________________, _______, + _______, _______, _______, _______, _______, _______ + ), + + [LR_SYSCTL] = LAYOUT_wrapper( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _________________SYSCTL_R1_________________, _______, + _______, _______, _______, _______, _______, _______, _________________SYSCTL_R2_________________, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _________________SYSCTL_R3_________________, _______, + _______, _______, _______, _______, _______, _______ + ), + + [LR_KBCTL] = LAYOUT_wrapper( + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + XXXXXXX, __________________KBCTL_L1_________________, __________________KBCTL_R1_________________, XXXXXXX, + XXXXXXX, __________________KBCTL_L2_________________, __________________KBCTL_R2_________________, XXXXXXX, + BASE , __________________KBCTL_L3_________________, XXXXXXX, XXXXXXX, __________________KBCTL_R3_________________, XXXXXXX, + XXXXXXX, _______, XXXXXXX, XXXXXXX, _______, XXXXXXX + ) +}; diff --git a/keyboards/keebio/iris/keymaps/pvinis/rules.mk b/keyboards/keebio/iris/keymaps/pvinis/rules.mk new file mode 100644 index 0000000000..899312894b --- /dev/null +++ b/keyboards/keebio/iris/keymaps/pvinis/rules.mk @@ -0,0 +1,2 @@ +AUDIO_ENABLE = no # off for now +RGBLIGHT_ENABLE = no # off for now diff --git a/layouts/community/ergodox/pvinis/Changelog.md b/layouts/community/ergodox/pvinis/Changelog.md deleted file mode 100644 index e5816200b8..0000000000 --- a/layouts/community/ergodox/pvinis/Changelog.md +++ /dev/null @@ -1,7 +0,0 @@ -## v0.3 - -*2016-10-11* - -### Starting point - -* The starting point of this keymap. A beginner layout, and a couple placeholders. diff --git a/layouts/community/ergodox/pvinis/keymap.c b/layouts/community/ergodox/pvinis/keymap.c deleted file mode 100644 index 1bca0398dc..0000000000 --- a/layouts/community/ergodox/pvinis/keymap.c +++ /dev/null @@ -1,475 +0,0 @@ -// pvinis' ergodox keymap - -#include QMK_KEYBOARD_H -#include "mousekey.h" - -// easier name for left ctrl-alt-gui -#define ALLM(kc) LCAG(kc) - -// layers -enum { - BASE = 0, - BEGIN, - QWERTY, - CARPALX, - SYSCTL, - MOUSE, -}; - -// extra keys -enum { - NONE = 0, - - // tap dance - TD_FLSH, // flash keyboard - TD_LAYR, // SYSCTL and MOUSE layer switch -}; - -// application selection -// this is sending ctrl-alt-gui-, and this is picked up by hammerspoon -#define AP_SLCK ALLM(KC_S) -#define AP_XCOD ALLM(KC_X) -#define AP_MSGR ALLM(KC_M) - -// keymaps -const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { -/* BASE - * the base of the keyboard. - * - * ,--------------------------------------------------. ,--------------------------------------------------. - * |4x FLASH| | | | | | | | | | | | | | | - * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| - * | | | | | | | | | | | | | | | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | | | | | |------| |------| | | | | | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | | | | | | | | | | | | | | | - * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' - * | | | | | | |SYSCTL| | | | | - * `----------------------------------' `----------------------------------' - * ,-------------. ,-------------. - * |BEGIN |QWERTY| | | | - * ,------|------|------| |------+--------+------. - * | | |CARPAL| |Slack | | | - * |Backsp|LShift|------| |------| Enter |Space | - * | | |SYSCTL| |Msngr | | | - * `--------------------' `----------------------' - */ -[BASE] = LAYOUT_ergodox( - TD(TD_FLSH) ,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 - - ,TG(BEGIN) ,TD(TD_LAYR) - ,TG(MOUSE) - ,KC_BSPC ,KC_LSFT ,TD(TD_LAYR) - - ,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 - ,MO(SYSCTL) ,KC_NO ,KC_NO ,KC_NO ,KC_NO - - ,TG(SYSCTL) ,KC_NO - ,AP_SLCK - ,AP_MSGR ,KC_ENT ,KC_SPC -), - -/* BEGIN - * a beginner's keymap i currently use. - * - * ,--------------------------------------------------. ,--------------------------------------------------. - * | | 1 | 2 | 3 | 4 | 5 | opt | | 6 | 7 | 8 | 9 | 0 | - | = | - * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| - * | Tab | Q | W | E | R | T | [ | | ] | Y | U | I | O | P | \ | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * |Esc/Ctrl| A | S | D | F | G |------| |------| H | J | K | L | ; | Enter | - * |--------+------+------+------+------+------| ( | | ) |------+------+------+------+------+--------| - * | LShift | Z | X | C | V | B | | | | N | M | , | . | / | RShift | - * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' - * | | ` | Cmd | | Cmd | | | | | ' | | - * `----------------------------------' `----------------------------------' - * ,-------------. ,-------------. - * | | | | | | - * ,------|------|------| |------+--------+------. - * | | | | | | | | - * | | |------| |------| | | - * | | | | | | | | - * `--------------------' `----------------------' - */ -[BEGIN] = LAYOUT_ergodox( - KC_TRNS ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_LALT -,KC_TAB ,KC_Q ,KC_W ,KC_E ,KC_R ,KC_T ,KC_LBRC -,CTL_T(KC_ESC) ,KC_A ,KC_S ,KC_D ,KC_F ,KC_G -,KC_LSFT ,KC_Z ,KC_X ,KC_C ,KC_V ,KC_B ,KC_LPRN -,KC_TRNS ,KC_GRV ,KC_LGUI ,KC_LEFT ,KC_RIGHT - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_6 ,KC_7 ,KC_8 ,KC_9 ,KC_0 ,KC_MINS ,KC_EQL - ,KC_RBRC ,KC_Y ,KC_U ,KC_I ,KC_O ,KC_P ,KC_BSLS - ,KC_H ,KC_J ,KC_K ,KC_L ,KC_SCLN ,KC_ENT - ,KC_RPRN ,KC_N ,KC_M ,KC_COMM ,KC_DOT ,KC_SLSH ,KC_RSFT - ,KC_TRNS ,KC_DOWN ,KC_TRNS ,KC_QUOT ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS -), - -/* QWERTY - * the default qwerty keymap. not really used, but i'll keep it here for now. - * - * ,--------------------------------------------------. ,--------------------------------------------------. - * | | 1 | 2 | 3 | 4 | 5 | | | | 6 | 7 | 8 | 9 | 0 | | - * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| - * | | Q | W | E | R | T | | | | Y | U | I | O | P | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | A | S | D | F | G |------| |------| H | J | K | L | ; | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | Z | X | C | V | B | | | | N | M | , | . | / | | - * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' - * | | | | | | | | | | | | - * `----------------------------------' `----------------------------------' - * ,-------------. ,-------------. - * | | | | | | - * ,------|------|------| |------+--------+------. - * | | | | | | | | - * | | |------| |------| | | - * | | | | | | | | - * `--------------------' `----------------------' - */ -[QWERTY] = LAYOUT_ergodox( - KC_TRNS ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_TRNS -,KC_TRNS ,KC_Q ,KC_W ,KC_E ,KC_R ,KC_T ,KC_TRNS -,KC_TRNS ,KC_A ,KC_S ,KC_D ,KC_F ,KC_G -,KC_TRNS ,KC_Z ,KC_X ,KC_C ,KC_V ,KC_B ,KC_TRNS -,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_6 ,KC_7 ,KC_8 ,KC_9 ,KC_0 ,KC_TRNS - ,KC_TRNS ,KC_Y ,KC_U ,KC_I ,KC_O ,KC_P ,KC_TRNS - ,KC_H ,KC_J ,KC_K ,KC_L ,KC_SCLN ,KC_TRNS - ,KC_TRNS ,KC_N ,KC_M ,KC_COMM ,KC_DOT ,KC_SLSH ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS -), - -/* CARPALX - * the keymap i would like to transition to. - * - * ,--------------------------------------------------. ,--------------------------------------------------. - * | | 1 | 2 | 3 | 4 | 5 | | | RIGHT| 6 | 7 | 8 | 9 | 0 | | - * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| - * | | Q | G | M | L | W | | | L1 | Y | F | U | B | ; | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | D | S | T | N | R |------| |------| I | A | E | O | H | | - * |--------+------+------+------+------+------| | | Meh |------+------+------+------+------+--------| - * | | Z | X | C | V | J | | | | K | P | , | . | / | | - * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' - * | | | | | | | Up | | | | | - * `----------------------------------' `----------------------------------' - * ,-------------. ,-------------. - * | | | | | | - * ,------|------|------| |------+------+------. - * | | | | | | | | - * | | |------| |------| | | - * | | | | | | | | - * `--------------------' `--------------------' - */ -[CARPALX] = LAYOUT_ergodox( - KC_TRNS ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_TRNS -,KC_TRNS ,KC_Q ,KC_G ,KC_M ,KC_L ,KC_W ,KC_TRNS -,KC_TRNS ,KC_D ,KC_S ,KC_T ,KC_N ,KC_R -,KC_TRNS ,KC_Z ,KC_X ,KC_C ,KC_V ,KC_J ,KC_TRNS -,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_6 ,KC_7 ,KC_8 ,KC_9 ,KC_0 ,KC_TRNS - ,KC_TRNS ,KC_Y ,KC_F ,KC_U ,KC_B ,KC_SCLN ,KC_TRNS - ,KC_I ,KC_A ,KC_E ,KC_O ,KC_H ,KC_TRNS - ,KC_TRNS ,KC_K ,KC_P ,KC_COMM ,KC_DOT ,KC_SLSH ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS -), - -/* SYSCTL - * a keymap to control my system. - * - * ,--------------------------------------------------. ,------------------------------------------------------. - * | ^ | | | | | | | | | | | | | | | - * |--------+------+------+------+------+-------------| |------+------+------+----------+------+------+--------| - * | | | | | | | | | | Mute | Home | Up | End | | | - * |--------+------+------+------+------+------| | | |------+------+----------+------+------+--------| - * | | | | | | |------| |------|VolUp | Left | Down |Right | | Lock | - * |--------+------+------+------+------+------| | | |------+------+----------+------+------+--------| - * | | | | | | | | | |VolDn | Prev |Play/Pause| Next | | Sleep | - * `--------+------+------+------+------+-------------' `-------------+------+----------+------+------+--------' - * | | | | | | | | | | | Power| - * `----------------------------------' `--------------------------------------' - * ,-------------. ,-------------. - * | | | | | | - * ,------|------|------| |------+------+------. - * | | | | | | | | - * | | |------| |------| | | - * | | | ^ | | | | | - * `--------------------' `--------------------' - */ -[SYSCTL] = LAYOUT_ergodox( - 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_POP /// */,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO - /* /// ,KC_PTRN*/,KC_NO ,KC_MUTE ,KC_HOME ,KC_UP ,KC_END ,KC_NO ,KC_NO - ,KC_VOLU ,KC_LEFT ,KC_DOWN ,KC_RGHT ,KC_NO ,LCTL(LSFT(KC_PWR)) - ,KC_NO ,KC_VOLD ,KC_MPRV ,KC_MPLY ,KC_MNXT ,KC_NO ,KC_SLEP - ,KC_TRNS ,KC_NO ,KC_NO ,KC_NO ,KC_PWR - - ,KC_NO ,KC_NO - ,KC_NO - ,KC_NO ,KC_NO ,KC_NO -), - -/* MOUSE - * a keymap to control my system. - * - * ,--------------------------------------------------. ,--------------------------------------------------. - * | ^ | | | | | | | | | | | | | | | - * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| - * | | | | | | | | | | | | MsUp | | | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | | | | | |------| |------| |MsLeft| MsDn |MsRght| | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | | | | | | | | | | | | | | | - * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' - * | | | | | | | | | | | | - * `----------------------------------' `----------------------------------' - * ,-------------. ,-------------. - * | | | | |MidClk| - * ,------|------|------| |------+------+------. - * | | | | | |Left |Right | - * | | |------| |------| Click| Click| - * | | | ^ | | | | | - * `--------------------' `--------------------' - */ -[MOUSE] = LAYOUT_ergodox( - 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 -), - -/* TEMPLATE - * keymap template with transparent and non-transparent keys - * - * ,--------------------------------------------------. ,--------------------------------------------------. - * | | | | | | | | | | | | | | | | - * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| - * | | | | | | | | | | | | | | | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | | | | | |------| |------| | | | | | | - * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| - * | | | | | | | | | | | | | | | | - * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' - * | | | | | | | | | | | | - * `----------------------------------' `----------------------------------' - * ,-------------. ,-------------. - * | | | | | | - * ,------|------|------| |------+--------+------. - * | | | | | | | | - * | | |------| |------| | | - * | | | | | | | | - * `--------------------' `----------------------' - */ -/* -[TEMPLATE] = LAYOUT_ergodox( - KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS -,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS -,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS -,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS -,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS ,KC_TRNS - - ,KC_TRNS ,KC_TRNS - ,KC_TRNS - ,KC_TRNS ,KC_TRNS ,KC_TRNS -), -[TEMPLATE] = LAYOUT_ergodox( - 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_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_NO - ,KC_NO ,KC_NO ,KC_NO -), -*/ -}; - -// keyboard initialization -void matrix_init_user() { - 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(); -} - -// light up leds based on the layer -void matrix_scan_user(void) { - uint8_t layer = biton32(layer_state); - - switch(layer) { - case SYSCTL: - ergodox_right_led_3_on(); - break; - case MOUSE: - ergodox_right_led_2_on(); - break; - default: - ergodox_right_led_1_off(); - ergodox_right_led_2_off(); - ergodox_right_led_3_off(); - break; - } -} - -// extra keys -const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) { - switch (id) { - } - return MACRO_NONE; -} - -// tap dances - -// flash keyboard on 4x tap, with leds -void flash_each_tap(qk_tap_dance_state_t *state, void *user_data) { - switch (state->count) { - case 1: - ergodox_right_led_3_on(); - break; - case 2: - ergodox_right_led_2_on(); - break; - case 3: - ergodox_right_led_1_on(); - break; - case 4: - ergodox_right_led_3_off(); - wait_ms(50); - ergodox_right_led_2_off(); - wait_ms(50); - ergodox_right_led_1_off(); - break; - } -} - -void flash_dance_finished(qk_tap_dance_state_t *state, void *user_data) { - if (state->count >= 4) { - reset_keyboard(); - reset_tap_dance(state); - } -} - -void flash_dance_reset(qk_tap_dance_state_t *state, void *user_data) { - ergodox_right_led_1_off(); - wait_ms(50); - ergodox_right_led_2_off(); - wait_ms(50); - ergodox_right_led_3_off(); -} - -// SYSCTL on first tap, MOUSE ON second tap -void layers_dance_finished(qk_tap_dance_state_t *state, void *user_data) { - uint8_t layer = biton32(layer_state); - - switch(state->count) { - case 1: - switch(layer) { - case SYSCTL: - layer_off(SYSCTL); - break; - case MOUSE: - layer_off(MOUSE); - break; - default: - layer_on(SYSCTL); - break; - } - break; - case 2: - layer_on(MOUSE); - break; - } -} - -qk_tap_dance_action_t tap_dance_actions[] = { - [TD_FLSH] = ACTION_TAP_DANCE_FN_ADVANCED( flash_each_tap, flash_dance_finished, flash_dance_reset ), - [TD_LAYR] = ACTION_TAP_DANCE_FN_ADVANCED( NULL, layers_dance_finished, NULL ), -}; diff --git a/layouts/community/ergodox/pvinis/rules.mk b/layouts/community/ergodox/pvinis/rules.mk deleted file mode 100644 index 87cbd93c2b..0000000000 --- a/layouts/community/ergodox/pvinis/rules.mk +++ /dev/null @@ -1,7 +0,0 @@ -CONSOLE_ENABLE = no # for debugging - -SLEEP_LED_ENABLE = no # no led blinking while sleeping -NKRO_ENABLE = yes # disable for windows -TAP_DANCE_ENABLE = yes # tap-tap-tap - - diff --git a/quantum/audio/song_list.h b/quantum/audio/song_list.h index 1d4eec7116..9ca8231e49 100644 --- a/quantum/audio/song_list.h +++ b/quantum/audio/song_list.h @@ -51,7 +51,6 @@ Q__NOTE(_E4), Q__NOTE(_C4), \ Q__NOTE(_E4), -/* Requires: PLAY_NOTE_ARRAY(..., ..., STACCATO); */ #define IN_LIKE_FLINT \ E__NOTE(_AS4), E__NOTE(_AS4), QD_NOTE(_B4), \ E__NOTE(_AS4), E__NOTE(_B4), QD_NOTE(_CS4), \ @@ -548,8 +547,8 @@ H__NOTE(_D5), Q__NOTE(_C5), Q__NOTE(_C5), Q__NOTE(_A4), H__NOTE(_C5), Q__NOTE(_C5), \ W__NOTE(_C5), Q__NOTE(_F4), Q__NOTE(_C5), Q__NOTE(_D5), Q__NOTE(_E5), H__NOTE(_D5), \ H__NOTE(_C5), Q__NOTE(_C5), H__NOTE(_G5), Q__NOTE(_C5), HD_NOTE(_D5), \ - HD_NOTE(_G4), Q__NOTE(_C5), Q__NOTE(_D5), BD_NOTE(_C5), - + HD_NOTE(_G4), Q__NOTE(_C5), Q__NOTE(_D5), BD_NOTE(_C5), + #define CAMPANELLA \ Q__NOTE(_DS4), E__NOTE(_DS4), E__NOTE(_DS5), Q__NOTE(_DS5), E__NOTE(_DS5), E__NOTE(_DS6), Q__NOTE(_DS5), E__NOTE(_DS5), \ E__NOTE(_DS6), Q__NOTE(_CS5), E__NOTE(_CS5), E__NOTE(_DS6), Q__NOTE(_B4), E__NOTE(_B4), E__NOTE(_DS6), \ @@ -566,7 +565,7 @@ E__NOTE(_B5), E__NOTE(_DS7), Q__NOTE(_B5), E__NOTE(_B5), E__NOTE(_DS7), Q__NOTE(_AS5), E__NOTE(_AS5), \ E__NOTE(_DS7), Q__NOTE(_GS5), E__NOTE(_GS5), E__NOTE(_DS7), Q__NOTE(_G5), E__NOTE(_G5), E__NOTE(_DS7), \ Q__NOTE(_GS5), E__NOTE(_GS5), E__NOTE(_DS7), Q__NOTE(_AS5), E__NOTE(_AS5), E__NOTE(_DS7), Q__NOTE(_DS5), \ - E__NOTE(_DS5), E__NOTE(_DS7), W__NOTE(_DS6), W__NOTE(_GS5), + E__NOTE(_DS5), E__NOTE(_DS7), W__NOTE(_DS6), W__NOTE(_GS5), #define MEGALOVANIA \ Q__NOTE(_D4), Q__NOTE(_D4), H__NOTE(_D5), HD_NOTE(_A4), H__NOTE(_AF4), H__NOTE(_G4), H__NOTE(_F4), \ @@ -595,7 +594,7 @@ H__NOTE(_A5), H__NOTE(_A5), W__NOTE(_B5), H__NOTE(_A5), H__NOTE(_B5), W__NOTE(_A5), W__NOTE(_A6), \ W__NOTE(_GS6), H__NOTE(_CS6), Q__NOTE(_E6), Q__NOTE(_CS6), W__NOTE(_B5), H__NOTE(_B5), H__NOTE(_CS6), \ W__NOTE(_B5), H__NOTE(_A5), Q__NOTE(_B5), BD_NOTE(_A5), - + #define LIEBESLEID \ Q__NOTE(_E4), Q__NOTE(_DS4), Q__NOTE(_E4), Q__NOTE(_F4), Q__NOTE(_E4), Q__NOTE(_FS4), Q__NOTE(_EF4), Q__NOTE(_G4), Q__NOTE(_D4), \ Q__NOTE(_GS4), Q__NOTE(_CS4), W__NOTE(_A4), H__NOTE(_E5), H__NOTE(_E5), HD_NOTE(_G4), Q__NOTE(_E5), E__NOTE(_E5), \ @@ -605,8 +604,8 @@ Q__NOTE(_C5), E__NOTE(_C5), E__NOTE(_D5), E__NOTE(_C5), HD_NOTE(_BF4), Q__NOTE(_C5), H__NOTE(_D5), H__NOTE(_FS4), \ H__NOTE(_F4), HD_NOTE(_E4), Q__NOTE(_A4), HD_NOTE(_FS4), Q__NOTE(_A4), HD_NOTE(_GS4), Q__NOTE(_B4), Q__NOTE(_A4), \ Q__NOTE(_E4), Q__NOTE(_DS4), Q__NOTE(_E4), Q__NOTE(_F4), Q__NOTE(_D4), Q__NOTE(_FS4), Q__NOTE(_CS4), Q__NOTE(_G4), \ - Q__NOTE(_C4), Q__NOTE(_GS4), Q__NOTE(_D4), WD_NOTE(_A4), - + Q__NOTE(_C4), Q__NOTE(_GS4), Q__NOTE(_D4), WD_NOTE(_A4), + #define MELODIES_OF_LIFE \ H__NOTE(_B5), W__NOTE(_GS6), H__NOTE(_GS6), H__NOTE(_FS6), W__NOTE(_E6), H__NOTE(_E6), H__NOTE(_DS6), H__NOTE(_CS6), H__NOTE(_DS6), \ H__NOTE(_E6), H__NOTE(_FS6), WD_NOTE(_B5), H__NOTE(_B5), H__NOTE(_CS6), H__NOTE(_DS6), H__NOTE(_E6), H__NOTE(_CS6), \ @@ -614,7 +613,7 @@ WD_NOTE(_FS6), H__NOTE(_GS6), WD_NOTE(_B6), H__NOTE(_CS7), H__NOTE(_B6), H__NOTE(_A6), H__NOTE(_A6), H__NOTE(_GS6), \ H__NOTE(_GS6), H__NOTE(_FS6), H__NOTE(_FS6), H__NOTE(_GS6), WD_NOTE(_A6), Q__NOTE(_GS6), Q__NOTE(_FS6), Q__NOTE(_FS6), \ Q__NOTE(_E6), W__NOTE(_E6), Q__NOTE(_B5), Q__NOTE(_CS6), WD_NOTE(_E6), Q__NOTE(_E6), Q__NOTE(_FS6), W__NOTE(_GS6), \ - H__NOTE(_A6), B__NOTE(_FS6), + H__NOTE(_A6), B__NOTE(_FS6), #define EYES_ON_ME \ Q__NOTE(_A6), Q__NOTE(_G6), Q__NOTE(_FS6), Q__NOTE(_D6), Q__NOTE(_A5), Q__NOTE(_G5), Q__NOTE(_FS5), Q__NOTE(_D5), \ @@ -640,7 +639,7 @@ W__NOTE(_G6), H__NOTE(_AF6), W__NOTE(_G6), H__NOTE(_AF6), H__NOTE(_G6), H__NOTE(_F6), H__NOTE(_D6), H__NOTE(_D6), \ H__NOTE(_EF6), B__NOTE(_EF6), WD_NOTE(_E6), H__NOTE(_E6), H__NOTE(_F6), H__NOTE(_G6), H__NOTE(_BF6), H__NOTE(_AF6), \ W__NOTE(_AF6), H__NOTE(_C6), H__NOTE(_AF6), H__NOTE(_G6), W__NOTE(_G6), H__NOTE(_F6), H__NOTE(_D6), BD_NOTE(_EF6), \ - WD_NOTE(_F6), WD_NOTE(_G6), BD_NOTE(_C7), + WD_NOTE(_F6), WD_NOTE(_G6), BD_NOTE(_C7), #define NIER_AMUSEMENT_PARK \ H__NOTE(_D5), E__NOTE(_G6), E__NOTE(_GF6), Q__NOTE(_F6), Q__NOTE(_E6), Q__NOTE(_EF6), Q__NOTE(_DF6), Q__NOTE(_EF6), WD_NOTE(_D6), \ @@ -656,7 +655,7 @@ H__NOTE(_EF5), H__NOTE(_F5), W__NOTE(_D5), W__NOTE(_BF5), W__NOTE(_G5), W__NOTE(_D5), W__NOTE(_EF5), QD_NOTE(_C5), \ QD_NOTE(_D5), Q__NOTE(_EF5), H__NOTE(_G5), H__NOTE(_F5), H__NOTE(_EF5), H__NOTE(_F5), B__NOTE(_D5), B__NOTE(_BF4), \ B__NOTE(_C5), H__NOTE(_C5), H__NOTE(_D5), H__NOTE(_EF5), H__NOTE(_F5), WD_NOTE(_G5), H__NOTE(_C5), W__NOTE(_AF5), \ - WD_NOTE(_G5), + WD_NOTE(_G5), #define COPIED_CITY \ Q__NOTE(_F6), Q__NOTE(_BF5), Q__NOTE(_EF6), Q__NOTE(_G5), Q__NOTE(_AF5), Q__NOTE(_G6), Q__NOTE(_AF6), Q__NOTE(_EF6), Q__NOTE(_BF5), \ @@ -670,7 +669,7 @@ Q__NOTE(_F4), Q__NOTE(_G4), H__NOTE(_AF4), Q__NOTE(_C5), Q__NOTE(_EF5), Q__NOTE(_F5), Q__NOTE(_C5), Q__NOTE(_EF5), \ Q__NOTE(_F5), Q__NOTE(_G5), Q__NOTE(_BF5), Q__NOTE(_AF5), Q__NOTE(_G5), Q__NOTE(_EF5), Q__NOTE(_F5), Q__NOTE(_C5), \ Q__NOTE(_AF4), Q__NOTE(_F5), Q__NOTE(_G5), Q__NOTE(_AF5), Q__NOTE(_G5), Q__NOTE(_F5), Q__NOTE(_EF5), Q__NOTE(_F5), \ - Q__NOTE(_G5), Q__NOTE(_BF5), Q__NOTE(_C6), Q__NOTE(_G6), Q__NOTE(_EF6), WD_NOTE(_F7), + Q__NOTE(_G5), Q__NOTE(_BF5), Q__NOTE(_C6), Q__NOTE(_G6), Q__NOTE(_EF6), WD_NOTE(_F7), #define VAGUE_HOPE_COLD_RAIN \ HD_NOTE(_D6), HD_NOTE(_E6), HD_NOTE(_CS6), HD_NOTE(_D6), HD_NOTE(_B5), Q__NOTE(_B5), Q__NOTE(_CS6), Q__NOTE(_D6), WD_NOTE(_A6), \ @@ -685,7 +684,7 @@ W__NOTE(_FS5), HD_NOTE(_FS6), HD_NOTE(_B5), H__NOTE(_D6), H__NOTE(_CS6), H__NOTE(_E6), HD_NOTE(_A6), HD_NOTE(_E6), \ W__NOTE(_D6), Q__NOTE(_CS6), Q__NOTE(_D6), HD_NOTE(_E6), HD_NOTE(_FS6), WD_NOTE(_B6), HD_NOTE(_E6), HD_NOTE(_FS6), \ HD_NOTE(_B5), Q__NOTE(_B5), Q__NOTE(_B5), Q__NOTE(_CS6), H__NOTE(_D6), H__NOTE(_E6), H__NOTE(_FS6), HD_NOTE(_E6), \ - HD_NOTE(_CS6), H__NOTE(_FS6), H__NOTE(_A6), H__NOTE(_B6), W__NOTE(_A6), H__NOTE(_FS6), BD_NOTE(_B6), + HD_NOTE(_CS6), H__NOTE(_FS6), H__NOTE(_A6), H__NOTE(_B6), W__NOTE(_A6), H__NOTE(_FS6), BD_NOTE(_B6), #define KAINE_SALVATION \ BD_NOTE(_D5), W__NOTE(_BF4), W__NOTE(_C5), W__NOTE(_F5), BD_NOTE(_D5), BD_NOTE(_BF4), BD_NOTE(_C5), W__NOTE(_BF4), W__NOTE(_C5), \ @@ -711,7 +710,7 @@ Q__NOTE(_F6), H__NOTE(_E6), H__NOTE(_F6), HD_NOTE(_E6), H__NOTE(_D6), H__NOTE(_C6), H__NOTE(_D6), BD_NOTE(_D6), \ Q__NOTE(_E6), Q__NOTE(_D6), Q__NOTE(_C6), Q__NOTE(_B5), H__NOTE(_C6), Q__NOTE(_C6), H__NOTE(_C6), HD_NOTE(_C6), \ H__NOTE(_B5), H__NOTE(_C6), H__NOTE(_E6), H__NOTE(_G6), WD_NOTE(_G6), Q__NOTE(_C6), B__NOTE(_C6), H__NOTE(_B6), \ - Q__NOTE(_C7), BD_NOTE(_C7), + Q__NOTE(_C7), BD_NOTE(_C7), #define ISABELLAS_LULLABY \ W__NOTE(_BF4), B__NOTE(_D5), W__NOTE(_EF5), B__NOTE(_F5), W__NOTE(_BF5), B__NOTE(_AF5), W__NOTE(_GF5), BD_NOTE(_F5), B__NOTE(_CS5), \ @@ -739,7 +738,7 @@ E__NOTE(_GS4), E__NOTE(_CS5), E__NOTE(_E5), E__NOTE(_DS5), E__NOTE(_CS5), E__NOTE(_DS5), E__NOTE(_CS5), E__NOTE(_C5), \ E__NOTE(_CS5), E__NOTE(_E5), E__NOTE(_GS5), E__NOTE(_DS5), E__NOTE(_E5), E__NOTE(_DS5), E__NOTE(_REST), E__NOTE(_DS5), \ E__NOTE(_B5), E__NOTE(_AS5), E__NOTE(_GS5), E__NOTE(_REST), E__NOTE(_E6), E__NOTE(_DS6), E__NOTE(_CS6), E__NOTE(_B5), \ - E__NOTE(_AS5), E__NOTE(_GS5), E__NOTE(_REST), E__NOTE(_AS5), WD_NOTE(_GS5), + E__NOTE(_AS5), E__NOTE(_GS5), E__NOTE(_REST), E__NOTE(_AS5), WD_NOTE(_GS5), #define TERRAS_THEME \ Q__NOTE(_GS5), Q__NOTE(_AS5), Q__NOTE(_B5), Q__NOTE(_EF6), BD_NOTE(_B5), Q__NOTE(_AS5), Q__NOTE(_GS5), W__NOTE(_AS5), \ @@ -762,7 +761,7 @@ Q__NOTE(_E6), H__NOTE(_E6), H__NOTE(_E6), Q__NOTE(_E6), H__NOTE(_FS6), WD_NOTE(_E6), W__NOTE(_B6), W__NOTE(_GS6), \ W__NOTE(_FS6), H__NOTE(_GS6), H__NOTE(_GS6), H__NOTE(_FS6), H__NOTE(_E6), H__NOTE(_FS6), B__NOTE(_GS6), H__NOTE(_GS6), \ W__NOTE(_CS7), W__NOTE(_GS6), W__NOTE(_E6), H__NOTE(_GS6), H__NOTE(_GS6), HD_NOTE(_E6), H__NOTE(_E6), Q__NOTE(_E6), \ - H__NOTE(_FS6), WD_NOTE(_E6), + H__NOTE(_FS6), WD_NOTE(_E6), #define PLATINUM_DISCO \ H__NOTE(_DS6), H__NOTE(_FS6), H__NOTE(_GS6), H__NOTE(_AS6), H__NOTE(_DS6), H__NOTE(_FS6), W__NOTE(_GS6), H__NOTE(_DS6), H__NOTE(_FS6), \ @@ -778,7 +777,7 @@ WD_NOTE(_FS6), H__NOTE(_CS6), WD_NOTE(_DS6), H__NOTE(_CS6), WD_NOTE(_DS6), H__NOTE(_CS6), H__NOTE(_DS6), H__NOTE(_FS6), \ H__NOTE(_GS6), H__NOTE(_AS6), H__NOTE(_CS7), H__NOTE(_AS6), H__NOTE(_GS6), H__NOTE(_FS6), H__NOTE(_DS6), W__NOTE(_FS6), \ H__NOTE(_CS6), H__NOTE(_DS6), W__NOTE(_FS6), H__NOTE(_FS6), H__NOTE(_GS6), H__NOTE(_FS6), H__NOTE(_GS6), H__NOTE(_FS6), \ - B__NOTE(_FS6), + B__NOTE(_FS6), #define NOCTURNE_OP_9_NO_1 \ H__NOTE(_BF5), H__NOTE(_C6), H__NOTE(_DF6), H__NOTE(_A5), H__NOTE(_BF5), H__NOTE(_GF5), W__NOTE(_F5), W__NOTE(_F5), W__NOTE(_F5), \ @@ -790,6 +789,6 @@ B__NOTE(_DF5), W__NOTE(_BF4), W__NOTE(_BF5), W__NOTE(_BF5), W__NOTE(_BF5), BD_NOTE(_AF5), W__NOTE(_DF5), H__NOTE(_BF4), \ H__NOTE(_C5), H__NOTE(_DF5), H__NOTE(_GF5), H__NOTE(_GF5), BD_NOTE(_F5), W__NOTE(_EF5), H__NOTE(_F5), H__NOTE(_EF5), \ H__NOTE(_DF5), H__NOTE(_A4), B__NOTE(_AF4), W__NOTE(_DF5), W__NOTE(_EF5), H__NOTE(_F5), H__NOTE(_EF5), H__NOTE(_DF5), \ - H__NOTE(_EF5), BD_NOTE(_F5), + H__NOTE(_EF5), BD_NOTE(_F5), #endif diff --git a/users/pvinis/config.h b/users/pvinis/config.h new file mode 100644 index 0000000000..7f17f2d023 --- /dev/null +++ b/users/pvinis/config.h @@ -0,0 +1,9 @@ +#pragma once + +#ifdef AUDIO_ENABLE +// #define STARTUP_SONG SONG(SONIC_RING) +#endif + +// allow rolling when keys have hold functionality +#define IGNORE_MOD_TAP_INTERRUPT +// #define TAPPING_TERM 150 diff --git a/users/pvinis/pvinis.c b/users/pvinis/pvinis.c new file mode 100644 index 0000000000..7544035794 --- /dev/null +++ b/users/pvinis/pvinis.c @@ -0,0 +1,79 @@ +#include "pvinis.h" +#include "version.h" + +#ifdef AUDIO_ENABLE +#include "audio.h" +#endif // AUDIO_ENABLE + + +#ifdef AUDIO_ENABLE +// float tone_katamari_rolling_star[][2] = SONG(KATAMARI_ROLLING_STAR); +#endif // AUDIO_ENABLE + + +// SYMBOL + SYSCTL = KBCTL +uint32_t layer_state_set_user(uint32_t state) { + uint32_t intermediate_state = update_tri_layer_state(state, LR_SYMBOL, LR_SYSCTL, LR_KBCTL); + intermediate_state = layer_state_set_user_local(intermediate_state); + return intermediate_state; +} + + +// functions for the individual keymaps to implement if they need something extra +__attribute__ ((weak)) +bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { + return true; +} + + +// handle my own keycodes +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + + case PV_VRSN: + if (record->event.pressed) { + SEND_STRING(QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION); + } + return false; + + case PV_MAKE: + if (!record->event.pressed) { + SEND_STRING("make " QMK_KEYBOARD ":" QMK_KEYMAP +#if (defined(BOOTLOADER_DFU) || defined(BOOTLOADER_LUFA_DFU) || defined(BOOTLOADER_QMK_DFU)) + ":dfu" +#elif defined(BOOTLOADER_HALFKAY) + ":teensy" +#elif defined(BOOTLOADER_CATERINA) + ":avrdude" +#endif + SS_TAP(X_ENTER) + ); + } + return false; + + case PV_FLSH: + reset_keyboard(); + return false; + + case PV_KTMR: + if (record->event.pressed) { +#ifdef AUDIO_ENABLE + // PLAY_SONG(tone_katamari_rolling_star); +#endif + } + return false; + } + return process_record_keymap(keycode, record); +} + + +#ifdef TAP_DANCE_ENABLE +qk_tap_dance_action_t tap_dance_actions[] = { +}; +#endif // TAP_DANCE_ENABLE + + +// init stuff +void keyboard_post_init_user(void) { + keyboard_post_init_user_local(); +} diff --git a/users/pvinis/pvinis.h b/users/pvinis/pvinis.h new file mode 100644 index 0000000000..0c5e2841a1 --- /dev/null +++ b/users/pvinis/pvinis.h @@ -0,0 +1,152 @@ +#pragma once + +#include "quantum.h" + + +// my own keycodes +enum userspace_custom_keycodes { + PV_ = SAFE_RANGE, + + PV_VRSN, // prints firmware version + PV_MAKE, // prints the make command of the keyboard + PV_FLSH, // resets keyboard + PV_KTMR, // play katamari music + + PV_SAFE_RANGE, // used for extra keycodes in the individual keymaps +}; + +enum tap_dance_indexes { + // tap dance + TD_FLSH, // flash keyboard (as if the physical flash key was pressed) +}; + +#define ALLM(kc) LCAG(kc) // easier name for left ctrl-alt-gui +#define PV_ESCC CTL_T(KC_ESC) // esc on tap, ctrl on hold +#define PV_LOCK LCTL(LSFT(KC_PWR)) // lock computer +#define TD_3FLS TD(TD_FLSH) // tap dance 3 times for flash + + +// layers +enum { + LR_BASE = 0, // used for basic keys like the surrounding ctrl, cmd, etc + + LR_QWERTY, + LR_CARPALX, + + LR_SYMBOL, // symbol input (!, @, #, etc) + LR_SYSCTL, // system control (music, volume, keyboard flash, etc) + LR_KBCTL, // keyboard control (version, make, flash, etc) +}; + + +// layer switchers +#define BASE TO(LR_BASE) +#define QWERTY TO(LR_QWERTY) +#define CARPALX TO(LR_CARPALX) + +#define SYMBOL MO(LR_SYMBOL) +#define SYSCTL MO(LR_SYSCTL) +#define KBCTL MO(LR_KBCTL) + + +// layout parts for easy reuse between keyboard keymaps + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define ________________NUMBERS_L__________________ KC_1, KC_2, KC_3, KC_4, KC_5 +#define ________________NUMBERS_R__________________ KC_6, KC_7, KC_8, KC_9, KC_0 + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// | F1 | F2 | F3 | F4 | F5 | | F6 | F7 | F8 | F9 | F10 | +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define ______________________F_L__________________ KC_F1, KC_F2, KC_F3, KC_F4, KC_F5 +#define ______________________F_R__________________ KC_F6, KC_F7, KC_F8, KC_F9, KC_F10 + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// | Q | W | E | R | T | | Y | U | I | O | P | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | A | S | D | F | G | | H | J | K | L | ; | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | Z | X | C | V | B | | N | M | , | . | / | +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define _________________QWERTY_L1_________________ KC_Q , KC_W , KC_E , KC_R , KC_T +#define _________________QWERTY_L2_________________ KC_A , KC_S , KC_D , KC_F , KC_G +#define _________________QWERTY_L3_________________ KC_Z , KC_X , KC_C , KC_V , KC_B + +#define _________________QWERTY_R1_________________ KC_Y , KC_U , KC_I , KC_O , KC_P +#define _________________QWERTY_R2_________________ KC_H , KC_J , KC_K , KC_L , KC_SCLN +#define _________________QWERTY_R3_________________ KC_N , KC_M , KC_COMM, KC_DOT , KC_SLSH + +#define _____________MOD_QWERTY_L2_________________ KC_A , SFT_T(KC_S), GUI_T(KC_D), KC_F , KC_G +#define _____________MOD_QWERTY_R2_________________ KC_H , KC_J , GUI_T(KC_K), SFT_T(KC_L), KC_SCLN + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// | Q | G | M | L | W | | Y | F | I | O | P | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | D | S | T | N | R | | I | A | K | L | ; | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | Z | X | C | V | J | | K | P | , | . | / | +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define ________________CARPALX_L1_________________ KC_Q , KC_G , KC_M , KC_L , KC_W +#define ________________CARPALX_L2_________________ KC_D , KC_S , KC_T , KC_N , KC_R +#define ________________CARPALX_L3_________________ KC_Z , KC_X , KC_C , KC_V , KC_J + +#define ________________CARPALX_R1_________________ KC_Y , KC_F , KC_U , KC_B , KC_SCLN +#define ________________CARPALX_R2_________________ KC_I , KC_A , KC_E , KC_O , KC_H +#define ________________CARPALX_R3_________________ KC_K , KC_P , KC_COMM, KC_DOT , KC_SLSH + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// | ! | @ | { | } | _ | | \ | | ` | | | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | # | $ | ( | ) | - | | = | & | ' | " | | | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | % | ^ | [ | ] | + | | * | ~ | < | > | / | +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define _________________SYMBOL_L1_________________ KC_EXLM, KC_AT , KC_LCBR, KC_RCBR, KC_UNDS +#define _________________SYMBOL_L2_________________ KC_HASH, KC_DLR , KC_LPRN, KC_RPRN, KC_MINS +#define _________________SYMBOL_L3_________________ KC_PERC, KC_CIRC, KC_LBRC, KC_RBRC, KC_PLUS + +#define _________________SYMBOL_R1_________________ KC_BSLS, _______, KC_GRV , _______, _______ +#define _________________SYMBOL_R2_________________ KC_EQL , KC_AMPR, KC_QUOT, KC_DQUO, KC_PIPE +#define _________________SYMBOL_R3_________________ KC_ASTR, KC_TILD, KC_LABK, KC_RABK, KC_SLSH + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// | | | | | | |MUTE |HOME | ^ | END | | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | | | | | | |VOLUP| < | v | > | | +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// | | | | | | |VOLDN|MPREV|MPLAY|MNEXT| | +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define _________________SYSCTL_L1_________________ +#define _________________SYSCTL_L2_________________ +#define _________________SYSCTL_L3_________________ + +// vol v ctl v +#define _________________SYSCTL_R1_________________ KC_MUTE , KC_HOME , KC_UP , KC_END , PV_LOCK +#define _________________SYSCTL_R2_________________ KC_VOLU , KC_LEFT , KC_DOWN , KC_RGHT /* < arrows */ , KC_SLEP +#define _________________SYSCTL_R3_________________ KC_VOLD , KC_MPRV , KC_MPLY , KC_MNXT /* < music */ , KC_PWR + +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +// |XXXXX|XXXXX|XXXXX|XXXXX|XXXXX| |XXXXX|XXXXX|XXXXX|XXXXX|XXXXX| +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// |XXXXX|XXXXX|XXXXX|XXXXX|XXXXX| |XXXXX|VERSN|MAKE |FLASH|XXXXX| +// ,-----+-----+-----x-----x-----, ,-----x-----x-----+-----+-----, +// |XXXXX|XXXXX|XXXXX|XXXXX|XXXXX| |XXXXX|XXXXX|XXXXX|XXXXX|XXXXX| +// ,-----+-----+-----+-----+-----, ,-----+-----+-----+-----+-----, +#define __________________KBCTL_L1_________________ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX +#define __________________KBCTL_L2_________________ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX +#define __________________KBCTL_L3_________________ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + +#define __________________KBCTL_R1_________________ XXXXXXX, XXXXXXX, XXXXXXX, PV_KTMR, XXXXXXX +#define __________________KBCTL_R2_________________ XXXXXXX, PV_VRSN, PV_MAKE, PV_FLSH, XXXXXXX +#define __________________KBCTL_R3_________________ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + +// we need wrappers in order for these definitions, because they need to be expanded before being used as arguments to the LAYOUT_xxx macro +#define LAYOUT_ergodox_pretty_wrapper(...) LAYOUT_ergodox_pretty(__VA_ARGS__) +#define LAYOUT_wrapper(...) LAYOUT(__VA_ARGS__) + + +// extra stuff that might be needed +void keyboard_post_init_user_local(void); +uint32_t layer_state_set_user_local(uint32_t state); diff --git a/users/pvinis/rules.mk b/users/pvinis/rules.mk new file mode 100644 index 0000000000..da10cc7437 --- /dev/null +++ b/users/pvinis/rules.mk @@ -0,0 +1,15 @@ +# add userspace file +SRC += pvinis.c + +AUDIO_ENABLE = no # piezo speaker sounds +RGBLIGHT_ENABLE = no # rgb leds underlight +TAP_DANCE_ENABLE = yes +BACKLIGHT_ENABLE = no # leds under keycaps +#MOUSEKEY_ENABLE = no +#SLEEP_LED_ENABLE = no # no led blinking while sleeping +#NKRO_ENABLE = yes + +# make firmware smaller +LINK_TIME_OPTIMIZATION_ENABLE = yes +CONSOLE_ENABLE = no +COMMAND_ENABLE = no