Zephyr API Documentation 4.2.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches

ST Microelectronics LIS2DH 3-axis accelerometer. More...

Files

file  lis2dh.h
 Header file for extended sensor API of LIS2DH sensor.

Enumerations

enum  lis2dh_self_test { LIS2DH_SELF_TEST_DISABLE = 0 , LIS2DH_SELF_TEST_POSITIVE = 1 , LIS2DH_SELF_TEST_NEGATIVE = 2 }
 Possible values for SENSOR_ATTR_LIS2DH_SELF_TEST custom attribute. More...
enum  sensor_attribute_lis2dh { SENSOR_ATTR_LIS2DH_SELF_TEST = SENSOR_ATTR_PRIV_START }
 Custom sensor attributes for LIS2DH. More...

Detailed Description

ST Microelectronics LIS2DH 3-axis accelerometer.

Enumeration Type Documentation

◆ lis2dh_self_test

#include <zephyr/drivers/sensor/lis2dh.h>

Possible values for SENSOR_ATTR_LIS2DH_SELF_TEST custom attribute.

Enumerator
LIS2DH_SELF_TEST_DISABLE 

Self-test disabled.

LIS2DH_SELF_TEST_POSITIVE 

Simulates a positive-direction acceleration.

LIS2DH_SELF_TEST_NEGATIVE 

Simulates a negative-direction acceleration.

◆ sensor_attribute_lis2dh

#include <zephyr/drivers/sensor/lis2dh.h>

Custom sensor attributes for LIS2DH.

Enumerator
SENSOR_ATTR_LIS2DH_SELF_TEST 

Sets the self-test mode.

Applies an electrostatic force to the sensor to simulate acceleration without actually moving the device.

Use a value from lis2dh_self_test, passed in the sensor_value.val1 field.