Pages: [1]   Go Down
Author Topic: I2C timeout?  (Read 314 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 17
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi!

I'm using an I2C network to connect a couple of Arduclemas (an Arduino derivative with screw terminals on all pins, and I2C pullUp resistors).

My problem is this: if one node card (microcontroller) fails or leaves the network, the Master seems to block indefinitely while doing Wire.endTransmission(). I can't seem to find a way to check if the node is alive before talking to it, or recover gracefully (and quickly) when the communication fails. The ideia is to have a timeout when communicating; if it takes more than a few ms just return in error and keep going.

Has anyone found a way to deal with this?
Thanks!
--
Óscar
Logged

Pages: [1]   Go Up
Jump to: