Browse Source

Update Restart Hostname

jomjol 4 năm trước cách đây
mục cha
commit
c6ae989b82

+ 1 - 0
README.md

@@ -44,6 +44,7 @@ If you would like to support the developer with a cup of coffee you can do that
 ##### Rolling - (2021-03-21)
 ##### Rolling - (2021-03-21)
 
 
 * Bug fixing in `html.zip`
 * Bug fixing in `html.zip`
+* Bug fixing: restart after renaming hostname in `config.ini` did not work reliable
 * based on v6.4.0
 * based on v6.4.0
 
 
 ##### 6.4.0 Image Processing in Memory - (2021-03-20)
 ##### 6.4.0 Image Processing in Memory - (2021-03-20)

+ 3 - 0
code/components/connect_wlan/connect_wlan.cpp

@@ -292,11 +292,14 @@ bool ChangeHostName(std::string fn, std::string _newhostname)
 
 
     for (int i = 0; i < neuesfile.size(); ++i)
     for (int i = 0; i < neuesfile.size(); ++i)
     {
     {
+        printf(neuesfile[i].c_str());
         fputs(neuesfile[i].c_str(), pFile);
         fputs(neuesfile[i].c_str(), pFile);
     }
     }
 
 
     fclose(pFile);
     fclose(pFile);
 
 
+    printf("*** Update hostname done ***\n");
+
     return true;
     return true;
 }
 }
 
 

+ 1 - 0
code/components/jomjol_fileserver_ota/server_ota.h

@@ -9,4 +9,5 @@ static const char *TAGPARTOTA = "server_ota";
 void register_server_ota_sdcard_uri(httpd_handle_t server);
 void register_server_ota_sdcard_uri(httpd_handle_t server);
 void CheckOTAUpdate();
 void CheckOTAUpdate();
 void doReboot();
 void doReboot();
+void hard_restart();
 
 

+ 3 - 0
code/components/jomjol_flowcontroll/ClassFlowControll.cpp

@@ -382,6 +382,9 @@ bool ClassFlowControll::ReadParameter(FILE* pfile, string& aktparamgraph)
             {
             {
                 // reboot notwendig damit die neue wlan.ini auch benutzt wird !!!
                 // reboot notwendig damit die neue wlan.ini auch benutzt wird !!!
                 fclose(pfile);
                 fclose(pfile);
+                printf("do reboot\n");
+                esp_restart();
+                hard_restart();                   
                 doReboot();
                 doReboot();
             }
             }
         }
         }

+ 3 - 3
code/main/version.cpp

@@ -1,4 +1,4 @@
-const char* GIT_REV="3b3d924";
+const char* GIT_REV="a0ebf35";
 const char* GIT_TAG="";
 const char* GIT_TAG="";
-const char* GIT_BRANCH="master";
-const char* BUILD_TIME="2021-03-17 22:46";
+const char* GIT_BRANCH="rolling";
+const char* BUILD_TIME="2021-03-21 20:49";

+ 1 - 1
code/main/version.h

@@ -13,7 +13,7 @@ extern "C"
 #include "Helper.h"
 #include "Helper.h"
 #include <fstream>
 #include <fstream>
 
 
-const char* GIT_BASE_BRANCH = "master - v6.3.1 - 2020-03-16";
+const char* GIT_BASE_BRANCH = "master - v6.4.0 - 2020-03-20";
 
 
 
 
 const char* git_base_branch(void)
 const char* git_base_branch(void)

+ 3 - 3
code/version.cpp

@@ -1,4 +1,4 @@
-const char* GIT_REV="3b3d924";
+const char* GIT_REV="a0ebf35";
 const char* GIT_TAG="";
 const char* GIT_TAG="";
-const char* GIT_BRANCH="master";
-const char* BUILD_TIME="2021-03-17 22:46";
+const char* GIT_BRANCH="rolling";
+const char* BUILD_TIME="2021-03-21 20:49";

BIN
firmware/bootloader.bin


BIN
firmware/firmware.bin