ESP8266 Developer Zone The Official ESP8266 Forum 2015-04-30T15:26:03+08:00 https://bbs.espressif.com:443/feed.php?f=7&t=424 2015-04-30T15:26:03+08:00 2015-04-30T15:26:03+08:00 https://bbs.espressif.com:443/viewtopic.php?t=424&p=1597#p1597 <![CDATA[Re: esp8266 DNS failed]]>
Here is an example of DNS function http://bbs.espressif.com/viewtopic.php?f=21&t=232

Please have a try , if it still has your problem, please offer your test code and we will help debugging it.

Thanks for your interest in ESP8266 !

Statistics: Posted by ESP_Faye — Thu Apr 30, 2015 3:26 pm


]]>
2015-04-30T13:37:40+08:00 2015-04-30T13:37:40+08:00 https://bbs.espressif.com:443/viewtopic.php?t=424&p=1596#p1596 <![CDATA[esp8266 DNS failed]]> 1.disconnect router with internet
2.power up esp8266. firstly, it is gonna connect with router and then gets ip assigned by router, secondly esp8266 runs DNS request routine which is of course get failed
for the sake of router's disconnecting with internet .
3. reconnect router to internet , esp8266 still runs the routine of DNS requests again and again and prints logs as follows
user_esp_platform_dns_check_cb
get hosted name state = -5
user_esp_platform_dns_found NULL
user_esp_platform_dns_check_cb
get hosted name state = -5
user_esp_platform_dns_found NULL
user_esp_platform_dns_check_cb
get hosted name state = -5
user_esp_platform_dns_found NULL
user_esp_platform_dns_check_cb
get hosted name state = -5
user_esp_platform_dns_check_cb
get hosted name state = -1
user_esp_platform_dns_check_cb
get hosted name state = -1
user_esp_platform_dns_check_cb
get hosted name state = -1

get hosted name state = -1 means the return error code when get_hosted_name recalled
error code:
-1 = ESPCONN_MEM
-5 =ESPCONN_INPROGRESS
only when esp8066 get restarted can it request DNS successfully

Statistics: Posted by mikewang — Thu Apr 30, 2015 1:37 pm


]]>