Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 5295a5f

Browse files
committed
Modulino: avoid calling read() and write() and address >= 0x7F
1 parent b89cb1f commit 5295a5f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎src/Modulino.h‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ class Module : public Printable {
5151
return Modulino._wire;
5252
}
5353
bool read(uint8_t* buf, int howmany) {
54-
if (address == 0xFF) {
54+
if (address >= 0x7F) {
5555
return false;
5656
}
5757
Modulino._wire->requestFrom(address, howmany + 1);
@@ -72,7 +72,7 @@ class Module : public Printable {
7272
return true;
7373
}
7474
bool write(uint8_t* buf, int howmany) {
75-
if (address == 0xFF) {
75+
if (address >= 0x7F) {
7676
return false;
7777
}
7878
Modulino._wire->beginTransmission(address);

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /