/* Configures the I2C Bus Timeout B (SCL cumulative Timeout).  */
void I2C_TimeoutBConfig(I2C_TypeDef *I2Cx, uint16_t Timeout)
/* Configures the I2C Bus Timeout B (SCL cumulative Timeout).  */
void I2C_TimeoutBConfig(I2C_TypeDef *I2Cx, uint16_t Timeout)
{
  uint32_t tmpreg = 0;
  assert_param(IS_I2C_ALL_PERIPH(I2Cx));
  assert_param(IS_I2C_TIMEOUT(Timeout));
  tmpreg = I2Cx->TIMEOUTR;
  tmpreg &= (uint32_t)~((uint32_t)I2C_TIMEOUTR_TIMEOUTB);
  tmpreg |= (uint32_t)(((uint32_t)Timeout << 16) & I2C_TIMEOUTR_TIMEOUTB) ;
  I2Cx->TIMEOUTR = tmpreg;
}