-
Notifications
You must be signed in to change notification settings - Fork 68
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
about read_block_data(i2c_addr, register, force=None) #58
Comments
Afraid I can't help you much in your quest. I have no Arduino experience myself. While looking for the answer, you might wanna check two things:
import smbus2
# Assuming you already have opened the `bus`
rbd_supported = bus.funcs & smbus2.I2cFunc.SMBUS_READ_DATA > 0
print(rdb_supported) If you don't see
|
I am having a problem with read_block_data too. I tried this but SMBUS_READ_DATA appears not to be an attribute of smbus2.I2cfunc:
For me the issue with read block data is it is returning the correct number of bytes however they are all zeros, which should not be the case |
Sorry. Was a typo in my previous comment. Should have been import smbus2
# Assuming you already have opened the `bus`
rbd_supported = bus.funcs & smbus2.I2cFunc.SMBUS_READ_BLOCK_DATA > 0
print(rdb_supported) RPi's normally don't support |
thanks, yeah it returns |
I use i2c to connect rpi and arduino . I check the data i sent to arduino in Serial Monitor if i sent a array by write_block_data() function , arduino receive start register + length + array .
I want to know how to use read_block_data() to read the data returned by arduino .
I tried these days , rpi always receive a empty list and arduino Wire.write() only send back a byte data how can i combine these two function together.
The text was updated successfully, but these errors were encountered: