Monday, June 20, 2016

Enable I2C on Raspberry Pi running Raspbian Jessie

This post show how to enable I2C (or IIC) interface on Raspberry Pi running Raspbian Jessie.


This test run on Raspberry Pi 2/Raspbian Jessie (2016-05-27)

To run Raspberry Pi Configuration:

> Menu > Preferences > Raspberry Pi Configuration


Select Interfaces tab, and click to enable I2C, OK.


Install i2c-tools, such that you can scan any connected I2C devices, and find its I2C address.
$ sudo apt install i2c-tools

Power off Raspberry Pi, connect I2C device and power on.


run the i2cdetect with option 1 for rev 2 board, or option 0 for rev 1 board.
$ sudo i2cdetect -y 1
$ sudo i2cdetect -y 0

(The connected device with I2C address 0x3C shown in the video is a I2C OLED display, refer to next post: Raspberry Pi display on 128x64 I2C OLED with SSD1306, using Python)

No comments: