boards: stm32: add button and leds gpio definitions

Provide led and button nodes to stm32 based boards.
Provide matching zephyr aliases.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
This commit is contained in:
Erwan Gouriou 2017-11-24 10:08:03 +01:00 committed by Kumar Gala
commit 7c6cf201e0
36 changed files with 1080 additions and 4 deletions

View file

@ -16,6 +16,29 @@
zephyr,sram = &sram0;
zephyr,flash = &flash0;
};
leds {
compatible = "gpio-leds";
green_led_2: led@0 {
gpios = <&gpiod 13 GPIO_INT_ACTIVE_HIGH>;
label = "User LD2";
};
};
gpio_keys {
compatible = "gpio-keys";
#address-cells = <1>;
#size-cells = <0>;
user_button: button@0 {
label = "User";
gpios = <&gpiob 9 GPIO_INT_ACTIVE_LOW>;
};
};
aliases {
led0 = &green_led_2;
sw0 = &user_button;
};
};
&usart2 {