1# Copyright (c) 2018-2019 STMicroelectronics 2# SPDX-License-Identifier: Apache-2.0 3 4menuconfig LIS2MDL 5 bool "LIS2MDL Magnetometer" 6 depends on I2C || SPI 7 select HAS_STMEMSC 8 select USE_STDC_LIS2MDL 9 help 10 Enable driver for LIS2MDL I2C-based magnetometer sensor. 11 12if LIS2MDL 13 14choice LIS2MDL_TRIGGER_MODE 15 prompt "Trigger mode" 16 default LIS2MDL_TRIGGER_GLOBAL_THREAD 17 help 18 Specify the type of triggering to be used by the driver. 19 20config LIS2MDL_TRIGGER_NONE 21 bool "No trigger" 22 23config LIS2MDL_TRIGGER_GLOBAL_THREAD 24 bool "Use global thread" 25 depends on GPIO 26 select LIS2MDL_TRIGGER 27 28config LIS2MDL_TRIGGER_OWN_THREAD 29 bool "Use own thread" 30 depends on GPIO 31 select LIS2MDL_TRIGGER 32 33endchoice # LIS2MDL_TRIGGER_MODE 34 35config LIS2MDL_TRIGGER 36 bool 37 38config LIS2MDL_THREAD_PRIORITY 39 int "Thread priority" 40 depends on LIS2MDL_TRIGGER_OWN_THREAD 41 default 10 42 help 43 Priority of thread used by the driver to handle interrupts. 44 45config LIS2MDL_THREAD_STACK_SIZE 46 int "Thread stack size" 47 depends on LIS2MDL_TRIGGER_OWN_THREAD 48 default 1024 49 help 50 Stack size of thread used by the driver to handle interrupts. 51 52config LIS2MDL_MAG_ODR_RUNTIME 53 bool "Set magnetometer sampling frequency (ODR) at runtime (default: 10 Hz)" 54 default y 55 56endif # LIS2MDL 57