Bugfixes for I2C and port impl