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
13/ {
14	model = "NXP FRDM_MCXA156 board";
15	compatible = "nxp,mcxa156", "nxp,mcx";
16
17	aliases{
18		led0 = &red_led;
19		led1 = &green_led;
20		led2 = &red_led;
21		sw0 = &user_button_2;
22		sw1 = &user_button_3;
23		pwm-0 = &flexpwm0_pwm0;
24		mcuboot-button0 = &user_button_2;
25	};
26
27	chosen {
28		zephyr,sram = &sram0;
29		zephyr,flash = &flash;
30		zephyr,flash-controller = &fmu;
31		zephyr,code-partition = &slot0_partition;
32		zephyr,console = &lpuart0;
33		zephyr,shell-uart = &lpuart0;
34		zephyr,uart-mcumgr = &lpuart0;
35	};
36
37	leds {
38		compatible = "gpio-leds";
39		red_led: led_0 {
40			gpios = <&gpio3 12 GPIO_ACTIVE_LOW>;
41			label = "Red LED";
42		};
43		green_led: led_1 {
44			gpios = <&gpio3 13 GPIO_ACTIVE_LOW>;
45			label = "Green LED";
46		};
47		blue_led: led_2 {
48			gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
49			label = "Blue LED";
50		};
51	};
52
53	gpio_keys {
54		compatible = "gpio-keys";
55		user_button_2: button_2 {
56			label = "User SW2";
57			gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
58			zephyr,code = <INPUT_KEY_0>;
59		};
60		user_button_3: button_3 {
61			label = "User SW3";
62			gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
63			zephyr,code = <INPUT_KEY_1>;
64		};
65	};
66
67};
68
69&gpio0 {
70	status = "okay";
71};
72
73&gpio1 {
74	status = "okay";
75};
76
77&gpio2 {
78	status = "okay";
79};
80
81&gpio3 {
82	status = "okay";
83};
84
85&gpio4 {
86	status = "okay";
87};
88
89&lpuart0 {
90	status = "okay";
91	current-speed = <115200>;
92	pinctrl-0 = <&pinmux_lpuart0>;
93	pinctrl-names = "default";
94};
95
96&ctimer0 {
97	status = "okay";
98};
99
100&dac0 {
101	status = "okay";
102	pinctrl-0 = <&pinmux_dac0>;
103	pinctrl-names = "default";
104};
105
106&flexpwm0_pwm0 {
107	status = "okay";
108	pinctrl-0 = <&pinmux_flexpwm0_pwm0>;
109	pinctrl-names = "default";
110};
111
112&lpadc0 {
113	status = "okay";
114	pinctrl-0 = <&pinmux_lpadc0>;
115	pinctrl-names = "default";
116};
117
118&lpcmp0 {
119	status = "okay";
120	pinctrl-0 = <&pinmux_lpcmp0>;
121	pinctrl-names = "default";
122};
123
124&lpi2c0 {
125	status = "okay";
126	pinctrl-0 = <&pinmux_lpi2c0>;
127	pinctrl-names = "default";
128};
129
130&lpi2c3 {
131	status = "okay";
132	pinctrl-0 = <&pinmux_lpi2c3>;
133	pinctrl-names = "default";
134};
135
136&lptmr0 {
137	status = "okay";
138};
139
140zephyr_udc0: &usb {
141	status = "okay";
142	num-bidir-endpoints = <8>;
143};
144
145&flash {
146	partitions {
147		compatible = "fixed-partitions";
148		#address-cells = <1>;
149		#size-cells = <1>;
150
151		boot_partition: partition@0 {
152			label = "mcuboot";
153			reg = <0x00000000 DT_SIZE_K(64)>;
154			read-only;
155		};
156		slot0_partition: partition@10000 {
157			label = "image-0";
158			reg = <0x00010000 DT_SIZE_K(424)>;
159		};
160		slot1_partition: partition@7a000 {
161			label = "image-1";
162			reg = <0x0007a000 DT_SIZE_K(424)>;
163		};
164		storage_partition: partition@e4000 {
165			label = "storage";
166			reg = <0x000e4000 DT_SIZE_K(112)>;
167		};
168	};
169};
170