1/*
2 * Copyright (c) 2024 Renesas Electronics Corporation
3 * SPDX-License-Identifier: Apache-2.0
4 */
5
6/dts-v1/;
7
8#include <renesas/ra/ra4/r7fa4w1ad2cng.dtsi>
9#include <dt-bindings/gpio/gpio.h>
10#include <dt-bindings/input/input-event-codes.h>
11#include <zephyr/dt-bindings/adc/adc.h>
12#include "ek_ra4w1-pinctrl.dtsi"
13
14/ {
15	model = "Renesas EK-RA4W1";
16	compatible = "renesas,ra4w1", "renesas,ra";
17
18	chosen {
19		zephyr,sram = &sram0;
20		zephyr,flash = &flash0;
21		zephyr,console = &uart0;
22		zephyr,shell-uart = &uart0;
23		zephyr,entropy = &trng;
24	};
25
26	leds {
27		compatible = "gpio-leds";
28		led1: led1 {
29			gpios = <&ioport1 6 GPIO_ACTIVE_HIGH>;
30			label = "LED1";
31		};
32
33		led2: led2 {
34			gpios = <&ioport4 4 GPIO_ACTIVE_HIGH>;
35			label = "LED2";
36		};
37	};
38
39	buttons {
40		compatible = "gpio-keys";
41		button0: s1 {
42			gpios = <&ioport4 2 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>;
43			label = "Push button switch 1";
44			zephyr,code = <INPUT_KEY_0>;
45		};
46	};
47
48	aliases {
49		led0 = &led1;
50		sw0 = &button0;
51	};
52};
53
54&subclk {
55	status = "okay";
56};
57
58&sci0 {
59	pinctrl-0 = <&sci0_default>;
60	pinctrl-names = "default";
61	status = "okay";
62	uart0: uart {
63		current-speed = <115200>;
64		status = "okay";
65	};
66};
67
68&ioport1 {
69	status = "okay";
70};
71
72&ioport4 {
73	status = "okay";
74};
75
76&spi1 {
77	pinctrl-0 = <&spi1_default>;
78	pinctrl-names = "default";
79	status = "okay";
80};
81
82&trng {
83	status = "okay";
84};
85
86&adc0 {
87	status = "okay";
88	pinctrl-0 = <&adc0_default>;
89	pinctrl-names = "default";
90};
91
92&port_irq4 {
93	interrupts = <31 12>;
94	status = "okay";
95};
96
97&pwm1 {
98	pinctrl-0 = <&pwm1_default>;
99	pinctrl-names = "default";
100	interrupts = <8 1>, <9 1>;
101	interrupt-names = "gtioca", "overflow";
102	status = "okay";
103};
104
105&iic0 {
106	pinctrl-0 = <&iic0_default>;
107	pinctrl-names = "default";
108	#address-cells = <1>;
109	#size-cells = <0>;
110	clock-frequency = <DT_FREQ_M(1)>;
111	interrupts = <10 1>, <11 1>, <12 1>, <13 1>;
112	interrupt-names = "rxi", "txi", "tei", "eri";
113	status = "okay";
114};
115