-
Notifications
You must be signed in to change notification settings - Fork 8
Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27
Comments
I'm glad that the new feature is working for you. I've updated that The design for CP, I remember, has no timeout. But depending on what is the real cause, you can write some simple code using timer and the resetFunc() to take care of the auto-reboot. For example, after the Virtual SW is pressed, you start an auto-resetting timer, then call resetAndEnterConfigPortal(). resetFunction() can use ESP.reset() for ESP8266 or ESP.restart() for ESP32 Depending on which is the cause of CP:
Hope to receive more issues, leading to new ideas, from you, Good Luck, BR |
Thanks @khoih-prog for taking the time on this. I think |
You can write a flag to LittleFS, SPIFFS or EEPROM, then after reboot, check that flag to start a rebooting timer.
Later, I'll think about introducing this feature (thanks to you again) into the libraries (already reserved data for it)
What else do you suggest? |
Oh, you're right. I forget we have this feature
Try test and use this to see if OK for you. |
I have tested the following code inserted before the
How were these three lines supposed to work? Either way, the new Even with the three lines, above, the Config Portal stays lit for a long time unless I access the CP and SAVE it. I understand your suggestion of setting a flag in persistent memory to pick up on reboot, was trying to remember if this feature was already built into the library. If not, I'll set the LittleFS flag and read it. Should work fine. |
To be considered, those lines must be before all the #include <BlynkSimpleEsp????.h> statements, not after. Currently, they are already in the
The operation is as follows:
if you've been in CP for more than (CONFIG_TIMEOUT * CONFIG_TIMEOUT_RETRYTIMES_BEFORE_RESET) = (60s * 5) = 300s, the ESP will reset itself. If the forced CP is non-persistent or DRD/MRD, the reset will return the ESP to normal operation. It's good that this feature, designed from long time ago without good usage, now can be used for this purpose.
So please try to see if the |
You're great, @khoih-prog OK, I am following your doc and suggestions. Here is the setup code. I am on an ESP8266 with
Here is the reset call Any thoughts? |
OK now, just change a line of code as this new feature is not in my mind in the original design. Will post to master within 10 mins. |
You are too much! Of course, I will try your updated library immediately. Amazing! Here is how I interpret your parameters
Kindly correct me if I have any (or all!) of these wrong. Thanks again. And please signal me when the update is usable. Of course, I'll try it out. |
New release v.1.1.3 thanks to your contribution Releases v1.1.3
-- Test result OK
|
### Releases v1.2.3 1. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.2.3 1. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.2.1 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.2.1 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.2.1 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Releases v1.1.1 1. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27)
### Major Releases v1.2.0 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 4. Add the new Virtual ConfigPortal SW feature to examples. 5. Disable the GSM/GPRS modem initialization which blocks the operation of Config Portal when using Config Portal.
### Major Releases v1.2.0 1. To permit autoreset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 2. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 3. Add functions to control Config Portal from software or Virtual Switches. Check [How to trigger a Config Portal from code #25](khoih-prog/Blynk_WM#25) 4. Add the new Virtual ConfigPortal SW feature to examples. 5. Disable the GSM/GPRS modem initialization which blocks the operation of Config Portal when using Config Portal.
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
### Major Releases v1.2.0 1. Enable scan of WiFi networks for selection in Configuration Portal. Check [PR for v1.3.0 - Enable scan of WiFi networks #10](khoih-prog/WiFiManager_NINA_Lite#10). Now you can select optional **SCAN_WIFI_NETWORKS**, **MANUAL_SSID_INPUT_ALLOWED** to be able to manually input SSID, not only from a scanned SSID lists and **MAX_SSID_IN_LIST** (from 2-15) 2. Fix invalid "blank" Config Data treated as Valid. 3. Permit optionally inputting one set of WiFi SSID/PWD by using `REQUIRE_ONE_SET_SSID_PW == true` 4. Enforce WiFi PWD minimum length of 8 chars 5. Minor enhancement to not display garbage when data is invalid 6. Fix issue of custom Blynk port (different from 8080 or 9443) not working on ESP32. Check [Custom Blynk port not working for BlynkSimpleEsp32_Async_WM.h #4](khoih-prog/Blynk_Async_WM#4) 7. To permit auto-reset after configurable timeout if DRD/MRD or non-persistent forced-CP. Check [**Good new feature: Blynk.resetAndEnterConfigPortal() Thanks & question #27**](khoih-prog/Blynk_WM#27) 8. Fix rare Config Portal bug not updating Config and dynamic Params data successfully in very noisy or weak WiFi situation 9. Tested with [**Latest ESP32 Core 1.0.6**](https://github.com/espressif/arduino-esp32) for ESP32-based boards. 10. Update examples
Hi @khoih-prog
Nice work adding this feature. I now use it and find it handy. I've set up a (hidden) Blynk button widget that, when pushed, forces the reset and Config Portal. Much appreciated.
Questions you may have already answered.
How do I set the time-out for the Config Portal, whether it was triggered by DRD or by this new feature, so it automatically turns off and reboots the ESP? I am trying to avoid any physical resetting of the device.
I see this code in your doc and examples, not sure how to get it to do what I want it to do.
Kindly explain when you have a moment.
Best wishes. Thanks again.
@thorathome
The text was updated successfully, but these errors were encountered: