jamesbowman / i2cdriver

I2CDriver open source tools
https://i2cdriver.com/
BSD 3-Clause "New" or "Revised" License
184 stars 57 forks source link

Inaccurate data read in capture mode #33

Open codehero opened 4 years ago

codehero commented 4 years ago

I am reading the following data between a Pi and a microcontroller at address 0x31 TX -> 01 RX <- 0d 76 09 01 00 01 01 01 02 00 32 00 00

I shown capture output for 2 identical runs. The Pi is correctly reading data over i2c. The i2cdriver LCD display also shows correct data. The capture mode shows correct data for the first run but not the second.

<START 0x31 WRITE ACK> <WRITE 0x01 ACK> <START 0x31 READ ACK> <READ 0x0d ACK> <READ 0x76 ACK> <READ 0x09 ACK> <READ 0x01 ACK> <READ 0x00 ACK> <READ 0x01 ACK> <READ 0x01 ACK> <READ 0x01 ACK> <READ 0x02 ACK> <READ 0x00 ACK> <READ 0x32 ACK> <READ 0x00 ACK> <READ 0x00 ACK> <READ 0x10 NACK>

![image](https://user-images.githubusercontent.com/194165/72831212-62bfab00-3c50-11ea-943d-4c4168a4dcda.png)
jamesbowman commented 4 years ago

Is the PI driving I2C at 100 or 400 KHz? If it is 400, might be worth trying at 100.

codehero commented 4 years ago

The SCL runs at max 25 KHz.