8 years, 5 months ago.

"wifi.connect" hang up

By problems such as access point, in a case where the connection destination is no longer, and repeat the initialization of the following, you can hang up in the "wifi.connect" several times. Will there countermeasures like? Nice to meet you. Matsuda

--------------- Wifi Connect --------------- int Wifi_Connect() { int ret = 0;

Initialize Wi-Fi interface ret = wifi.init(); if(ret != 0){ printf("Wi-Fi initial failed %d\r\n", ret); return ret; } wait(0.5);

ret = wifi.disconnect(); if(ret != 0) { printf("on the disconnect state %d\r\n", ret); return ret; } wait(0.3);

ret = wifi.connect( WifiSet.Wifi_SSID, strlen(WifiSet.Wifi_SSID) , SecuriryType , WifiSet.Wifi_SECURITY_KEY, strlen(WifiSet.Wifi_SECURITY_KEY) ); if(ret != 0) { printf("Connect AP is failed %d\r\n", ret); return ret; } wait(0.5);

DHCP IP GET int retIp = wifi.setIPConfig(true); wait(0.5); printf("IP Address Get!!! %d\n", retIp);

return(true); }

Question relating to:

Murata TypeYD - NTPClient example.
Be the first to answer this question.

Assigned to Yoshimi Matsuda 8 years, 5 months ago.

This means that the question has been accepted and is being worked on.