LCOV - code coverage report
Current view: top level - zephyr/sensing - sensing_sensor_types.h Coverage Total Hit
Test: new.info Lines: 88.9 % 9 8
Test Date: 2025-09-05 20:47:19

            Line data    Source code
       1            0 : /*
       2              :  * Copyright (c) 2022-2023 Intel Corporation.
       3              :  *
       4              :  * SPDX-License-Identifier: Apache-2.0
       5              :  */
       6              : 
       7              : #ifndef ZEPHYR_INCLUDE_SENSING_SENSOR_TYPES_H_
       8              : #define ZEPHYR_INCLUDE_SENSING_SENSOR_TYPES_H_
       9              : 
      10              : /**
      11              :  * @defgroup sensing_sensor_types Sensor Types (Sensing)
      12              :  * @ingroup sensing_api
      13              :  *
      14              :  * @brief Sensor type identifiers used by the sensing subsystem.
      15              :  *
      16              :  * Sensor types definition followed HID standard.
      17              :  * https://usb.org/sites/default/files/hutrr39b_0.pdf
      18              :  *
      19              :  * TODO: will add more types
      20              :  * @{
      21              :  */
      22              : 
      23              : /**
      24              :  * @name Light sensors
      25              :  * @{
      26              :  */
      27              : 
      28              : /** Sensor type for ambient light sensors. */
      29            1 : #define SENSING_SENSOR_TYPE_LIGHT_AMBIENTLIGHT                  0x41
      30              : 
      31              : /** @} */
      32              : 
      33              : /**
      34              :  * @name Motion sensors
      35              :  * @{
      36              :  */
      37              : 
      38              : /** Sensor type for 3D accelerometers. */
      39            1 : #define SENSING_SENSOR_TYPE_MOTION_ACCELEROMETER_3D             0x73
      40              : /** Sensor type for 3D gyrometers. */
      41            1 : #define SENSING_SENSOR_TYPE_MOTION_GYROMETER_3D                 0x76
      42              : /** Sensor type for motion detectors. */
      43            1 : #define SENSING_SENSOR_TYPE_MOTION_MOTION_DETECTOR              0x77
      44              : /** Sensor type for uncalibrated 3D accelerometers. */
      45            1 : #define SENSING_SENSOR_TYPE_MOTION_UNCALIB_ACCELEROMETER_3D     0x240
      46              : /** Sensor type for hinge angle sensors. */
      47            1 : #define SENSING_SENSOR_TYPE_MOTION_HINGE_ANGLE                  0x20B
      48              : 
      49              : /** @} */
      50              : 
      51              : /**
      52              :  * @name Other sensors
      53              :  * @{
      54              :  */
      55              : 
      56              : /** Sensor type for custom sensors. */
      57            1 : #define SENSING_SENSOR_TYPE_OTHER_CUSTOM 0xE1
      58              : 
      59              : /** @} */
      60              : 
      61              : /**
      62              :  * @brief Sensor type for all sensors.
      63              :  *
      64              :  * This macro defines the sensor type for all sensors.
      65              :  *
      66              :  * @note This value is not a valid sensor type and is used as a sentinel value to indicate all
      67              :  *       sensor types.
      68              :  */
      69            1 : #define SENSING_SENSOR_TYPE_ALL                                 0xFFFF
      70              : 
      71              : /**
      72              :  * @}
      73              :  */
      74              : 
      75              : #endif /*ZEPHYR_INCLUDE_SENSING_SENSOR_TYPES_H_*/
        

Generated by: LCOV version 2.0-1