diff options
author | Mario Tesi <mario.tesi@st.com> | 2016-11-18 09:48:42 +0100 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2017-02-09 03:10:22 -0800 |
commit | 8db50ce410cd71a6b4429fb91a3be9e103312f8f (patch) | |
tree | def49c0684d3d0b1e10491ed475afb9ebbc1eb22 /common | |
parent | b6c5e8e7a2edee6f167fe1282db6e1263fa6988e (diff) | |
download | chrome-ec-8db50ce410cd71a6b4429fb91a3be9e103312f8f.tar.gz |
driver: accel: Add acc driver basics and FIFO for LIS2DH/LIS2DH12
Add driver for acc sensor ST lis2dh/lis2dh12
Support interrupt management for FIFO watermark
Starting to share common code with other devices
like lsm6dsm/lsm6dsl (acc/gyro) or new lis2mdl (mag)
TODO: Add all embedded functions support (click,
tap and so on)
BUG=none
BRANCH=master
TEST=Tested on discovery BOARD with sensor connected on
EC i2c master bus. Added motion sense task on discovery
board task list, added gpio info in board configuration
file and tested with motion sense console commands. Data
for acc seems ok: can successfully change ODR and
full scale range. Also FIFO and interrupt tested
Device tested is lis2dh (lis2dh12 simply differs for low
pin count but share the same registers)
Change-Id: I16abeac3f139a604094b38d8d8b857a62c93a242
Signed-off-by: Mario Tesi <mario.tesi@st.com>
Reviewed-on: https://chromium-review.googlesource.com/412700
Commit-Ready: mario tesi <mario.tesi@st.com>
Tested-by: mario tesi <mario.tesi@st.com>
Reviewed-by: Gwendal Grignou <gwendal@chromium.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/build.mk | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/common/build.mk b/common/build.mk index 6ccd800753..ca2da65de7 100644 --- a/common/build.mk +++ b/common/build.mk @@ -13,6 +13,7 @@ common-$(CONFIG_ACCELGYRO_BMA255)+=math_util.o common-$(CONFIG_ACCELGYRO_BMI160)+=math_util.o common-$(CONFIG_ACCELGYRO_LSM6DS0)+=math_util.o common-$(CONFIG_ACCELGYRO_LSM6DSM)+=math_util.o +common-$(CONFIG_ACCEL_LIS2DH)+=math_util.o common-$(CONFIG_ACCEL_KXCJ9)+=math_util.o common-$(CONFIG_ACCEL_KX022)+=math_util.o common-$(CONFIG_ADC)+=adc.o |