boards: st: steval_stwinbx1: Improve sensor support
Add few other sensors support to steval_stwinbx1 board:
- IIS2MDC: 3-axis magnetometer
- ISM330DHCX: IMU, 3D accelerometer and 3D gyroscope
- IIS2DLPC: 3-axis accelerometer
- IIS2ICLX: 2-axis digital inclinometer
Signed-off-by: Armando Visconti <armando.visconti@st.com>
diff --git a/boards/st/steval_stwinbx1/doc/index.rst b/boards/st/steval_stwinbx1/doc/index.rst
index 9027db1..0008f6d 100644
--- a/boards/st/steval_stwinbx1/doc/index.rst
+++ b/boards/st/steval_stwinbx1/doc/index.rst
@@ -361,10 +361,9 @@
usb 3-1: Manufacturer: STMicroelectronics
usb 3-1: SerialNumber: 207136863530
-.. You can build and flash the provided sample application
-.. (:ref:`sensortile_box_pro_sample_sensors`) that reads sensors data and outputs
-.. values on the console.
-
+You can build and flash the provided sample application
+(:ref:`steval_stwinbx1_sample_sensors`) that reads sensors data and outputs
+values on the console.
.. _STEVAL-STWINBX1 Development kit website:
https://www.st.com/en/evaluation-tools/steval-stwinbx1.html
diff --git a/boards/st/steval_stwinbx1/steval_stwinbx1.dts b/boards/st/steval_stwinbx1/steval_stwinbx1.dts
index d8c3586..040452e 100644
--- a/boards/st/steval_stwinbx1/steval_stwinbx1.dts
+++ b/boards/st/steval_stwinbx1/steval_stwinbx1.dts
@@ -149,6 +149,39 @@
status = "okay";
};
+&spi2 {
+ pinctrl-0 = <&spi2_sck_pi1 &spi2_miso_pd3 &spi2_mosi_pi3>;
+ pinctrl-names = "default";
+ status = "okay";
+
+ cs-gpios = <&gpioh 6 GPIO_ACTIVE_LOW>,
+ <&gpioh 15 GPIO_ACTIVE_LOW>,
+ <&gpioi 7 GPIO_ACTIVE_LOW>;
+ iis2dlpc: iis2dlpc@0 {
+ compatible = "st,iis2dlpc";
+ spi-max-frequency = <DT_FREQ_M(10)>;
+ reg = <0>;
+ drdy-gpios = <&gpiof 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
+ drdy-int = <1>;
+ };
+
+ ism330dhcx: ism330dhcx@1 {
+ compatible = "st,ism330dhcx";
+ spi-max-frequency = <DT_FREQ_M(10)>;
+ reg = <1>;
+ drdy-gpios = <&gpiob 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
+ int-pin = <1>;
+ };
+
+ iis2iclx: iis2iclx@2 {
+ compatible = "st,iis2iclx";
+ spi-max-frequency = <DT_FREQ_M(10)>;
+ reg = <2>;
+ drdy-gpios = <&gpiof 11 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>;
+ int-pin = <2>;
+ };
+};
+
&spi3 {
pinctrl-0 = <&spi3_sck_pg9 &spi3_miso_pb4 &spi3_mosi_pb5>;
pinctrl-names = "default";
@@ -178,6 +211,13 @@
int-gpios = <&gpiof 5 GPIO_ACTIVE_HIGH>;
status = "okay";
};
+
+ iis2mdc@1e {
+ compatible = "st,iis2mdc";
+ reg = <0x1e>;
+ drdy-gpios = <&gpiof 9 GPIO_ACTIVE_HIGH>;
+ status = "okay";
+ };
};
&timers5 {