2.8 Bus Time-Out

SMBus and PMBus protocols require a bus watchdog to prevent a stalled device from hanging the bus indefinitely. The I2C module provides a bus time-out feature that can be used to reset the module if one of the bus devices is taking too long to respond. The I2C Bus Time-Out (I2CxBTO) register is used to select the time-out source for the module. When the time-out source expires, the I2CxBTO register notifies the module hardware and resets the module.

If the module is configured as a client and a bus time-out event occurs while the client is active (Client Mode Active bit (SMA) = 1), the SMA and Client Clock Stretching (CSTR) bits are cleared, the module is reset, and the Bus Time-Out Interrupt Flag (BTOIF) bit is set (see Figure 2-8). If the Bus Time-Out Interrupt Enable (BTOIE) bit is set when the BTOIF bit becomes set, the generic I2C Error Interrupt Flag (I2CxEIF) is also set.

Figure 2-8. Client Receive Bus Time-Out Event Example