Inter-integrated circuit interface (I2C)
13.2.15.3 I2C_GetITStatus
ITStatus I2C_GetITStatus ( I2C_TypeDef * I2Cx, uint32_t
I2C_IT)
Checks whether the specified I2C interrupt has occurred or not.
ï‚· I2Cx : where x can be 1 or 2 to select the I2C peripheral.
ï‚· I2C_IT : specifies the interrupt source to check. This
parameter can be one of the following values:
ï€ I2C_IT_TXIS : Transmit interrupt status
ï€ I2C_IT_RXNE : Receive data register not empty
ï€ I2C_IT_ADDR : Address matched (slave mode)
ï€ I2C_IT_NACKF : NACK received flag
ï€ I2C_IT_STOPF : STOP detection flag
ï€ I2C_IT_TC : Transfer complete (master mode)
ï€ I2C_IT_TCR : Transfer complete reload
ï€ I2C_IT_BERR : Bus error
ï€ I2C_IT_ARLO : Arbitration lost
ï€ I2C_IT_OVR : Overrun/Underrun
ï€ I2C_IT_PECERR : PEC error in reception
ï€ I2C_IT_TIMEOUT : Timeout or Tlow detection flag
ï€ I2C_IT_ALERT : SMBus Alert
ï‚· The new state of I2C_IT (SET or RESET).
13.2.15.4 I2C_ClearITPendingBit
void I2C_ClearITPendingBit ( I2C_TypeDef * I2Cx, uint32_t
I2C_IT)
Clears the I2Cx's interrupt pending bits.
ï‚· I2Cx : where x can be 1 or 2 to select the I2C peripheral.
ï‚· I2C_IT : specifies the interrupt pending bit to clear. This
parameter can be any combination of the following values:
ï€ I2C_IT_ADDR : Address matched (slave mode)
ï€ I2C_IT_NACKF : NACK received flag
ï€ I2C_IT_STOPF : STOP detection flag
ï€ I2C_IT_BERR : Bus error
ï€ I2C_IT_ARLO : Arbitration lost
ï€ I2C_IT_OVR : Overrun/Underrun
ï€ I2C_IT_PECERR : PEC error in reception
ï€ I2C_IT_TIMEOUT : Timeout or Tlow detection flag