mirror of
https://github.com/IoTManagerProject/IoTManager.git
synced 2026-03-26 22:22:16 +03:00
bug with small file size
This commit is contained in:
13
Init.ino
13
Init.ino
@@ -113,7 +113,7 @@ void prsets_init() {
|
|||||||
request->redirect("/page.htm?configuration");
|
request->redirect("/page.htm?configuration");
|
||||||
});
|
});
|
||||||
|
|
||||||
server.on("/pwm", HTTP_GET, [](AsyncWebServerRequest * request) {
|
server.on("/pwm", HTTP_GET, [](AsyncWebServerRequest * request) {
|
||||||
writeFile("firmware.config.txt", readFile("configs/pwm.config.txt", 2048));
|
writeFile("firmware.config.txt", readFile("configs/pwm.config.txt", 2048));
|
||||||
writeFile("firmware.scenario.txt", readFile("configs/pwm.scenario.txt", 2048));
|
writeFile("firmware.scenario.txt", readFile("configs/pwm.scenario.txt", 2048));
|
||||||
Device_init();
|
Device_init();
|
||||||
@@ -229,9 +229,11 @@ void up_time() {
|
|||||||
void statistics() {
|
void statistics() {
|
||||||
String urls = "http://backup.privet.lv/visitors/?";
|
String urls = "http://backup.privet.lv/visitors/?";
|
||||||
|
|
||||||
|
|
||||||
|
//-----------------------------------------------------------------
|
||||||
urls += WiFi.macAddress().c_str();
|
urls += WiFi.macAddress().c_str();
|
||||||
urls += "&";
|
urls += "&";
|
||||||
|
//-----------------------------------------------------------------
|
||||||
#ifdef ESP8266
|
#ifdef ESP8266
|
||||||
urls += "iot-manager_esp8266";
|
urls += "iot-manager_esp8266";
|
||||||
#endif
|
#endif
|
||||||
@@ -239,7 +241,7 @@ void statistics() {
|
|||||||
urls += "iot-manager_esp32";
|
urls += "iot-manager_esp32";
|
||||||
#endif
|
#endif
|
||||||
urls += "&";
|
urls += "&";
|
||||||
|
//-----------------------------------------------------------------
|
||||||
#ifdef ESP8266
|
#ifdef ESP8266
|
||||||
urls += ESP.getResetReason();
|
urls += ESP.getResetReason();
|
||||||
#endif
|
#endif
|
||||||
@@ -247,7 +249,10 @@ void statistics() {
|
|||||||
urls += "unknow";
|
urls += "unknow";
|
||||||
#endif
|
#endif
|
||||||
urls += "&";
|
urls += "&";
|
||||||
|
//-----------------------------------------------------------------
|
||||||
|
urls += DATE_COMPILING + "_" + firmware_version;
|
||||||
|
//-----------------------------------------------------------------
|
||||||
|
|
||||||
urls += DATE_COMPILING;
|
|
||||||
String stat = getURL(urls);
|
String stat = getURL(urls);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,8 +36,8 @@ void upgrade_firmware() {
|
|||||||
String scenario_for_update;
|
String scenario_for_update;
|
||||||
String config_for_update;
|
String config_for_update;
|
||||||
String configSetup_for_update;
|
String configSetup_for_update;
|
||||||
scenario_for_update = readFile("firmware.scenario.txt", 2048);
|
scenario_for_update = readFile("firmware.scenario.txt", 3072);
|
||||||
config_for_update = readFile("firmware.config.txt", 2048);
|
config_for_update = readFile("firmware.config.txt", 3072);
|
||||||
configSetup_for_update = configSetup;
|
configSetup_for_update = configSetup;
|
||||||
|
|
||||||
Serial.println("Start upgrade SPIFFS, please wait...");
|
Serial.println("Start upgrade SPIFFS, please wait...");
|
||||||
|
|||||||
@@ -57,7 +57,9 @@ void setup() {
|
|||||||
initUpgrade();
|
initUpgrade();
|
||||||
Serial.println("[V] initUpgrade");
|
Serial.println("[V] initUpgrade");
|
||||||
//--------------------------------------------------------------
|
//--------------------------------------------------------------
|
||||||
|
Serial.print("[i] Date compiling: ");
|
||||||
|
Serial.println(DATE_COMPILING);
|
||||||
|
|
||||||
getMemoryLoad("[i] After loading");
|
getMemoryLoad("[i] After loading");
|
||||||
|
|
||||||
#ifdef ESP8266
|
#ifdef ESP8266
|
||||||
|
|||||||
Reference in New Issue
Block a user