Корректируем новую схему с новыми устройствами esp01

This commit is contained in:
2022-10-12 15:48:05 +03:00
parent 3af9b457de
commit 0e44ba1a3e
20 changed files with 380 additions and 502 deletions

View File

@@ -72,7 +72,7 @@ bool upgradeBuild() {
handleUpdateStatus(true, PATH_ERROR);
return ret;
}
#ifdef esp8266_4mb
#if defined (esp8266_4mb) || defined (esp8266_1mb) || defined (esp8266_1mb_ota)
ESPhttpUpdate.rebootOnUpdate(false);
t_httpUpdate_return retBuild = ESPhttpUpdate.update(wifiClient, getBinPath("firmware.bin"));
#endif

View File

@@ -1,31 +1,14 @@
#include "ESPConfiguration.h"
void* getAPI_Loging(String subtype, String params);
void* getAPI_LogingDaily(String subtype, String params);
void* getAPI_Timer(String subtype, String params);
void* getAPI_Variable(String subtype, String params);
void* getAPI_VButton(String subtype, String params);
void* getAPI_Acs712(String subtype, String params);
void* getAPI_AhtXX(String subtype, String params);
void* getAPI_AnalogAdc(String subtype, String params);
void* getAPI_Bme280(String subtype, String params);
void* getAPI_Bmp280(String subtype, String params);
void* getAPI_Dht1122(String subtype, String params);
void* getAPI_Ds18b20(String subtype, String params);
void* getAPI_GY21(String subtype, String params);
void* getAPI_Hdc1080(String subtype, String params);
void* getAPI_Max6675(String subtype, String params);
void* getAPI_Pzem004(String subtype, String params);
void* getAPI_RCswitch(String subtype, String params);
void* getAPI_Sht20(String subtype, String params);
void* getAPI_Sht30(String subtype, String params);
void* getAPI_Sonar(String subtype, String params);
void* getAPI_UART(String subtype, String params);
void* getAPI_ButtonIn(String subtype, String params);
void* getAPI_ButtonOut(String subtype, String params);
void* getAPI_IoTServo(String subtype, String params);
void* getAPI_Mcp23017(String subtype, String params);
void* getAPI_Mp3(String subtype, String params);
void* getAPI_Pcf8574(String subtype, String params);
void* getAPI_Pwm8266(String subtype, String params);
void* getAPI_TelegramLT(String subtype, String params);
@@ -33,32 +16,15 @@ void* getAPI_Lcd2004(String subtype, String params);
void* getAPI(String subtype, String params) {
void* tmpAPI;
if ((tmpAPI = getAPI_Loging(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_LogingDaily(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Timer(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Variable(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_VButton(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Acs712(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_AhtXX(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_AnalogAdc(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Bme280(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Bmp280(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Dht1122(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Ds18b20(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_GY21(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Hdc1080(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Max6675(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Pzem004(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_RCswitch(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Sht20(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Sht30(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Sonar(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_UART(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_ButtonIn(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_ButtonOut(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_IoTServo(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Mcp23017(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Mp3(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Pcf8574(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_Pwm8266(subtype, params)) != nullptr) return tmpAPI;
if ((tmpAPI = getAPI_TelegramLT(subtype, params)) != nullptr) return tmpAPI;

View File

@@ -108,6 +108,12 @@
],
"esp8266_4mb": [
"marcoschwartz/LiquidCrystal_I2C@^1.1.4"
],
"esp8266_1mb": [
"marcoschwartz/LiquidCrystal_I2C@^1.1.4"
],
"esp8266_1mb_ota": [
"marcoschwartz/LiquidCrystal_I2C@^1.1.4"
]
}
}

View File

@@ -42,6 +42,8 @@
"defActive": true,
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -43,6 +43,8 @@
"defActive": true,
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -45,6 +45,14 @@
"esp8266_4mb": [
"adafruit/Adafruit MCP23017 Arduino Library@^2.1.0",
"adafruit/Adafruit BusIO @ ^1.13.2"
],
"esp8266_1mb": [
"adafruit/Adafruit MCP23017 Arduino Library@^2.1.0",
"adafruit/Adafruit BusIO @ ^1.13.2"
],
"esp8266_1mb_ota": [
"adafruit/Adafruit MCP23017 Arduino Library@^2.1.0",
"adafruit/Adafruit BusIO @ ^1.13.2"
]
}
}

View File

@@ -37,6 +37,12 @@
],
"esp8266_4mb": [
"adafruit/Adafruit BusIO @ ^1.13.2"
],
"esp8266_1mb": [
"adafruit/Adafruit BusIO @ ^1.13.2"
],
"esp8266_1mb_ota": [
"adafruit/Adafruit BusIO @ ^1.13.2"
]
}
}

View File

@@ -41,6 +41,8 @@
"defActive": true,
"usedLibs": {
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -51,6 +51,8 @@
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -43,6 +43,12 @@
],
"esp8266_4mb": [
"milesburton/DallasTemperature@^3.9.1"
],
"esp8266_1mb": [
"milesburton/DallasTemperature@^3.9.1"
],
"esp8266_1mb_ota": [
"milesburton/DallasTemperature@^3.9.1"
]
}
}

View File

@@ -37,6 +37,8 @@
"defActive": true,
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -69,6 +69,8 @@
"defActive": true,
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -34,6 +34,8 @@
"defActive": true,
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}

View File

@@ -71,6 +71,8 @@
"defActive": true,
"usedLibs": {
"esp32_4mb": [],
"esp8266_4mb": []
"esp8266_4mb": [],
"esp8266_1mb": [],
"esp8266_1mb_ota": []
}
}