ESPHome  2024.11.2
Public Member Functions | Protected Member Functions | Protected Attributes
esphome::sprinkler::SprinklerValveOperator Class Reference

#include <sprinkler.h>

Public Member Functions

 SprinklerValveOperator ()
 
 SprinklerValveOperator (SprinklerValve *valve, Sprinkler *controller)
 
void loop ()
 
void set_controller (Sprinkler *controller)
 
void set_valve (SprinklerValve *valve)
 
void set_run_duration (uint32_t run_duration)
 
void set_start_delay (uint32_t start_delay, bool start_delay_is_valve_delay)
 
void set_stop_delay (uint32_t stop_delay, bool stop_delay_is_valve_delay)
 
void start ()
 
void stop ()
 
uint32_t run_duration ()
 
uint32_t time_remaining ()
 
SprinklerState state ()
 
SprinklerSwitchpump_switch ()
 

Protected Member Functions

void pump_off_ ()
 
void pump_on_ ()
 
void valve_off_ ()
 
void valve_on_ ()
 
void kill_ ()
 
void run_ ()
 

Protected Attributes

bool start_delay_is_valve_delay_ {false}
 
bool stop_delay_is_valve_delay_ {false}
 
uint32_t start_delay_ {0}
 
uint32_t stop_delay_ {0}
 
uint32_t run_duration_ {0}
 
uint64_t start_millis_ {0}
 
uint64_t stop_millis_ {0}
 
Sprinklercontroller_ {nullptr}
 
SprinklerValvevalve_ {nullptr}
 
SprinklerState state_ {IDLE}
 

Detailed Description

Definition at line 144 of file sprinkler.h.

Constructor & Destructor Documentation

◆ SprinklerValveOperator() [1/2]

esphome::sprinkler::SprinklerValveOperator::SprinklerValveOperator ( )

Definition at line 146 of file sprinkler.cpp.

◆ SprinklerValveOperator() [2/2]

esphome::sprinkler::SprinklerValveOperator::SprinklerValveOperator ( SprinklerValve valve,
Sprinkler controller 
)

Definition at line 147 of file sprinkler.cpp.

Member Function Documentation

◆ kill_()

void esphome::sprinkler::SprinklerValveOperator::kill_ ( )
protected

Definition at line 331 of file sprinkler.cpp.

◆ loop()

void esphome::sprinkler::SprinklerValveOperator::loop ( )

Definition at line 150 of file sprinkler.cpp.

◆ pump_off_()

void esphome::sprinkler::SprinklerValveOperator::pump_off_ ( )
protected

Definition at line 285 of file sprinkler.cpp.

◆ pump_on_()

void esphome::sprinkler::SprinklerValveOperator::pump_on_ ( )
protected

Definition at line 299 of file sprinkler.cpp.

◆ pump_switch()

SprinklerSwitch * esphome::sprinkler::SprinklerValveOperator::pump_switch ( )

Definition at line 275 of file sprinkler.cpp.

◆ run_()

void esphome::sprinkler::SprinklerValveOperator::run_ ( )
protected

Definition at line 337 of file sprinkler.cpp.

◆ run_duration()

uint32_t esphome::sprinkler::SprinklerValveOperator::run_duration ( )

Definition at line 250 of file sprinkler.cpp.

◆ set_controller()

void esphome::sprinkler::SprinklerValveOperator::set_controller ( Sprinkler controller)

Definition at line 179 of file sprinkler.cpp.

◆ set_run_duration()

void esphome::sprinkler::SprinklerValveOperator::set_run_duration ( uint32_t  run_duration)

Definition at line 196 of file sprinkler.cpp.

◆ set_start_delay()

void esphome::sprinkler::SprinklerValveOperator::set_start_delay ( uint32_t  start_delay,
bool  start_delay_is_valve_delay 
)

Definition at line 202 of file sprinkler.cpp.

◆ set_stop_delay()

void esphome::sprinkler::SprinklerValveOperator::set_stop_delay ( uint32_t  stop_delay,
bool  stop_delay_is_valve_delay 
)

Definition at line 207 of file sprinkler.cpp.

◆ set_valve()

void esphome::sprinkler::SprinklerValveOperator::set_valve ( SprinklerValve valve)

Definition at line 185 of file sprinkler.cpp.

◆ start()

void esphome::sprinkler::SprinklerValveOperator::start ( )

Definition at line 212 of file sprinkler.cpp.

◆ state()

SprinklerState esphome::sprinkler::SprinklerValveOperator::state ( )

Definition at line 273 of file sprinkler.cpp.

◆ stop()

void esphome::sprinkler::SprinklerValveOperator::stop ( )

Definition at line 230 of file sprinkler.cpp.

◆ time_remaining()

uint32_t esphome::sprinkler::SprinklerValveOperator::time_remaining ( )

Definition at line 252 of file sprinkler.cpp.

◆ valve_off_()

void esphome::sprinkler::SprinklerValveOperator::valve_off_ ( )
protected

Definition at line 313 of file sprinkler.cpp.

◆ valve_on_()

void esphome::sprinkler::SprinklerValveOperator::valve_on_ ( )
protected

Definition at line 322 of file sprinkler.cpp.

Field Documentation

◆ controller_

Sprinkler* esphome::sprinkler::SprinklerValveOperator::controller_ {nullptr}
protected

Definition at line 175 of file sprinkler.h.

◆ run_duration_

uint32_t esphome::sprinkler::SprinklerValveOperator::run_duration_ {0}
protected

Definition at line 172 of file sprinkler.h.

◆ start_delay_

uint32_t esphome::sprinkler::SprinklerValveOperator::start_delay_ {0}
protected

Definition at line 170 of file sprinkler.h.

◆ start_delay_is_valve_delay_

bool esphome::sprinkler::SprinklerValveOperator::start_delay_is_valve_delay_ {false}
protected

Definition at line 168 of file sprinkler.h.

◆ start_millis_

uint64_t esphome::sprinkler::SprinklerValveOperator::start_millis_ {0}
protected

Definition at line 173 of file sprinkler.h.

◆ state_

SprinklerState esphome::sprinkler::SprinklerValveOperator::state_ {IDLE}
protected

Definition at line 177 of file sprinkler.h.

◆ stop_delay_

uint32_t esphome::sprinkler::SprinklerValveOperator::stop_delay_ {0}
protected

Definition at line 171 of file sprinkler.h.

◆ stop_delay_is_valve_delay_

bool esphome::sprinkler::SprinklerValveOperator::stop_delay_is_valve_delay_ {false}
protected

Definition at line 169 of file sprinkler.h.

◆ stop_millis_

uint64_t esphome::sprinkler::SprinklerValveOperator::stop_millis_ {0}
protected

Definition at line 174 of file sprinkler.h.

◆ valve_

SprinklerValve* esphome::sprinkler::SprinklerValveOperator::valve_ {nullptr}
protected

Definition at line 176 of file sprinkler.h.


The documentation for this class was generated from the following files: