summaryrefslogtreecommitdiffstats
path: root/keyboards/ergodox_ez/ergodox_ez.h
diff options
context:
space:
mode:
authornoroadsleft <18669334+noroadsleft@users.noreply.github.com>2018-06-13 06:55:08 +0200
committerDrashna Jaelre <drashna@live.com>2018-06-13 06:55:08 +0200
commit698ce733b73a2a8d6d41942b514af4c9d45190df (patch)
treef481bf93d49436f0ba7342acb554930a03f30580 /keyboards/ergodox_ez/ergodox_ez.h
parent454bc3c2643029e876e30e266004223f0c8fccee (diff)
downloadqmk_firmware-698ce733b73a2a8d6d41942b514af4c9d45190df.tar.gz
qmk_firmware-698ce733b73a2a8d6d41942b514af4c9d45190df.tar.xz
Ergodox EZ refactor (#3171)
* Refactor matrices and keymaps * Fixes for @ericgebhart keymap * Deleted macro aliases * ericgebhart/keymap.c to LAYOUT_ergodox_wrapper
Diffstat (limited to 'keyboards/ergodox_ez/ergodox_ez.h')
-rw-r--r--keyboards/ergodox_ez/ergodox_ez.h61
1 files changed, 30 insertions, 31 deletions
diff --git a/keyboards/ergodox_ez/ergodox_ez.h b/keyboards/ergodox_ez/ergodox_ez.h
index eda6d767c..dea2b2463 100644
--- a/keyboards/ergodox_ez/ergodox_ez.h
+++ b/keyboards/ergodox_ez/ergodox_ez.h
@@ -106,9 +106,12 @@ inline void ergodox_led_all_set(uint8_t n)
ergodox_right_led_3_set(n);
}
-#define KEYMAP( \
+/*
+ * LEFT HAND: LINES 115-122
+ * RIGHT HAND: LINES 124-131
+ */
+#define LAYOUT_ergodox( \
\
- /* left hand, spatial positions */ \
k00,k01,k02,k03,k04,k05,k06, \
k10,k11,k12,k13,k14,k15,k16, \
k20,k21,k22,k23,k24,k25, \
@@ -118,7 +121,6 @@ inline void ergodox_led_all_set(uint8_t n)
k54, \
k53,k52,k51, \
\
- /* right hand, spatial positions */ \
k07,k08,k09,k0A,k0B,k0C,k0D, \
k17,k18,k19,k1A,k1B,k1C,k1D, \
k28,k29,k2A,k2B,k2C,k2D, \
@@ -147,9 +149,12 @@ inline void ergodox_led_all_set(uint8_t n)
{ k0D, k1D, k2D, k3D, k4D, KC_NO } \
}
-#define KEYMAP_80( \
+/*
+ * LEFT HAND: LINES 158-165
+ * RIGHT HAND: LINES 167-174
+ */
+#define LAYOUT_ergodox_80( \
\
- /* left hand, spatial positions */ \
k00,k01,k02,k03,k04,k05,k06, \
k10,k11,k12,k13,k14,k15,k16, \
k20,k21,k22,k23,k24,k25, \
@@ -159,7 +164,6 @@ inline void ergodox_led_all_set(uint8_t n)
k45,k46,k54, \
k53,k52,k51, \
\
- /* right hand, spatial positions */ \
k07,k08,k09,k0A,k0B,k0C,k0D, \
k17,k18,k19,k1A,k1B,k1C,k1D, \
k28,k29,k2A,k2B,k2C,k2D, \
@@ -188,16 +192,16 @@ inline void ergodox_led_all_set(uint8_t n)
{ k0D, k1D, k2D, k3D, k4D, KC_NO } \
}
-#define KEYMAP_PRETTY( \
- /* left hand, spatial positions */ /* right hand, spatial positions */ \
- L00,L01,L02,L03,L04,L05,L06, R00,R01,R02,R03,R04,R05,R06, \
- L10,L11,L12,L13,L14,L15,L16, R10,R11,R12,R13,R14,R15,R16, \
- L20,L21,L22,L23,L24,L25, R21,R22,R23,R24,R25,R26, \
- L30,L31,L32,L33,L34,L35,L36, R30,R31,R32,R33,R34,R35,R36, \
- L40,L41,L42,L43,L44, R42,R43,R44,R45,R46, \
- L55,L56, R50,R51, \
- L54, R52, \
- L53,L52,L51, R55,R54,R53 ) \
+/* ---------- LEFT HAND ----------- ---------- RIGHT HAND ---------- */
+#define LAYOUT_ergodox_pretty( \
+ L00,L01,L02,L03,L04,L05,L06, R00,R01,R02,R03,R04,R05,R06, \
+ L10,L11,L12,L13,L14,L15,L16, R10,R11,R12,R13,R14,R15,R16, \
+ L20,L21,L22,L23,L24,L25, R21,R22,R23,R24,R25,R26, \
+ L30,L31,L32,L33,L34,L35,L36, R30,R31,R32,R33,R34,R35,R36, \
+ L40,L41,L42,L43,L44, R42,R43,R44,R45,R46, \
+ L55,L56, R50,R51, \
+ L54, R52, \
+ L53,L52,L51, R55,R54,R53 ) \
\
/* matrix positions */ \
{ \
@@ -218,16 +222,16 @@ inline void ergodox_led_all_set(uint8_t n)
{ R06, R16, R26, R36, R46, KC_NO } \
}
-#define KEYMAP_PRETTY_80( \
- /* left hand, spatial positions */ /* right hand, spatial positions */ \
- L00,L01,L02,L03,L04,L05,L06, R00,R01,R02,R03,R04,R05,R06, \
- L10,L11,L12,L13,L14,L15,L16, R10,R11,R12,R13,R14,R15,R16, \
- L20,L21,L22,L23,L24,L25, R21,R22,R23,R24,R25,R26, \
- L30,L31,L32,L33,L34,L35,L36, R30,R31,R32,R33,R34,R35,R36, \
- L40,L41,L42,L43,L44, R42,R43,R44,R45,R46, \
- L55,L56, R50,R51, \
- L45,L46,L54, R52,R40,R41, \
- L53,L52,L51, R55,R54,R53 ) \
+/* ---------- LEFT HAND ----------- ---------- RIGHT HAND ---------- */
+#define LAYOUT_ergodox_pretty_80( \
+ L00,L01,L02,L03,L04,L05,L06, R00,R01,R02,R03,R04,R05,R06, \
+ L10,L11,L12,L13,L14,L15,L16, R10,R11,R12,R13,R14,R15,R16, \
+ L20,L21,L22,L23,L24,L25, R21,R22,R23,R24,R25,R26, \
+ L30,L31,L32,L33,L34,L35,L36, R30,R31,R32,R33,R34,R35,R36, \
+ L40,L41,L42,L43,L44, R42,R43,R44,R45,R46, \
+ L55,L56, R50,R51, \
+ L45,L46,L54, R52,R40,R41, \
+ L53,L52,L51, R55,R54,R53 ) \
\
/* matrix positions */ \
{ \
@@ -248,9 +252,4 @@ inline void ergodox_led_all_set(uint8_t n)
{ R06, R16, R26, R36, R46, KC_NO } \
}
-#define LAYOUT_ergodox KEYMAP
-#define LAYOUT_ergodox_pretty KEYMAP_PRETTY
-#define LAYOUT_ergodox_80 KEYMAP_80
-#define LAYOUT_ergodox_pretty_80 KEYMAP_PRETTY_80
-
#endif