blob: 9e2765382d4fe57ca4a0e8493d67b381ffd2e2f0 [file] [log] [blame]
/*
* Copyright (c) 2020 Nordic Semiconductor ASA
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/gpio/arduino-header-r3.h>
/ {
leds {
compatible = "gpio-leds";
led0: led_0 {
gpios = <&gpio0 28 GPIO_ACTIVE_LOW>;
label = "Green LED 0";
};
led1: led_1 {
gpios = <&gpio0 29 GPIO_ACTIVE_LOW>;
label = "Green LED 1";
};
led2: led_2 {
gpios = <&gpio0 30 GPIO_ACTIVE_LOW>;
label = "Green LED 2";
};
led3: led_3 {
gpios = <&gpio0 31 GPIO_ACTIVE_LOW>;
label = "Green LED 3";
};
};
buttons {
compatible = "gpio-keys";
button0: button_0 {
gpios = <&gpio0 23 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button 1";
zephyr,code = <INPUT_KEY_0>;
};
button1: button_1 {
gpios = <&gpio0 24 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button 2";
zephyr,code = <INPUT_KEY_1>;
};
button2: button_2 {
gpios = <&gpio0 8 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button 3";
zephyr,code = <INPUT_KEY_2>;
};
button3: button_3 {
gpios = <&gpio0 9 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
label = "Push button 4";
zephyr,code = <INPUT_KEY_3>;
};
};
arduino_header: connector {
compatible = "arduino-header-r3";
#gpio-cells = <2>;
gpio-map-mask = <0xffffffff 0xffffffc0>;
gpio-map-pass-thru = <0 0x3f>;
gpio-map = <ARDUINO_HEADER_R3_A0 0 &gpio0 4 0>,
<ARDUINO_HEADER_R3_A1 0 &gpio0 5 0>,
<ARDUINO_HEADER_R3_A2 0 &gpio0 6 0>,
<ARDUINO_HEADER_R3_A3 0 &gpio0 7 0>,
<ARDUINO_HEADER_R3_A4 0 &gpio0 25 0>,
<ARDUINO_HEADER_R3_A5 0 &gpio0 26 0>,
<ARDUINO_HEADER_R3_D0 0 &gpio1 0 0>,
<ARDUINO_HEADER_R3_D1 0 &gpio1 1 0>,
<ARDUINO_HEADER_R3_D2 0 &gpio1 4 0>,
<ARDUINO_HEADER_R3_D3 0 &gpio1 5 0>,
<ARDUINO_HEADER_R3_D4 0 &gpio1 6 0>,
<ARDUINO_HEADER_R3_D5 0 &gpio1 7 0>,
<ARDUINO_HEADER_R3_D6 0 &gpio1 8 0>,
<ARDUINO_HEADER_R3_D7 0 &gpio1 9 0>,
<ARDUINO_HEADER_R3_D8 0 &gpio1 10 0>,
<ARDUINO_HEADER_R3_D9 0 &gpio1 11 0>,
<ARDUINO_HEADER_R3_D10 0 &gpio1 12 0>,
<ARDUINO_HEADER_R3_D11 0 &gpio1 13 0>,
<ARDUINO_HEADER_R3_D12 0 &gpio1 14 0>,
<ARDUINO_HEADER_R3_D13 0 &gpio1 15 0>,
<ARDUINO_HEADER_R3_D14 0 &gpio1 2 0>,
<ARDUINO_HEADER_R3_D15 0 &gpio1 3 0>;
};
/* These aliases are provided for compatibility with samples */
aliases {
led0 = &led0;
led1 = &led1;
led2 = &led2;
led3 = &led3;
sw0 = &button0;
sw1 = &button1;
sw2 = &button2;
sw3 = &button3;
mcuboot-button0 = &button0;
mcuboot-led0 = &led0;
};
};