Examples on how to use I2C using mraa library
Following examples are provided to use I2C using MRAA library.
- mraa_i2c.c
- mraa_i2c.cpp
- mraa_i2c.py
Usage:
Prerequisite: debian running on 96Boards CE with libmraa installed
- Copy the examples to 96Boards CE
- Build the C/C++ examples:
$ gcc mraa_i2c.c -o i2c_c $ g++ mraa_i2c.cpp -o i2c_c++
- Execute the examples:
$ sudo ./i2c_c $ sudo ./i2c_c++ $ sudo python mraa_i2c.py
Expected Behaviour:
Checks for MPU6050 sensor at I2C bus 0.