Closed 9a4gl closed 5 years ago
I reverted that patch and everything is working fine. Looks initial problem is fixed and this patch should be reverted.
My tests:
reverting WiFi.scanNetworks();
to WiFi.scanComplete();
it's working fine and asynchronously
but fully reverting the commit, it stuck =/
so keep status != WL_CONNECTED
looks lika a good ideia
What do you think @9a4gl ?
Have you traced where and why it get stuck ? I do not remember I had such issues. Currently in my project I am using more customized version of this libarary. I didn't like after Wifi.begin we have loop waiting to get connected. It bloked my app for few seconds each time it get reconnected. I may try to provide you this fully non-blocking version, but I am afraid it is not oneliner.
Here is small update after some testing. So, my version which do scan (and connect) asynchronously works fine for first scan, it connects and works. But, if it loose network, new scan does not work, actually it finds something on each cca 20th scan, and then it fails to connect to AP. Looks I will not use MultiWifi :(
any update ?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This stale issue has been automatically closed. Thank you for your contributions.
Hardware:
Board: lolin32 lite Core Installation/update date: ? IDE name: Platform.io Flash Frequency: ? Upload Speed: 115200
Description:
In 9dae9cea373abac265f5ed28210bffaee78c92fd run method has been changed to call WiFi.scanNetworks() instead WiFi.scanComplete()
As scanNetwork is called with any parameter it performs synchronous scanning causing program flow to block for few seconds. As this is called when app starts it cause a lot of problem to other initialization flows, like it disrupts serial communication with my Nextion display, causing some bytes to miss on serial interface.