diff --git a/README.md b/README.md index 6213e7a9..893d07e5 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,13 @@ If you would like to support the developer with a cup of coffee you can do that -##### Rolling - (2021-01-18) +##### Rolling - (2021-01-19) + +* Improvement for wlan password: additionally now "`=`" is possible in the password or wlan-name + +* Reduction of log file info (removal of memory information) + +2021-01-18 * New Feature `ExtendedResolution` uses the after comma digit of the last analog counter to increase precision by one digit. This can only be activated in expert mode. diff --git a/code/components/connect_wlan/connect_wlan.cpp b/code/components/connect_wlan/connect_wlan.cpp index 04e6d96a..c9f334f6 100644 --- a/code/components/connect_wlan/connect_wlan.cpp +++ b/code/components/connect_wlan/connect_wlan.cpp @@ -314,6 +314,8 @@ void LoadWlanFromFile(std::string fn, std::string &_ssid, std::string &_passphra printf("%s", line.c_str()); zerlegt = ZerlegeZeile(line, "="); zerlegt[0] = trim(zerlegt[0], " "); + for (int i = 2; i < zerlegt.size(); ++i) + zerlegt[i] = zerlegt[i-1] + zerlegt[i]; if ((zerlegt.size() > 1) && (toUpper(zerlegt[0]) == "HOSTNAME")){ _hostname = trim(zerlegt[1]); diff --git a/code/components/jomjol_controlcamera/server_camera.cpp b/code/components/jomjol_controlcamera/server_camera.cpp index 21eb9363..d318a736 100644 --- a/code/components/jomjol_controlcamera/server_camera.cpp +++ b/code/components/jomjol_controlcamera/server_camera.cpp @@ -95,10 +95,9 @@ esp_err_t handler_capture(httpd_req_t *req) esp_err_t handler_capture_with_ligth(httpd_req_t *req) { - +#ifdef DEBUG_DETAIL_ON LogFile.WriteHeapInfo("handler_capture_with_ligth - Start"); - - LogFile.WriteToFile("handler_capture_with_ligth"); +#endif char _query[100]; char _delay[10]; diff --git a/code/components/jomjol_flowcontroll/ClassFlowControll.cpp b/code/components/jomjol_flowcontroll/ClassFlowControll.cpp index 444f8619..3d24feab 100644 --- a/code/components/jomjol_flowcontroll/ClassFlowControll.cpp +++ b/code/components/jomjol_flowcontroll/ClassFlowControll.cpp @@ -212,10 +212,9 @@ bool ClassFlowControll::doFlow(string time) zw_time = gettimestring("%Y%m%d-%H%M%S"); aktstatus = zw_time + ": " + FlowControll[i]->name(); -// #ifdef DEBUG_DETAIL_ON + string zw = "FlowControll.doFlow - " + FlowControll[i]->name(); LogFile.WriteHeapInfo(zw); -// #endif if (!FlowControll[i]->doFlow(time)){ repeat++; @@ -393,6 +392,11 @@ bool ClassFlowControll::ReadParameter(FILE* pfile, string& aktparamgraph) SetupModeActive = true; } } + + if ((toUpper(zerlegt[0]) == "LOGLEVEL") && (zerlegt.size() > 1)) + { + LogFile.setLogLevel(stoi(zerlegt[1])); + } } return true; } diff --git a/code/components/jomjol_logfile/ClassLogFile.cpp b/code/components/jomjol_logfile/ClassLogFile.cpp index ad525fd5..f8fbb3fc 100644 --- a/code/components/jomjol_logfile/ClassLogFile.cpp +++ b/code/components/jomjol_logfile/ClassLogFile.cpp @@ -12,8 +12,10 @@ ClassLogFile LogFile("/sdcard/log/message", "log_%Y-%m-%d.txt"); void ClassLogFile::WriteHeapInfo(std::string _id) { - std::string _zw; - _zw = "\t" + _id + "\t" + getESPHeapInfo(); +std::string _zw = "\t" + _id; + if (loglevel > 0) + _zw = _zw + "\t" + getESPHeapInfo(); + WriteToFile(_zw); } @@ -188,4 +190,5 @@ ClassLogFile::ClassLogFile(std::string _logroot, std::string _logfile) logfile = _logfile; doLogFile = true; retentionInDays = 10; + loglevel = 0; } diff --git a/code/components/jomjol_logfile/ClassLogFile.h b/code/components/jomjol_logfile/ClassLogFile.h index b4a3429c..02401ab6 100644 --- a/code/components/jomjol_logfile/ClassLogFile.h +++ b/code/components/jomjol_logfile/ClassLogFile.h @@ -9,11 +9,14 @@ private: std::string logfile; bool doLogFile; unsigned short retentionInDays; + int loglevel; public: ClassLogFile(std::string _logpath, std::string _logfile); std::string getESPHeapInfo(); + void setLogLevel(int i){loglevel = i;}; + void WriteHeapInfo(std::string _id); void SwitchOnOff(bool _doLogFile); diff --git a/code/main/version.cpp b/code/main/version.cpp index 8c25d451..0b328a30 100644 --- a/code/main/version.cpp +++ b/code/main/version.cpp @@ -1,4 +1,4 @@ -const char* GIT_REV="c65de27"; +const char* GIT_REV="2530691"; const char* GIT_TAG=""; const char* GIT_BRANCH="rolling"; -const char* BUILD_TIME="2021-01-18 20:57"; \ No newline at end of file +const char* BUILD_TIME="2021-01-19 19:44"; \ No newline at end of file diff --git a/code/version.cpp b/code/version.cpp index 8c25d451..0b328a30 100644 --- a/code/version.cpp +++ b/code/version.cpp @@ -1,4 +1,4 @@ -const char* GIT_REV="c65de27"; +const char* GIT_REV="2530691"; const char* GIT_TAG=""; const char* GIT_BRANCH="rolling"; -const char* BUILD_TIME="2021-01-18 20:57"; \ No newline at end of file +const char* BUILD_TIME="2021-01-19 19:44"; \ No newline at end of file diff --git a/firmware/bootloader.bin b/firmware/bootloader.bin index 5c66c5d1..b8b66536 100644 Binary files a/firmware/bootloader.bin and b/firmware/bootloader.bin differ diff --git a/firmware/firmware.bin b/firmware/firmware.bin index c27fcfe2..b493194a 100644 Binary files a/firmware/firmware.bin and b/firmware/firmware.bin differ