ESPHome
2026.6.0-dev
Loading...
Searching...
No Matches
esphome
components
opentherm
output
opentherm_output.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
esphome/components/output/float_output.h
"
4
#include "
esphome/components/opentherm/input.h
"
5
#include "
esphome/core/log.h
"
6
7
namespace
esphome::opentherm
{
8
9
class
OpenthermOutput
:
public
output::FloatOutput
,
public
Component
,
public
OpenthermInput
{
10
protected
:
11
bool
has_state_
=
false
;
12
const
char
*
id_
=
nullptr
;
13
14
float
min_value_
,
max_value_
;
15
16
public
:
17
float
state
;
18
19
void
set_id
(
const
char
*
id
) { this->id_ =
id
; }
20
21
void
write_state
(
float
state
)
override
;
22
23
bool
has_state
() {
return
this->
has_state_
; };
24
25
void
set_min_value
(
float
min_value)
override
{ this->min_value_ = min_value; }
26
void
set_max_value
(
float
max_value)
override
{ this->max_value_ = max_value; }
27
float
get_min_value
() {
return
this->
min_value_
; }
28
float
get_max_value
() {
return
this->
max_value_
; }
29
};
30
31
}
// namespace esphome::opentherm
esphome::Component
Definition
component.h:145
esphome::opentherm::OpenthermInput
Definition
input.h:5
esphome::opentherm::OpenthermOutput
Definition
opentherm_output.h:9
esphome::opentherm::OpenthermOutput::id_
const char * id_
Definition
opentherm_output.h:12
esphome::opentherm::OpenthermOutput::set_max_value
void set_max_value(float max_value) override
Definition
opentherm_output.h:26
esphome::opentherm::OpenthermOutput::min_value_
float min_value_
Definition
opentherm_output.h:14
esphome::opentherm::OpenthermOutput::state
float state
Definition
opentherm_output.h:17
esphome::opentherm::OpenthermOutput::has_state
bool has_state()
Definition
opentherm_output.h:23
esphome::opentherm::OpenthermOutput::max_value_
float max_value_
Definition
opentherm_output.h:14
esphome::opentherm::OpenthermOutput::has_state_
bool has_state_
Definition
opentherm_output.h:11
esphome::opentherm::OpenthermOutput::set_min_value
void set_min_value(float min_value) override
Definition
opentherm_output.h:25
esphome::opentherm::OpenthermOutput::set_id
void set_id(const char *id)
Definition
opentherm_output.h:19
esphome::opentherm::OpenthermOutput::get_min_value
float get_min_value()
Definition
opentherm_output.h:27
esphome::opentherm::OpenthermOutput::write_state
void write_state(float state) override
Definition
opentherm_output.cpp:8
esphome::opentherm::OpenthermOutput::get_max_value
float get_max_value()
Definition
opentherm_output.h:28
esphome::output::FloatOutput
Base class for all output components that can output a variable level, like PWM.
Definition
float_output.h:38
id
uint16_t id
Definition
dns_server_esp32_idf.cpp:0
float_output.h
input.h
log.h
esphome::opentherm
Definition
automation.h:7
Generated by
1.12.0