ESPHome  2022.1.2
template_sensor.h
Go to the documentation of this file.
1 #pragma once
2 
5 
6 namespace esphome {
7 namespace template_ {
8 
10  public:
11  void set_template(std::function<optional<float>()> &&f);
12 
13  void update() override;
14 
15  void dump_config() override;
16 
17  float get_setup_priority() const override;
18 
19  protected:
21 };
22 
23 } // namespace template_
24 } // namespace esphome
float get_setup_priority() const override
void set_template(std::function< optional< float >()> &&f)
This class simplifies creating components that periodically check a state.
Definition: component.h:266
Library based on https://github.com/miguelbalboa/rfid and adapted to ESPHome by . ...
Definition: a4988.cpp:4
Base-class for all sensors.
Definition: sensor.h:47
optional< std::function< optional< float >)> > f_