[Fixed] ESP32 compile error: no matching function for call to 'WiFiClass::begin(String&, String&)' #22
EmbeddedDevver
started this conversation in
General
Replies: 1 comment
-
Hello, you might want to look a bit more and you'll discover that Arduino also provides API for wl_status_t begin(const String& ssid, const String& passphrase = (const char*)NULL, int32_t channel = 0, const uint8_t* bssid = NULL, bool connect = true) {
return begin(ssid.c_str(), passphrase.c_str(), channel, bssid, connect);
} But I added you config to the build: CI job passed: https://github.com/mathieucarbou/MycilaESPConnect/actions/runs/9766416658/job/26959326144 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Compilation for ESP32 gives the error
no matching function for call to 'WiFiClass::begin(String&, String&)'
Looking up I see this
WiFi.begin(_config.wifiSSID, _config.wifiPassword);
if I change to
WiFi.begin(_config.wifiSSID.c_str(), _config.wifiPassword.c_str());
Everything runs fine. The WiFi.begin does not accept String only c_str();
Do I use the wrong WiFi begin lib? Or is this an issue with the code :-)
My settings:
Beta Was this translation helpful? Give feedback.
All reactions