Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
RobTillaart committed Jan 6, 2024
1 parent 7541dec commit fcdfb27
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rotaryDecoder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -188,9 +188,9 @@ uint8_t rotaryDecoder::_read8()

bool rotaryDecoder::_write8(uint8_t value)
{
_wire->beginTransmission(address);
_wire->beginTransmission(_address);
_wire->write(value);
return (_wire->endTransmission == 0);
return (_wire->endTransmission() == 0);
}


Expand Down
1 change: 1 addition & 0 deletions rotaryDecoder.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ class rotaryDecoder
int32_t _encoder[4] = { 0, 0, 0, 0 };

uint8_t _read8();
bool _write8(uint8_t value);
uint8_t _address;
TwoWire * _wire;
};
Expand Down

0 comments on commit fcdfb27

Please sign in to comment.