mirror of
https://github.com/esphome/esphome.git
synced 2025-03-26 04:28:17 +00:00
commit
f28da2082a
@ -368,7 +368,7 @@ bool Mcp4461Component::increase_wiper_(Mcp4461WiperIdx wiper) {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (this->reg_[wiper_idx].state == 256) {
|
if (this->reg_[wiper_idx].state == 256) {
|
||||||
ESP_LOGV(TAG, "%s", "Maximum wiper level reached, further increase of wiper %" PRIu8 " prohibited", wiper_idx);
|
ESP_LOGV(TAG, "Maximum wiper level reached, further increase of wiper %" PRIu8 " prohibited", wiper_idx);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
ESP_LOGV(TAG, "Increasing wiper %" PRIu8 "", wiper_idx);
|
ESP_LOGV(TAG, "Increasing wiper %" PRIu8 "", wiper_idx);
|
||||||
@ -402,7 +402,7 @@ bool Mcp4461Component::decrease_wiper_(Mcp4461WiperIdx wiper) {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (this->reg_[wiper_idx].state == 0) {
|
if (this->reg_[wiper_idx].state == 0) {
|
||||||
ESP_LOGV(TAG, "%s", "Minimum wiper level reached, further decrease of wiper %" PRIu8 " prohibited", wiper_idx);
|
ESP_LOGV(TAG, "Minimum wiper level reached, further decrease of wiper %" PRIu8 " prohibited", wiper_idx);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
ESP_LOGV(TAG, "Decreasing wiper %" PRIu8 "", wiper_idx);
|
ESP_LOGV(TAG, "Decreasing wiper %" PRIu8 "", wiper_idx);
|
||||||
|
@ -25,7 +25,7 @@ class Mcp4461Wiper : public output::FloatOutput, public Parented<Mcp4461Componen
|
|||||||
void write_state(float state) override;
|
void write_state(float state) override;
|
||||||
Mcp4461Component *parent_;
|
Mcp4461Component *parent_;
|
||||||
Mcp4461WiperIdx wiper_;
|
Mcp4461WiperIdx wiper_;
|
||||||
uint16_t state_;
|
float state_;
|
||||||
optional<uint16_t> initial_value_;
|
optional<uint16_t> initial_value_;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user