Skip to content

Regression: WiFi.begin is never gets connected #2193

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
di9it opened this issue Jun 26, 2016 · 3 comments
Closed

Regression: WiFi.begin is never gets connected #2193

di9it opened this issue Jun 26, 2016 · 3 comments

Comments

@di9it
Copy link

di9it commented Jun 26, 2016

Basic Infos

WiFi.begin related code is working fine on 2.2 but doesn't work on 2.3. Regression?
See example below

Hardware

Hardware: ESP-01
Core Version: 2.2.0

Description

l.d(String("Setting SSID as "") + ssid + "" and PWD as " + secrethidden);
WiFi.softAPdisconnect(true);
delay(100);
WiFi.begin(ssid, secret);

int attempts = 0;
int waitconnect = 1000;
while (WiFi.status() != WL_CONNECTED) {
l.i(String("WiFi.status is ") + WiFi.status() + "...");
delay(waitconnect);
if (attempts++ * waitconnect == 8000 ) { // 8 seconds
break;
}
}

if (WiFi.status() != WL_CONNECTED) {
l.e(String("Cannot connect to specified WiFi, status is ") + WiFi.status());
return false;
}

Settings in IDE

Module: Generic ESP8266 Module
Flash Size: 4MB/1MB
CPU Frequency: 80Mhz
Flash Mode: qio
Flash Frequency: 40Mhz
Upload Using: SERIAL

@igrr
Copy link
Member

igrr commented Jun 26, 2016

Possible duplicate of #2186?
Please check if the workaround in #2186 (comment) helps.

@igrr
Copy link
Member

igrr commented Jul 4, 2016

No response, closing.

@igrr igrr closed this as completed Jul 4, 2016
@ThermalEnergy
Copy link

In order to connect to Wifi from ESP32 and other boards, the WiFi connection needs to be 2.4GHz, wireless mode must be legacy. It cannot be set to Auto or N only. Go to your router box web page, and change this setting under Advanced Settings > Wireless.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants