Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By daveb1014
#52449 No; WiFi.begin() is the only method I use for init?

I have noticed that when it doesn't connect, it seems to put itself in access point mode (in fact, it seems to have a 5GHz access point running all the time - it apparently has dual radios) and broadcasts an SSID like ESP_88EDABC

Is that normal? Is there more init that needs to be done?
User avatar
By schufti
#52453 Hi,
that's the way I use it and up to now never had a reconnection problem..
Code: Select all 
//WIFI credentials go here
IPAddress ip(192, 168, 22, 1);   
IPAddress gw(192, 168, 22, 123);
IPAddress nm(255, 255, 255, 0);

const char* ssid     = "YOUR_SSID";
const char* password = "your_pwd";
const char* server = "184.106.153.149";
WiFiClient client;
...
  WiFi.mode(WIFI_STA);
  WiFi.config(ip, gw, nm, gw, gw);
  WiFi.begin(ssid, password);
User avatar
By daveb1014
#52454 Thanks, I haven't used the config() or mode() methods before. I have added a .mode(WIFI_STA) before my wifi.begin() for good measure; I have also added .persistent(false) before wifi.begin, so now my code is:

Code: Select allWiFi.mode(WIFI_STA);// set station/client mode
WiFi.persistent(false);
WiFi.begin((char*)SSID.c_str(), (char*)PSK.c_str());


Will let you know if it works :)