Olimex Support Forum

OLinuXino Android / Linux boards and System On Modules => A10 => Topic started by: DevinG on May 26, 2018, 04:31:54 AM

Title: A10 I2C
Post by: DevinG on May 26, 2018, 04:31:54 AM
I cannot find any information of using I2C with the A10 board. Which GPIO pins correspond to which I2C bus?
Thanks.
Title: Re: A10 I2C
Post by: LubOlimex on May 28, 2018, 12:47:05 PM
A10-OLinuXino-LIME? The definitions can be checked in the fex file: ftp://staging.olimex.com/Lub-clients/A10_build/4-debian_3.4.90_release_3/script.fex

The i2c is called twi. The three I2C ports enabled and their corresponding pins are:

[twi0_para]
twi0_used = 1
twi0_scl = port:PB00<2><default><default><default>
twi0_sda = port:PB01<2><default><default><default>

[twi1_para]
twi1_used = 1
twi1_scl = port:PB18<2><default><default><default>
twi1_sda = port:PB19<2><default><default><default>

[twi2_para]
twi2_used = 1
twi2_scl = port:PB20<2><default><default><default>
twi2_sda = port:PB21<2><default><default><default>

You might want to check this Python package for I2C/GPIO/UART/SPI control: https://pypi.org/project/pyA10Lime/
Title: Re: A10 I2C
Post by: DevinG on May 29, 2018, 11:33:41 PM
Thanks, you are the greatest!