Add definition and function for new i2c api.