blob: 32436e71fb9cf547dce352df3aa6edcde6eaf7f9 [file] [log] [blame]
menuconfig BMI160
bool "Bosch BMI160 inertial measurement unit"
depends on SENSOR
depends on SPI
default n
help
Enable Bosch BMI160 inertial measurement unit that provides acceleration
and angular rate measurements.
config BMI160_SYS_LOG_LEVEL
int "BMI160 Log level"
depends on SYS_LOG && BMI160
default 0
range 0 4
help
Sets log level for BMI160 driver.
Levels are:
- 0 OFF: do not write
- 1 ERROR: only write SYS_LOG_ERR
- 2 WARNING: write SYS_LOG_WRN in addition to previous level
- 3 INFO: write SYS_LOG_INF in addition to previous levels
- 4 DEBUG: write SYS_LOG_DBG in addition to previous levels
config BMI160_INIT_PRIORITY
int
prompt "BMI160 Init priority"
default 70
depends on BMI160
help
Device driver initialization priority.
As the device is connected to SPI bus, its driver has
to be initialized after the SPI one.
config BMI160_NAME
string "Driver's name"
depends on BMI160
default "bmi160"
config BMI160_SPI_PORT_NAME
string "SPI master controller port name"
depends on BMI160
default ""
help
Master I2C port name through which BMI160 chip is accessed.
config BMI160_SLAVE
hex "BMI160 SPI slave select pin"
depends on BMI160
default 0
help
BMI160 chip select pin.
config BMI160_SPI_BUS_FREQ
int "BMI160 SPI bus speed in Hz"
default 640000
depends on BMI160
help
This is the maximum supported SPI bus frequency. The chip supports a
frequency up to 10MHz.
choice
prompt "Trigger mode"
depends on BMI160
default BMI160_TRIGGER_GLOBAL_FIBER
help
Specify the type of triggering to be used by the driver.
config BMI160_TRIGGER_NONE
bool
prompt "No trigger"
config BMI160_TRIGGER_GLOBAL_FIBER
bool "Use global fiber"
depends on SYSTEM_WORKQUEUE
select BMI160_TRIGGER
config BMI160_TRIGGER_OWN_FIBER
bool "Use own fiber"
select BMI160_TRIGGER
endchoice
config BMI160_TRIGGER
bool
depends on BMI160
choice
prompt "Trigger source"
depends on BMI160 && BMI160_TRIGGER && (GPIO || IPM)
default BMI160_TRIGGER_SOURCE_IPM
config BMI160_TRIGGER_SOURCE_IPM
bool "IPM device"
depends on IPM
config BMI160_TRIGGER_SOURCE_GPIO
bool "GPIO device"
depends on GPIO
endchoice
config BMI160_FIBER_PRIORITY
int "Own fiber priority"
depends on BMI160 && BMI160_TRIGGER_OWN_FIBER
default 10
help
The priority of the fiber used for handling interrupts.
config BMI160_FIBER_STACK_SIZE
int "Own fiber stack size"
depends on BMI160 && BMI160_TRIGGER_OWN_FIBER
default 1024
help
The fiber stack size.
config BMI160_GPIO_DEV_NAME
string "Gpio device"
default "GPIO_1"
depends on BMI160 && BMI160_TRIGGER && BMI160_TRIGGER_SOURCE_GPIO
help
The name of the GPIO device to which the BMI160 interrupt pin is
connected.
config BMI160_GPIO_PIN_NUM
int "Interrupt GPIO pin number"
default 4
depends on BMI160 && BMI160_TRIGGER && BMI160_TRIGGER_SOURCE_GPIO
help
The number of the GPIO pin which is connected to BMI160 interrupt pin.
choice
prompt "Accelerometer power mode"
depends on BMI160
default BMI160_ACCEL_PMU_RUNTIME
config BMI160_ACCEL_PMU_RUNTIME
bool "Set at runtime."
depends on BMI160
config BMI160_ACCEL_PMU_SUSPEND
bool "suspended/not used"
depends on BMI160
config BMI160_ACCEL_PMU_NORMAL
bool "normal"
depends on BMI160
config BMI160_ACCEL_PMU_LOW_POWER
bool "low power"
depends on BMI160
endchoice
choice
prompt "Accelerometer range setting"
depends on BMI160 && (BMI160_ACCEL_PMU_RUNTIME || BMI160_ACCEL_PMU_NORMAL || BMI160_ACCEL_PMU_LOW_POWER)
default BMI160_ACCEL_RANGE_RUNTIME
config BMI160_ACCEL_RANGE_RUNTIME
bool "Set at runtime."
config BMI160_ACCEL_RANGE_2G
bool "2G"
config BMI160_ACCEL_RANGE_4G
bool "4G"
config BMI160_ACCEL_RANGE_8G
bool "8G"
config BMI160_ACCEL_RANGE_16G
bool "16G"
endchoice
choice
prompt "Accelerometer sampling frequency."
depends on BMI160 && (BMI160_ACCEL_PMU_RUNTIME || BMI160_ACCEL_PMU_NORMAL || BMI160_ACCEL_PMU_LOW_POWER)
default BMI160_ACCEL_ODR_RUNTIME
config BMI160_ACCEL_ODR_RUNTIME
bool "Set at runtime."
config BMI160_ACCEL_ODR_25_32
depends on BMI160_ACCEL_PMU_LOW_POWER
bool "0.78 Hz"
config BMI160_ACCEL_ODR_25_16
depends on BMI160_ACCEL_PMU_LOW_POWER
bool "1.56 Hz"
config BMI160_ACCEL_ODR_25_8
depends on BMI160_ACCEL_PMU_LOW_POWER
bool "3.125 Hz"
config BMI160_ACCEL_ODR_25_4
depends on BMI160_ACCEL_PMU_LOW_POWER
bool "6.25 Hz"
config BMI160_ACCEL_ODR_25_2
bool "12.5 Hz"
config BMI160_ACCEL_ODR_25
bool "25 Hz"
config BMI160_ACCEL_ODR_50
bool "50 Hz"
config BMI160_ACCEL_ODR_100
bool "100 Hz"
config BMI160_ACCEL_ODR_200
bool "200 Hz"
config BMI160_ACCEL_ODR_400
bool "400 Hz"
config BMI160_ACCEL_ODR_800
bool "800 Hz"
config BMI160_ACCEL_ODR_1600
bool "1600 Hz"
endchoice
choice
prompt "Gyroscope power mode"
depends on BMI160
default BMI160_GYRO_PMU_RUNTIME
config BMI160_GYRO_PMU_RUNTIME
bool "Set at runtime."
depends on BMI160
config BMI160_GYRO_PMU_SUSPEND
bool "suspended/not used"
depends on BMI160
config BMI160_GYRO_PMU_NORMAL
bool "normal"
depends on BMI160
config BMI160_GYRO_PMU_FAST_STARTUP
bool "fast start-up"
depends on BMI160
endchoice
choice
prompt "Gyroscope range setting."
depends on BMI160 && (BMI160_GYRO_PMU_RUNTIME || BMI160_GYRO_PMU_NORMAL || BMI160_GYRO_PMU_FAST_STARTUP)
default BMI160_GYRO_RANGE_RUNTIME
config BMI160_GYRO_RANGE_RUNTIME
bool "Set at runtime."
config BMI160_GYRO_RANGE_2000DPS
bool "2000 DPS"
config BMI160_GYRO_RANGE_1000DPS
bool "1000 DPS"
config BMI160_GYRO_RANGE_500DPS
bool "500 DPS"
config BMI160_GYRO_RANGE_250DPS
bool "250 DPS"
config BMI160_GYRO_RANGE_125DPS
bool "125 DPS"
endchoice
choice
prompt "Gyroscope sampling frequency."
depends on BMI160 && (BMI160_GYRO_PMU_RUNTIME || BMI160_GYRO_PMU_NORMAL || BMI160_GYRO_PMU_FAST_STARTUP)
default BMI160_GYRO_ODR_RUNTIME
config BMI160_GYRO_ODR_RUNTIME
bool "Set at runtime."
config BMI160_GYRO_ODR_25
bool "25 Hz"
config BMI160_GYRO_ODR_50
bool "50 Hz"
config BMI160_GYRO_ODR_100
bool "100 Hz"
config BMI160_GYRO_ODR_200
bool "200 Hz"
config BMI160_GYRO_ODR_400
bool "400 Hz"
config BMI160_GYRO_ODR_800
bool "800 Hz"
config BMI160_GYRO_ODR_1600
bool "1600 Hz"
config BMI160_GYRO_ODR_3200
bool "3200 Hz"
endchoice