profile
viewpoint

Ask questionsAfter 1.0.6 update WiFi won't connect to other network // connection time increased

Hello.

Using ESP32 with arduino.

Below snippet was working ok on all previous versions. I updated today to 1.0.6 and now it won't connect to my home network, always creates Access Point instead.

WiFi.begin(wifiSSID.c_str(), wifiPSWD.c_str());
	while(WiFi.status() != WL_CONNECTED) {
		if(millis() - startTime > 2000) break;	
		delay(100);
		tft.drawCentreString(CONNECTING_WIFI, OFFSET_WIDTH, OFFSET_HEIGHT+WIFI_OFFSET_HEIGHT, 1);
	}
	if(WiFi.status() != WL_CONNECTED) {
		WiFi.disconnect(true);
		WiFi.mode(WIFI_AP);
		delay(100);
//		WiFi.softAPConfig(local_ip, gateway, subnet);
		WiFi.softAP(wifiSSID.c_str(), wifiPSWD.c_str());
		delay(500);
		IPAddress IP = WiFi.softAPIP();
		tft.setCursor(10, 230);
		tft.println(IP);
		wifiOn = false;
	} else {
		wifiOn = true;
		tft.setCursor(10, 230);
		tft.println(WiFi.localIP());
	}

Reverted back to 1.0.5 and 1.0.6, power cycled device many times and nothing helps. Once I use 1.0.5 everything works as it should.

espressif/arduino-esp32

Answer questions ThomasWaldmann

If nobody fixed this, there is no reason for a stupid stale bot closing this.

useful!
source:https://uonfu.com/
answerer
TW ThomasWaldmann Earth, Solar System, Local Interstellar Cloud, Local Bubble, Orion–Cygnus Arm, Milky Way
Github User Rank List