Open kajnorman opened 1 year ago
Ahh! I see. It is not an error.. not even a minor error ;-) .
Hi @kajnorman. Thanks for your report. Even though the code is valid, I still think this should be considered a bug so I will reopen it.
Unused code is always a bug and in this case it is especially harmful because the user will be led to believe they can set the password via the pass
variable, when that variable is actually not serving any purpose at all.
So the resolution should be either:
pass
variable declaration.pass
variable to the WiFi.begin
call.A pull request for either of those fixes would be welcome.
Thx per1234
I totally agree with you.
Thx for the nice library
And thx for fixin the “issue”
https://github.com/arduino-libraries/WiFi/blob/e9a39701a6b1b82a466f4e6e909a67b526e9e63c/examples/WiFiUdpSendReceiveString/WiFiUdpSendReceiveString.ino#L56
should be:
Although the code is valid for an open access point, the presence of this line in the sketch clearly indicates the sketch was intended for use with a WPA encrypted access point:
https://github.com/arduino-libraries/WiFi/blob/e9a39701a6b1b82a466f4e6e909a67b526e9e63c/examples/WiFiUdpSendReceiveString/WiFiUdpSendReceiveString.ino#L22
The user will be confused to find the board is unable to connect to the access point even though they set the correct password.