reference-en
reference-en copied to clipboard
[Documentation] Wire read return type
Returns The next byte received
It should be:
Returns The next byte received (or -1 if no data is available). Data type: int.
Is that always meant to be the case? In the Mbed core it looks like it returns 0:
https://github.com/arduino/ArduinoCore-mbed/blob/949c70ce6ae7d2910e5768d6d88fc3ae0e943584/libraries/Wire/Wire.cpp#L123
Edit: It is meant to be -1, the Mbed core will be updated.