summaryrefslogtreecommitdiff
path: root/keyboards/mechwild/obe/keymaps
diff options
context:
space:
mode:
authorLess/Rikki <86894501+lesshonor@users.noreply.github.com>2022-08-05 21:54:22 -0400
committerGitHub <noreply@github.com>2022-08-05 18:54:22 -0700
commit660dedfb176314c9a449c719b98acf9651968ce4 (patch)
tree5ea06365a214588d5126276e4455945fcf0cdf79 /keyboards/mechwild/obe/keymaps
parent8978960a875b61d9e3de6ef0ca60d066e19e4fef (diff)
[Keyboard] encoder map on more mechwild boards (#17894)
Diffstat (limited to 'keyboards/mechwild/obe/keymaps')
-rw-r--r--keyboards/mechwild/obe/keymaps/default/keymap.c15
-rw-r--r--keyboards/mechwild/obe/keymaps/default/rules.mk1
-rw-r--r--keyboards/mechwild/obe/keymaps/via/keymap.c21
-rw-r--r--keyboards/mechwild/obe/keymaps/via/rules.mk2
4 files changed, 27 insertions, 12 deletions
diff --git a/keyboards/mechwild/obe/keymaps/default/keymap.c b/keyboards/mechwild/obe/keymaps/default/keymap.c
index fd91890ae0..59f163cc9d 100644
--- a/keyboards/mechwild/obe/keymaps/default/keymap.c
+++ b/keyboards/mechwild/obe/keymaps/default/keymap.c
@@ -13,15 +13,13 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-
+
#include QMK_KEYBOARD_H
// Defines names for use in layer keycodes and the keymap
enum layer_names {
_BASE,
- _FN1,
- _FN2,
- _FN3
+ _FN1
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
@@ -33,7 +31,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_UP, KC_RSFT,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(1), KC_SPC, KC_RALT, MO(2), KC_LEFT, KC_DOWN, KC_RGHT
),
- [_FN1] = LAYOUT(
+ [_FN1] = LAYOUT(
KC_TRNS, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS, KC_DEL,
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_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
@@ -41,3 +39,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
),
};
+
+#ifdef ENCODER_MAP_ENABLE
+ const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
+ [_BASE] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
+ [_FN1] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
+ };
+#endif
diff --git a/keyboards/mechwild/obe/keymaps/default/rules.mk b/keyboards/mechwild/obe/keymaps/default/rules.mk
new file mode 100644
index 0000000000..ee32568148
--- /dev/null
+++ b/keyboards/mechwild/obe/keymaps/default/rules.mk
@@ -0,0 +1 @@
+ENCODER_MAP_ENABLE = yes
diff --git a/keyboards/mechwild/obe/keymaps/via/keymap.c b/keyboards/mechwild/obe/keymaps/via/keymap.c
index 23b9309901..cd6dcda001 100644
--- a/keyboards/mechwild/obe/keymaps/via/keymap.c
+++ b/keyboards/mechwild/obe/keymaps/via/keymap.c
@@ -13,15 +13,15 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-
+
#include QMK_KEYBOARD_H
// Defines names for use in layer keycodes and the keymap
enum layer_names {
_BASE,
_FN1,
- _FN2,
- _FN3
+ _FN2,
+ _FN3
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
@@ -33,21 +33,21 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_UP, KC_RSFT,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(1), KC_SPC, KC_RALT, MO(2), KC_LEFT, KC_DOWN, KC_RGHT
),
- [_FN1] = LAYOUT(
+ [_FN1] = LAYOUT(
KC_TRNS, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS, KC_DEL,
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_CAPS, 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
),
- [_FN2] = LAYOUT(
+ [_FN2] = LAYOUT(
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
),
- [_FN3] = LAYOUT(
+ [_FN3] = LAYOUT(
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,
@@ -55,3 +55,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
)
};
+
+#ifdef ENCODER_MAP_ENABLE
+ const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
+ [_BASE] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
+ [_FN1] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
+ [_FN2] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
+ [_FN3] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
+ };
+#endif
diff --git a/keyboards/mechwild/obe/keymaps/via/rules.mk b/keyboards/mechwild/obe/keymaps/via/rules.mk
index 16d33cd89f..f1adcab005 100644
--- a/keyboards/mechwild/obe/keymaps/via/rules.mk
+++ b/keyboards/mechwild/obe/keymaps/via/rules.mk
@@ -1,2 +1,2 @@
VIA_ENABLE = yes
-
+ENCODER_MAP_ENABLE = yes