ESPHome 2025.6.1
Loading...
Searching...
No Matches
dac_output_select.cpp
Go to the documentation of this file.
1#include "dac_output_select.h"
2
3namespace esphome {
4namespace es8388 {
5
6void DacOutputSelect::control(const std::string &value) {
7 this->publish_state(value);
8 this->parent_->set_dac_output(static_cast<DacOutputLine>(this->index_of(value).value()));
9}
10
11} // namespace es8388
12} // namespace esphome
void control(const std::string &value) override
optional< size_t > index_of(const std::string &option) const
Find the (optional) index offset of the provided option value.
Definition select.cpp:35
void publish_state(const std::string &state)
Definition select.cpp:9
Providing packet encoding functions for exchanging data with a remote host.
Definition a01nyub.cpp:7