mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2026-01-26 08:39:09 +03:00
fix RC120RF check
This commit is contained in:
@@ -76,9 +76,11 @@ uint8_t Roomctrl::get_hc(uint8_t addr) {
|
||||
if (addr >= 0x40 && addr <= 0x44 && type_[addr - 0x40] == SENSOR) {
|
||||
return addr - 0x40; // SENSOR
|
||||
} else if (addr >= 0x38 && addr <= 0x3B
|
||||
&& (type_[addr - 0x38] == RC100H || type_[addr - 0x38] == RC200 || type_[addr - 0x38] == RC100 || type_[addr - 0x38] == RT800)) {
|
||||
return addr - 0x38; // RC100H, RC200
|
||||
} else if (addr >= 0x18 && addr <= 0x1B && (type_[addr - 0x18] == RC20 || type_[addr - 0x18] == FB10)) {
|
||||
&& (type_[addr - 0x38] == RC100H || type_[addr - 0x38] == RC200 || type_[addr - 0x38] == RC100 || type_[addr - 0x38] == RT800
|
||||
|| type_[addr - 0x38] == RC120RF)) {
|
||||
return addr - 0x38; // RC100H, RC200
|
||||
}
|
||||
else if (addr >= 0x18 && addr <= 0x1B && (type_[addr - 0x18] == RC20 || type_[addr - 0x18] == FB10)) {
|
||||
return addr - 0x18; // RC20, FB10
|
||||
}
|
||||
return 0xFF; // invalid
|
||||
|
||||
Reference in New Issue
Block a user