kingmathers313 / FHEM_Arduino

A library for arduino to communicate with a FHEM Server
MIT License
2 stars 1 forks source link

obsolete api call for client.begin #1

Open doabigcheese opened 3 years ago

doabigcheese commented 3 years ago

C:\Users\user\Documents\Arduino\libraries\FHEM\src\FHEM.cpp: In member function 'void FHEM::PrepareClient(String)': C:\Users\user\Documents\Arduino\libraries\FHEM\src\FHEM.cpp:83:14: error: call to 'HTTPClient::begin' declared with attribute error: obsolete API, use ::begin(WiFiClient, url) 83 | client.begin(URL); | ~~^~~ exit status 1

localy fixed with: on top add:

include

WiFiClient wifiClient;

line 110: client.begin(wifiClient,URL);

CharleHei commented 1 year ago

exit status 1

Compilation error: call to 'HTTPClient::begin' declared with attribute error: obsolete API, use ::begin(WiFiClient, url)

tutulportal commented 1 year ago

I have fixed my code by using this: //add this to top

include

WiFiClient wifiClient;

//where find the error their: http.begin(wifiClient, url);

Thanks to @doabigcheese for sharing 👍