[Keyboard] Add Pearlboards boards to directory (#15005)

Co-authored-by: Ryan <fauxpark@gmail.com>
This commit is contained in:
Koobaczech
2021-12-23 16:43:10 -05:00
committed by GitHub
parent e9d1a711b4
commit e804e28e8e
37 changed files with 1281 additions and 93 deletions

View File

@@ -15,3 +15,28 @@
*/
#include "pandora.h"
// Encoder rotate function
bool encoder_update_user(uint8_t index, bool clockwise) {
/* First encoder */
if (index == 0) {
if (clockwise) {
tap_code(KC_AUDIO_VOL_UP);
} else {
tap_code(KC_AUDIO_VOL_DOWN);
}
}
return true;
}
// Encoder click function
bool dip_switch_update_user(uint8_t index, bool active) {
switch (index) {
/* First encoder */
case 0:
if (active) {
tap_code(KC_MEDIA_PLAY_PAUSE);
}
break;
}
return true;
}