Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No need to wait after Wire.requestFrom() and it should not be followed by Wire.endTransmission(). #1

Closed
Koepel opened this issue Apr 27, 2019 · 4 comments

Comments

@Koepel
Copy link

Koepel commented Apr 27, 2019

The usage of the Wire library is not okay in these files:

  • boat-systems/hardware/compassAndRudderInterface/firmware/autopilot/libraries/LIS3MDL/LIS3MDL.cpp
  • boat-systems/hardware/compassAndRudderInterface/firmware/autopilot/libraries/LSM6/LSM6.cpp
  • boat-systems/hardware/compassAndRudderInterface/firmware/autopilot/libraries/L3G/L3G.cpp
  • boat-systems/hardware/compassAndRudderInterface/firmware/autopilot/libraries/LSM303/LSM303.cpp

There is no such thing as a timeout after a Wire.requestFrom().
The Wire.requestFrom() should not be followed by Wire.endTransmission.
Explanation: Common-mistakes, number 1 and 2.
See also my alternative explanation of the functions of the Wire library.

@scottburch
Copy link
Owner

Thanks for the comment. Those are not my libraries, but I will check if there are newer versions.

@scottburch
Copy link
Owner

Closing

@Koepel
Copy link
Author

Koepel commented Apr 27, 2019

Is Pololu the original author of the code? I wanted to create a issue over there, but I already did: pololu/zumo-shield-arduino-library#1

@scottburch
Copy link
Owner

scottburch commented Apr 27, 2019

@Koepel I don't remember where I got those files from. It has been a couple of years. But, it probably was them. Thanks again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants