Can I use STA and AP at the same time ?
Posted: Mon Oct 28, 2019 10:57 am
Hello !
TL;DR: How can I have AP and STA at the same time, configuring SSID, Password and/or IP Address, Gateway, SubnetMask, DNS while also serving pages using ESPAsyncWebServer to the user giving it the possibility of configuring the previously mentioned parameters and much more.
Right now, my code is separated into two blocks: AP and STA.
While in AP, I give the end-user the possibility of configuring SSID, Password and/or IP Address, Gateway, SubnetMask, DNS.
After the values were entered and saved, the ESP restarts and tries a WiFi.begin(SSID, Password); followed by WiFi.config();
And in STA I have the "functional" code, depending on the project at hand.
I would like to eliminate the ESP.restart() that separates the two WiFi modes and the transition time from one mode to the other. I would like to offer the user a smooth experience while setting up the ESP32.
TL;DR: How can I have AP and STA at the same time, configuring SSID, Password and/or IP Address, Gateway, SubnetMask, DNS while also serving pages using ESPAsyncWebServer to the user giving it the possibility of configuring the previously mentioned parameters and much more.
Right now, my code is separated into two blocks: AP and STA.
While in AP, I give the end-user the possibility of configuring SSID, Password and/or IP Address, Gateway, SubnetMask, DNS.
After the values were entered and saved, the ESP restarts and tries a WiFi.begin(SSID, Password); followed by WiFi.config();
And in STA I have the "functional" code, depending on the project at hand.
I would like to eliminate the ESP.restart() that separates the two WiFi modes and the transition time from one mode to the other. I would like to offer the user a smooth experience while setting up the ESP32.