changed json var names to more visible

This commit is contained in:
Dmitry Borisenko
2020-06-19 14:50:34 +02:00
parent e6637dcd69
commit 48ba3c99dd
18 changed files with 428 additions and 340 deletions

View File

@@ -1,7 +1,7 @@
#include "Global.h"
void saveConfig() {
writeFile("config.json", configSetup);
writeFile("config.json", configSetupJson);
}
//--------------------Посчитать -----------------------------------------------------------------------------------
@@ -49,7 +49,7 @@ void safeDataToFile(String data, String Folder) {
fileName = Folder + "/" + fileName + ".txt";
// addFile(fileName, GetTime() + "/" + data);
Serial.println(fileName);
jsonWriteStr(configJson, "test", fileName);
jsonWriteStr(configLiveJson, "test", fileName);
}
// ------------- Чтение файла в строку -------------------------------------------------------------------------------
@@ -113,7 +113,7 @@ String readFileString(const String& filename, const String& str_to_found) {
void sendCONFIG(String topik, String widgetConfig, String key, String date) {
yield();
topik = jsonReadStr(configSetup, "mqttPrefix") + "/" + chipID + "/" + topik + "/status";
topik = jsonReadStr(configSetupJson, "mqttPrefix") + "/" + chipID + "/" + topik + "/status";
String outer = "{\"widgetConfig\":";
String inner = "{\"";
inner = inner + key;