summaryrefslogtreecommitdiff
path: root/app/dts
diff options
context:
space:
mode:
authorKevin <chenkevinh11@gmail.com>2020-09-02 17:37:39 -0700
committerKevin <chenkevinh11@gmail.com>2020-09-02 17:37:39 -0700
commit5b493ef334c32a7074e29b68f779f81cbdf6596c (patch)
tree193a6ebf7e0820a3fbb54f2f42487991b8321144 /app/dts
parent068626d1a74d3883a8ccb2cd514a217098e99420 (diff)
parentd53a8e36ca17f988b7b1df754478baf2e87597e6 (diff)
Merge branch 'main' into docs/encoders
Sync with upstream
Diffstat (limited to 'app/dts')
-rw-r--r--app/dts/behaviors.dtsi1
-rw-r--r--app/dts/behaviors/layer_tap.dtsi12
-rw-r--r--app/dts/behaviors/mod_tap.dtsi5
-rw-r--r--app/dts/bindings/behaviors/zmk,behavior-hold-tap.yaml23
-rw-r--r--app/dts/bindings/behaviors/zmk,behavior-mod-tap.yaml8
5 files changed, 40 insertions, 9 deletions
diff --git a/app/dts/behaviors.dtsi b/app/dts/behaviors.dtsi
index 4cfb7a0..ab70bcc 100644
--- a/app/dts/behaviors.dtsi
+++ b/app/dts/behaviors.dtsi
@@ -2,6 +2,7 @@
#include <behaviors/transparent.dtsi>
#include <behaviors/none.dtsi>
#include <behaviors/mod_tap.dtsi>
+#include <behaviors/layer_tap.dtsi>
#include <behaviors/momentary_layer.dtsi>
#include <behaviors/toggle_layer.dtsi>
#include <behaviors/reset.dtsi>
diff --git a/app/dts/behaviors/layer_tap.dtsi b/app/dts/behaviors/layer_tap.dtsi
new file mode 100644
index 0000000..af7319b
--- /dev/null
+++ b/app/dts/behaviors/layer_tap.dtsi
@@ -0,0 +1,12 @@
+/ {
+ behaviors {
+ lt: behavior_layer_tap {
+ compatible = "zmk,behavior-hold-tap";
+ label = "LAYER_TAP";
+ #binding-cells = <2>;
+ flavor = "tap-preferred";
+ tapping_term_ms = <200>;
+ bindings = <&mo>, <&kp>;
+ };
+ };
+};
diff --git a/app/dts/behaviors/mod_tap.dtsi b/app/dts/behaviors/mod_tap.dtsi
index 8e3b4e9..4ce732b 100644
--- a/app/dts/behaviors/mod_tap.dtsi
+++ b/app/dts/behaviors/mod_tap.dtsi
@@ -1,9 +1,12 @@
/ {
behaviors {
mt: behavior_mod_tap {
- compatible = "zmk,behavior-mod-tap";
+ compatible = "zmk,behavior-hold-tap";
label = "MOD_TAP";
#binding-cells = <2>;
+ flavor = "hold-preferred";
+ tapping_term_ms = <200>;
+ bindings = <&kp>, <&kp>;
};
};
};
diff --git a/app/dts/bindings/behaviors/zmk,behavior-hold-tap.yaml b/app/dts/bindings/behaviors/zmk,behavior-hold-tap.yaml
new file mode 100644
index 0000000..a20578f
--- /dev/null
+++ b/app/dts/bindings/behaviors/zmk,behavior-hold-tap.yaml
@@ -0,0 +1,23 @@
+# Copyright (c) 2020, Cody McGinnis; Okke Formsma
+# SPDX-License-Identifier: MIT
+
+description: Hold or Tap behavior
+
+compatible: "zmk,behavior-hold-tap"
+
+include: two_param.yaml
+
+properties:
+ bindings:
+ type: phandles
+ required: true
+ tapping_term_ms:
+ type: int
+ flavor:
+ type: string
+ required: false
+ default: "hold-preferred"
+ enum:
+ - "hold-preferred"
+ - "balanced"
+ - "tap-preferred" \ No newline at end of file
diff --git a/app/dts/bindings/behaviors/zmk,behavior-mod-tap.yaml b/app/dts/bindings/behaviors/zmk,behavior-mod-tap.yaml
deleted file mode 100644
index 7911082..0000000
--- a/app/dts/bindings/behaviors/zmk,behavior-mod-tap.yaml
+++ /dev/null
@@ -1,8 +0,0 @@
-# Copyright (c) 2020, Pete Johanson
-# SPDX-License-Identifier: MIT
-
-description: Mod-Tap Beavhior
-
-compatible: "zmk,behavior-mod-tap"
-
-include: two_param.yaml