boards: add zephyr,code properties to the various gpio-keys nodes

Add gpio-keys codes for all boards. These are mostly INPUT_KEY_0 and so
on but I've used some more specific ones where it was obvious that
there's something else on the boards.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
This commit is contained in:
Fabio Baltieri 2023-08-03 10:52:22 +00:00 committed by Carles Cufí
commit 57e0da4d80
306 changed files with 930 additions and 88 deletions

View file

@ -1,5 +1,7 @@
/* SPDX-License-Identifier: Apache-2.0 */
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
aliases {
led0 = &led0;
@ -63,36 +65,43 @@
/* gpio flags need validation */
gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
label = "Push button switch 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
label = "Push button switch 1";
zephyr,code = <INPUT_KEY_1>;
};
button2: button_2 {
/* gpio flags need validation */
gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
label = "Push button switch 2";
zephyr,code = <INPUT_KEY_2>;
};
switch0: switch_0 {
/* gpio flags need validation */
gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 1";
zephyr,code = <INPUT_KEY_3>;
};
switch1: switch_1 {
/* gpio flags need validation */
gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 2";
zephyr,code = <INPUT_KEY_4>;
};
switch2: switch_2 {
/* gpio flags need validation */
gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 3";
zephyr,code = <INPUT_KEY_5>;
};
switch3: switch_3 {
/* gpio flags need validation */
gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 4";
zephyr,code = <INPUT_KEY_6>;
};
};

View file

