ESPHome
2026.6.0-dev
Loading...
Searching...
No Matches
esphome
components
pylontech
text_sensor
pylontech_text_sensor.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
../pylontech.h
"
4
#include "
esphome/components/text_sensor/text_sensor.h
"
5
6
namespace
esphome::pylontech
{
7
8
class
PylontechTextSensor
:
public
PylontechListener
{
9
public
:
10
PylontechTextSensor
(int8_t bat_num);
11
void
dump_config
()
override
;
12
13
SUB_TEXT_SENSOR
(base_state)
14
SUB_TEXT_SENSOR
(voltage_state)
15
SUB_TEXT_SENSOR
(current_state)
16
SUB_TEXT_SENSOR
(temperature_state)
17
18
void
on_line_read
(
LineContents
*
line
)
override
;
19
20
protected
:
21
int8_t
bat_num_
;
22
};
23
24
}
// namespace esphome::pylontech
esphome::pylontech::PylontechListener
Definition
pylontech.h:12
esphome::pylontech::PylontechListener::on_line_read
virtual void on_line_read(LineContents *line)
esphome::pylontech::PylontechTextSensor
Definition
pylontech_text_sensor.h:8
esphome::pylontech::PylontechTextSensor::SUB_TEXT_SENSOR
SUB_TEXT_SENSOR(base_state) SUB_TEXT_SENSOR(voltage_state) SUB_TEXT_SENSOR(current_state) SUB_TEXT_SENSOR(temperature_state) void on_line_read(LineContents *line) override
esphome::pylontech::PylontechTextSensor::dump_config
void dump_config() override
Definition
pylontech_text_sensor.cpp:11
esphome::pylontech::PylontechTextSensor::bat_num_
int8_t bat_num_
Definition
pylontech_text_sensor.h:21
esphome::pylontech::PylontechTextSensor::PylontechTextSensor
PylontechTextSensor(int8_t bat_num)
Definition
pylontech_text_sensor.cpp:9
esphome::pylontech
Definition
pylontech.cpp:27
esphome::line
const char int line
Definition
log.h:74
pylontech.h
esphome::pylontech::PylontechListener::LineContents
Definition
pylontech.h:14
text_sensor.h
Generated by
1.12.0