boards: st: fix STM32G0 boards DTS files coding style
Fix board DTS coding style issues to prevent they spread when a new board is introduced and used this DTS as example start point. Issues addressed from Zephyr devicetree style guidelines [1]: - Insert a single empty line to separate nodes at the same hierarchy level. No functional change. Link: https://docs.zephyrproject.org/latest/contribute/style/devicetree.html [1] Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
This commit is contained in:
parent
3782c24ad7
commit
e8e3560ecf
7 changed files with 36 additions and 1 deletions
|
@ -22,6 +22,7 @@
|
||||||
|
|
||||||
leds: leds {
|
leds: leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
green_led_3: led_3 {
|
green_led_3: led_3 {
|
||||||
gpios = <&gpioc 6 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpioc 6 GPIO_ACTIVE_HIGH>;
|
||||||
label = "User LD3";
|
label = "User LD3";
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
|
|
||||||
leds: leds {
|
leds: leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
green_led_1: led_4 {
|
green_led_1: led_4 {
|
||||||
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
||||||
label = "User LD4";
|
label = "User LD4";
|
||||||
|
@ -33,6 +34,7 @@
|
||||||
|
|
||||||
gpio_keys {
|
gpio_keys {
|
||||||
compatible = "gpio-keys";
|
compatible = "gpio-keys";
|
||||||
|
|
||||||
user_button: button {
|
user_button: button {
|
||||||
label = "User";
|
label = "User";
|
||||||
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
||||||
|
@ -101,6 +103,7 @@
|
||||||
&timers3 {
|
&timers3 {
|
||||||
st,prescaler = <10000>;
|
st,prescaler = <10000>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
pwm3: pwm {
|
pwm3: pwm {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
pinctrl-0 = <&tim3_ch1_pa6>;
|
pinctrl-0 = <&tim3_ch1_pa6>;
|
||||||
|
|
|
@ -23,9 +23,9 @@
|
||||||
zephyr,flash = &flash0;
|
zephyr,flash = &flash0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
leds: leds {
|
leds: leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
green_led_1: led_4 {
|
green_led_1: led_4 {
|
||||||
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
||||||
label = "User LD4";
|
label = "User LD4";
|
||||||
|
@ -34,6 +34,7 @@
|
||||||
|
|
||||||
gpio_keys {
|
gpio_keys {
|
||||||
compatible = "gpio-keys";
|
compatible = "gpio-keys";
|
||||||
|
|
||||||
user_button: button {
|
user_button: button {
|
||||||
label = "User";
|
label = "User";
|
||||||
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
||||||
|
@ -107,6 +108,7 @@
|
||||||
&timers3 {
|
&timers3 {
|
||||||
st,prescaler = <10000>;
|
st,prescaler = <10000>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
pwm3: pwm {
|
pwm3: pwm {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
pinctrl-0 = <&tim3_ch1_pa6>;
|
pinctrl-0 = <&tim3_ch1_pa6>;
|
||||||
|
|
|
@ -27,6 +27,7 @@
|
||||||
|
|
||||||
leds: leds {
|
leds: leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
green_led_1: led_4 {
|
green_led_1: led_4 {
|
||||||
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
||||||
label = "User LD4";
|
label = "User LD4";
|
||||||
|
@ -35,6 +36,7 @@
|
||||||
|
|
||||||
gpio_keys {
|
gpio_keys {
|
||||||
compatible = "gpio-keys";
|
compatible = "gpio-keys";
|
||||||
|
|
||||||
user_button: button {
|
user_button: button {
|
||||||
label = "User";
|
label = "User";
|
||||||
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
||||||
|
@ -115,6 +117,7 @@ zephyr_udc0: &usb {
|
||||||
&timers3 {
|
&timers3 {
|
||||||
st,prescaler = <10000>;
|
st,prescaler = <10000>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
pwm3: pwm {
|
pwm3: pwm {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
pinctrl-0 = <&tim3_ch1_pb4>;
|
pinctrl-0 = <&tim3_ch1_pb4>;
|
||||||
|
@ -125,6 +128,7 @@ zephyr_udc0: &usb {
|
||||||
&timers15 {
|
&timers15 {
|
||||||
st,prescaler = <10000>;
|
st,prescaler = <10000>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
pwm15: pwm {
|
pwm15: pwm {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
pinctrl-0 = <&tim15_ch1_pb14>;
|
pinctrl-0 = <&tim15_ch1_pb14>;
|
||||||
|
@ -205,14 +209,17 @@ zephyr_udc0: &usb {
|
||||||
reg = <0x00000000 DT_SIZE_K(48)>;
|
reg = <0x00000000 DT_SIZE_K(48)>;
|
||||||
read-only;
|
read-only;
|
||||||
};
|
};
|
||||||
|
|
||||||
slot0_partition: partition@C000 {
|
slot0_partition: partition@C000 {
|
||||||
label = "image-0";
|
label = "image-0";
|
||||||
reg = <0x0000C000 DT_SIZE_K(200)>;
|
reg = <0x0000C000 DT_SIZE_K(200)>;
|
||||||
};
|
};
|
||||||
|
|
||||||
slot1_partition: partition@3E000 {
|
slot1_partition: partition@3E000 {
|
||||||
label = "image-1";
|
label = "image-1";
|
||||||
reg = <0x0003E000 DT_SIZE_K(200)>;
|
reg = <0x0003E000 DT_SIZE_K(200)>;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* final 64KiB reserved for app storage partition */
|
/* final 64KiB reserved for app storage partition */
|
||||||
storage_partition: partition@70000 {
|
storage_partition: partition@70000 {
|
||||||
label = "storage";
|
label = "storage";
|
||||||
|
|
|
@ -28,6 +28,7 @@
|
||||||
|
|
||||||
leds {
|
leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
green_led_1: led_2 {
|
green_led_1: led_2 {
|
||||||
gpios = <&gpioa 12 GPIO_ACTIVE_LOW>;
|
gpios = <&gpioa 12 GPIO_ACTIVE_LOW>;
|
||||||
label = "User LD2";
|
label = "User LD2";
|
||||||
|
@ -36,6 +37,7 @@
|
||||||
|
|
||||||
gpio_keys {
|
gpio_keys {
|
||||||
compatible = "gpio-keys";
|
compatible = "gpio-keys";
|
||||||
|
|
||||||
user_button: button {
|
user_button: button {
|
||||||
label = "User";
|
label = "User";
|
||||||
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
|
gpios = <&gpioa 0 GPIO_ACTIVE_LOW>;
|
||||||
|
|
|
@ -23,18 +23,22 @@
|
||||||
|
|
||||||
leds {
|
leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
red_led_4: led4 {
|
red_led_4: led4 {
|
||||||
gpios = <&gpiod 9 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 9 GPIO_ACTIVE_HIGH>;
|
||||||
label = "TO_REC";
|
label = "TO_REC";
|
||||||
};
|
};
|
||||||
|
|
||||||
red_led_5: led5 {
|
red_led_5: led5 {
|
||||||
gpios = <&gpiod 8 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 8 GPIO_ACTIVE_HIGH>;
|
||||||
label = "TO_PLUG";
|
label = "TO_PLUG";
|
||||||
};
|
};
|
||||||
|
|
||||||
green_led_6: led6 {
|
green_led_6: led6 {
|
||||||
gpios = <&gpiod 5 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 5 GPIO_ACTIVE_HIGH>;
|
||||||
label = "SINK_SPY";
|
label = "SINK_SPY";
|
||||||
};
|
};
|
||||||
|
|
||||||
green_led_7: led7 {
|
green_led_7: led7 {
|
||||||
gpios = <&gpioc 12 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpioc 12 GPIO_ACTIVE_HIGH>;
|
||||||
label = "SOURCE";
|
label = "SOURCE";
|
||||||
|
@ -43,26 +47,31 @@
|
||||||
|
|
||||||
gpio_keys {
|
gpio_keys {
|
||||||
compatible = "gpio-keys";
|
compatible = "gpio-keys";
|
||||||
|
|
||||||
joy_sel: button0 {
|
joy_sel: button0 {
|
||||||
label = "JOY_SEL";
|
label = "JOY_SEL";
|
||||||
gpios = <&gpioc 0 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 0 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_ENTER>;
|
zephyr,code = <INPUT_KEY_ENTER>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_left: button1 {
|
joy_left: button1 {
|
||||||
label = "JOY_LEFT";
|
label = "JOY_LEFT";
|
||||||
gpios = <&gpioc 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_LEFT>;
|
zephyr,code = <INPUT_KEY_LEFT>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_down: button2 {
|
joy_down: button2 {
|
||||||
label = "JOY_DOWN";
|
label = "JOY_DOWN";
|
||||||
gpios = <&gpioc 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_DOWN>;
|
zephyr,code = <INPUT_KEY_DOWN>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_right: button3 {
|
joy_right: button3 {
|
||||||
label = "JOY_RIGHT";
|
label = "JOY_RIGHT";
|
||||||
gpios = <&gpioc 3 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 3 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_RIGHT>;
|
zephyr,code = <INPUT_KEY_RIGHT>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_up: button4 {
|
joy_up: button4 {
|
||||||
label = "JOY_UP";
|
label = "JOY_UP";
|
||||||
gpios = <&gpioc 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
|
@ -72,6 +81,7 @@
|
||||||
|
|
||||||
cc_config {
|
cc_config {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
encc1 {
|
encc1 {
|
||||||
gpios = <&gpiob 10 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiob 10 GPIO_ACTIVE_HIGH>;
|
||||||
label = "ENCC1";
|
label = "ENCC1";
|
||||||
|
|
|
@ -22,18 +22,22 @@
|
||||||
|
|
||||||
leds {
|
leds {
|
||||||
compatible = "gpio-leds";
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
led_1: led1 {
|
led_1: led1 {
|
||||||
gpios = <&gpiod 5 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 5 GPIO_ACTIVE_HIGH>;
|
||||||
label = "LED1";
|
label = "LED1";
|
||||||
};
|
};
|
||||||
|
|
||||||
led_2: led2 {
|
led_2: led2 {
|
||||||
gpios = <&gpiod 6 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 6 GPIO_ACTIVE_HIGH>;
|
||||||
label = "LED2";
|
label = "LED2";
|
||||||
};
|
};
|
||||||
|
|
||||||
led_3: led3 {
|
led_3: led3 {
|
||||||
gpios = <&gpiod 8 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 8 GPIO_ACTIVE_HIGH>;
|
||||||
label = "LED3";
|
label = "LED3";
|
||||||
};
|
};
|
||||||
|
|
||||||
led_4: led4 {
|
led_4: led4 {
|
||||||
gpios = <&gpiod 9 GPIO_ACTIVE_HIGH>;
|
gpios = <&gpiod 9 GPIO_ACTIVE_HIGH>;
|
||||||
label = "LED4";
|
label = "LED4";
|
||||||
|
@ -42,26 +46,31 @@
|
||||||
|
|
||||||
gpio_keys {
|
gpio_keys {
|
||||||
compatible = "gpio-keys";
|
compatible = "gpio-keys";
|
||||||
|
|
||||||
joy_sel: button0 {
|
joy_sel: button0 {
|
||||||
label = "JOY_SEL";
|
label = "JOY_SEL";
|
||||||
gpios = <&gpioa 0 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioa 0 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_ENTER>;
|
zephyr,code = <INPUT_KEY_ENTER>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_left: button1 {
|
joy_left: button1 {
|
||||||
label = "JOY_LEFT";
|
label = "JOY_LEFT";
|
||||||
gpios = <&gpioc 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_LEFT>;
|
zephyr,code = <INPUT_KEY_LEFT>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_down: button2 {
|
joy_down: button2 {
|
||||||
label = "JOY_DOWN";
|
label = "JOY_DOWN";
|
||||||
gpios = <&gpioc 3 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 3 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_DOWN>;
|
zephyr,code = <INPUT_KEY_DOWN>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_right: button3 {
|
joy_right: button3 {
|
||||||
label = "JOY_RIGHT";
|
label = "JOY_RIGHT";
|
||||||
gpios = <&gpioc 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
zephyr,code = <INPUT_KEY_RIGHT>;
|
zephyr,code = <INPUT_KEY_RIGHT>;
|
||||||
};
|
};
|
||||||
|
|
||||||
joy_up: button4 {
|
joy_up: button4 {
|
||||||
label = "JOY_UP";
|
label = "JOY_UP";
|
||||||
gpios = <&gpioc 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
gpios = <&gpioc 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
||||||
|
@ -121,6 +130,7 @@
|
||||||
|
|
||||||
&timers15 {
|
&timers15 {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
pwm15: pwm {
|
pwm15: pwm {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
pinctrl-0 = <&tim15_ch1_pc1>;
|
pinctrl-0 = <&tim15_ch1_pc1>;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue