-
-
Notifications
You must be signed in to change notification settings - Fork 7k
Official EthernetClient Sample Not Compiling - Ambiguous overload error with latest Arduino 1.0.6 #2611
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
Comments
Hi, the code is wrong. We'll fix it asap. Correct syntax is |
I think might be better fix in library code if possible than update documentation... Several printed media is currently showing the way it worked in 1.0.5 eg. page 163 of this book. And this book (Non-English language) And there are a lot of apps and code samples using the old way - this search shows it will break a lot out there unnecessarily. |
You're right. I've proposed a change in #2618. Please leave your comment |
Please try one of the IDEs at #2618 (comment) |
@OzmoOzmo corrected in the reference. Can i close this issue? |
Thanks very much - that does indeed sort that problem. Sorry not getting back to you sooner - but I was trying to get the whole
But thanks for getting EtherClient working anyway :) On Fri, Feb 20, 2015 at 12:10 PM, Arturo Guadalupi <[email protected]
|
The code sample below - the official Arduino sample code.
will not compile:
My public code libraries use the EthernetClient library like this - and same method I used is mentioned in several books and several ethernet sources - but it will not compile anymore on 1.0.6
(I have tried official 1.0.6 and the nightly build ARDUINO 1.6.0rc3 - 2015.02.03)
The problem is EthernetClient cannot be tested for true/false anymore (it used to have a overloading that allowed you to query it being ready by using boolean comparitor).
The sample code has not worked since 1.0.5
Official Sample Code:
EthernetClient client = server.available();
if (client == true) { //compiler error here
}
What is the correct new way to do this test now - and will the documentation be changed or the IDE/Compiler be changed back (best option)?
Thanks very much.
The text was updated successfully, but these errors were encountered: