mirror of
https://github.com/esphome/esphome.git
synced 2025-03-28 21:48:16 +00:00
Update mcp4461_output.cpp
This commit is contained in:
parent
604eaa80af
commit
7ca80bf008
@ -96,8 +96,9 @@ void Mcp4461Wiper::increase_wiper() {
|
||||
ESP_LOGW(TAG, "Cannot increase nonvolatile wiper %" PRIu8 " !", wiper_idx);
|
||||
return;
|
||||
}
|
||||
this->state_ = this->state_ + 1.0;
|
||||
this->parent_->increase_wiper(this->wiper_);
|
||||
if (this->parent_->increase_wiper(this->wiper_)) {
|
||||
this->state_ = this->state_ + 1.0;
|
||||
}
|
||||
}
|
||||
|
||||
void Mcp4461Wiper::decrease_wiper() {
|
||||
@ -110,8 +111,9 @@ void Mcp4461Wiper::decrease_wiper() {
|
||||
ESP_LOGW(TAG, "Cannot decrease nonvolatile wiper %" PRIu8 " !", wiper_idx);
|
||||
return;
|
||||
}
|
||||
this->state_ = this->state_ - 1.0;
|
||||
this->parent_->decrease_wiper(this->wiper_);
|
||||
if (this->parent_->decrease_wiper(this->wiper_)) {
|
||||
this->state_ = this->state_ - 1.0;
|
||||
}
|
||||
}
|
||||
|
||||
void Mcp4461Wiper::enable_terminal(char terminal) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user