Skip to content

Instantly share code, notes, and snippets.

@bouzuya
Last active Sep 9, 2019
Embed
What would you like to do?
ErgoDox EZ bouzuya v23
#include "ergodox.h"
#include "action_layer.h"
#define L0 0
#define L1 1
#define L2 2
#define L3 3
#define L4 4
enum custom_keycodes {
PLACEHOLDER = SAFE_RANGE
};
#define _______ KC_TRNS
#define XXXXXXX KC_NO
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[L0] = KEYMAP(
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, KC_Q, KC_W, KC_E, KC_R, KC_T, XXXXXXX,
XXXXXXX, CTL_T(KC_A), KC_S, KC_D, KC_F, KC_G,
XXXXXXX, SFT_T(KC_Z), KC_X, KC_C, KC_V, KC_B, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_LALT,
XXXXXXX, XXXXXXX,
XXXXXXX,
TO(L1), GUI_T(KC_SPC), XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, KC_Y, KC_U, KC_I, KC_O, KC_P, XXXXXXX,
KC_H, KC_J, KC_K, KC_L, OSL(L3), XXXXXXX,
XXXXXXX, KC_N, KC_M, KC_COMM, KC_DOT, SFT_T(KC_SLSH), XXXXXXX,
KC_RCTL, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX,
XXXXXXX,
XXXXXXX, GUI_T(KC_SPC), TO(L2)),
[L1] = KEYMAP(
_______, _______, _______, _______, _______, _______, _______,
_______, KC_EXLM, KC_DQUO, KC_HASH, KC_DLR, KC_PERC, _______,
_______, _______, _______, _______, _______, _______,
_______, _______, KC_TILDE, KC_GRV, KC_EQL, KC_PIPE, _______,
_______, _______, _______, _______, _______,
_______, RESET,
_______,
_______, _______, _______,
_______, _______, _______, _______, _______, _______, _______,
_______, KC_AMPR, KC_QUOT, KC_LPRN, KC_RPRN, KC_UNDS, _______,
KC_HOME, KC_PGDN, KC_PGUP, KC_END, _______, _______,
_______, KC_PLUS, KC_ASTR, KC_LCBR, KC_RCBR, _______, _______,
_______, _______, _______, _______, _______,
RESET, _______,
_______,
_______, _______, _______),
[L2] = KEYMAP(
_______, _______, _______, _______, _______, _______, _______,
_______, KC_1, KC_2, KC_3, KC_4, KC_5, _______,
_______, KC_DOT, KC_SLSH, KC_ASTR, KC_MINS, KC_PLUS,
_______, _______, KC_GRV, KC_AT, KC_MINS, KC_BSLS, _______,
_______, _______, _______, _______, _______,
_______, _______,
_______,
_______, _______, _______,
_______, _______, _______, _______, _______, _______, _______,
_______, KC_6, KC_7, KC_8, KC_9, KC_0, _______,
KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, _______, _______,
_______, KC_SCLN, KC_COLN, KC_LBRC, KC_RBRC, _______, _______,
_______, _______, _______, _______, _______,
_______, _______,
_______,
_______, _______, _______),
[L3] = KEYMAP(
_______, _______, _______, _______, _______, _______, _______,
_______, KC_ESC, _______, KC_END, OSL(L4), _______, _______,
_______, KC_HOME, _______, KC_DEL, KC_RGHT, _______,
_______, _______, _______, _______, _______, KC_LEFT, _______,
_______, _______, _______, _______, _______,
_______, _______,
_______,
_______, _______, _______,
_______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, KC_TAB, _______, KC_UP, _______,
KC_BSPC, KC_LANG1, TO(L0), KC_LANG2, _______, _______,
_______, KC_DOWN, KC_ENT, _______, _______, _______, _______,
_______, _______, _______, _______, _______,
_______, _______,
_______,
_______, _______, _______),
[L4] = KEYMAP(
_______, _______, _______, _______, _______, _______, _______,
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, _______,
_______, KC_F11, KC_F12, KC_F13, KC_F14, KC_F15,
_______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______,
_______, _______,
_______,
_______, _______, _______,
_______, _______, _______, _______, _______, _______, _______,
_______, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, _______,
KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, _______,
_______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______,
_______, _______,
_______,
_______, _______, _______)};
void matrix_scan_user(void)
{
uint8_t layer = biton32(layer_state);
ergodox_board_led_off();
ergodox_right_led_1_off();
ergodox_right_led_2_off();
ergodox_right_led_3_off();
switch (layer)
{
case 1:
ergodox_right_led_1_on();
break;
case 2:
ergodox_right_led_2_on();
break;
case 3:
ergodox_right_led_3_on();
break;
case 4:
ergodox_right_led_1_on();
ergodox_right_led_2_on();
break;
case 5:
ergodox_right_led_1_on();
ergodox_right_led_3_on();
break;
case 6:
ergodox_right_led_2_on();
ergodox_right_led_3_on();
break;
case 7:
ergodox_right_led_1_on();
ergodox_right_led_2_on();
ergodox_right_led_3_on();
break;
default:
break;
}
}
@bouzuya

This comment has been minimized.

Copy link
Owner Author

@bouzuya bouzuya commented Sep 6, 2017

v18

https://gist.github.com/bouzuya/cb95efa40691ab8a556ddd487ac87346/7eb8a88afe4ae26c31c61e92269d61423e2007ea

  • バックスラッシュが入力できないのを修正

v19

https://gist.github.com/bouzuya/cb95efa40691ab8a556ddd487ac87346/cded3376c2859129857bb89b519d2a5596d18229

  • mod tap を A (ctrl), L2 . (ctrl), Z (shift), / (shift), space (gui) に導入
  • 4 行目の shift を削除
  • 親指に space (gui) を追加
  • alt の位置を移動
  • L4 を L0 から L3 に移動
@bouzuya

This comment has been minimized.

Copy link
Owner Author

@bouzuya bouzuya commented Sep 7, 2017

v20

https://gist.github.com/bouzuya/cb95efa40691ab8a556ddd487ac87346/0843faf14035168e9bd5994b0dd870524957ab9f

  • L1, L2 を入れ替え
  • mod tap を削減
  • let's split v7 に同期
@bouzuya

This comment has been minimized.

Copy link
Owner Author

@bouzuya bouzuya commented Sep 8, 2017

@bouzuya

This comment has been minimized.

Copy link
Owner Author

@bouzuya bouzuya commented Sep 8, 2017

@bouzuya

This comment has been minimized.

Copy link
Owner Author

@bouzuya bouzuya commented Sep 10, 2017

v23

  • Let's Split v10 と同期
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment