mirror of
https://github.com/esphome/esphome.git
synced 2025-04-07 11:20:28 +01:00
Update mcp4461.cpp
This commit is contained in:
parent
6b60e8dc9e
commit
0d3a1d50ea
@ -83,7 +83,7 @@ uint16_t Mcp4461Component::get_status_register() {
|
|||||||
uint16_t buf;
|
uint16_t buf;
|
||||||
if (!this->read_byte_16(reg, &buf)) {
|
if (!this->read_byte_16(reg, &buf)) {
|
||||||
this->status_set_warning();
|
this->status_set_warning();
|
||||||
ESP_LOGW(TAG, "Error fetching status register value");
|
ESP_LOGE(TAG, "Error fetching status register value");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
return buf;
|
return buf;
|
||||||
@ -112,7 +112,7 @@ uint8_t Mcp4461Component::get_wiper_address_(uint8_t wiper) {
|
|||||||
addr = static_cast<uint8_t>(Mcp4461Addresses::MCP4461_VW3);
|
addr = static_cast<uint8_t>(Mcp4461Addresses::MCP4461_VW3);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
ESP_LOGE(TAG, "unknown wiper specified");
|
ESP_LOGW(TAG, "unknown wiper specified");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
if (nonvolatile) {
|
if (nonvolatile) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user