aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.c
diff options
context:
space:
mode:
authorLouis Burda <quent.burda@gmail.com>2022-12-19 00:33:54 +0100
committerLouis Burda <quent.burda@gmail.com>2022-12-19 00:41:30 +0100
commite4783bbcc4214416befceb53f6af9ebdfb35ba86 (patch)
tree71ae9268017cb3f0b7dabe1e9016970fb137872c /src/main.c
parent8e60c68eac5dbe749c80d1b42160ad1f7de42200 (diff)
downloadsxkbd-e4783bbcc4214416befceb53f6af9ebdfb35ba86.tar.gz
sxkbd-e4783bbcc4214416befceb53f6af9ebdfb35ba86.zip
Add more keys to keymap and add split role detection
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 265b8af..86663b5 100644
--- a/src/main.c
+++ b/src/main.c
@@ -56,6 +56,9 @@ main(void)
void
tud_mount_cb(void)
{
+#ifndef SPLIT_ROLE
+ split_role = MASTER;
+#endif
led_rgb = WS2812_U32RGB(100, 0, 100);
led_mode = LED_ON;
led_reset = true;
@@ -73,6 +76,9 @@ tud_umount_cb(void)
void
tud_suspend_cb(bool remote_wakeup_en)
{
+#ifndef SPLIT_ROLE
+ split_role = SLAVE;
+#endif
led_rgb = WS2812_U32RGB(100, 100, 100);
led_mode = LED_ON;
led_reset = true;