ESPHome  2024.4.0
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:283
This is a workaround until we can figure out a way to get the tflite-micro idf component code availab...
Definition: a01nyub.cpp:7
Base-class for all sensors.
Definition: sensor.h:57
optional< std::function< optional< float >)> > f_