ESP8266 Developer Zone The Official ESP8266 Forum 2017-03-24T13:39:17+08:00 https://bbs.espressif.com:443/feed.php?f=7&t=3253 2017-03-24T13:39:17+08:00 2017-03-24T13:39:17+08:00 https://bbs.espressif.com:443/viewtopic.php?t=3253&p=11557#p11557 <![CDATA[Re: High variance in wifi reconnects]]>
Can wifi_set_event_handler_cb help you? Event EVENT_STAMODE_GOT_IP means that ESP8266 station connects to the router successfully.

Thanks for your interest in ESP8266!

Statistics: Posted by ESP_Faye — Fri Mar 24, 2017 1:39 pm


]]>
2017-01-11T04:48:04+08:00 2017-01-11T04:48:04+08:00 https://bbs.espressif.com:443/viewtopic.php?t=3253&p=11083#p11083 <![CDATA[High variance in wifi reconnects]]>
I'm noticing a very high variance for the time it needs to reconnect to a known network. It is sometimes done in 3 secs, but it can also take 15 secs, 30 secs or 9 secs, completely unpredictable.

What I'm doing in a loop is:

1) Scan and upload
2) Go to forced MODEM_SLEEP for around 30 secs
3) Wake up and restart from 1)

The transmission is always done within several milliseconds, but the reconnect to the wifi network is what concerns me, because it makes the entire cycle completely unpredictable.

While watching the output of Serial.setDebugOutput(true) I see endless sequences like this, which repeat in a second interval:


f r0, scandone
state: 0 -> 2 (b0)
state: 2 -> 3 (0)
state: 3 -> 0 (29)
reconnect
f 0, scandone
state: 0 -> 2 (b0)
state: 2 -> 3 (0)
state: 3 -> 0 (29)


What does state: 3 -> 0 (29) mean? It seems to be a fallback to DISCONNECTED, but what means 29?

What can I do against this?

Statistics: Posted by neilyoung — Wed Jan 11, 2017 4:48 am


]]>