mirror of
https://github.com/anklimov/lighthub
synced 2025-12-06 19:59:50 +03:00
fix
This commit is contained in:
@@ -227,7 +227,7 @@ void Input::dht22Poll() {
|
|||||||
#endif
|
#endif
|
||||||
aJsonObject *emit = aJson.getObjectItem(inputObj, "emit");
|
aJsonObject *emit = aJson.getObjectItem(inputObj, "emit");
|
||||||
aJsonObject *item = aJson.getObjectItem(inputObj, "item");
|
aJsonObject *item = aJson.getObjectItem(inputObj, "item");
|
||||||
if (item) thermoSetCurTemp(item, temp);
|
if (item) thermoSetCurTemp(item->valuestring, temp);
|
||||||
debugSerial << F("IN:") << pin << F(" DHT22 type. T=") << temp << F("°C H=") << humidity << F("%");
|
debugSerial << F("IN:") << pin << F(" DHT22 type. T=") << temp << F("°C H=") << humidity << F("%");
|
||||||
if (emit && temp && humidity && temp == temp && humidity == humidity) {
|
if (emit && temp && humidity && temp == temp && humidity == humidity) {
|
||||||
char addrstr[MQTT_TOPIC_LENGTH] = "";
|
char addrstr[MQTT_TOPIC_LENGTH] = "";
|
||||||
|
|||||||
@@ -270,7 +270,7 @@ if (isSet)
|
|||||||
while (payload && i < 3)
|
while (payload && i < 3)
|
||||||
Par[i++] = getInt((char **) &payload);
|
Par[i++] = getInt((char **) &payload);
|
||||||
|
|
||||||
return Ctrl(0, i, Par, send, subItem);
|
return Ctrl(0, i, Par, send, subItemN);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|||||||
@@ -79,6 +79,7 @@ e-mail anklimov@gmail.com
|
|||||||
#include "aJSON.h"
|
#include "aJSON.h"
|
||||||
|
|
||||||
extern aJsonObject *items;
|
extern aJsonObject *items;
|
||||||
|
extern short thermoSetCurTemp(char *name, float t);
|
||||||
|
|
||||||
int txt2cmd (char * payload);
|
int txt2cmd (char * payload);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user