ESPHome 2025.5.0
Loading...
Searching...
No Matches
shtcx.h
Go to the documentation of this file.
1#pragma once
2
6
7namespace esphome {
8namespace shtcx {
9
11
14 public:
15 void set_temperature_sensor(sensor::Sensor *temperature_sensor) { temperature_sensor_ = temperature_sensor; }
16 void set_humidity_sensor(sensor::Sensor *humidity_sensor) { humidity_sensor_ = humidity_sensor; }
17
18 void setup() override;
19 void dump_config() override;
20 float get_setup_priority() const override;
21 void update() override;
22 void soft_reset();
23 void sleep();
24 void wake_up();
25
26 protected:
28 uint16_t sensor_id_;
31};
32
33} // namespace shtcx
34} // namespace esphome
This class simplifies creating components that periodically check a state.
Definition component.h:301
Implementation of a i2c functions for Sensirion sensors Sensirion data requires crc checking.
Base-class for all sensors.
Definition sensor.h:57
This class implements support for the SHT3x-DIS family of temperature+humidity i2c sensors.
Definition shtcx.h:13
void set_temperature_sensor(sensor::Sensor *temperature_sensor)
Definition shtcx.h:15
sensor::Sensor * humidity_sensor_
Definition shtcx.h:30
sensor::Sensor * temperature_sensor_
Definition shtcx.h:29
void dump_config() override
Definition shtcx.cpp:58
void set_humidity_sensor(sensor::Sensor *humidity_sensor)
Definition shtcx.h:16
float get_setup_priority() const override
Definition shtcx.cpp:70
@ SHTCX_TYPE_SHTC1
Definition shtcx.h:10
@ SHTCX_TYPE_UNKNOWN
Definition shtcx.h:10
@ SHTCX_TYPE_SHTC3
Definition shtcx.h:10
Providing packet encoding functions for exchanging data with a remote host.
Definition a01nyub.cpp:7