summaryrefslogtreecommitdiff
path: root/app/include/zmk/split/bluetooth/service.h
diff options
context:
space:
mode:
authorPete Johanson <peter@peterjohanson.com>2020-12-20 09:49:42 -0500
committerNick Van Doorn <nick@nv.delivery>2021-11-22 08:42:13 -0800
commitfd609695ae510344c5dbb88f1d253565bd588ea3 (patch)
tree65557196f4bd4d22532bbda17cb531b468cb8af2 /app/include/zmk/split/bluetooth/service.h
parent67d30762529bee82236446d43b98858072f8afd0 (diff)
feature(split): behavior locality support.
* GATT characteristic allowing passng data + behavior label to invoke the behavior on the peripheral side. * Behaviors have a locality setting to specify where they run. * Build reset/power/RGB on peripheral.
Diffstat (limited to 'app/include/zmk/split/bluetooth/service.h')
-rw-r--r--app/include/zmk/split/bluetooth/service.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/app/include/zmk/split/bluetooth/service.h b/app/include/zmk/split/bluetooth/service.h
index b9f9fc3..f0c1d79 100644
--- a/app/include/zmk/split/bluetooth/service.h
+++ b/app/include/zmk/split/bluetooth/service.h
@@ -6,5 +6,19 @@
#pragma once
+#define ZMK_SPLIT_RUN_BEHAVIOR_DEV_LEN 9
+
+struct zmk_split_run_behavior_data {
+ uint8_t position;
+ uint8_t state;
+ uint32_t param1;
+ uint32_t param2;
+} __packed;
+
+struct zmk_split_run_behavior_payload {
+ struct zmk_split_run_behavior_data data;
+ char behavior_dev[ZMK_SPLIT_RUN_BEHAVIOR_DEV_LEN];
+} __packed;
+
int zmk_split_bt_position_pressed(uint8_t position);
int zmk_split_bt_position_released(uint8_t position); \ No newline at end of file