7static const char *
const TAG =
"hoermann_hcp.light";
35 if (binary == heading_on)
38 ESP_LOGD(TAG,
"Ignoring the restored state, the door decides what the lamp is doing");
39 }
else if (published != binary) {
42 ESP_LOGW(TAG,
"Door has not reported the lamp yet, ignoring the requested state");
47 ESP_LOGW(TAG,
"Light command was not accepted by the door");
void status_set_warning()
void status_clear_warning()
bool is_light_heading_on() const
bool is_light_known() const
bool cancel_light_toggle()
void add_on_state_callback(F &&callback)
light::LightTraits get_traits() override
light::LightState * light_state_
void write_state(light::LightState *state) override
HoermannHcp *const parent_
void publish_lamp_state_(bool on)
void update_from_state_()
optional< bool > published_state_
void setup_state(light::LightState *state) override
LightCall & set_save(bool save)
Set whether this light call should trigger a save state to recover them at startup....
LightCall & set_state(optional< bool > state)
Set the binary ON/OFF state of the light.
bool is_on() const
Get the binary true/false state of these light color values.
This class represents the communication layer between the front-end MQTT layer and the hardware outpu...
LightColorValues remote_values
The remote color values reported to the frontend.
void current_values_as_binary(bool *binary)
The result of all the current_values_as_* methods have gamma correction applied.
This class is used to represent the capabilities of a light.
@ ON_OFF
Only on/off control.