class DeviceI2C

Since I2C is a bus, there are actually two classes involved. A PortI2C object manages a port as I2C master for one or more objects of class DeviceI2C, each representing a separate device. You can have multiple ports as I2C bus (running at a different speed perhaps), each talking to multiple I2C devices. Devices sharing the same bus must each have a unique ID in the range 0 .. 127.

Example definition:

PortI2C myBus (3, PortI2C::KHZ400);
DeviceI2C myDev (myBus, 0x77);

Once a device object has been created, I/O transfers to and from that device can be performed.

#include <Ports.h> 
#include <RF12.h> // needed to avoid a linker error :(

class DeviceI2C;

Public API