1# ST Microelectronics LSM6DSO16IS 6-axis IMU sensor driver
2
3# Copyright (c) 2023 STMicroelectronics
4# SPDX-License-Identifier: Apache-2.0
5
6menuconfig LSM6DSO16IS
7	bool "LSM6DSO16IS I2C/SPI accelerometer and gyroscope Chip"
8	default y
9	depends on DT_HAS_ST_LSM6DSO16IS_ENABLED
10	select I2C if $(dt_compat_on_bus,$(DT_COMPAT_ST_LSM6DSO16IS),i2c)
11	select SPI if $(dt_compat_on_bus,$(DT_COMPAT_ST_LSM6DSO16IS),spi)
12	select HAS_STMEMSC
13	select USE_STDC_LSM6DSO16IS
14	help
15	  Enable driver for LSM6DSO16IS accelerometer and gyroscope
16	  sensor.
17
18if LSM6DSO16IS
19
20choice LSM6DSO16IS_TRIGGER_MODE
21	prompt "Trigger mode"
22	help
23	  Specify the type of triggering to be used by the driver.
24
25config LSM6DSO16IS_TRIGGER_NONE
26	bool "No trigger"
27
28config LSM6DSO16IS_TRIGGER_GLOBAL_THREAD
29	bool "Use global thread"
30	depends on GPIO
31	select LSM6DSO16IS_TRIGGER
32
33config LSM6DSO16IS_TRIGGER_OWN_THREAD
34	bool "Use own thread"
35	depends on GPIO
36	select LSM6DSO16IS_TRIGGER
37
38endchoice
39
40config LSM6DSO16IS_TRIGGER
41	bool
42
43if LSM6DSO16IS_TRIGGER
44
45config LSM6DSO16IS_THREAD_PRIORITY
46	int "Thread priority"
47	depends on LSM6DSO16IS_TRIGGER_OWN_THREAD
48	default 10
49	help
50	  Priority of thread used by the driver to handle interrupts.
51
52config LSM6DSO16IS_THREAD_STACK_SIZE
53	int "Thread stack size"
54	depends on LSM6DSO16IS_TRIGGER_OWN_THREAD
55	default 1024
56	help
57	  Stack size of thread used by the driver to handle interrupts.
58
59endif # LSM6DSO16IS_TRIGGER
60
61config LSM6DSO16IS_ENABLE_TEMP
62	bool "Temperature"
63	help
64	  Enable/disable temperature
65
66config LSM6DSO16IS_SENSORHUB
67	bool "I2C sensorhub feature"
68	help
69	  Enable/disable internal sensorhub. You can enable
70	  a maximum of two external sensors (if more than two are enabled
71	  the system would enumerate only the first two found)
72
73if LSM6DSO16IS_SENSORHUB
74
75config LSM6DSO16IS_EXT_LIS2MDL
76	bool "LIS2MDL as external sensor"
77	default y
78
79config LSM6DSO16IS_EXT_LPS22HH
80	bool "LPS22HH as external sensor"
81
82config LSM6DSO16IS_EXT_HTS221
83	bool "HTS221 as external sensor"
84
85config LSM6DSO16IS_EXT_LPS22HB
86	bool "LPS22HB as external sensor"
87
88config LSM6DSO16IS_EXT_LPS22DF
89	bool "LPS22DF as external sensor"
90	default y
91
92endif # LSM6DSO16IS_SENSORHUB
93
94endif # LSM6DSO16IS
95