Failed connection Raspberry Pi with pico through I2C, error occured when send more then one byte data by wire.write() #222
-
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
Do you need to add terminating (pull-up) resistors, for the i2c bus? Could it just be signal degradation? |
Beta Was this translation helpful? Give feedback.
-
Good description. I have an idea what's going on, but need to wire up some stuff to test the theory out. (Since there are 2 cores and 2 I2C peripherals, I can do your test on the Pico itself). I believe the issue is that in slave mode you've sent a 5x1-byte writew down but the RPI stops clocking after the 1st byte. In master mode, because the Pico generates the clock, you can be assured all bytes will eventually go out. Here, I bet the Pico is stuck on the 2nd byte write which may never exit because the I2C state machine will have reset since the RPI sent I2C end . |
Beta Was this translation helpful? Give feedback.
Good description. I have an idea what's going on, but need to wire up some stuff to test the theory out. (Since there are 2 cores and 2 I2C peripherals, I can do your test on the Pico itself).
I believe the issue is that in slave mode you've sent a 5x1-byte writew down but the RPI stops clocking after the 1st byte. In master mode, because the Pico generates the clock, you can be assured all bytes will eventually go out. Here, I bet the Pico is stuck on the 2nd byte write which may never exit because the I2C state machine will have reset since the RPI sent I2C end .