1/* 2 * Copyright 2024 NXP 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7/dts-v1/; 8 9#include <nxp/nxp_mcxa156.dtsi> 10#include "frdm_mcxa156-pinctrl.dtsi" 11#include <zephyr/dt-bindings/input/input-event-codes.h> 12#include <freq.h> 13 14/ { 15 model = "NXP FRDM_MCXA156 board"; 16 compatible = "nxp,mcxa156", "nxp,mcx"; 17 18 aliases{ 19 led0 = &red_led; 20 led1 = &green_led; 21 led2 = &red_led; 22 sw0 = &user_button_2; 23 sw1 = &user_button_3; 24 pwm-0 = &flexpwm0_pwm0; 25 mcuboot-button0 = &user_button_2; 26 watchdog0 = &wwdt0; 27 ambient-temp0 = &p3t1755; 28 die-temp0 = &temp0; 29 }; 30 31 chosen { 32 zephyr,sram = &sram0; 33 zephyr,flash = &flash; 34 zephyr,flash-controller = &fmu; 35 zephyr,code-partition = &slot0_partition; 36 zephyr,console = &lpuart0; 37 zephyr,shell-uart = &lpuart0; 38 zephyr,uart-mcumgr = &lpuart0; 39 zephyr,canbus = &flexcan0; 40 }; 41 42 leds { 43 compatible = "gpio-leds"; 44 red_led: led_0 { 45 gpios = <&gpio3 12 GPIO_ACTIVE_LOW>; 46 label = "Red LED"; 47 }; 48 green_led: led_1 { 49 gpios = <&gpio3 13 GPIO_ACTIVE_LOW>; 50 label = "Green LED"; 51 }; 52 blue_led: led_2 { 53 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>; 54 label = "Blue LED"; 55 }; 56 }; 57 58 gpio_keys { 59 compatible = "gpio-keys"; 60 user_button_2: button_2 { 61 label = "User SW2"; 62 gpios = <&gpio1 7 GPIO_ACTIVE_LOW>; 63 zephyr,code = <INPUT_KEY_0>; 64 }; 65 user_button_3: button_3 { 66 label = "User SW3"; 67 gpios = <&gpio0 6 GPIO_ACTIVE_LOW>; 68 zephyr,code = <INPUT_KEY_1>; 69 }; 70 }; 71 72 /* 73 * This node describes the GPIO pins of the LCD-PAR-S035 panel 8080 interface. 74 */ 75 nxp_lcd_8080_connector: lcd-8080-connector { 76 compatible = "nxp,lcd-8080"; 77 #gpio-cells = <2>; 78 gpio-map-mask = <0xffffffff 0xffffffc0>; 79 gpio-map-pass-thru = <0 0x3f>; 80 gpio-map = <9 0 &gpio2 15 0>, /* Pin 9, LCD touch INT */ 81 <10 0 &gpio3 22 0>, /* Pin 10, LCD backlight control */ 82 <11 0 &gpio3 0 0>; /* Pin 11, LCD and touch reset */ 83 }; 84 85 arduino_header: arduino-connector { 86 compatible = "arduino-header-r3"; 87 #gpio-cells = <2>; 88 gpio-map-mask = <0xffffffff 0xffffffc0>; 89 gpio-map-pass-thru = <0 0x3f>; 90 gpio-map = <0 0 &gpio1 10 0>, /* A0 */ 91 <1 0 &gpio2 5 0>, /* A1 */ 92 <2 0 &gpio2 3 0>, /* A2 */ 93 <3 0 &gpio2 4 0>, /* A3 */ 94 <4 0 &gpio1 12 0>, /* A4 */ 95 <5 0 &gpio1 13 0>, /* A5 */ 96 <6 0 &gpio2 11 0>, /* D0 */ 97 <7 0 &gpio2 10 0>, /* D1 */ 98 <8 0 &gpio3 1 0>, /* D2 */ 99 <9 0 &gpio3 12 0>, /* D3 */ 100 <10 0 &gpio3 31 0>, /* D4 */ 101 <11 0 &gpio3 14 0>, /* D5 */ 102 <12 0 &gpio3 16 0>, /* D6 */ 103 <13 0 &gpio1 14 0>, /* D7 */ 104 <14 0 &gpio1 15 0>, /* D8 */ 105 <15 0 &gpio3 17 0>, /* D9 */ 106 <16 0 &gpio3 13 0>, /* D10 */ 107 <17 0 &gpio3 15 0>, /* D11 */ 108 <18 0 &gpio2 16 0>, /* D12 */ 109 <19 0 &gpio2 12 0>, /* D13 */ 110 <20 0 &gpio0 16 0>, /* D14 */ 111 <21 0 &gpio0 17 0>; /* D15 */ 112 }; 113}; 114 115&gpio0 { 116 status = "okay"; 117}; 118 119&gpio1 { 120 status = "okay"; 121}; 122 123&gpio2 { 124 status = "okay"; 125}; 126 127&gpio3 { 128 status = "okay"; 129}; 130 131&gpio4 { 132 status = "okay"; 133}; 134 135&lpuart0 { 136 status = "okay"; 137 current-speed = <115200>; 138 pinctrl-0 = <&pinmux_lpuart0>; 139 pinctrl-names = "default"; 140}; 141 142&lpuart1 { 143 status = "okay"; 144 current-speed = <115200>; 145 pinctrl-0 = <&pinmux_lpuart1>; 146 pinctrl-names = "default"; 147}; 148 149&ctimer0 { 150 status = "okay"; 151}; 152 153&dac0 { 154 status = "okay"; 155 pinctrl-0 = <&pinmux_dac0>; 156 pinctrl-names = "default"; 157}; 158 159&edma0 { 160 status = "okay"; 161}; 162 163&flexcan0 { 164 status = "okay"; 165 pinctrl-0 = <&pinmux_flexcan0>; 166 pinctrl-names = "default"; 167}; 168 169&flexio0 { 170 status = "okay"; 171}; 172 173nxp_8080_touch_panel_i2c: &lpi2c2 { 174 pinctrl-0 = <&pinmux_lpi2c2>; 175 pinctrl-names = "default"; 176}; 177 178zephyr_mipi_dbi_parallel: &flexio0_lcd { 179 /* DMA channels 0, muxed to FlexIO TX */ 180 dmas = <&edma0 0 71>; 181 dma-names = "tx"; 182 shifters-count = <4>; 183 timers-count = <1>; 184 enwr-pin = <31>; 185 rd-pin = <28>; 186 data-pin-start = <0>; 187 reset-gpios = <&gpio3 0 GPIO_ACTIVE_HIGH>; 188 cs-gpios = <&gpio2 19 GPIO_ACTIVE_HIGH>; 189 rs-gpios = <&gpio2 17 GPIO_ACTIVE_HIGH>; 190 pinctrl-0 = <&pinmux_flexio_lcd>; 191 pinctrl-names = "default"; 192}; 193 194&flexpwm0_pwm0 { 195 status = "okay"; 196 pinctrl-0 = <&pinmux_flexpwm0_pwm0>; 197 pinctrl-names = "default"; 198}; 199 200&i3c0 { 201 status = "okay"; 202 pinctrl-0 = <&pinmux_i3c0>; 203 pinctrl-names = "default"; 204 205 i2c-scl-hz = <DT_FREQ_K(400)>; 206 i3c-scl-hz = <DT_FREQ_M(4)>; 207 i3c-od-scl-hz = <DT_FREQ_K(1500)>; 208 209 p3t1755: p3t1755@4800000236152a0090 { 210 compatible = "nxp,p3t1755"; 211 reg = <0x48 0x0236 0x152a0090>; 212 status = "okay"; 213 }; 214}; 215 216&lpadc0 { 217 status = "okay"; 218 pinctrl-0 = <&pinmux_lpadc0>; 219 pinctrl-names = "default"; 220}; 221 222&lpcmp0 { 223 status = "okay"; 224 pinctrl-0 = <&pinmux_lpcmp0>; 225 pinctrl-names = "default"; 226}; 227 228&lpi2c0 { 229 status = "okay"; 230 pinctrl-0 = <&pinmux_lpi2c0>; 231 pinctrl-names = "default"; 232}; 233 234&lpi2c3 { 235 status = "okay"; 236 pinctrl-0 = <&pinmux_lpi2c3>; 237 pinctrl-names = "default"; 238}; 239 240&lpspi0 { 241 status = "okay"; 242 pinctrl-0 = <&pinmux_lpspi0>; 243 pinctrl-names = "default"; 244}; 245 246&lptmr0 { 247 status = "okay"; 248}; 249 250/* 251 * Uses OS timer as the kernel timer 252 */ 253&ostimer0 { 254 status = "okay"; 255}; 256 257zephyr_udc0: &usb { 258 status = "okay"; 259 num-bidir-endpoints = <8>; 260}; 261 262&wwdt0 { 263 status = "okay"; 264}; 265 266&flash { 267 partitions { 268 compatible = "fixed-partitions"; 269 #address-cells = <1>; 270 #size-cells = <1>; 271 272 boot_partition: partition@0 { 273 label = "mcuboot"; 274 reg = <0x00000000 DT_SIZE_K(64)>; 275 read-only; 276 }; 277 slot0_partition: partition@10000 { 278 label = "image-0"; 279 reg = <0x00010000 DT_SIZE_K(424)>; 280 }; 281 slot1_partition: partition@7a000 { 282 label = "image-1"; 283 reg = <0x0007a000 DT_SIZE_K(424)>; 284 }; 285 storage_partition: partition@e4000 { 286 label = "storage"; 287 reg = <0x000e4000 DT_SIZE_K(112)>; 288 }; 289 }; 290}; 291