-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Testing connection to new AP gives up easily #102
Comments
I've noticed the connection error is always that the wifi is idle? *WM: Sent wifi save page |
hi, have you got the flash size under tools set to the same size your esp module has? i have seen this happen at times with the wrong flash size set, also some weird combination of delays in the sketch cause it not to connect and fail immediately with 0 unfortunatelly this is quite random, i can t replicate it |
i can t try to connect harder or longer, the library is using the exact same functions you and everyone else is using to connect, but due to mode switching from AP to STA weirdness like this seems to happen |
My details on the info page are: Flash Chip ID And I'm using "4M (1M SPIFFS)" Is it possible to get it to try connecting a few times? |
hi, if you can you should update to the latest github version of the library and check the new info page, there s an ide flash size and a chip flash size that should be equal i have also added a new option to WiFiManger to set a connect timeout. |
Thanks for making the changes. I've updated to the latest git version. Info page tells me:
I added the 30 second timeout for trying to connect, I had it connect 1 out of 10 tries. Also tried setting the timeout to 60. Timed the wait and its waiting the amount of time I set t to. I once also had it return connection result 4, but other than that the failures were all 0.
|
that s a pitty... |
if you don t use WiFiManager, in a test sketch, does everything work ok? Does your module see and connect ok to the router causing you issues? |
Given the basic WifiClient esp8266 sketch another try, connected fine first time each try, swapped back to wifimanager and had the same issue as before. (same esp8266 module, same wifi ap its trying to connect to) |
ok, thanks for letting me know. given that i only use the standard functions, i ll think what the differences are (of calling order, as that s the only thing) and try to build a sample sketch we can use to debug and send to esp8266 core so they can research the possible bug there. will you be able to test stuff? |
More than happy to. :) |
hi, sorry for the delay could you give this a spin? it basically tries to duplicate as much as possible from the WiFiManager flow, without all the nice things, to see if we can find where the issue lies... |
I've tested that script 10 times, all 10 it worked correctly and connected fine showing the following serial output: I checked as well and I could see it broadcasting correctly as an AP during the process as well.
|
i ve added a new fix to WiFiManager that tries to avoid a race condition that i found. i don t think it might be useful in your case, but worth a try nontheless... |
hi, i ve just made another commit to this, could you please try the github version of WiFiManager and see if anything changed for you? |
Apologies for the delay. I've just done a git pull and tested it with my module. It now works perfectly with the examples in the library. I've tried it 10 times with 2 different AP's that the esp is trying to connect to (that it was failing on before) and it connected first time everytime. Thanks so much for fixing it, Charles |
that is wonderful news |
With the latest commit the ability to make a connection has been greatly improved. Thanks for solving this bug, |
good to know, thank you. i ll probably release it soon then cheers |
I'm trying to connect to my tp-link tl-wr702n router through wifimanager.
Currently when it tries to connect it will fail out very quickly and not connect, where as it will connect fine to my wifi router in the other room fine.
I've been running my project fine with this module and wifi ap just calling wifi connect normally so I wonder if wifimanager is just timing out trying to connect really quickly, or needs to try multiple times?
I can't currently see any settings to tell it how hard to try to connect to a new network.
The text was updated successfully, but these errors were encountered: