Browse Source

feat(bluetooth): Add new settings_reset shield.

* Easy to build board/image that will clear
  saved profile/bond information for a fresh
  start for keyboards.
xmkb
Pete Johanson 4 years ago
parent
commit
652bb6ce05
  1. 1
      .github/workflows/build.yml
  2. 10
      app/boards/shields/settings_reset/Kconfig.defconfig
  3. 5
      app/boards/shields/settings_reset/Kconfig.shield
  4. 1
      app/boards/shields/settings_reset/settings_reset.conf
  5. 22
      app/boards/shields/settings_reset/settings_reset.keymap
  6. 24
      app/boards/shields/settings_reset/settings_reset.overlay

1
.github/workflows/build.yml

@ -17,6 +17,7 @@ jobs: @@ -17,6 +17,7 @@ jobs:
- lily58_left
- lily58_right
- romac
- settings_reset
include:
- board: proton_c
shield: clueboard_california

10
app/boards/shields/settings_reset/Kconfig.defconfig

@ -0,0 +1,10 @@ @@ -0,0 +1,10 @@
# Copyright (c) 2020 The ZMK Contributors
# SPDX-License-Identifier: MIT
if SHIELD_SETTINGS_RESET
config ZMK_KEYBOARD_NAME
default "SETTINGS RESET"
endif

5
app/boards/shields/settings_reset/Kconfig.shield

@ -0,0 +1,5 @@ @@ -0,0 +1,5 @@
# Copyright (c) 2020 The ZMK Contributors
# SPDX-License-Identifier: MIT
config SHIELD_SETTINGS_RESET
def_bool $(shields_list_contains,settings_reset)

1
app/boards/shields/settings_reset/settings_reset.conf

@ -0,0 +1 @@ @@ -0,0 +1 @@
CONFIG_ZMK_BLE_CLEAR_BONDS_ON_START=y

22
app/boards/shields/settings_reset/settings_reset.keymap

@ -0,0 +1,22 @@ @@ -0,0 +1,22 @@
/*
* Copyright (c) 2020 The ZMK Contributors
*
* SPDX-License-Identifier: MIT
*/
#include <behaviors.dtsi>
#include <dt-bindings/zmk/keys.h>
/ {
keymap {
compatible = "zmk,keymap";
default_layer {
bindings = <
&reset
>;
};
};
};

24
app/boards/shields/settings_reset/settings_reset.overlay

@ -0,0 +1,24 @@ @@ -0,0 +1,24 @@
/*
* Copyright (c) 2020 The ZMK Contributors
*
* SPDX-License-Identifier: MIT
*/
#include <dt-bindings/zmk/matrix-transform.h>
/ {
chosen {
zmk,kscan = &kscan0;
};
kscan0: kscan {
compatible = "zmk,kscan-gpio-direct";
label = "KSCAN";
input-gpios
= <&pro_micro_d 4 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
;
};
};
Loading…
Cancel
Save