The I2C class represents an I2C two-wire serial port, of which the imp contains two. See Wikipedia for more background on I2C.
The I2C objects are instantiated at startup, and are accessed via hardware.i2c12 or hardware.i2c89.
When implementing I2C using an imp, note that external pull-ups are required: it is not possible to enable the internal pull-ups when pins are used for I2C.
The i2c object has the following member functions: