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

Usage of Wire library. #30

Open
Koepel opened this issue Oct 22, 2018 · 1 comment
Open

Usage of Wire library. #30

Koepel opened this issue Oct 22, 2018 · 1 comment

Comments

@Koepel
Copy link

Koepel commented Oct 22, 2018

The usage of the Wire library is wrong in many places.

A delay between Wire.beginTransmission() and Wire.write() is not needed, because they only operate on a buffer (a buffer inside the Wire library).
A delay between Wire.write() and Wire.endTransmission() is also not needed.

A timeout or a delay or waiting after a Wire.requestFrom() is not needed. There is no such thing as a timeout after a Wire.requestFrom(). That has been made up, and copied a lot.

A Wire.requestFrom() should not be followed by a Wire.endTransmission().

The common mistakes are: Common-mistakes
I wrote also an alternative explanation of the functions of the Wire library.

@seanshahkarami
Copy link
Member

seanshahkarami commented Oct 24, 2018

I'm in the process of updating a large part of the existing device firmware, so I'll review the notes you've linked to. I think I've learned a bit more about the library over time and am interested in what's there.

Thanks a lot for this! 😄

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