Previously the definition was copied almost 1:1 from the `none` behavior
in order to set up the important files and have a small running, but
featureless sample.
This change introduces a way to actually configure the custom lock
behavior, using the following syntax:
```
behaviors {
dead_lock_prevent {
compatible = "zmk,behavior-custom-lock";
// to define a key
dead: dead_key {
#binding-cells = <2>;
bindings = <&kp>, <&kp>;
}
// or to define a macro
deadm: dead_macro {
#binding-cells = <2>;
bindings = <¯o>, <&kp>;
}
}
}
```
Additionally, there's now no standard definition flying around (deletion
of `dts/behaviors/custom_lock.dtsi`)
Signed-off-by: Sophie Tyalie <dev@flowerpot.me>
This is the first commit introducing custom lock behavior. Currently
does nothing, except existing and that one can reference it in the
keyboard layout not dissimilar to e.g. `&none`.
The code is also orientated along the latter for right now, ready to be
extended.
Signed-off-by: Sophie Tyalie <dev@flowerpot.me>
To combine multiple sticky modifiers, the sticky keys must ignore
other (sticky) modifier keypresses.
This behavior is important for "callum-style mods", where all modifiers
are sticky mods.
Fixes#829
* 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.
* Use lesser-known DT features to skip behaviors not referenced
in the user keymap
* Update the behaviors to skip code if no nodes found.
* Remove some empty config/data structs where unused in
behaviors.
Added a new setting to remember the user's preferred endpoint. When both USB and
BLE are connected, the preferred endpoint will be used.
Added a new behavior to control this setting. It supports commands:
&end END_USB - Prefer USB output
&end END_BLE - Prefer BLE output
&end END_TOG - Toggle between USB and BLE
* Add `bt` behavior that can be used to perform certain actions,
such as next/prev identity, reset identity, etc.
NOTE: Multiple identities is only supported for non-split shields,
due to missing Zephyr identity functionality for dual
central/peripheral devices.
* Proper bond reset tied to action, that honors peripheral bonds,
so folks can reset and pair to other hosts, without breaking
bonds between splt halves.
* Add initial event manager implementation,
roughly mimicking Nordic's API.
* Add `position_state_changed` and
`keycode_state_changed` events.
* Hook up HID and keymap to new events
instead of using behaviour global event
crazy.
* Use extra comptible = "zmk,behavior-global" to add
behaviors to global bindings for event notification.
* Implement mod-tap, as a keymap binding and global one
to skip tap if other keycode pressed while held.