@ -1,5 +1,7 @@
/* SPDX-License-Identifier: Apache-2.0 */
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
aliases {
led0 = &led0;
@ -58,21 +60,25 @@
/* gpio flags need validation */
gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 1";
zephyr,code = <INPUT_KEY_0>;
};
switch1: switch_1 {
/* gpio flags need validation */
gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 2";
zephyr,code = <INPUT_KEY_1>;
};
switch2: switch_2 {
/* gpio flags need validation */
gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 3";
zephyr,code = <INPUT_KEY_2>;
};
switch3: switch_3 {
/* gpio flags need validation */
gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
label = "DIP SW1 - Switch 4";
zephyr,code = <INPUT_KEY_3>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f412Xg.dtsi>
#include <st/f4/stm32f412c(e-g)ux-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Tocoding Argonkey 96boards";
@ -36,6 +37,7 @@
user_button: button {
label = "User";
gpios = <&gpioa 2 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
#include <st/f4/stm32f401Xe.dtsi>
#include <st/f4/stm32f401r(d-e)tx-pinctrl.dtsi>
#include "96b_lscon.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Seeed Studio Carbon 96boards";
@ -42,6 +43,7 @@
user_button: button {
label = "User";
gpios = <&gpiob 2 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f411Xe.dtsi>
#include <st/f4/stm32f411c(c-e)ux-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Tocoding Neonkey 96boards";
@ -44,6 +45,7 @@
user_button: button_0 {
label = "User";
gpios = <&gpiob 2 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
#include <nordic/nrf52832_qfaa.dtsi>
#include "96b_lscon.dtsi"
#include "96b_nitrogen-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Seeed Studio Nitrogen 96board";
@ -52,6 +53,7 @@
/* gpio flags need validation */
gpios = <&gpio0 27 GPIO_ACTIVE_LOW>;
label = "User Push Button";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f446Xe.dtsi>
#include <st/f4/stm32f446v(c-e)tx-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "STMicroelectronics 96Boards STM32 Sensor Mezzanine board";
@ -40,6 +41,7 @@
user_button: button {
label = "Key";
gpios = <&gpiod 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -4,6 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include "actinius_icarus_common-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Actinius Icarus IoT Dev Board";
@ -59,6 +60,7 @@
button0: button_0 {
gpios = <&gpio0 5 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push Button 1";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -4,6 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include "actinius_icarus_bee_common-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Actinius Icarus Bee";
@ -59,6 +60,7 @@
button0: button_0 {
gpios = <&gpio0 4 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push Button 1";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -5,6 +5,7 @@
*/
#include "actinius_icarus_som_dk_common-pinctrl.dtsi"
#include <dt-bindings/led/led.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Actinius Icarus SoM DK";
@ -40,6 +41,7 @@
button0: button_0 {
gpios = <&gpio0 23 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push Button 1";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
#include <nordic/nrf52840_qiaa.dtsi>
#include "feather_connector.dtsi"
#include "adafruit_feather_nrf52840-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Adafruit Feather nRF52840 Express";
@ -42,6 +43,7 @@
button0: button_0 {
gpios = <&gpio1 2 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button switch";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52840_qiaa.dtsi>
#include "adafruit_itsybitsy_nrf52840-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Adafruit ItsyBitsy nRF52840 Express";
@ -37,6 +38,7 @@
button0: button_0 {
gpios = <&gpio0 29 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button switch";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -5,6 +5,7 @@
*/
#include "arduino_r3_connector.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
leds {
@ -24,6 +25,7 @@
compatible = "gpio-keys";
user_button: button_0 {
gpios = <&gpioc 13 GPIO_ACTIVE_HIGH>;
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52832_qfaa.dtsi>
#include "arduino_nicla_sense_me-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Arduino Nicla Sense ME";
@ -18,6 +19,7 @@
label = "user button";
gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
status = "okay";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -6,6 +6,7 @@
#include <zephyr/dt-bindings/gpio/gpio.h>
#include <mem.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
@ -105,34 +106,42 @@
sw0: sw0 {
gpios = <&gpio0_2 0 GPIO_ACTIVE_HIGH>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
sw1: sw1 {
gpios = <&gpio0_2 1 GPIO_ACTIVE_HIGH>;
label = "SW1";
zephyr,code = <INPUT_KEY_1>;
};
sw2: sw2 {
gpios = <&gpio0_2 2 GPIO_ACTIVE_HIGH>;
label = "SW2";
zephyr,code = <INPUT_KEY_2>;
};
sw3: sw3 {
gpios = <&gpio0_2 3 GPIO_ACTIVE_HIGH>;
label = "SW3";
zephyr,code = <INPUT_KEY_3>;
};
btn0: btn0 {
gpios = <&gpio1_2 0 GPIO_ACTIVE_HIGH>;
label = "BTN0";
zephyr,code = <INPUT_KEY_4>;
};
btn1: btn1 {
gpios = <&gpio1_2 1 GPIO_ACTIVE_HIGH>;
label = "BTN1";
zephyr,code = <INPUT_KEY_5>;
};
btn2: btn2 {
gpios = <&gpio1_2 2 GPIO_ACTIVE_HIGH>;
label = "BTN2";
zephyr,code = <INPUT_KEY_6>;
};
btn3: btn3 {
gpios = <&gpio1_2 3 GPIO_ACTIVE_HIGH>;
label = "BTN3";
zephyr,code = <INPUT_KEY_7>;
};
};

View file

@ -8,6 +8,7 @@
#include <atmel/samc21x18.dtsi>
#include "atsamc21n_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM C21N Xplained Pro";
@ -49,6 +50,7 @@
user_button: button_0 {
gpios = <&portb 19 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "User Button";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <atmel/samd20.dtsi>
#include "atsamd20_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM D20 Xplained Pro";
@ -38,6 +39,7 @@
user_button: button_0 {
gpios = <&porta 15 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <atmel/samd21.dtsi>
#include "atsamd21_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM D21 Xplained Pro";
@ -47,6 +48,7 @@
user_button: button_0 {
gpios = <&porta 15 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <atmel/same5xx20.dtsi>
#include "atsame54_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM E54 Xplained Pro";
@ -47,6 +48,7 @@
button0: button_0 {
gpios = <&portb 31 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <atmel/saml21.dtsi>
#include "atsaml21_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM L21 Xplained Pro";
@ -46,6 +47,7 @@
user_button: button_0 {
gpios = <&porta 2 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <atmel/samr21.dtsi>
#include "atsamr21_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM R21 Xplained Pro";
@ -48,6 +49,7 @@
user_button: button_0 {
gpios = <&porta 28 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <atmel/samr34.dtsi>
#include "atsamr34_xpro-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "SAM R34 Xplained Pro";
@ -46,6 +47,7 @@
user_button: button_0 {
gpios = <&porta 28 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW0";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f412Xg.dtsi>
#include <st/f4/stm32f412r(e-g)tx-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "MXChip AZ3166 IoT Developer Kit";
@ -80,11 +81,13 @@
button_a: button_a {
gpios = <&gpioa 4 (GPIO_ACTIVE_LOW | GPIO_PULL_DOWN)>;
label = "Button A";
zephyr,code = <INPUT_KEY_A>;
};
button_b: button_b {
gpios = <&gpioa 10 (GPIO_ACTIVE_LOW | GPIO_PULL_DOWN)>;
label = "Button B";
zephyr,code = <INPUT_KEY_B>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/g4/stm32g474Xe.dtsi>
#include <st/g4/stm32g474r(b-c-e)tx-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "B-G474E-DPOW1 Discovery board";
@ -44,22 +45,27 @@
joystick_sel: button0 {
label = "JOYSTICK_SEL";
gpios = <&gpioc 13 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_ENTER>;
};
joystick_left: button1 {
label = "JOYSTICK_LEFT";
gpios = <&gpioc 4 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_LEFT>;
};
joystick_down: button2 {
label = "JOYSTICK_DOWN";
gpios = <&gpioc 5 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_DOWN>;
};
joystick_right: button3 {
label = "JOYSTICK_RIGHT";
gpios = <&gpiob 2 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_RIGHT>;
};
joystick_up: button4 {
label = "JOYSTICK_UP";
gpios = <&gpiob 10 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_UP>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/l0/stm32l072Xz.dtsi>
#include <st/l0/stm32l072c(b-z)tx-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "STMicroelectronics B-L072Z-LRWAN1 Discovery kit";
@ -44,6 +45,7 @@
user_button: button_0 {
label = "Push button switch";
gpios = <&gpiob 2 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
#include <st/l4/stm32l4s5Xi.dtsi>
#include <st/l4/stm32l4s5vitx-pinctrl.dtsi>
#include "arduino_r3_connector.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "STMicroelectronics B-L4S5I-IOT01A discovery kit";
@ -39,6 +40,7 @@
user_button: button {
label = "User";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
#include <st/u5/stm32u585Xi.dtsi>
#include <st/u5/stm32u585aiixq-pinctrl.dtsi>
#include "arduino_r3_connector.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
leds {
@ -26,6 +27,7 @@
user_button: button {
label = "User";
gpios = <&gpioc 13 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf51822_qfaa.dtsi>
#include "bbc_microbit-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "BBC Micro:bit";
@ -37,11 +38,13 @@
buttonA: button_0 {
label = "BTN_A";
gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_A>;
};
buttonB: button_1 {
label = "BTN_B";
gpios = <&gpio0 26 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_B>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52833_qiaa.dtsi>
#include "bbc_microbit_v2-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "BBC Micro:bit V2";
@ -37,11 +38,13 @@
buttonA: button_0 {
label = "BTN_A";
gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_A>;
};
buttonB: button_1 {
label = "BTN_B";
gpios = <&gpio0 23 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_B>;
};
};

View file

@ -9,6 +9,7 @@
#include <ti/cc1352r7.dtsi>
#include "beagleconnect_freedom-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
#define BTN_GPIO_FLAGS (GPIO_ACTIVE_LOW | GPIO_PULL_UP)
@ -38,6 +39,7 @@
compatible = "gpio-keys";
button0: button_0 {
gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -5,6 +5,7 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include "bl5340_dvk_cpuapp_common-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
@ -25,26 +26,31 @@
boot_button0: boot_button {
gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
label = "Bootloader button (S4)";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpio_exp0 0 GPIO_ACTIVE_LOW>;
label = "Push button switch 1 (S1)";
zephyr,code = <INPUT_KEY_1>;
};
button2: button_2 {
gpios = <&gpio_exp0 1 GPIO_ACTIVE_LOW>;
label = "Push button switch 2 (S2)";
zephyr,code = <INPUT_KEY_2>;
};
button3: button_3 {
gpios = <&gpio_exp0 2 GPIO_ACTIVE_LOW>;
label = "Push button switch 3 (S9)";
zephyr,code = <INPUT_KEY_3>;
};
button4: button_4 {
gpios = <&gpio_exp0 3 GPIO_ACTIVE_LOW>;
label = "Push button switch 4 (S10)";
zephyr,code = <INPUT_KEY_4>;
};
};

View file

@ -8,6 +8,7 @@
/dts-v1/;
#include <nordic/nrf52832_qfaa.dtsi>
#include "bl652_dvk-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Laird BL652 DVK";
@ -41,10 +42,12 @@
button1: button_1 {
gpios = <&gpio0 11 GPIO_PULL_UP>;
label = "Push button switch 1";
zephyr,code = <INPUT_KEY_0>;
};
button2: button_2 {
gpios = <&gpio0 15 GPIO_PULL_UP>;
label = "Push button switch 2";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -8,6 +8,7 @@
/dts-v1/;
#include <nordic/nrf52833_qiaa.dtsi>
#include "bl653_dvk-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Laird BL653 Dev Kit";
@ -50,18 +51,22 @@
button1: button_1 {
gpios = <&gpio0 11 GPIO_PULL_UP>;
label = "Push button switch 1 (SW1)";
zephyr,code = <INPUT_KEY_0>;
};
button2: button_2 {
gpios = <&gpio0 12 GPIO_PULL_UP>;
label = "Push button switch 2 (SW2)";
zephyr,code = <INPUT_KEY_1>;
};
button3: button_3 {
gpios = <&gpio0 24 GPIO_PULL_UP>;
label = "Push button switch 3 (SW9)";
zephyr,code = <INPUT_KEY_2>;
};
button4: button_4 {
gpios = <&gpio0 22 GPIO_PULL_UP>;
label = "Push button switch 4 (SW10)";
zephyr,code = <INPUT_KEY_3>;
};
};

View file

@ -8,6 +8,7 @@
/dts-v1/;
#include <nordic/nrf52840_qiaa.dtsi>
#include "bl654_dvk-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Laird BL654 Dev Kit";
@ -50,18 +51,22 @@
button1: button_1 {
gpios = <&gpio0 11 GPIO_PULL_UP>;
label = "Push button switch 1 (SW1)";
zephyr,code = <INPUT_KEY_0>;
};
button2: button_2 {
gpios = <&gpio0 12 GPIO_PULL_UP>;
label = "Push button switch 2 (SW2)";
zephyr,code = <INPUT_KEY_1>;
};
button3: button_3 {
gpios = <&gpio0 24 GPIO_PULL_UP>;
label = "Push button switch 3 (SW9)";
zephyr,code = <INPUT_KEY_2>;
};
button4: button_4 {
gpios = <&gpio0 25 GPIO_PULL_UP>;
label = "Push button switch 4 (SW10)";
zephyr,code = <INPUT_KEY_3>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52840_qiaa.dtsi>
#include "bl654_sensor_board-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Laird BL654 Sensor Board";
@ -37,6 +38,7 @@
button1: button_1 {
gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
label = "Push button switch 1 (SW1)";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f407Xe.dtsi>
#include <st/f4/stm32f407v(e-g)tx-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "black_f407ve board";
@ -38,14 +39,17 @@
user_button_0: K0 {
label = "Key K0";
gpios = <&gpioe 4 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_1: K1 {
label = "Key K1";
gpios = <&gpioe 3 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
user_button_UP: K_UP {
label = "Key WK_UP";
gpios = <&gpioa 0 GPIO_ACTIVE_HIGH>;
zephyr,code = <INPUT_KEY_UP>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f407Xg.dtsi>
#include <st/f4/stm32f407z(e-g)tx-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "black_f407zg_pro board";
@ -38,14 +39,17 @@
user_button_0: K0 {
label = "Key K0";
gpios = <&gpiob 9 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_1: K1 {
label = "Key K1";
gpios = <&gpiob 8 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
user_button_UP: K_UP {
label = "Key WK_UP";
gpios = <&gpioa 0 GPIO_ACTIVE_HIGH>;
zephyr,code = <INPUT_KEY_UP>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f401Xc.dtsi>
#include <st/f4/stm32f401c(d-e)ux-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "WeAct Studio Black Pill V3.0 Board";
@ -32,6 +33,7 @@
user_button: button {
label = "KEY";
gpios = <&gpioa 0 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/f4/stm32f401Xe.dtsi>
#include <st/f4/stm32f401c(d-e)ux-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "WeAct Studio Black Pill V3.0 Board";
@ -32,6 +33,7 @@
user_button: button {
label = "KEY";
gpios = <&gpioa 0 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
/dts-v1/;
#include <st/f4/stm32f411Xe.dtsi>
#include <st/f4/stm32f411c(c-e)ux-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "WeAct Studio Black Pill V2.0 Board";
@ -33,6 +34,7 @@
user_button: button {
label = "KEY";
gpios = <&gpioa 0 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52832_qfaa.dtsi>
#include "blueclover_plt_demo_v2_nrf52832-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Blue Clover PLT Demo Board V2";
@ -28,10 +29,12 @@
button0: button_0 {
gpios = <&gpio0 26 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button switch 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpio0 21 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button switch 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52840_qiaa.dtsi>
#include "bt510-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Laird Sentrius BT510 Sensor";
@ -41,10 +42,12 @@
button0: button_0 {
gpios = <&gpio1 10 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button switch 1 (SW1)";
zephyr,code = <INPUT_KEY_0>;
};
tm0: tm_0 {
gpios = <&gpio0 3 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Test mode (TM)";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52840_qiaa.dtsi>
#include "bt610-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Laird BT610 Sensor";
@ -55,10 +56,12 @@
button1: button_1 {
gpios = <&gpio0 24 GPIO_PULL_UP>;
label = "Boot button switch 1 (SW1)";
zephyr,code = <INPUT_KEY_0>;
};
button2: button_2 {
gpios = <&gpio1 1 GPIO_PULL_UP>;
label = "Tamper switch 2 (SW2)";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -9,6 +9,7 @@
#include <ti/cc1352r.dtsi>
#include "../cc1352r1_launchxl/boosterpack_connector.dtsi"
#include "cc1352p1_launchxl-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "TI CC1352P1 LaunchXL";
@ -73,10 +74,12 @@
btn0: btn_0 {
gpios = <&gpio0 15 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
label = "Push button 1";
zephyr,code = <INPUT_KEY_0>;
};
btn1: btn_1 {
gpios = <&gpio0 14 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
label = "Push button 2";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -9,6 +9,7 @@
#include <ti/cc1352r.dtsi>
#include "boosterpack_connector.dtsi"
#include "cc1352r1_launchxl-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
#define BTN_GPIO_FLAGS (GPIO_ACTIVE_LOW | GPIO_PULL_UP)
@ -49,10 +50,12 @@
btn0: btn_0 {
gpios = <&gpio0 15 BTN_GPIO_FLAGS>;
label = "Push button 1";
zephyr,code = <INPUT_KEY_0>;
};
btn1: btn_1 {
gpios = <&gpio0 14 BTN_GPIO_FLAGS>;
label = "Push button 2";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -10,6 +10,7 @@
#include <ti/cc1352r.dtsi>
#include "../cc1352r1_launchxl/boosterpack_connector.dtsi"
#include "cc1352r_sensortag-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
#define BTN_GPIO_FLAGS (GPIO_ACTIVE_LOW | GPIO_PULL_UP)
@ -59,10 +60,12 @@
btn0: btn_0 {
gpios = <&gpio0 15 BTN_GPIO_FLAGS>;
label = "Push button 1";
zephyr,code = <INPUT_KEY_0>;
};
btn1: btn_1 {
gpios = <&gpio0 14 BTN_GPIO_FLAGS>;
label = "Push button 2";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -9,6 +9,7 @@
#include <ti/cc2652r.dtsi>
#include "boosterpack_connector.dtsi"
#include "cc26x2r1_launchxl-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
#define BTN_GPIO_FLAGS (GPIO_ACTIVE_LOW | GPIO_PULL_UP)
@ -48,10 +49,12 @@
btn0: btn_0 {
gpios = <&gpio0 13 BTN_GPIO_FLAGS>;
label = "Push button 1";
zephyr,code = <INPUT_KEY_0>;
};
btn1: btn_1 {
gpios = <&gpio0 14 BTN_GPIO_FLAGS>;
label = "Push button 2";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -5,6 +5,7 @@
#include <ti/cc3220sf.dtsi>
#include "boosterpack_connector.dtsi"
#include "cc3220sf_launchxl-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "TI CC3220SF LaunchXL";
@ -52,11 +53,13 @@
sw2: button_0 {
gpios = <&gpioa2 6 GPIO_ACTIVE_HIGH>;
label = "Push button switch 2";
zephyr,code = <INPUT_KEY_0>;
};
/* Push button 3 */
sw3: button_1 {
gpios = <&gpioa1 5 GPIO_ACTIVE_HIGH>;
label = "Push button switch 3";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -8,6 +8,7 @@
#include <ti/cc3235sf.dtsi>
#include "cc3235sf_launchxl-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "TI CC3235SF LaunchXL";
@ -55,11 +56,13 @@
sw2: button_0 {
gpios = <&gpioa2 6 GPIO_ACTIVE_HIGH>;
label = "Push button switch 2";
zephyr,code = <INPUT_KEY_0>;
};
/* Push button 3 */
sw3: button_1 {
gpios = <&gpioa1 5 GPIO_ACTIVE_HIGH>;
label = "Push button switch 3";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -5,6 +5,7 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include "circuitdojo_feather_nrf9160_common-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Circuit Dojo nRF9160 Feather";
@ -36,6 +37,7 @@
button0: button_0 {
gpios = <&gpio0 12 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Switch 1";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
#include <nxp/nxp_imx7d_m4.dtsi>
#include "colibri_imx7d_m4-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "TORADEX Colibri IMX7D board";
@ -38,6 +39,7 @@
user_switch_1: user_sw_1 {
gpios = <&gpio2 26 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
label = "User SW1";
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -4,6 +4,8 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
aliases {
led0 = &user_led;
@ -24,6 +26,7 @@
user_bt: button_0 {
label = "SW_0";
gpios = <&gpio_prt0 4 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -8,6 +8,7 @@
/dts-v1/;
#include <cypress/psoc6_cm0.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "cy8ckit_062_wifi_bt_m0 with a Cypress PSoC6 SoC";
@ -40,6 +41,7 @@
user_bt: button_0 {
label = "SW_0";
gpios = <&gpio_prt0 4 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -3,6 +3,8 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
aliases {
led0 = &user_led;
@ -23,6 +25,7 @@
user_bt: button_0 {
label = "SW_0";
gpios = <&gpio_prt0 4 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -9,6 +9,7 @@
#include <infineon/psoc6/mpns/CYBLE_416045_02.dtsi>
#include <infineon/psoc6/system_clocks.dtsi>
#include "cy8cproto_063_ble-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "CY8CPROTO-063-BLE PSoC™ 6 BLE Prototyping Kit";
@ -44,6 +45,7 @@
user_bt: button_0 {
label = "SW_0";
gpios = <&gpio_prt0 4 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
zephyr,code = <INPUT_KEY_0>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52832_qfaa.dtsi>
#include "decawave_dwm1001_dev-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Decawave DWM1001-DEV";
@ -57,6 +58,7 @@
button0: button_0 {
gpios = <&gpio0 2 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button switch 0";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52840_qiaa.dtsi>
#include "degu_evk-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Degu Evaluation Kit";
@ -46,14 +47,17 @@
button0: button_0 {
gpios = <&gpio1 0 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW2";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpio1 1 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW3";
zephyr,code = <INPUT_KEY_1>;
};
button2: button_2 {
gpios = <&gpio1 14 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "SW4";
zephyr,code = <INPUT_KEY_2>;
};
};

View file

@ -8,6 +8,7 @@
#include <st/l4/stm32l475Xg.dtsi>
#include <st/l4/stm32l475v(c-e-g)tx-pinctrl.dtsi>
#include "arduino_r3_connector.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "STMicroelectronics B-L475E-IOT01Ax board";
@ -39,6 +40,7 @@
user_button: button_0 {
label = "User";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -9,6 +9,7 @@
/dts-v1/;
#include <nordic/nrf52832_qfaa.dtsi>
#include "ebyte_e73_tbb_nrf52832-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "EBYTE E73-TBB NRF52832";
@ -49,10 +50,12 @@
button0: button_0 {
gpios = <&gpio0 14 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button SW1";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpio0 13 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button SW2";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <silabs/efm32gg12b810f1024gm64.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32GG SLTB009A board";
@ -44,10 +45,12 @@
button0: button_0 {
gpios = <&gpiod 5 GPIO_ACTIVE_HIGH>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpiod 8 GPIO_ACTIVE_HIGH>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -8,6 +8,7 @@
/dts-v1/;
#include <silabs/efm32gg11b820f2048gl192.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32GG SLWSTK6121A board";
@ -47,11 +48,13 @@
/* gpio flags need validation */
gpios = <&gpiod 6 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiod 8 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <silabs/efm32gg11b820f2048gl192.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32GG STK3701A board";
@ -46,11 +47,13 @@
/* gpio flags need validation */
gpios = <&gpioc 8 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpioc 9 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <silabs/efm32hg322f64.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32HG SLSTK3400A board";
@ -44,11 +45,13 @@
/* gpio flags need validation */
gpios = <&gpioc 9 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpioc 10 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -4,6 +4,8 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32PG STK3401A board";
@ -41,11 +43,13 @@
/* gpio flags need validation */
gpios = <&gpiof 6 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiof 7 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -6,6 +6,8 @@
*/
#include "efm32pg_stk3402a-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32PG STK3402A board";
@ -45,11 +47,13 @@
/* gpio flags need validation */
gpios = <&gpiof 6 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiof 7 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <silabs/efm32wg990f256.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs EFM32WG STK3800 board";
@ -44,11 +45,13 @@
/* gpio flags need validation */
gpios = <&gpiob 9 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiob 19 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -4,6 +4,8 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
zephyr,console = &usart0;
@ -41,11 +43,13 @@
/* gpio flags need validation */
gpios = <&gpiof 6 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiof 7 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <silabs/efr32mg21a020f1024im32.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs BRD4180A (Mighty Gecko Radio Board)";
@ -46,11 +47,13 @@
/* gpio flags need validation */
gpios = <&gpiod 2 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiod 3 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <silabs/efr32mg24b220f1536im48.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs BRD4187C (Mighty Gecko Radio Board)";
@ -45,10 +46,12 @@
button0: button_0 {
gpios = <&gpiob GECKO_PIN(1) GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpiob GECKO_PIN(3) GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -4,6 +4,8 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
zephyr,bt-c2h-uart = &usart1;
@ -26,6 +28,7 @@
button0: button_0 {
gpios = <&gpiob GECKO_PIN(1) GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <silabs/efr32mg12p332f1024gl125.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silabs EFR32MG SLTB004A board (aka Thunderboard Sense 2)";
@ -48,11 +49,13 @@
/* gpio flags need validation */
gpios = <&gpiod 14 GPIO_ACTIVE_LOW>;
label = "User Push Button 0";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
/* gpio flags need validation */
gpios = <&gpiod 15 GPIO_ACTIVE_LOW>;
label = "User Push Button 1";
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <silabs/efr32mg24b310f1536im48.dtsi>
#include <silabs/efr32mg24-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Silicon Labs BRD2601B (Mighty Gecko Radio Board)";
@ -45,9 +46,11 @@
compatible = "gpio-keys";
button0: button_0 {
gpios = <&gpiob GECKO_PIN(2) GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpiob GECKO_PIN(3) GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -8,6 +8,7 @@
#include <nxp/nxp_lpc11u67.dtsi>
#include <zephyr/dt-bindings/led/led.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>
#include "faze-pinctrl.dtsi"
@ -35,8 +36,9 @@
/* Handle the USB_SLEEP GPIO as a button. */
usb_sleep_button: button_0 {
gpios = <&gpio0 20 GPIO_ACTIVE_HIGH>;
gpios = <&gpio0 20 GPIO_ACTIVE_HIGH>;
label = "USB sleep button";
zephyr,code = <INPUT_KEY_SLEEP>;
};
};

View file

@ -9,6 +9,7 @@
#include <nxp/nxp_k2x.dtsi>
#include <zephyr/dt-bindings/pwm/pwm.h>
#include "frdm_k22f-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP Freedom MK22F board";
@ -75,10 +76,12 @@
user_button_2: button_0 {
label = "User SW2";
gpios = <&gpioc 1 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_3: button_1 {
label = "User SW3";
gpios = <&gpiob 17 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -4,6 +4,7 @@
#include <nxp/nxp_k6x.dtsi>
#include "frdm_k64f-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP Freedom MK64F board";
@ -50,10 +51,12 @@
user_button_2: button_0 {
label = "User SW2";
gpios = <&gpioc 6 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_3: button_1 {
label = "User SW3";
gpios = <&gpioa 4 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -10,6 +10,7 @@
#include <nxp/nxp_k82fn256vxx15.dtsi>
#include <zephyr/dt-bindings/pwm/pwm.h>
#include "frdm_k82f-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP Kinetis K82 Freedom Board";
@ -79,10 +80,12 @@
user_button_0: button_0 {
label = "User SW2";
gpios = <&gpioa 4 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_1: button_1 {
label = "User SW3";
gpios = <&gpioc 6 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -4,6 +4,7 @@
#include <nxp/nxp_kl25z.dtsi>
#include "frdm_kl25z-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP Freedom KL25Z board";
@ -46,10 +47,12 @@
user_button_0: button_0 {
label = "User SW0";
gpios = <&gpioa 16 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_1: button_1 {
label = "User SW1";
gpios = <&gpioa 17 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -4,6 +4,7 @@
#include <nxp/nxp_kw41z.dtsi>
#include "frdm_kw41z-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP Freedom KW41Z board";
@ -71,10 +72,12 @@
user_button_3: button_0 {
label = "User SW3";
gpios = <&gpioc 4 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_4: button_1 {
label = "User SW4";
gpios = <&gpioc 5 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32e10x/gd32e103vbt6.dtsi>
#include "gd32e103v_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice gd32e103v Evaluation Kit";
@ -45,14 +46,17 @@
wakeup_key: wakeup_key {
label = "WAKEUP_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
tamper_key: tamper_key {
label = "TAMPER_KEY";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_key: user_key {
label = "USER_KEY1";
gpios = <&gpiob 14 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
#include <arm/gigadevice/gd32e50x/gd32e507xe.dtsi>
#include "gd32e507v_start-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32E507V-START";
@ -32,6 +33,7 @@
user_key: user_key {
label = "USER_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
#include <arm/gigadevice/gd32e50x/gd32e507xe.dtsi>
#include "gd32e507z_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32E507Z-EVAL";
@ -40,22 +41,27 @@
key_a: key_a {
label = "KEY_A";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_A>;
};
key_b: key_b {
label = "KEY_B";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_B>;
};
key_c: key_c {
label = "KEY_C";
gpios = <&gpiof 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_C>;
};
key_d: key_d {
label = "KEY_D";
gpios = <&gpiof 14 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_D>;
};
key_cet: key_cet {
label = "KEY_CET";
gpios = <&gpiof 15 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32f403/gd32f403zet6.dtsi>
#include "gd32f403z_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32F403Z Evaluation Kit";
@ -45,18 +46,22 @@
wakeup_key: wakeup_key {
label = "WAKEUP_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
tamper_key: tamper_key {
label = "TAMPER_KEY";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_key1: user_key1 {
label = "USER_KEY1";
gpios = <&gpiof 5 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
user_key2: user_key2 {
label = "USER_KEY2";
gpios = <&gpiof 4 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_2>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32f4xx/gd32f407xk.dtsi>
#include "gd32f407v_start-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32F407V-START";
@ -31,6 +32,7 @@
user_key: user_key {
label = "USER_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32f4xx/gd32f450xk.dtsi>
#include "gd32f450i_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32F450I-EVAL";
@ -41,14 +42,17 @@
wakeup_key: wakeup_key {
label = "WAKEUP_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
tamper_key: tamper_key {
label = "TAMPER_KEY";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_key: user_key {
label = "USER_KEY";
gpios = <&gpiob 14 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
#include <arm/gigadevice/gd32f4xx/gd32f450xk.dtsi>
#include "gd32f450v_start-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32F450V-START";
@ -31,6 +32,7 @@
user_key: user_key {
label = "USER_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32f4xx/gd32f450xk.dtsi>
#include "gd32f450z_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32F450Z-EVAL";
@ -41,14 +42,17 @@
wakeup_key: wakeup_key {
label = "WAKEUP_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
tamper_key: tamper_key {
label = "TAMPER_KEY";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_key: user_key {
label = "USER_KEY";
gpios = <&gpiob 14 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32f4xx/gd32f470ik.dtsi>
#include "gd32f470i_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32F470I-EVAL";
@ -41,14 +42,17 @@
wakeup_key: wakeup_key {
label = "WAKEUP_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
tamper_key: tamper_key {
label = "TAMPER_KEY";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_key: user_key {
label = "USER_KEY";
gpios = <&gpiob 14 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
#include <gigadevice/gd32l23x/gd32l233rc.dtsi>
#include "gd32l233r_eval-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "GigaDevice GD32L233R Evaluation Kit";
@ -45,10 +46,12 @@
wakeup_key: wakeup_key {
label = "WAKEUP_KEY";
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
tamper_key: tamper_key {
label = "TAMPER_KEY";
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <st/g0/stm32g0b1Xe.dtsi>
#include <st/g0/stm32g0b1r(b-c-e)ixn-pinctrl.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Google Twinkie V2";
@ -38,6 +39,7 @@
*/
dfu_detect: dfudetect {
gpios = <&gpioa 14 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nordic/nrf52832_qfaa.dtsi>
#include "holyiot_yj16019-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Holyiot YJ-16019";
@ -31,6 +32,7 @@
button0: button_0 {
gpios = <&gpio0 28 GPIO_ACTIVE_LOW>;
label = "Push button switch";
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -9,6 +9,7 @@
#include <st/f0/stm32f070cbtx-pinctrl.dtsi>
#include <zephyr/dt-bindings/led/led.h>
#include <zephyr/dt-bindings/led/seagate_legend_b1414.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
@ -28,14 +29,17 @@
brd_id0: brd_id_0 {
label = "BRD_ID_0";
gpios = <&gpioc 13 0>;
zephyr,code = <INPUT_KEY_0>;
};
brd_id1: brd_id_1 {
label = "BRD_ID_1";
gpios = <&gpioc 14 0>;
zephyr,code = <INPUT_KEY_1>;
};
brd_id2: brd_id_2 {
label = "BRD_ID_2";
gpios = <&gpioc 15 0>;
zephyr,code = <INPUT_KEY_2>;
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/;
#include <seeed/lora-e5.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "Seeed Studio LoRa-E5 Dev Board";
@ -33,12 +34,14 @@
boot_button: button_0 {
label = "SW1";
gpios = <&gpiob 13 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
user_button: button_1 {
label = "SW2";
gpios = <&gpioa 0 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
/* user_button can be disconnected, using J14 (D0) */
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -7,6 +7,7 @@
/dts-v1/;
#include <nxp/nxp_lpc11u68.dtsi>
#include <zephyr/dt-bindings/input/input-event-codes.h>
#include "lpcxpresso11u68-pinctrl.dtsi"
@ -34,10 +35,12 @@
isp_button: button_0 {
gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
label = "ISP enable button";
zephyr,code = <INPUT_KEY_0>;
};
wake_up_button: button_1 {
gpios = <&gpio0 16 GPIO_ACTIVE_HIGH>;
label = "Wake-up button";
zephyr,code = <INPUT_KEY_WAKEUP>;
};
};

View file

@ -8,6 +8,7 @@
#include <nxp/nxp_lpc51u68.dtsi>
#include "lpcxpresso51u68-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP LPCXPRESSO51U68 board";
@ -51,14 +52,17 @@
btn_wk: button_0 {
label = "Wakeup button";
gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
isp0_button: button_1 {
label = "ISP0 button";
gpios = <&gpio0 31 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
isp1_button: button_2 {
label = "ISP1 button";
gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};
};

View file

@ -8,6 +8,7 @@
#include <nxp/nxp_lpc54xxx_m4.dtsi>
#include "lpcxpresso54114.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP LPCXpresso54114 board";
@ -32,14 +33,17 @@
user_button_1: button_0 {
label = "User SW1";
gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_2: button_1 {
label = "User SW2";
gpios = <&gpio0 31 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_1>;
};
user_button_3: button_2 {
label = "User SW3";
gpios = <&gpio0 4 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_2>;
};
};
};

View file

@ -6,6 +6,7 @@
*/
#include "lpcxpresso55s06-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
@ -51,14 +52,17 @@
btn_wk: button_0 {
label = "Wakeup button";
gpios = <&gpio0 28 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
btn_usr: button_1 {
label = "User button";
gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
btn_isp: button_2 {
label = "ISP button";
gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -5,6 +5,7 @@
*/
#include "lpcxpresso55s16-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
chosen {
@ -50,14 +51,17 @@
btn_wk: button_0 {
label = "Wakeup button";
gpios = <&gpio1 18 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
btn_usr: button_1 {
label = "USR button";
gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
btn_isp: button_2 {
label = "ISP button";
gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_1>;
};
};

View file

@ -8,6 +8,7 @@
#include <nxp/nxp_lpc55S2x.dtsi>
#include "lpcxpresso55s28_common.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP LPCXpresso55S28 board";
@ -34,14 +35,17 @@
user_button_1: button_0 {
label = "User SW1";
gpios = <&gpio0 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_2: button_1 {
label = "User SW2";
gpios = <&gpio1 18 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_1>;
};
user_button_3: button_2 {
label = "User SW3";
gpios = <&gpio1 9 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_2>;
};
};
};

View file

@ -8,6 +8,7 @@
#include <nxp/nxp_lpc55S36_ns.dtsi>
#include "lpcxpresso55s36-pinctrl.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP LPCXpresso55S36 board";
@ -54,10 +55,12 @@
btn_wk: button_0 {
label = "Wakeup button";
gpios = <&gpio1 18 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_WAKEUP>;
};
btn_usr: button_1 {
label = "USR button";
gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
zephyr,code = <INPUT_KEY_0>;
};
};

View file

@ -9,6 +9,7 @@
#include <nxp/nxp_lpc55S6x.dtsi>
#include "lpcxpresso55s69.dtsi"
#include <zephyr/dt-bindings/pwm/pwm.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>
/ {
model = "NXP LPCXpresso55S69 board";
@ -48,14 +49,17 @@
user_button_1: button_0 {
label = "User SW1";
gpios = <&gpio0 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_0>;
};
user_button_2: button_1 {
label = "User SW2";
gpios = <&gpio1 18 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_1>;
};
user_button_3: button_2 {
label = "User SW3";
gpios = <&gpio1 9 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
zephyr,code = <INPUT_KEY_2>;
};
};

Some files were not shown because too many files have changed in this diff Show more