1/* 2 * Copyright (c) 2019 Linumiz 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7/dts-v1/; 8#include <st/f4/stm32f401Xc.dtsi> 9#include <st/f4/stm32f401c(b-c)ux-pinctrl.dtsi> 10 11/ { 12 model = "STMicroelectronics Flight Controller Board"; 13 compatible = "st,flight-controller-board"; 14 15 chosen { 16 zephyr,console = &usart1; 17 zephyr,shell-uart = &usart1; 18 zephyr,sram = &sram0; 19 zephyr,flash = &flash0; 20 }; 21 22 leds { 23 compatible = "gpio-leds"; 24 red_led_1: led_1 { 25 gpios = <&gpiob 5 GPIO_ACTIVE_HIGH>; 26 label = "User LD1"; 27 }; 28 29 red_led_2: led_2 { 30 gpios = <&gpiob 4 GPIO_ACTIVE_HIGH>; 31 label = "User LD2"; 32 }; 33 }; 34 35 aliases { 36 led0 = &red_led_1; 37 led1 = &red_led_2; 38 watchdog0 = &iwdg; 39 }; 40}; 41 42&clk_lsi { 43 status = "okay"; 44}; 45 46&clk_hse { 47 clock-frequency = <DT_FREQ_M(16)>; 48 status = "okay"; 49}; 50 51&pll { 52 div-m = <16>; 53 mul-n = <336>; 54 div-p = <4>; 55 div-q = <7>; 56 clocks = <&clk_hse>; 57 status = "okay"; 58}; 59 60&rcc { 61 clocks = <&pll>; 62 clock-frequency = <DT_FREQ_M(84)>; 63 ahb-prescaler = <1>; 64 apb1-prescaler = <2>; 65 apb2-prescaler = <1>; 66}; 67 68&i2c2 { 69 pinctrl-0 = <&i2c2_sda_pb3 &i2c2_scl_pb10>; 70 pinctrl-names = "default"; 71 status = "okay"; 72 clock-frequency = <I2C_BITRATE_FAST>; 73}; 74 75&usart1 { 76 pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; 77 pinctrl-names = "default"; 78 current-speed = <115200>; 79 status = "okay"; 80}; 81 82&timers2 { 83 status = "okay"; 84 85 pwm2: pwm { 86 status = "okay"; 87 pinctrl-0 = <&tim2_ch1_pa0>; 88 pinctrl-names = "default"; 89 }; 90}; 91 92&rtc { 93 clocks = <&rcc STM32_CLOCK_BUS_APB1 0x10000000>, 94 <&rcc STM32_SRC_LSI RTC_SEL(2)>; 95 status = "okay"; 96}; 97 98&iwdg { 99 status = "okay"; 100}; 101