11 SUB_BINARY_SENSOR(open_endstop)
12 SUB_BINARY_SENSOR(close_endstop)
15 void setup()
override;
17 void dump_config()
override;
31 bool is_open_()
const {
return this->open_endstop_binary_sensor_->state; }
32 bool is_closed_()
const {
return this->close_endstop_binary_sensor_->state; }
virtual void setup()
Where the component's initialization should happen.
Base class for all cover devices.
Trigger * prev_command_trigger_
void start_direction_(cover::CoverOperation dir)
uint32_t last_recompute_time_
void stop_prev_trigger_()
bool is_at_target_() const
void recompute_position_()
void control(const cover::CoverCall &call) override
uint32_t last_publish_time_
cover::CoverOperation last_operation_
CoverOperation
Enum encoding the current operation of a cover.
@ COVER_OPERATION_OPENING
The cover is currently opening.