1/*
2 * Copyright (c) 2024 BayLibre
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7/dts-v1/;
8#include <st/f4/stm32f469Xi.dtsi>
9#include <st/f4/stm32f469nihx-pinctrl.dtsi>
10#include "arduino_r3_connector.dtsi"
11#include "adi_sdp_120pin_connector.dtsi"
12
13/ {
14	model = "Analog Devices Inc. SDP-K1 board";
15	compatible = "adi,sdp-k1";
16
17	chosen {
18		zephyr,console = &uart5;
19		zephyr,shell-uart = &uart5;
20		zephyr,sram = &sram0;
21		zephyr,flash = &flash0;
22		zephyr,ccm = &ccm0;
23	};
24
25	leds {
26		compatible = "gpio-leds";
27		status_led: led_ds3 {
28			gpios = <&gpiok 4 GPIO_ACTIVE_HIGH>;
29			label = "Status DS3";
30		};
31		green_led_1: led_ds4 {
32			gpios = <&gpiok 5 GPIO_ACTIVE_HIGH>;
33			label = "User LD1";
34		};
35		orange_led_2: led_ds5 {
36			gpios = <&gpiok 6 GPIO_ACTIVE_HIGH>;
37			label = "User LD2";
38		};
39		red_led_3: led_ds6 {
40			gpios = <&gpiok 7 GPIO_ACTIVE_HIGH>;
41			label = "User LD3";
42		};
43	};
44
45	otghs_ulpi_phy: otghs_ulpis_phy {
46		compatible = "usb-ulpi-phy";
47		reset-gpios = <&gpiod 7 (GPIO_ACTIVE_LOW)>;
48		#phy-cells = <0>;
49	};
50
51	aliases {
52		led0 = &status_led;
53	};
54};
55
56&clk_lsi {
57	status = "okay";
58};
59
60&clk_hse {
61	clock-frequency = <DT_FREQ_M(8)>;
62	status = "okay";
63};
64
65&pll {
66	div-m = <8>;
67	mul-n = <336>;
68	div-p = <2>;
69	div-q = <7>;
70	clocks = <&clk_hse>;
71	status = "okay";
72};
73
74&rcc {
75	clocks = <&pll>;
76	clock-frequency = <DT_FREQ_M(168)>;
77	ahb-prescaler = <1>;
78	apb1-prescaler = <4>;
79	apb2-prescaler = <2>;
80};
81
82&uart5 {
83	pinctrl-0 = <&uart5_tx_pc12 &uart5_rx_pd2>;
84	pinctrl-names = "default";
85	current-speed = <115200>;
86	status = "okay";
87};
88
89zephyr_udc0: &usbotg_hs {
90	pinctrl-0 = <&usb_otg_hs_ulpi_ck_pa5
91		     &usb_otg_hs_ulpi_d0_pa3
92		     &usb_otg_hs_ulpi_d1_pb0
93		     &usb_otg_hs_ulpi_d2_pb1
94		     &usb_otg_hs_ulpi_d3_pb10
95		     &usb_otg_hs_ulpi_d4_pb11
96		     &usb_otg_hs_ulpi_d5_pb12
97		     &usb_otg_hs_ulpi_d6_pb13
98		     &usb_otg_hs_ulpi_d7_pb5
99		     &usb_otg_hs_ulpi_stp_pc0
100		     &usb_otg_hs_ulpi_dir_pc2
101		     &usb_otg_hs_ulpi_nxt_pc3>;
102	pinctrl-names = "default";
103	maximum-speed = "high-speed";
104	/* Enable OTGHSULPIEN rather than OTGHSEN */
105	clocks = <&rcc STM32_CLOCK_BUS_AHB1 0x60000000>,
106		 <&rcc STM32_SRC_PLL_Q NO_SEL>;
107	phys = <&otghs_ulpi_phy>;
108	status = "okay";
109};
110