Skip to content

Commit

Permalink
boards: nucleo_l476rg: add ST Morpho connector nexus node
Browse files Browse the repository at this point in the history
Add a new GPIO nexus node for the ST Morpho connector in the board.

Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
  • Loading branch information
mniestroj committed Jun 26, 2023
1 parent de47992 commit 90f3d5f
Show file tree
Hide file tree
Showing 2 changed files with 68 additions and 0 deletions.
1 change: 1 addition & 0 deletions boards/arm/nucleo_l476rg/nucleo_l476rg.dts
Expand Up @@ -8,6 +8,7 @@
#include <st/l4/stm32l476Xg.dtsi>
#include <st/l4/stm32l476r(c-e-g)tx-pinctrl.dtsi>
#include "arduino_r3_connector.dtsi"
#include "st_morpho_connector.dtsi"

/ {
model = "STMicroelectronics STM32L476RG-NUCLEO board";
Expand Down
67 changes: 67 additions & 0 deletions boards/arm/nucleo_l476rg/st_morpho_connector.dtsi
@@ -0,0 +1,67 @@
/*
* Copyright (c) 2023 Marcin Niestroj
* SPDX-License-Identifier: Apache-2.0
*/

#include <zephyr/dt-bindings/gpio/gpio.h>
#include <zephyr/dt-bindings/gpio/st-morpho-header.h>

/ {
st_morpho_header: st-morpho-header {
compatible = "st-morpho-header";
#gpio-cells = <2>;
gpio-map-mask = <ST_MORPHO_PIN_MASK 0x0>;
gpio-map-pass-thru = <0x0 GPIO_DT_FLAGS_MASK>;
gpio-map = <ST_MORPHO_CN7_1 0 &gpioc 10 0>,
<ST_MORPHO_CN7_2 0 &gpioc 11 0>,
<ST_MORPHO_CN7_3 0 &gpioc 12 0>,
<ST_MORPHO_CN7_4 0 &gpiod 2 0>,
<ST_MORPHO_CN7_13 0 &gpioa 13 0>,
<ST_MORPHO_CN7_15 0 &gpioa 14 0>,
<ST_MORPHO_CN7_17 0 &gpioa 15 0>,
<ST_MORPHO_CN7_21 0 &gpiob 7 0>,
<ST_MORPHO_CN7_23 0 &gpioc 13 0>,
<ST_MORPHO_CN7_25 0 &gpioc 14 0>,
<ST_MORPHO_CN7_27 0 &gpioc 15 0>,
<ST_MORPHO_CN7_28 0 &gpioa 0 0>,
<ST_MORPHO_CN7_29 0 &gpioh 0 0>,
<ST_MORPHO_CN7_30 0 &gpioa 1 0>,
<ST_MORPHO_CN7_31 0 &gpioh 1 0>,
<ST_MORPHO_CN7_32 0 &gpioa 4 0>,
<ST_MORPHO_CN7_34 0 &gpiob 0 0>,
<ST_MORPHO_CN7_35 0 &gpioc 2 0>,
<ST_MORPHO_CN7_36 0 &gpioc 1 0>, /* SB56=ON, SB46=OFF */
<ST_MORPHO_CN7_37 0 &gpioc 3 0>,
<ST_MORPHO_CN7_38 0 &gpioc 0 0>, /* SB51=ON, SB52=OFF */
<ST_MORPHO_CN10_1 0 &gpioc 9 0>,
<ST_MORPHO_CN10_2 0 &gpioc 8 0>,
<ST_MORPHO_CN10_3 0 &gpiob 8 0>,
<ST_MORPHO_CN10_4 0 &gpioc 6 0>,
<ST_MORPHO_CN10_5 0 &gpiob 9 0>,
<ST_MORPHO_CN10_6 0 &gpioc 5 0>,
<ST_MORPHO_CN10_11 0 &gpioa 5 0>,
<ST_MORPHO_CN10_12 0 &gpioa 12 0>,
<ST_MORPHO_CN10_13 0 &gpioa 6 0>,
<ST_MORPHO_CN10_14 0 &gpioa 11 0>,
<ST_MORPHO_CN10_15 0 &gpioa 7 0>,
<ST_MORPHO_CN10_16 0 &gpiob 12 0>,
<ST_MORPHO_CN10_17 0 &gpiob 6 0>,
<ST_MORPHO_CN10_18 0 &gpiob 11 0>,
<ST_MORPHO_CN10_19 0 &gpioc 7 0>,
<ST_MORPHO_CN10_21 0 &gpioa 9 0>,
<ST_MORPHO_CN10_22 0 &gpiob 2 0>,
<ST_MORPHO_CN10_23 0 &gpioa 8 0>,
<ST_MORPHO_CN10_24 0 &gpiob 1 0>,
<ST_MORPHO_CN10_25 0 &gpiob 10 0>,
<ST_MORPHO_CN10_26 0 &gpiob 15 0>,
<ST_MORPHO_CN10_27 0 &gpiob 4 0>,
<ST_MORPHO_CN10_28 0 &gpiob 14 0>,
<ST_MORPHO_CN10_29 0 &gpiob 5 0>,
<ST_MORPHO_CN10_30 0 &gpiob 13 0>,
<ST_MORPHO_CN10_31 0 &gpiob 3 0>,
<ST_MORPHO_CN10_33 0 &gpioa 10 0>,
<ST_MORPHO_CN10_34 0 &gpioc 4 0>,
<ST_MORPHO_CN10_35 0 &gpioa 2 0>,
<ST_MORPHO_CN10_37 0 &gpioa 3 0>;
};
};

0 comments on commit 90f3d5f

Please sign in to comment.