Chat freely about anything...

User avatar
By alonewolfx2
#6663
Athena wrote:
Baoshi wrote:
Athena wrote:@Baoshi ,could you show me some error logs ? And your account of Espressif BBS has been actived ;)


Many thanks Athena.

The following is the dump from UART0. I also attach my testing code, basically same as the rtos sdk sample without the client part.

Code: Select all[00]
 ets Jan  8 2013,rst cause:1, boot mode:(3,7)

load 0x40100000, len 28956, room 16
tail 12
chksum 0x8b
ho 0 tail 12 room 4
load 0x3ffe8000, len 1968, room 12
tail 4
chksum 0x05
load 0x3ffe87b0, len 6716, room 4
tail 8
chksum 0xc2
csum 0xc2
pp_task_hdl : 3fff1c68, prio:20, stack:512
ApiMsgMutex created
idle_task_hdl : 3fff42a8
tim_task_hdl : 3fff4500
xPortStartScheduler

OS SDK ver: 0.0.5 compiled @ Jan  4 2015 13:52:04
phy ver: 273, pp ver: 6

SDK version:0.0.5
mode : sta(18:fe:34:9c:d2:ba)
add if0
S > create socket: 0
S > bind port: 80
S > listen ok
S > wait client
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1
rm match
reconnect
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1
-----------------------------< 5 minutes later
rm match
reconnect
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1
-----------------------------< 5 minutes later
rm match
reconnect
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1
-----------------------------< 5 minutes later
rm match
reconnect
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1
-----------------------------< 5 minutes later
rm match
reconnect
b    << strange 'b' here
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1
-----------------------------< 5 minutes later
rm match
reconnect
scandone
add 0
aid 4
aid end
cnt

connected with OOOO, channel 1
dhcp client start...
ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1


@Baoshi , it seems that your disconnection to router is because that you do nothing since connected to router...
Please try to ping ESP8266 from PC, and see if it still disconnect from router.. PC -> Router -> ESP8266 , try ping

Hi Athena, the problem is dhcp lease time on the esp8266.
User avatar
By Athena
#7161 Hi,@alonewolfx2, only when “connected with OOOO, channel 1” this log shows, means the wifi connection broken, and try to connect again..


ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1

This three logs alone,only means to get ip from router,nothing wrong。。 especially when dhcp lease timeout is coming,it will get ip from router..
User avatar
By Baoshi
#7244
Athena wrote:Hi,@alonewolfx2, only when “connected with OOOO, channel 1” this log shows, means the wifi connection broken, and try to connect again..


ip:192.168.0.157
mask:255.255.255.0
gw:192.168.0.1

This three logs alone,only means to get ip from router,nothing wrong。。 especially when dhcp lease timeout is coming,it will get ip from router..



Hi Athena,
I guess there is something wrong with dhcp lease timing. My router lease period is 24 hours, but esp8266 is renewing ip address every 5 minutes. And the 5 minutes is so accurate that I do not believe it is some random connection drop thing.

I will redo some test and report more figure to you.
User avatar
By PuceBaboon
#7245
Baoshi wrote:I guess there is something wrong with dhcp lease timing. My router lease period is 24 hours, but esp8266 is renewing ip address every 5 minutes. And the 5 minutes is so accurate that I do not believe it is some random connection drop thing.


Baoshi,

Check your Access Point set-up for mDNS (multicast DNS) settings, too. Both wired and wireless clients would lose
ARP cache settings for my ESP8266 after it reconnected with the AP (even though the ESP8266 got it's DHCP lease
again without a problem). Despite the fact that ARP is broadcast (not multicast) the main problem turned out to be
the AP blocking multicast packets. Disabling that multicast block (along with an update to SDK 0.9.5_b1) seems to
have solved the problem for me.

Just for reference, the AP is a Fonera 2100 running DD-WRT v24-sp2 (10/10/09) std - build 13064.

-John-