Add support for Geistmaschine Macropod (#20116)

Co-authored-by: Pablo Martínez <58857054+elpekenin@users.noreply.github.com>
This commit is contained in:
Moritz Plattner 2023-04-02 20:02:20 +02:00 committed by GitHub
parent ebe36ea83c
commit 5687fc7646
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 273 additions and 0 deletions

View file

@ -0,0 +1,21 @@
// Copyright 2022 QMK
// SPDX-License-Identifier: GPL-2.0-or-later
#include "quantum.h"
// This will be overridden by encoder map in all default keymaps, but serves as a catch-all for user keymaps that may omit the map.
#if defined (ENCODER_ENABLE) && !defined (ENCODER_MAP_ENABLE)
bool encoder_update_kb(uint8_t index, bool clockwise) {
if (!encoder_update_user(index, clockwise)) {
return false; /* Don't process further events if user function exists and returns false */
}
if (index == 0) { /* First encoder */
if (clockwise) {
tap_code_delay(KC_VOLU, 10);
} else {
tap_code_delay(KC_VOLD, 10);
}
}
return true;
}
#endif