Legacy input rcmd bug fixed

This commit is contained in:
2020-04-02 02:40:26 +03:00
parent 054ac6a206
commit d1d62515b6
2 changed files with 3 additions and 1 deletions

View File

@@ -2,3 +2,5 @@
-DW5500_CS_PIN=53
-DARTNET_ENABLE
-DDMX_SMOOTH
-DMODBUS_DIMMER_PARAM=SERIAL_8N1
-DMODBUS_SERIAL_BAUD=9600

View File

@@ -934,7 +934,7 @@ if (!strchr(addrstr,'/')) setTopic(addrstr,sizeof(addrstr),T_OUT,emit->valuestri
else if (strlen(scmd->valuestring))
it.Ctrl(scmd->valuestring, true);
} else { //send reset command
if (!rcmd || rcmd->type == aJson_String) it.Ctrl(CMD_OFF, 0, NULL, true);
if (!rcmd || rcmd->type != aJson_String) it.Ctrl(CMD_OFF, 0, NULL, true);
else if (strlen(rcmd->valuestring))
it.Ctrl(rcmd->valuestring, true);
}