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

example change about i2c-bus-promises #3

Open
LocalNic opened this issue Aug 16, 2021 · 1 comment
Open

example change about i2c-bus-promises #3

LocalNic opened this issue Aug 16, 2021 · 1 comment

Comments

@LocalNic
Copy link

Hi, can you please update your examples ?

const i2c = require('i2c-bus-promise')
to
const i2c = require('i2c-bus')

and

i2c.open(1).then(async (bus) => {
to
i2c.openPromisified(1).then(async (bus) => {

because since i2c-bus 5.0.0 or newer the "promises" is pat of the API

@ChocolateLoverRaj
Copy link

Instead of writing the changes in an issue u can just make a PR, then @williamkapke can simply merge it.

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