Simplified Initial WiFi Configuration #11693
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description:
In this PR, it is proposed a New Initial WiFi Configuration Menu and procedure.
In order to simplify the on-boarding to Tasmota, the first configuration step has been modified.
When powered up a blank device ( without any WiFi SSID stored in the firmware ), you will see in your Phone or PC a new WiFi Network named like tasmota_XXXXXX.
If you connect to it, you will see:
Clicking on any WiFi Network's name, that will be copied to the field called WiFi Network. And then, after you have completed the password, you will see:
Clicking on save, you will see the Testing Screen:
If the WiFi Credentials are wrong, few seconds later you will see:
If trying again but with correct password:
And if all WiFi Credentials are Ok, few seconds later you will see:
At this stage, Tasmota will turn off its own AP mode (its own WiFi Network will disappear) and your PC or Phone will automatically reconnect to its previous WiFi Network. If you wait few more seconds, the webpage will be redirected to the new IP of Tasmota in the Network it just connected and you will see the main page of Tasmota. So, you can continue using Tasmota in the same window, without the need of searching for your device in the Network:
OPTIONALS
If you do not want this redirecting feature, just define the following in your user_config_override.h:
And After the successful connection, you will see:
On the first page, if clicking on SCAN FOR ALL WiFi NETWORKS, you will see the complete list of Networks Tasmota is reaching.
On the first page, if clicking on MORE OPTIONS, you will see the extra options:
The old WiFi Configuration Page that has the Alternative SSId, CORS and Hostname, is available AFTER the initial configuration has finished and from the main menu of Tasmota.
The RESTART_AFTER_INITIAL_WIFI_CONFIG option is enabled by Default. If you define it as false in user_config_override.h file, Tasmota won´t restart and will remain in both modes AP and STA, so it will stay connected to the WiFi Network and also it will be providing the AP until next restart. You can reach Tasmota from both Networks.
This allows the user to continue the configuration.
In this mode, Tasmota shows the IP in both Networks the same as
SO53 1
If after a successful WiFi configuration, the user wants to enter again in the AP mode by pressing button1 6 times or by
wificonfig 2
command, the user will see the normal version of the wifimanager:List of modifications
On Initial AP Mode (Blank Device):
On AP Mode (Not a Blank Device):
SO53 1
)On all WiFi Configuration menus:
Tested on ESP8266 and ESP32. In both chips, it works as expected.
Tested on FIRMWARE-MINIMAL. The behaviour of that version is not modified and working as expected.
Tested on manual WIFIMANAGER mode after SSId Configured.
This PR adds 3KB of flash usage.
Related issue (if applicable): NA
Checklist:
NOTE: The code change must pass CI tests. Your PR cannot be merged unless tests pass