Intel® Makers
Intel® Edison, Intel® Joule™, Intel® Curie™, Intel® Galileo
Welcome - This is a Peer-to-Peer Forum only. Intel has discontinued these products but you may find support from other customers on this Forum
9881 Discussions

How to find which I2c bus? on Edison using arduino breakout board


I have read piles of doc's and different threads but I'm unable to be sure of which i2c bus to use and what pins to use when hooking up my i2c device.

looking in the hookup guide for the board

I have followed the configuation of the ports which gives me that 18/19 should be used

Initiating the i2c according to intel PDF breakoutboard for Io18,Io19

echo low > /sys/class/gpio/gpio214/direction

echo high > /sys/class/gpio/gpio204/direction

echo high > /sys/class/gpio/gpio205/direction

echo in > /sys/class/gpio/gpio14/direction

echo in > /sys/class/gpio/gpio165/direction

echo low > /sys/class/gpio/gpio236/direction

echo low > /sys/class/gpio/gpio237/direction

echo in > /sys/class/gpio/gpio212/direction

echo in > /sys/class/gpio/gpio213/direction

echo mode1 > /sys/kernel/debug/gpio_debug/gpio28/current_pinmux

echo mode1 > /sys/kernel/debug/gpio_debug/gpio27/current_pinmux

echo high > /sys/class/gpio/gpio214/direction

enclosed are the two ways I've tried first to the "SCL/SCA" which is the most obvious, The second using "A4/A5"

the board I use is the MS5803-14BA Pressure Sensor Hookup Guide - from spark fun.

it has the default adress 0x76, end a byte reset command 0x1E

python exampel failing

>>> import mraa


>>> b=mraa.I2c(0)


>>> b.address(0x76)



>>> b.writeByte(0x1E)



So to the question:

Which I2C bus should i use? 0,1 or 6?  

Which of the connections should I use for i2c? (SCL/SCA" or AI4/AI5)

The sparkfun sensor board has two pullup resistors on it. With the config above described in the edison documentation the edison itself shouldn't have pullup activated right?

0 Kudos
2 Replies

It's easy. There is (in newest kernel, but in BSP you may find it as well) a pin mappings in the pinctrl-merrifield.c driver, from which we can see the I2C pins:

/* Family 7: I2C (14 pins) */

PINCTRL_PIN(101, "GP19_I2C_1_SCL"),


PINCTRL_PIN(102, "GP20_I2C_1_SDA"),


PINCTRL_PIN(103, "GP21_I2C_2_SCL"),


PINCTRL_PIN(104, "GP22_I2C_2_SDA"),






PINCTRL_PIN(107, "GP23_I2C_4_SCL"),


PINCTRL_PIN(108, "GP24_I2C_4_SDA"),


PINCTRL_PIN(109, "GP25_I2C_5_SCL"),


PINCTRL_PIN(110, "GP26_I2C_5_SDA"),


PINCTRL_PIN(111, "GP27_I2C_6_SCL"),


PINCTRL_PIN(112, "GP28_I2C_6_SDA"),


PINCTRL_PIN(113, "GP29_I2C_7_SCL"),


PINCTRL_PIN(114, "GP30_I2C_7_SDA"),



/* Family 12: MSIC (15 pins) */


PINCTRL_PIN(180, "I2C_0_SCL"),


PINCTRL_PIN(181, "I2C_0_SDA"),



Bus 0 is dedicated for MSIC and can't be accessed.

The rest has a GPIO number prefix, and according to the schematics (page 10) the buses are 1 and 6:

I2C1_SCL <span style="font-family: mon...

Community Manager

Hi JoachimLindborg,



Did you tried 0andriy recommendation? It was useful?



Let us know if you still have issues.