Sorry, I hoped to finalize the new I2c class over the weekend. Didn't happen. If you update your board with the instructions above, you will have a mostly working I2c class.
There is C++ example of I2c communication for the MPR121 sensor in examples/06-Sensors/capacitive-touch/
.
This does not use the new I2cRt
class, but maintains its own I/O loop in a separate thread/
There is also an example Pd patch, if writing user-space I2c drivers from PureData is your thing! The core/default_libpd_render.cpp
is the backend for this Pd-I2c, and exemplifies the use of the I2cRt
class in include/I2cRt.h
which uses writeRt
or readRt
to write/read to the I2c bus asynchronously from the audio thread.