summaryrefslogtreecommitdiff
path: root/components/drivers/include
diff options
context:
space:
mode:
authorMeco Jianting Man <[email protected]>2021-04-05 10:01:59 +0800
committerGitHub <[email protected]>2021-04-05 10:01:59 +0800
commitfd227f79c0ac11d41c111a45f80148175e63f449 (patch)
tree026f2e63fc76cf208676d3c28c21e2a65fe46de6 /components/drivers/include
parentc18cd58e3e9b70f412097534313cf5a76fca12a6 (diff)
parent1e4a463f363dcde37f14d0ae2772360f4ff87a5e (diff)
Merge pull request #34 from RT-Thread/master
pr
Diffstat (limited to 'components/drivers/include')
-rw-r--r--components/drivers/include/drivers/sensor.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/components/drivers/include/drivers/sensor.h b/components/drivers/include/drivers/sensor.h
index d071893eed..e05006f9f6 100644
--- a/components/drivers/include/drivers/sensor.h
+++ b/components/drivers/include/drivers/sensor.h
@@ -49,6 +49,7 @@ extern "C" {
#define RT_SENSOR_CLASS_ECO2 (15) /* eCO2 sensor */
#define RT_SENSOR_CLASS_GNSS (16) /* GPS/GNSS sensor */
#define RT_SENSOR_CLASS_TOF (17) /* TOF sensor */
+#define RT_SENSOR_CLASS_SPO2 (18) /* SpO2 sensor */
/* Sensor vendor types */
@@ -89,6 +90,7 @@ extern "C" {
#define RT_SENSOR_UNIT_PPB (15) /* Concentration unit: ppb */
#define RT_SENSOR_UNIT_DMS (16) /* Coordinates unit: DMS */
#define RT_SENSOR_UNIT_DD (17) /* Coordinates unit: DD */
+#define RT_SENSOR_UNIT_PERCENT (18) /* Percentage unit: % */
/* Sensor communication interface types */
@@ -217,6 +219,7 @@ struct rt_sensor_data
rt_int32_t force; /* Force sensor. unit: mN */
rt_uint32_t dust; /* Dust sensor. unit: ug/m3 */
rt_uint32_t eco2; /* eCO2 sensor. unit: ppm */
+ rt_uint32_t spo2; /* SpO2 sensor. unit: % */
} data;
};