Skip to content

Commit

Permalink
add ccedil layer to ZMK
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelromao committed May 8, 2024
1 parent 6e8a06b commit a86f5e1
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 14 deletions.
Binary file modified img/overview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 13 additions & 11 deletions src/zmk/definitions/config.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,19 @@
#define CODING 14
#define NMODS 15
#define ALPHA2 16
#define SHIFT_A2 17
#define CASE_A2 18
#define SYMBOLS 19
#define SEN_CASE 20
#define SEN_E1 21
#define SEN_E2 22
#define NAV 23
#define MEDIA 24
#define NAV_F 25
#define LOCK_KB 26
#define SYSTEM 27
#define CCEDIL 17
#define SHIFT_A2 18
#define CASE_A2 19
#define CASE_CCEDIL 20
#define SYMBOLS 21
#define SEN_CASE 22
#define SEN_E1 23
#define SEN_E2 24
#define NAV 25
#define MEDIA 26
#define NAV_F 27
#define LOCK_KB 28
#define SYSTEM 29

#define TAPPING_TERM 175
#define TD_TAPPING_TERM 225
Expand Down
18 changes: 18 additions & 0 deletions src/zmk/definitions/keymap.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,15 @@
&trans &ht_magic NAV 0 &sl SYMBOLS &trans &mc_sqo &trans
>;
};
ccedil_layer {
label = "ALPHA2";
bindings = <
&trans &trans &trans &trans &trans &trans &ac_ocir &trans &trans &trans
&trans &trans &trans &trans &trans &trans &ac_atil &trans &trans &ac_uacu
&trans &trans &trans &trans &trans &trans &ac_otil &ac_aacu &ac_oacu &trans
&trans &trans &trans &trans &trans &trans
>;
};
shifted_alpha2_layer {
label = "CASE";
bindings = <
Expand All @@ -197,6 +206,15 @@
&trans &ht_magic NAV 0 &sl SYMBOLS &trans &mc_sqo_c &trans
>;
};
case_ccedil_layer {
label = "CASE";
bindings = <
&trans &trans &trans &trans &trans &trans &ac_ocir_c &trans &trans &trans
&trans &trans &trans &trans &trans &trans &ac_atil_c &trans &trans &ac_uacu_c
&trans &trans &trans &trans &trans &trans &ac_otil_c &ac_aacu_c &ac_oacu_c &trans
&trans &trans &trans &trans &trans &trans
>;
};
symbols_layer {
label = "SYMBOLS";
bindings = <
Expand Down
6 changes: 3 additions & 3 deletions src/zmk/features/accents.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,9 @@
ACCENTED_KEY(ac_ocir, O, I , OCIR_TERM, C_OCIR_TERM, S_OCIR_TERM)
ACCENTED_KEY(ac_uacu, U, E , UACU_TERM, C_UACU_TERM, S_UACU_TERM)

MACRO_KEY(mc_ced, &kp C_CEDIL)
MACRO_KEY(mc_ced_c, &kp LS(C_CEDIL))
MACRO_KEY(mc_ced_s, &kp RS(C_CEDIL))
MACRO_KEY(mc_ced, &kp C_CEDIL &sl CCEDIL)
MACRO_KEY(mc_ced_c, &kp LS(C_CEDIL) &sl CASE_CCEDIL)
MACRO_KEY(mc_ced_s, &kp RS(C_CEDIL) &sl CCEDIL)
MACRO_KEY(mc_qu, &macro_tap &kp Q &macro_wait_time 10 &macro_tap &kp U &kp QU_TERM)
MACRO_KEY(mc_qu_c, &macro_press &kp LSHFT &macro_tap &kp Q &macro_wait_time 10 &macro_tap &kp U &macro_release &kp LSHFT &kp QU_TERM)
MACRO_KEY(mc_qu_s, &macro_press &kp LSHFT &macro_tap &kp Q &macro_wait_time 10 &macro_release &kp LSHFT &macro_tap &kp U &kp QU_TERM)
Expand Down

0 comments on commit a86f5e1

Please sign in to comment.