From af59b24ff905d76ed9dc0f074f8bb532332b1bce Mon Sep 17 00:00:00 2001 From: tastendruecker123 <111116980+tastendruecker123@users.noreply.github.com> Date: Thu, 18 Aug 2022 20:20:54 +0200 Subject: [PATCH] Runs on ESP32 now --- tools/esp8266/app.cpp | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/tools/esp8266/app.cpp b/tools/esp8266/app.cpp index 8adb1b9f..7cd3f4b2 100644 --- a/tools/esp8266/app.cpp +++ b/tools/esp8266/app.cpp @@ -17,16 +17,10 @@ app::app() { Serial.begin(115200); DPRINTLN(DBG_VERBOSE, F("app::app")); mEep = new eep(); - DPRINTLN(DBG_VERBOSE, F("app::wifi")); mWifi = new ahoywifi(this, &mSysConfig, &mConfig); -DPRINTLN(DBG_VERBOSE, F("app::web")); - mWebInst = new web(this, &mSysConfig, &mConfig, mVersion); - DPRINTLN(DBG_VERBOSE, F("app::setup")); - mWebInst->setup(); -DPRINTLN(DBG_VERBOSE, F("app::reset")); + resetSystem(); - DPRINTLN(DBG_VERBOSE, F("app::config")); - loadDefaultConfig(); + loadDefaultConfig(); mSys = new HmSystemType(); } @@ -34,8 +28,7 @@ DPRINTLN(DBG_VERBOSE, F("app::reset")); //----------------------------------------------------------------------------- void app::setup(uint32_t timeout) { - DPRINTLN(DBG_VERBOSE, F("app::setup")); - + mWifiSettingsValid = checkEEpCrc(ADDR_START, ADDR_WIFI_CRC, ADDR_WIFI_CRC); mSettingsValid = checkEEpCrc(ADDR_START_SETTINGS, ((ADDR_NEXT)-(ADDR_START_SETTINGS)), ADDR_SETTINGS_CRC); loadEEpconfig(); @@ -46,6 +39,9 @@ void app::setup(uint32_t timeout) { setupMqtt(); #endif mSys->setup(&mConfig); + + mWebInst = new web(this, &mSysConfig, &mConfig, mVersion); + mWebInst->setup(); } //-----------------------------------------------------------------------------