Browse Source

domoticz: fix basic switch nvalue

fixes #1606

When ON domoticz sends:
value >= 1 for lights
value == 1 for basic switches
rules-rpn
Max Prokhorov 5 years ago
committed by GitHub
parent
commit
07ba3ff2d5
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      code/espurna/domoticz.ino

+ 1
- 1
code/espurna/domoticz.ino View File

@ -139,7 +139,7 @@ void _domoticzMqtt(unsigned int type, const char * topic, const char * payload)
if (relayID >= 0) { if (relayID >= 0) {
unsigned char value = root["nvalue"]; unsigned char value = root["nvalue"];
DEBUG_MSG_P(PSTR("[DOMOTICZ] Received value %u for IDX %u\n"), value, idx); DEBUG_MSG_P(PSTR("[DOMOTICZ] Received value %u for IDX %u\n"), value, idx);
_domoticzStatus(relayID, value > 1);
_domoticzStatus(relayID, value >= 1);
} }
} }


Loading…
Cancel
Save