1# FXAS21002 3-axis gyroscope 2 3# Copyright (c) 2017, NXP 4# SPDX-License-Identifier: Apache-2.0 5 6menuconfig FXAS21002 7 bool "FXAS21002 gyroscope driver" 8 default y 9 depends on DT_HAS_NXP_FXAS21002_ENABLED 10 select I2C if $(dt_compat_on_bus,$(DT_COMPAT_NXP_FXAS21002),i2c) 11 select SPI if $(dt_compat_on_bus,$(DT_COMPAT_NXP_FXAS21002),spi) 12 help 13 Enable driver for the FXAS21002 gyroscope 14 15if FXAS21002 16 17config FXAS21002_WHOAMI 18 hex "WHOAMI value" 19 range 0x00 0xff 20 default 0xd7 21 help 22 The datasheet defines the value of the WHOAMI register, but some 23 pre-production devices can have a different value. It is unlikely you 24 should need to change this configuration option from the default. 25 26config FXAS21002_RANGE 27 int "Full scale range" 28 range 0 3 29 default 0 30 help 31 Selects the full scale range 32 0: +/-2000 dps (62.5 mdps/LSB) 33 1: +/-1000 dps (31.25 mdps/LSB) 34 2: +/-500 dps (15.625 mdps/LSB) 35 3: +/-250 dps (7.8125 mdps/LSB) 36 37config FXAS21002_DR 38 int "Output data rate" 39 range 0 7 40 default 3 41 help 42 Selects the output data rate 43 0: 800 Hz 44 1: 400 Hz 45 2: 200 Hz 46 3: 100 Hz 47 4: 50 Hz 48 5: 25 Hz 49 6: 12.5 Hz 50 7: 12.5 Hz 51 52choice 53 prompt "Trigger mode" 54 default FXAS21002_TRIGGER_NONE 55 56config FXAS21002_TRIGGER_NONE 57 bool "No trigger" 58 59config FXAS21002_TRIGGER_GLOBAL_THREAD 60 bool "Use global thread" 61 select FXAS21002_TRIGGER 62 63config FXAS21002_TRIGGER_OWN_THREAD 64 bool "Use own thread" 65 select FXAS21002_TRIGGER 66 67endchoice 68 69config FXAS21002_TRIGGER 70 bool 71 72if FXAS21002_TRIGGER 73 74config FXAS21002_DRDY_INT1 75 bool "Data ready interrupt to INT1 pin" 76 help 77 Say Y to route data ready interrupt to INT1 pin. Say N to route to 78 INT2 pin. 79 80config FXAS21002_THREAD_PRIORITY 81 int "Own thread priority" 82 depends on FXAS21002_TRIGGER_OWN_THREAD 83 default 10 84 85config FXAS21002_THREAD_STACK_SIZE 86 int "Own thread stack size" 87 depends on FXAS21002_TRIGGER_OWN_THREAD 88 default 1024 89 90endif # FXAS21002_TRIGGER 91 92endif # FXAS21002 93