Skip to content

i2c_device: remove write(stop=), write_then_readinto(stop=) #55

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

Merged
merged 1 commit into from
Jul 26, 2020

Conversation

jepler
Copy link
Contributor

@jepler jepler commented Jul 26, 2020

Any code that uses the stop= kwarg will get an exception at runtime. This is the incomptaible alternative compared to #54.

CircuitPython 5.x and 6.x both have writeto_then_readfrom, as does Blinka. However, this is incompatible with CircuitPython 4. We have previously dropped building the 4.x bundle so this should be OK.

The changes ended up being a bit more extensive. Testing performed was creating the accelerometer object on an adafruit clue:

>>> a = adafruit_lsm6ds.LSM6DS33(board.I2C())
>>> a.acceleration
(-1.04566, -0.34337, -9.60359)

Any code that uses the stop= kwarg will get an exception at runtime.

CircuitPython 5.x and 6.x both have writeto_then_readfrom, as does
Blinka.  However, this is incompatible with CircuitPython 4.
We have previously dropped building the 4.x bundle so this should be
OK.
@jerryneedell
Copy link

repeated my tests from #54 on this PR -- they also work fine.

Copy link
Contributor

@dhalbert dhalbert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I'll accept this one based on my #54 comments. I'll merge it now so we can get something into the bundle right away.

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

Successfully merging this pull request may close these issues.

3 participants