Skip to content

Commit 2535e0e

Browse files
amiclausnunojsa
authored andcommitted
iio: accel: add ADXL380 driver
The ADXL380/ADXL382 is a low noise density, low power, 3-axis accelerometer with selectable measurement ranges. The ADXL380 supports the +/-4 g, +/-8 g, and +/-16 g ranges, and the ADXL382 supports +/-15 g, +/-30 g and +/-60 g ranges. The ADXL380/ADXL382 offers industry leading noise, enabling precision applications with minimal calibration. The low noise, and low power ADXL380/ADXL382 enables accurate measurement in an environment with high vibration, heart sounds and audio. In addition to its low power consumption, the ADXL380/ADXL382 has many features to enable true system level performance. These include a built-in micropower temperature sensor, single / double / triple tap detection and a state machine to prevent a false triggering. In addition, the ADXL380/ADXL382 has provisions for external control of the sampling time and/or an external clock. Link: https://lore.kernel.org/lkml/20240708104114.29894-2-antoniu.miclaus@analog.com/ Signed-off-by: Ramona Gradinariu <ramona.gradinariu@analog.com> Signed-off-by: Antoniu Miclaus <antoniu.miclaus@analog.com>
1 parent 1219655 commit 2535e0e

File tree

7 files changed

+2109
-0
lines changed

7 files changed

+2109
-0
lines changed

MAINTAINERS

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -661,6 +661,10 @@ M: Antoniu Miclaus <antoniu.miclaus@analog.com>
661661
S: Supported
662662
W: https://ez.analog.com/linux-software-drivers
663663
F: Documentation/devicetree/bindings/iio/accel/adi,adxl380.yaml
664+
F: drivers/iio/accel/adxl380.c
665+
F: drivers/iio/accel/adxl380.h
666+
F: drivers/iio/accel/adxl380_i2c.c
667+
F: drivers/iio/accel/adxl380_spi.c
664668

665669
AF9013 MEDIA DRIVER
666670
M: Antti Palosaari <crope@iki.fi>

drivers/iio/accel/Kconfig

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,33 @@ config ADXL372_I2C
177177
To compile this driver as a module, choose M here: the
178178
module will be called adxl372_i2c.
179179

180+
config ADXL380
181+
tristate
182+
select IIO_BUFFER
183+
select IIO_TRIGGERED_BUFFER
184+
185+
config ADXL380_SPI
186+
tristate "Analog Devices ADXL380 3-Axis Accelerometer SPI Driver"
187+
depends on SPI
188+
select ADXL380
189+
select REGMAP_SPI
190+
help
191+
Say yes here to add support for the Analog Devices ADXL380 triaxial
192+
acceleration sensor.
193+
To compile this driver as a module, choose M here: the
194+
module will be called adxl380_spi.
195+
196+
config ADXL380_I2C
197+
tristate "Analog Devices ADXL380 3-Axis Accelerometer I2C Driver"
198+
depends on I2C
199+
select ADXL380
200+
select REGMAP_I2C
201+
help
202+
Say yes here to add support for the Analog Devices ADXL380 triaxial
203+
acceleration sensor.
204+
To compile this driver as a module, choose M here: the
205+
module will be called adxl380_i2c.
206+
180207
config BMA180
181208
tristate "Bosch BMA023/BMA1x0/BMA250 3-Axis Accelerometer Driver"
182209
depends on I2C && INPUT_BMA150=n

drivers/iio/accel/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ obj-$(CONFIG_ADXL367_SPI) += adxl367_spi.o
2121
obj-$(CONFIG_ADXL372) += adxl372.o
2222
obj-$(CONFIG_ADXL372_I2C) += adxl372_i2c.o
2323
obj-$(CONFIG_ADXL372_SPI) += adxl372_spi.o
24+
obj-$(CONFIG_ADXL380) += adxl380.o
25+
obj-$(CONFIG_ADXL380_I2C) += adxl380_i2c.o
26+
obj-$(CONFIG_ADXL380_SPI) += adxl380_spi.o
2427
obj-$(CONFIG_BMA180) += bma180.o
2528
obj-$(CONFIG_BMA220) += bma220_spi.o
2629
obj-$(CONFIG_BMA400) += bma400_core.o

0 commit comments

Comments
 (0)