User Tools

Site Tools


tutorials:cb1:development:access_at24c_eeprom_via_i2c

This is an old revision of the document!


Access AT24C EEPROM via I2C

About this Article

Abstract

In this tutorial, an approach for accessing AT24C EEPROM via I2C bus on Cubieboard1 or Cubieboard2 is presented.

Configuration

In order to access peripheral I2C devices, Cubieboard's script.bin should enable I2C interfaces. Edit script.fex, make certain that the following lines exist there.

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

This will configure Cubieboard's IO port PB18 & PB19 to TWI1-SCK & TWI1-SDA (I2C-1).

Connection

AT24C Access

Example Codes

tutorials/cb1/development/access_at24c_eeprom_via_i2c.1386033644.txt.gz · Last modified: 2013/12/23 14:50 (external edit)