ошибки

This commit is contained in:
Dmitry Borisenko
2022-11-22 16:04:50 +01:00
parent b49c4ecb1a
commit 96d623f53b
2 changed files with 10 additions and 11 deletions

View File

@@ -159,7 +159,6 @@ void mqttCallback(char* topic, uint8_t* payload, size_t length) {
//здесь мы получаем события с других устройств, которые потом проверяются в сценариях этого устройства
else if (topicStr.indexOf("event") != -1) {
//пока не работает сетевой обмен этот код будет закомментирован
if (!jsonReadBool(settingsFlashJson, "mqttin")) {
return;
}
@@ -167,7 +166,7 @@ void mqttCallback(char* topic, uint8_t* payload, size_t length) {
String devId = selectFromMarkerToMarker(topicStr, "/", 2);
String id = selectFromMarkerToMarker(topicStr, "/", 3);
analyzeMsgFromNet(payloadStr, id);
//SerialPrint("i", F("=>MQTT"), "Received event from other device: '" + devId + "' " + id + " " + valAsStr);
// SerialPrint("i", F("=>MQTT"), "Received event from other device: '" + devId + "' " + id + " " + valAsStr);
}
}

View File

@@ -17,13 +17,13 @@ void SerialPrint(const String& errorLevel, const String& module, const String& m
}
}
// if (errorLevel == "E") {
// cleanString(tosend);
// // создаем событие об ошибке для возможной реакции в сценарии
// if (itemId != "") {
// createItemFromNet(itemId + "_onError", tosend, -4);
// } else {
// createItemFromNet("onError", tosend, -4);
// }
// }
if (errorLevel == "E") {
cleanString(tosend);
// создаем событие об ошибке для возможной реакции в сценарии
if (itemId != "") {
createItemFromNet(itemId + "_onError", tosend, -4);
} else {
// createItemFromNet("onError", tosend, -4);
}
}
}