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

Wire.endTransmission after Wire.requestFrom is not okay. #17

Closed
Koepel opened this issue Aug 22, 2015 · 2 comments
Closed

Wire.endTransmission after Wire.requestFrom is not okay. #17

Koepel opened this issue Aug 22, 2015 · 2 comments

Comments

@Koepel
Copy link

Koepel commented Aug 22, 2015

In two places there is a Wire.endTransmission after a Wire.requestFrom.
The Wire.requestFrom is a complete I2C transmission on its own, it should not be followed by a Wire.endTransmission.
The Wire.endTransmission transmits the bytes in the buffer that are written with Wire.write and waits until the I2C transmission (to write date) has finished.

@nkolban
Copy link

nkolban commented Dec 25, 2015

Worse ... I seem to see a Wire.beginTransmission() which starts a write immediately followed by a Wire.requestFrom() ... which is used to read from the bus ... something smells awfully fishy here.

@ladyada
Copy link
Member

ladyada commented Dec 21, 2020

resolved, using BusIO

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

3 participants