Add humidity support to climate (#5732)

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
This commit is contained in:
Stefan Rado
2023-12-13 02:23:02 +01:00
committed by GitHub
parent a72725f4b4
commit 6c7a133faa
23 changed files with 359 additions and 7 deletions
+3
View File
@@ -19,6 +19,7 @@ class PIDClimate : public climate::Climate, public Component {
void dump_config() override;
void set_sensor(sensor::Sensor *sensor) { sensor_ = sensor; }
void set_humidity_sensor(sensor::Sensor *sensor) { humidity_sensor_ = sensor; }
void set_cool_output(output::FloatOutput *cool_output) { cool_output_ = cool_output; }
void set_heat_output(output::FloatOutput *heat_output) { heat_output_ = heat_output; }
void set_kp(float kp) { controller_.kp_ = kp; }
@@ -85,6 +86,8 @@ class PIDClimate : public climate::Climate, public Component {
/// The sensor used for getting the current temperature
sensor::Sensor *sensor_;
/// The sensor used for getting the current humidity
sensor::Sensor *humidity_sensor_{nullptr};
output::FloatOutput *cool_output_{nullptr};
output::FloatOutput *heat_output_{nullptr};
PIDController controller_;