|
Home IO Control
ESPHome add-on for IO-Homecontrol devices
|
Sensor publishing the raw sun value a device answers its sun level poll with. More...
#include <platform_cover_controls.h>
Public Member Functions | |
| void | setup () override |
| Subscribe to the device's updates and publish what is already known. | |
| void | dump_config () override |
| Dump sensor configuration to the log. | |
| Public Member Functions inherited from esphome::home_io_control::IOHomeCompanionSensor | |
| float | get_setup_priority () const override |
| Get setup priority so the parent hub is available first. | |
| Public Member Functions inherited from esphome::home_io_control::DeviceBoundCompanion | |
| void | set_parent (IOHomeControlComponent *parent) |
| Set the parent controller component. | |
| void | set_device_id (const std::string &id) |
| Set the device ID whose state this companion sensor exposes. | |
Protected Attributes | |
| std::optional< uint16_t > | published_ |
| Last value handed to publish_state(); avoids re-publishing on every update. | |
| bool | published_once_ {false} |
| True once anything (a value or "unknown") was published. | |
| Protected Attributes inherited from esphome::home_io_control::DeviceBoundCompanion | |
| IOHomeControlComponent * | parent_ {nullptr} |
| std::string | device_id_ |
Additional Inherited Members | |
| Protected Member Functions inherited from esphome::home_io_control::DeviceBoundCompanion | |
| void | register_companion_binding_ (const std::function< void(const IoDevice &)> &publish) |
| Shared setup() body: subscribe to this device's updates and publish the initial state. | |
Sensor publishing the raw sun value a device answers its sun level poll with.
Only generated when the cover declares sun_level_poll_interval:, which also schedules the poll that feeds it (a subscription to EVENT_LOCAL_SENSOR, ADR 0064). Publishes the number as the device sends it, with no unit: 0 at night, rising with sun on the panel. No state until the first answered poll, and again after several unanswered polls.
Definition at line 161 of file platform_cover_controls.h.
|
override |
Dump sensor configuration to the log.
Definition at line 133 of file platform_cover_controls.cpp.
|
override |
Subscribe to the device's updates and publish what is already known.
Definition at line 121 of file platform_cover_controls.cpp.
|
protected |
Last value handed to publish_state(); avoids re-publishing on every update.
Definition at line 170 of file platform_cover_controls.h.
|
protected |
True once anything (a value or "unknown") was published.
Definition at line 171 of file platform_cover_controls.h.