RM0453 Rev 5 1087/1450
RM0453 Inter-integrated circuit (I2C) interface
1113
34.4.14 SMBus slave mode
This section is relevant only when the SMBus feature is supported (refer to Section 34.3).
In addition to I2C slave transfer management (refer to Section 34.4.8), some additional
software flows are provided to support the SMBus.
SMBus slave transmitter
When the IP is used in SMBus, SBC must be programmed to ‘1’ to enable the PEC
transmission at the end of the programmed number of data bytes. When the PECBYTE bit
is set, the number of bytes programmed in NBYTES[7:0] includes the PEC transmission. In
that case the total number of TXIS interrupts is NBYTES - 1 and the content of the
I2C_PECR register is automatically transmitted if the master requests an extra byte after the
NBYTES - 1 data transfer.
Caution: The PECBYTE bit has no effect when the RELOAD bit is set.
Figure 300. Transfer sequence flow for SMBus slave transmitter N bytes + PEC
MS19867V2
Slave initialization
SMBus slave
transmission
Write I2C_TXDR.TXDATA
I2C_ISR.TXIS
=1?
No
Yes
I2C_ISR.ADDR =
1?
Yes
No
Read ADDCODE and DIR in I2C_ISR
I2C_CR2.NBYTES = N + 1
PECBYTE=1
Set I2C_ICR.ADDRCF
SCL
stretched