1.. zephyr:code-sample:: x-nucleo-iks01a3-std
2   :name: X-NUCLEO-IKS01A3 shield - Standard (Mode 1)
3   :relevant-api: sensor_interface
4
5   Interact with all the sensors of an X-NUCLEO-IKS01A3 shield using Standard mode.
6
7Overview
8********
9This sample is provided as an example to test the X-NUCLEO-IKS01A3 shield
10configured in Standard mode (Mode 1).
11Please refer to :ref:`x-nucleo-iks01a3` for more info on this configuration.
12
13This sample enables all sensors of a X-NUCLEO-IKS01A3 shield, and then
14periodically reads and displays data from the shield sensors:
15
16- HTS221: ambient temperature and relative humidity
17- LPS22HH ambient temperature and atmospheric pressure
18- LIS2MDL 3-Axis magnetic field intensity
19- LIS2DW12 3-Axis acceleration
20- LSM6DSO 6-Axis acceleration and angular velocity
21- STTS751 temperature sensor
22
23Requirements
24************
25
26This sample communicates over I2C with the X-NUCLEO-IKS01A3 shield
27stacked on a board with an Arduino connector. The board's I2C must be
28configured for the I2C Arduino connector (both for pin muxing
29and devicetree). See for example the :ref:`nucleo_f401re_board` board
30source code:
31
32- :file:`$ZEPHYR_BASE/boards/arm/nucleo_f401re/nucleo_f401re.dts`
33- :file:`$ZEPHYR_BASE/boards/arm/nucleo_f401re/pinmux.c`
34
35Please note that this sample can't be used with boards already supporting
36one of the sensors available on the shield (such as disco_l475_iot1)
37as sensors multiple instances are not supported.
38
39References
40**********
41
42- X-NUCLEO-IKS01A3: https://www.st.com/en/ecosystems/x-nucleo-iks01a3.html
43
44Building and Running
45********************
46
47This sample runs with X-NUCLEO-IKS01A3 stacked on any board with a matching
48Arduino connector. For this example, we use a :ref:`nucleo_f401re_board` board.
49
50.. zephyr-app-commands::
51   :zephyr-app: samples/shields/x_nucleo_iks01a3/standard/
52   :host-os: unix
53   :board: nucleo_f401re
54   :goals: build
55   :compact:
56
57Sample Output
58=============
59
60 .. code-block:: console
61
62
63    X-NUCLEO-IKS01A3 sensor dashboard
64
65    HTS221: Temperature: 27.5 C
66    HTS221: Relative Humidity: 27.0%
67    LPS22HH: Temperature: 27.3 C
68    LPS22HH: Pressure:99.150 kpa
69    STTS751: Temperature: 27.6 C
70    LIS2MDL: Magn (gauss): x: -0.445, y: -0.054, z: -0.066
71    LIS2MDL: Temperature: 26.8 C
72    LIS2DW12: Accel (m.s-2): x: -0.413, y: 0.077, z: 10.337
73    LSM6DSO: Accel (m.s-2): x: 0.133, y: -0.133, z: 10.102
74    LSM6DSO: GYro (dps): x: 0.000, y: -0.006, z: -0.058
75    1:: lis2mdl trig 208
76    1:: lps22hh trig 214
77    1:: lsm6dso acc trig 426
78    1:: lsm6dso gyr trig 426
79
80    <updated endlessly every 2 seconds>
81