Line data Source code
1 1 : /*
2 : * Copyright (c) 2024 TDK Invensense
3 : *
4 : * SPDX-License-Identifier: Apache-2.0
5 : */
6 :
7 : #ifndef ZEPHYR_INCLUDE_DRIVERS_SENSOR_TDK_APEX_H_
8 : #define ZEPHYR_INCLUDE_DRIVERS_SENSOR_TDK_APEX_H_
9 :
10 : #include <zephyr/drivers/sensor.h>
11 :
12 : /**
13 : * @file
14 : * @brief Extended public API for TDK MEMS sensor
15 : *
16 : * Some capabilities and operational requirements for this sensor
17 : * cannot be expressed within the sensor driver abstraction.
18 : */
19 :
20 : /** TDK APEX features */
21 1 : #define TDK_APEX_PEDOMETER (1)
22 0 : #define TDK_APEX_TILT (2)
23 0 : #define TDK_APEX_SMD (3)
24 0 : #define TDK_APEX_WOM (4)
25 :
26 : /**
27 : * @brief Extended sensor channel for TDK MEMS supportintg APEX features
28 : *
29 : * This exposes sensor channel for the TDK MEMS which can be used for
30 : * getting the APEX features data.
31 : *
32 : * The APEX (Advanced Pedometer and Event Detection – neXt gen) features of
33 : * TDK MEMS consist of:
34 : * ** Pedometer: Tracks step count.
35 : * ** Tilt Detection: Detect the Tilt angle exceeds 35 degrees.
36 : * ** Wake on Motion (WoM): Detects motion when accelerometer samples exceed
37 : * a programmable threshold. This motion event can be used to enable device
38 : * operation from sleep mode.
39 : * ** Significant Motion Detector (SMD): Detects significant motion based on
40 : * accelerometer data.
41 : */
42 1 : enum sensor_channel_tdk_apex {
43 :
44 : /** APEX features */
45 : SENSOR_CHAN_APEX_MOTION = SENSOR_CHAN_PRIV_START,
46 : };
47 : #endif /* ZEPHYR_INCLUDE_DRIVERS_SENSOR_TDK_APEX_H_ */
|