diff --git a/keyboards/atreus62/rules.mk b/keyboards/atreus62/rules.mk new file mode 100644 index 00000000..49b952e7 --- /dev/null +++ b/keyboards/atreus62/rules.mk @@ -0,0 +1,3 @@ +COMBO_ENABLE = yes + +include ${ROOT_DIR}../../../../../rules.mk diff --git a/rpw.c b/rpw.c index 2db66af8..95cb2e72 100644 --- a/rpw.c +++ b/rpw.c @@ -12,3 +12,27 @@ bool get_permissive_hold(uint16_t keycode, keyrecord_t *record) { } } #endif + +#ifdef COMBO_ENABLE +enum combo_events { + COMBO_BSPC, + COMBO_NUMBAK, + COMBO_TAB, + COMBO_ESC, + COMBO_DEL, +}; + +const uint16_t PROGMEM combo_bspc[] = {KC_O, KC_P, COMBO_END}; +const uint16_t PROGMEM combo_numbak[] = {KC_0, KC_9, COMBO_END}; +const uint16_t PROGMEM combo_tab[] = {KC_Q, KC_W, COMBO_END}; +const uint16_t PROGMEM combo_esc[] = {KC_E, KC_W, COMBO_END}; +const uint16_t PROGMEM combo_del[] = {KC_MINS, KC_EQL, COMBO_END}; + +combo_t key_combos[] = { + [COMBO_BSPC] = COMBO(combo_bspc, KC_BSPC), + [COMBO_NUMBAK] = COMBO(combo_numbak, KC_BSPC), + [COMBO_TAB] = COMBO(combo_tab, KC_TAB), + [COMBO_ESC] = COMBO(combo_esc, KC_ESC), + [COMBO_DEL] = COMBO(combo_del, KC_DEL) +}; +#endif