1# LSM6DSL accelerometer and gyroscope sensor configuration 2# options 3 4# Copyright (c) 2017 Linaro Limited 5# SPDX-License-Identifier: Apache-2.0 6 7menuconfig LSM6DSL 8 bool "LSM6DSL I2C/SPI accelerometer and gyroscope Chip" 9 default y 10 depends on DT_HAS_ST_LSM6DSL_ENABLED 11 select I2C if $(dt_compat_on_bus,$(DT_COMPAT_ST_LSM6DSL),i2c) 12 select SPI if $(dt_compat_on_bus,$(DT_COMPAT_ST_LSM6DSL),spi) 13 help 14 Enable driver for LSM6DSL accelerometer and gyroscope 15 sensor. 16 17if LSM6DSL 18 19choice LSM6DSL_TRIGGER_MODE 20 prompt "Trigger mode" 21 help 22 Specify the type of triggering to be used by the driver. 23 24config LSM6DSL_TRIGGER_NONE 25 bool "No trigger" 26 27config LSM6DSL_TRIGGER_GLOBAL_THREAD 28 bool "Use global thread" 29 depends on GPIO 30 select LSM6DSL_TRIGGER 31 32config LSM6DSL_TRIGGER_OWN_THREAD 33 bool "Use own thread" 34 depends on GPIO 35 select LSM6DSL_TRIGGER 36 37endchoice 38 39config LSM6DSL_TRIGGER 40 bool 41 42config LSM6DSL_THREAD_PRIORITY 43 int "Thread priority" 44 depends on LSM6DSL_TRIGGER_OWN_THREAD 45 default 10 46 help 47 Priority of thread used by the driver to handle interrupts. 48 49config LSM6DSL_THREAD_STACK_SIZE 50 int "Thread stack size" 51 depends on LSM6DSL_TRIGGER_OWN_THREAD 52 default 1024 53 help 54 Stack size of thread used by the driver to handle interrupts. 55 56config LSM6DSL_ENABLE_TEMP 57 bool "Temperature" 58 help 59 Enable/disable temperature 60 61config LSM6DSL_SENSORHUB 62 bool "I2C sensorhub feature" 63 help 64 Enable/disable internal sensorhub 65 66choice LSM6DSL_EXTERNAL_SENSOR_0 67 prompt "External sensor 0" 68 depends on LSM6DSL_SENSORHUB 69 help 70 Choose the external sensor 0 connected to LSM6DS3. 71 72config LSM6DSL_EXT0_LIS2MDL 73 bool "LIS2MDL" 74 75config LSM6DSL_EXT0_LIS3MDL 76 bool "LIS3MDL" 77 78config LSM6DSL_EXT0_LPS22HB 79 bool "LPS22HB" 80 81endchoice 82 83menu "Attributes" 84 85config LSM6DSL_GYRO_FS 86 int "Gyroscope full-scale range" 87 default 0 88 help 89 Specify the default gyroscope full-scale range. 90 An X value for the config represents a range of +/- X degree per 91 second. Valid values are: 92 0: Full Scale selected at runtime 93 125: +/- 125dps 94 250: +/- 250dps 95 500: +/- 500dps 96 1000: +/- 1000dps 97 2000: +/- 2000dps 98 99config LSM6DSL_GYRO_ODR 100 int "Gyroscope Output data rate frequency" 101 range 0 10 102 default 0 103 help 104 Specify the default accelerometer output data rate expressed in 105 samples per second (Hz). 106 0: ODR selected at runtime 107 1: 12.5Hz 108 2: 26Hz 109 3: 52Hz 110 4: 104Hz 111 5: 208Hz 112 6: 416Hz 113 7: 833Hz 114 8: 1660Hz 115 9: 3330Hz 116 10: 6660Hz 117 118config LSM6DSL_ACCEL_FS 119 int "Accelerometer full-scale range" 120 default 0 121 help 122 Specify the default accelerometer full-scale range. 123 An X value for the config represents a range of +/- X G. Valid values 124 are: 125 0: Full Scale selected at runtime 126 2: +/- 2g 127 4: +/- 4g 128 8: +/- 8g 129 16: +/- 16g 130 131config LSM6DSL_ACCEL_ODR 132 int "Accelerometer Output data rate frequency" 133 range 0 11 134 default 0 135 help 136 Specify the default accelerometer output data rate expressed in 137 samples per second (Hz). 138 0: ODR selected at runtime 139 1: 12.5Hz 140 2: 26Hz 141 3: 52Hz 142 4: 104Hz 143 5: 208Hz 144 6: 416Hz 145 7: 833Hz 146 8: 1666Hz 147 9: 3332Hz 148 10: 6664Hz 149 11: 1.6Hz 150endmenu 151 152endif # LSM6DSL 153