Skip to content

Commit

Permalink
Fix #56, Correcting the problem that
Browse files Browse the repository at this point in the history
TwoWire::requestFrom() return value always zero
  • Loading branch information
soburi committed Sep 19, 2017
1 parent ace1f6b commit 6d657f7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libraries/Wire/Wire.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ uint8_t TwoWire::requestFrom(uint8_t address, size_t quantity, bool stopBit)
if(i2c->start(i2c->devinfo, address, WIRE_READ_FLAG))
{

i2c->read_bytes(i2c->devinfo, rxBuffer._aucBuffer, quantity);
byteRead = i2c->read_bytes(i2c->devinfo, rxBuffer._aucBuffer, quantity);
rxBuffer._iHead = quantity;

if (stopBit)
Expand Down

0 comments on commit 6d657f7

Please sign in to comment.