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

writeto_mem() wants a buffer #1

Closed
gkluoe opened this issue Apr 19, 2018 · 2 comments
Closed

writeto_mem() wants a buffer #1

gkluoe opened this issue Apr 19, 2018 · 2 comments

Comments

@gkluoe
Copy link
Owner

gkluoe commented Apr 19, 2018

As per pimoroni/bme680-python#7, we should make sure that we're passing as data an object which supports the buffer protocol to writeto_mem(), or it fails on at least some architectures.

@gkluoe
Copy link
Owner Author

gkluoe commented Apr 19, 2018

Yup, the error was coming from here:

https://github.com/micropython/micropython/blob/a3dc1b1957d2c96d7c60c2c629c95077b03488a1/py/obj.c#L524

I don't know how we were ever getting away with passing it an int but this has been working fine on a LoPy.

@gkluoe
Copy link
Owner Author

gkluoe commented Apr 20, 2018

Fixed in 539d595

@gkluoe gkluoe closed this as completed Apr 20, 2018
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

1 participant