2017-04-26 17:56:36 +02:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2017 Linaro Limited
|
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*/
|
|
|
|
|
|
|
|
/dts-v1/;
|
2018-09-27 08:21:55 -05:00
|
|
|
#include <st/l4/stm32l475Xg.dtsi>
|
2020-10-03 18:23:32 +02:00
|
|
|
#include <st/l4/stm32l475v(c-e-g)tx-pinctrl.dtsi>
|
2019-05-24 14:16:06 +02:00
|
|
|
#include "arduino_r3_connector.dtsi"
|
|
|
|
|
2017-04-26 17:56:36 +02:00
|
|
|
/ {
|
|
|
|
model = "STMicroelectronics B-L475E-IOT01Ax board";
|
2020-09-25 14:57:24 +02:00
|
|
|
compatible = "st,stm32l475-disco-iot";
|
2017-04-26 17:56:36 +02:00
|
|
|
|
|
|
|
chosen {
|
|
|
|
zephyr,console = &usart1;
|
2018-11-27 12:11:04 +01:00
|
|
|
zephyr,shell-uart = &usart1;
|
2017-04-26 17:56:36 +02:00
|
|
|
zephyr,sram = &sram0;
|
|
|
|
zephyr,flash = &flash0;
|
2018-11-15 09:36:41 -06:00
|
|
|
zephyr,code-partition = &slot0_partition;
|
2020-12-18 14:11:41 +01:00
|
|
|
zephyr,flash-controller = &mx25r6435f;
|
2017-04-26 17:56:36 +02:00
|
|
|
};
|
2017-11-24 10:08:03 +01:00
|
|
|
|
|
|
|
leds {
|
|
|
|
compatible = "gpio-leds";
|
2018-09-18 19:45:43 +02:00
|
|
|
green_led_1: led_1 {
|
2019-10-03 18:30:21 +02:00
|
|
|
gpios = <&gpioa 5 GPIO_ACTIVE_HIGH>;
|
2017-11-24 10:08:03 +01:00
|
|
|
label = "User LD1";
|
|
|
|
};
|
2018-09-18 19:45:43 +02:00
|
|
|
green_led_2: led_2 {
|
2019-10-03 18:30:21 +02:00
|
|
|
gpios = <&gpiob 14 GPIO_ACTIVE_HIGH>;
|
2017-11-24 10:08:03 +01:00
|
|
|
label = "User LD2";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
gpio_keys {
|
|
|
|
compatible = "gpio-keys";
|
2018-10-03 09:12:09 +02:00
|
|
|
user_button: button_0 {
|
2017-11-24 10:08:03 +01:00
|
|
|
label = "User";
|
2019-10-03 18:30:21 +02:00
|
|
|
gpios = <&gpioc 13 GPIO_ACTIVE_LOW>;
|
2017-11-24 10:08:03 +01:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2022-08-08 08:19:13 +02:00
|
|
|
power-states {
|
|
|
|
stop0: state0 {
|
|
|
|
compatible = "zephyr,power-state";
|
|
|
|
power-state-name = "suspend-to-idle";
|
|
|
|
substate-id = <1>;
|
|
|
|
min-residency-us = <500>;
|
|
|
|
};
|
|
|
|
stop1: state1 {
|
|
|
|
compatible = "zephyr,power-state";
|
|
|
|
power-state-name = "suspend-to-idle";
|
|
|
|
substate-id = <2>;
|
|
|
|
min-residency-us = <700>;
|
|
|
|
};
|
|
|
|
stop2: state2 {
|
|
|
|
compatible = "zephyr,power-state";
|
|
|
|
power-state-name = "suspend-to-idle";
|
|
|
|
substate-id = <3>;
|
|
|
|
min-residency-us = <1000>;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2017-11-24 10:08:03 +01:00
|
|
|
aliases {
|
|
|
|
led0 = &green_led_2;
|
|
|
|
led1 = &green_led_1;
|
|
|
|
sw0 = &user_button;
|
2018-10-09 18:02:26 +02:00
|
|
|
eswifi0 = &wifi0;
|
2022-07-19 10:33:14 +02:00
|
|
|
watchdog0 = &iwdg;
|
2022-07-19 13:42:10 +02:00
|
|
|
spi-flash0 = &mx25r6435f;
|
2022-07-23 14:58:54 +09:00
|
|
|
accel0 = &lsm6dsl;
|
2017-11-24 10:08:03 +01:00
|
|
|
};
|
2017-04-26 17:56:36 +02:00
|
|
|
};
|
|
|
|
|
2022-08-08 08:19:13 +02:00
|
|
|
&cpu0 {
|
|
|
|
cpu-power-states = <&stop0 &stop1 &stop2>;
|
|
|
|
};
|
|
|
|
|
2022-09-07 09:13:35 +02:00
|
|
|
&clk_lsi {
|
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
2022-08-08 08:19:13 +02:00
|
|
|
&clk_lse {
|
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
2021-05-07 20:50:04 +03:00
|
|
|
&clk_hsi {
|
2021-04-06 10:58:34 +02:00
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
|
|
|
&pll {
|
|
|
|
div-m = <1>;
|
|
|
|
mul-n = <20>;
|
|
|
|
div-p = <7>;
|
|
|
|
div-q = <2>;
|
|
|
|
div-r = <4>;
|
|
|
|
clocks = <&clk_hsi>;
|
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
|
|
|
&rcc {
|
|
|
|
clocks = <&pll>;
|
|
|
|
clock-frequency = <DT_FREQ_M(80)>;
|
2021-05-05 12:27:05 +02:00
|
|
|
ahb-prescaler = <1>;
|
|
|
|
apb1-prescaler = <1>;
|
|
|
|
apb2-prescaler = <1>;
|
2021-04-06 10:58:34 +02:00
|
|
|
};
|
|
|
|
|
2017-04-26 17:56:36 +02:00
|
|
|
&usart1 {
|
|
|
|
current-speed = <115200>;
|
2020-06-05 11:00:23 +02:00
|
|
|
pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>;
|
|
|
|
pinctrl-names = "default";
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2017-07-25 09:27:44 +02:00
|
|
|
};
|
|
|
|
|
2018-09-12 14:55:47 +02:00
|
|
|
&uart4 {
|
2020-10-06 15:09:53 +02:00
|
|
|
pinctrl-0 = <&uart4_tx_pa0 &uart4_rx_pa1>;
|
2021-09-07 16:38:13 +02:00
|
|
|
pinctrl-names = "default";
|
2018-09-12 14:55:47 +02:00
|
|
|
current-speed = <115200>;
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2018-09-12 14:55:47 +02:00
|
|
|
};
|
|
|
|
|
2017-06-29 17:26:38 +03:00
|
|
|
&i2c1 {
|
2020-10-12 17:53:50 +02:00
|
|
|
pinctrl-0 = <&i2c1_scl_pb8 &i2c1_sda_pb9>;
|
2021-11-08 10:59:17 +01:00
|
|
|
pinctrl-names = "default";
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2017-08-10 11:59:14 -05:00
|
|
|
clock-frequency = <I2C_BITRATE_FAST>;
|
2017-06-29 17:26:38 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
&i2c2 {
|
2020-10-12 17:53:50 +02:00
|
|
|
pinctrl-0 = <&i2c2_scl_pb10 &i2c2_sda_pb11>;
|
2021-11-08 10:59:17 +01:00
|
|
|
pinctrl-names = "default";
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2017-08-10 11:59:14 -05:00
|
|
|
clock-frequency = <I2C_BITRATE_FAST>;
|
2017-11-20 16:45:37 +01:00
|
|
|
|
|
|
|
lis3mdl-magn@1e {
|
|
|
|
compatible = "st,lis3mdl-magn";
|
|
|
|
reg = <0x1e>;
|
|
|
|
};
|
|
|
|
|
|
|
|
hts221@5f {
|
|
|
|
compatible = "st,hts221";
|
|
|
|
reg = <0x5f>;
|
2022-08-12 12:05:41 +02:00
|
|
|
drdy-gpios = <&gpiod 15 GPIO_ACTIVE_HIGH>;
|
2017-11-20 16:45:37 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
lps22hb-press@5d {
|
|
|
|
compatible = "st,lps22hb-press";
|
|
|
|
reg = <0x5d>;
|
|
|
|
};
|
|
|
|
|
2022-07-23 14:58:54 +09:00
|
|
|
lsm6dsl: lsm6dsl@6a {
|
2017-11-20 16:45:37 +01:00
|
|
|
compatible = "st,lsm6dsl";
|
|
|
|
reg = <0x6a>;
|
2019-10-15 13:04:09 -05:00
|
|
|
irq-gpios = <&gpiod 11 GPIO_ACTIVE_HIGH>;
|
2017-11-20 16:45:37 +01:00
|
|
|
};
|
2017-07-19 17:07:17 +02:00
|
|
|
|
|
|
|
vl53l0x@29 {
|
|
|
|
compatible = "st,vl53l0x";
|
|
|
|
reg = <0x29>;
|
2019-11-28 16:55:17 +01:00
|
|
|
xshut-gpios = <&gpioc 6 GPIO_ACTIVE_HIGH>;
|
2017-07-19 17:07:17 +02:00
|
|
|
};
|
2017-06-29 17:26:38 +03:00
|
|
|
};
|
|
|
|
|
2019-07-21 12:06:30 +03:00
|
|
|
&i2c3 {
|
2020-10-12 17:53:50 +02:00
|
|
|
pinctrl-0 = <&i2c3_scl_pc0 &i2c3_sda_pc1>;
|
2021-11-08 10:59:17 +01:00
|
|
|
pinctrl-names = "default";
|
2019-07-21 12:06:30 +03:00
|
|
|
status = "okay";
|
|
|
|
clock-frequency = <I2C_BITRATE_FAST>;
|
|
|
|
};
|
|
|
|
|
2018-01-05 20:22:50 +02:00
|
|
|
&spi1 {
|
2020-10-15 17:03:11 +02:00
|
|
|
pinctrl-0 = <&spi1_sck_pa5 &spi1_miso_pa6 &spi1_mosi_pa7>;
|
2021-11-08 12:23:47 +01:00
|
|
|
pinctrl-names = "default";
|
2021-06-17 10:26:53 +02:00
|
|
|
cs-gpios = <&gpioa 2 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2018-01-05 20:22:50 +02:00
|
|
|
};
|
|
|
|
|
2020-10-12 15:20:12 +02:00
|
|
|
&spi3_miso_pc11 { slew-rate = "very-high-speed"; };
|
|
|
|
|
2018-01-05 20:22:50 +02:00
|
|
|
&spi3 {
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2018-01-14 16:37:49 +02:00
|
|
|
|
2020-10-12 15:20:12 +02:00
|
|
|
pinctrl-0 = <&spi3_sck_pc10 &spi3_miso_pc11 &spi3_mosi_pc12>;
|
2021-11-08 12:23:47 +01:00
|
|
|
pinctrl-names = "default";
|
2020-10-12 15:20:12 +02:00
|
|
|
|
2022-03-04 12:05:07 +01:00
|
|
|
cs-gpios = <&gpiod 13 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>,
|
2020-07-04 20:48:57 +02:00
|
|
|
<&gpioe 0 GPIO_ACTIVE_LOW>;
|
2018-05-04 16:19:58 +02:00
|
|
|
|
2019-01-30 15:17:06 +01:00
|
|
|
spbtle-rf@0 {
|
|
|
|
compatible = "zephyr,bt-hci-spi";
|
2018-01-14 16:37:49 +02:00
|
|
|
reg = <0>;
|
2019-12-18 17:45:21 +01:00
|
|
|
reset-gpios = <&gpioa 8 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
|
|
|
|
irq-gpios = <&gpioe 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
|
2018-05-16 14:00:43 +02:00
|
|
|
spi-max-frequency = <2000000>;
|
2018-01-14 16:37:49 +02:00
|
|
|
};
|
2018-10-09 18:02:26 +02:00
|
|
|
|
2018-10-09 18:14:03 +02:00
|
|
|
wifi0: ism43362@1 {
|
2018-10-09 18:02:26 +02:00
|
|
|
compatible = "inventek,eswifi";
|
|
|
|
spi-max-frequency = <2000000>;
|
|
|
|
reg = <1>;
|
2019-12-11 10:11:29 +01:00
|
|
|
resetn-gpios = <&gpioe 8 GPIO_ACTIVE_HIGH>;
|
|
|
|
boot0-gpios = <&gpiob 12 GPIO_ACTIVE_HIGH>;
|
|
|
|
wakeup-gpios = <&gpiob 13 GPIO_ACTIVE_HIGH>;
|
|
|
|
data-gpios = <&gpioe 1 GPIO_ACTIVE_HIGH>;
|
2018-10-09 18:02:26 +02:00
|
|
|
};
|
2018-01-05 20:22:50 +02:00
|
|
|
};
|
|
|
|
|
2017-06-23 12:16:57 +02:00
|
|
|
&flash0 {
|
|
|
|
partitions {
|
|
|
|
compatible = "fixed-partitions";
|
|
|
|
#address-cells = <1>;
|
|
|
|
#size-cells = <1>;
|
|
|
|
|
|
|
|
boot_partition: partition@0 {
|
|
|
|
label = "mcuboot";
|
2022-05-06 14:54:51 +02:00
|
|
|
reg = <0x00000000 DT_SIZE_K(64)>;
|
2017-06-23 12:16:57 +02:00
|
|
|
read-only;
|
|
|
|
};
|
2017-07-19 18:44:59 -04:00
|
|
|
|
|
|
|
/*
|
|
|
|
* The flash starting at offset 0x10000 and ending at
|
|
|
|
* offset 0x1ffff is reserved for use by the application.
|
|
|
|
*/
|
|
|
|
|
2017-06-23 12:16:57 +02:00
|
|
|
slot0_partition: partition@20000 {
|
|
|
|
label = "image-0";
|
2022-05-06 14:54:51 +02:00
|
|
|
reg = <0x00020000 DT_SIZE_K(864)>;
|
2017-06-23 12:16:57 +02:00
|
|
|
};
|
2020-12-18 14:11:41 +01:00
|
|
|
|
2019-07-02 11:47:48 -05:00
|
|
|
scratch_partition: partition@f8000 {
|
2017-06-23 12:16:57 +02:00
|
|
|
label = "image-scratch";
|
2022-05-06 14:54:51 +02:00
|
|
|
reg = <0x000F8000 DT_SIZE_K(16)>;
|
2017-06-23 12:16:57 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
2018-02-28 22:20:00 +01:00
|
|
|
|
|
|
|
&timers2 {
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2018-02-28 22:20:00 +01:00
|
|
|
|
2020-05-01 16:13:37 +02:00
|
|
|
pwm2: pwm {
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2020-11-02 17:40:50 +01:00
|
|
|
pinctrl-0 = <&tim2_ch1_pa15>;
|
2021-11-08 11:48:51 +01:00
|
|
|
pinctrl-names = "default";
|
2018-02-28 22:20:00 +01:00
|
|
|
};
|
|
|
|
};
|
2018-06-19 16:21:36 +03:00
|
|
|
|
2019-11-08 15:11:45 +01:00
|
|
|
&lptim1 {
|
2022-08-08 08:19:13 +02:00
|
|
|
clocks = <&rcc STM32_CLOCK_BUS_APB1 0x80000000>,
|
|
|
|
<&rcc STM32_SRC_LSE LPTIM1_SEL(3)>;
|
2019-11-08 15:11:45 +01:00
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
2018-06-19 16:21:36 +03:00
|
|
|
&rtc {
|
2022-09-07 09:13:35 +02:00
|
|
|
clocks = <&rcc STM32_CLOCK_BUS_APB1 0x10000000>,
|
|
|
|
<&rcc STM32_SRC_LSI RTC_SEL(2)>;
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2018-06-19 16:21:36 +03:00
|
|
|
};
|
2018-07-11 11:39:30 +02:00
|
|
|
|
2021-10-21 10:16:57 +02:00
|
|
|
zephyr_udc0: &usbotg_fs {
|
2020-10-21 16:11:12 +02:00
|
|
|
pinctrl-0 = <&usb_otg_fs_dm_pa11 &usb_otg_fs_dp_pa12
|
|
|
|
&usb_otg_fs_id_pa10>;
|
2021-11-08 13:52:59 +01:00
|
|
|
pinctrl-names = "default";
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2018-07-11 11:39:30 +02:00
|
|
|
};
|
2019-02-01 16:12:50 +01:00
|
|
|
|
2019-04-04 15:46:31 +08:00
|
|
|
&iwdg {
|
2019-06-14 19:31:16 +02:00
|
|
|
status = "okay";
|
2019-02-01 16:12:50 +01:00
|
|
|
};
|
2020-04-03 11:58:01 +02:00
|
|
|
|
|
|
|
&rng {
|
|
|
|
status = "okay";
|
|
|
|
};
|
2020-07-21 17:56:50 +02:00
|
|
|
|
|
|
|
&adc1 {
|
2020-10-12 08:10:50 +02:00
|
|
|
pinctrl-0 = <&adc1_in5_pa0 &adc1_in3_pc2
|
|
|
|
&adc1_in4_pc3 &adc1_in13_pc4
|
|
|
|
&adc1_in14_pc5>;
|
2021-11-05 15:14:51 +01:00
|
|
|
pinctrl-names = "default";
|
2020-07-21 17:56:50 +02:00
|
|
|
status = "okay";
|
|
|
|
};
|
2020-12-18 14:11:41 +01:00
|
|
|
|
2022-05-17 17:34:30 +02:00
|
|
|
&die_temp {
|
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
2022-03-08 14:42:20 +01:00
|
|
|
&dac1 {
|
|
|
|
status = "okay";
|
|
|
|
pinctrl-0 = <&dac1_out1_pa4>;
|
|
|
|
pinctrl-names = "default";
|
|
|
|
};
|
|
|
|
|
2020-12-18 14:11:41 +01:00
|
|
|
&dma1 {
|
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
|
|
|
&quadspi {
|
|
|
|
pinctrl-0 = <&quadspi_clk_pe10 &quadspi_ncs_pe11
|
|
|
|
&quadspi_bk1_io0_pe12 &quadspi_bk1_io1_pe13
|
|
|
|
&quadspi_bk1_io2_pe14 &quadspi_bk1_io3_pe15>;
|
2021-11-08 10:50:31 +01:00
|
|
|
pinctrl-names = "default";
|
2021-06-16 17:00:39 +02:00
|
|
|
dmas = <&dma1 5 5 0x0000>;
|
2020-12-18 14:11:41 +01:00
|
|
|
dma-names = "tx_rx";
|
|
|
|
|
|
|
|
status = "okay";
|
|
|
|
|
|
|
|
mx25r6435f: qspi-nor-flash@0 {
|
|
|
|
compatible = "st,stm32-qspi-nor";
|
|
|
|
reg = <0>;
|
|
|
|
qspi-max-frequency = <50000000>;
|
|
|
|
/* 64 Megabits = 8 Megabytes */
|
|
|
|
size = <0x4000000>;
|
|
|
|
status = "okay";
|
|
|
|
|
|
|
|
partitions {
|
|
|
|
compatible = "fixed-partitions";
|
|
|
|
#address-cells = <1>;
|
|
|
|
#size-cells = <1>;
|
|
|
|
|
|
|
|
slot1_partition: partition@0 {
|
|
|
|
label = "image-1";
|
2022-05-06 14:54:51 +02:00
|
|
|
reg = <0x00000000 DT_SIZE_K(864)>;
|
2020-12-18 14:11:41 +01:00
|
|
|
};
|
|
|
|
|
2021-06-22 00:38:08 +05:30
|
|
|
storage_partition: partition@d8000 {
|
2020-12-18 14:11:41 +01:00
|
|
|
label = "storage";
|
2021-06-22 00:38:08 +05:30
|
|
|
reg = <0x000d8000 DT_SIZE_M(7)>;
|
2020-12-18 14:11:41 +01:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|