-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Display and health mode switches for haier platform added
- Loading branch information
Showing
7 changed files
with
91 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#include "display.h" | ||
|
||
namespace esphome { | ||
namespace haier { | ||
|
||
void DisplaySwitch::write_state(bool state) { | ||
this->publish_state(state); | ||
} | ||
|
||
} // namespace haier | ||
} // namespace esphome |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#pragma once | ||
|
||
#include "esphome/components/switch/switch.h" | ||
#include "../haier_base.h" | ||
|
||
namespace esphome { | ||
namespace haier { | ||
|
||
class DisplaySwitch : public switch_::Switch, public Parented<HaierClimateBase> { | ||
public: | ||
DisplaySwitch() = default; | ||
|
||
protected: | ||
void write_state(bool state) override; | ||
}; | ||
|
||
} // namespace haier | ||
} // namespace esphome |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#include "health_mode.h" | ||
|
||
namespace esphome { | ||
namespace haier { | ||
|
||
void HealthModeSwitch::write_state(bool state) { | ||
this->publish_state(state); | ||
} | ||
|
||
} // namespace haier | ||
} // namespace esphome |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#pragma once | ||
|
||
#include "esphome/components/switch/switch.h" | ||
#include "../haier_base.h" | ||
|
||
namespace esphome { | ||
namespace haier { | ||
|
||
class HealthModeSwitch : public switch_::Switch, public Parented<HaierClimateBase> { | ||
public: | ||
HealthModeSwitch() = default; | ||
|
||
protected: | ||
void write_state(bool state) override; | ||
}; | ||
|
||
} // namespace haier | ||
} // namespace esphome |