some I2C optimizations