microsoft / devkit-sdk

Arduino library and package for the MXChip IoT DevKit
https://aka.ms/devkit
MIT License
69 stars 52 forks source link

fix compile error in wire.h #918

Closed douglas-johnston closed 5 years ago

douglas-johnston commented 6 years ago

Adding a missing method description to Wire.h allows it to be included in sketches without preventing compilation.

msftclas commented 6 years ago

CLA assistant check
All CLA requirements met.

douglas-johnston commented 6 years ago

Added a second commit which allows for reading from I2C devices. With just the original commit, wire can compile but will ignore all messages from attached I2C devices.

douglas-johnston commented 6 years ago

added a third commit which re-establishes error checking in Wire.cpp requestFrom(). If the read(...) function from DevI2C.h returns -1 as an error , then requestFrom(...) will avoid reading. Otherwise, it will read in values from the I2C bus.

ArthurMa1978 commented 5 years ago

Thanks for your contributions.