Go Down

Topic: I2C, EEPROM communication problem (Read 1 time) previous topic - next topic


Dec 03, 2013, 11:01 pm Last Edit: Dec 04, 2013, 07:55 am by Jasam Reason: 1

I can't read and write to the eeprom 24C16 using Arduino Uno.
I decided to investigate. At the beginning, I checked connection - it is OK. Pins 1-4, 7 to ground, pin 5 to A4, pin 6 to A5, pin 8 to 3,3V
Then, I tried to run I2C scanner from http://www.gammon.com.au/forum/?id=10896

Code: [Select]
// I2C Scanner
// Written by Nick Gammon
// Date: 20th April 2011

#include <Wire.h>

void setup() {
 Serial.begin (9600);

 // Leonardo: wait for serial port to connect
 while (!Serial)

 Serial.println ();
 Serial.println ("I2C scanner. Scanning ...");
 byte count = 0;
 for (byte i = 1; i < 120; i++)
   Wire.beginTransmission (i);
   if (Wire.endTransmission () == 0)
     Serial.print ("Found address: ");
     Serial.print (i, DEC);
     Serial.print (" (0x");
     Serial.print (i, HEX);
     Serial.println (")");
     delay (1);  // maybe unneeded?
     } // end of good response
 } // end of for loop
 Serial.println ("Done.");
 Serial.print ("Found ");
 Serial.print (count, DEC);
 Serial.println (" device(s).");
}  // end of setup

void loop() {}

I was surpised, because the result was:

Code: [Select]
I2C scanner. Scanning ...
Found address: 80 (0x50)
Found address: 81 (0x51)
Found address: 82 (0x52)
Found address: 83 (0x53)
Found address: 84 (0x54)
Found address: 85 (0x55)
Found address: 86 (0x56)
Found address: 87 (0x57)
Found 8 device(s).

Why? I connected only one device at address 0x50.
Do you guys have any idea what's going wrong?
Thanks for your help.


If your device works as described in the FutureLec datasheet (http://www.futurlec.com/Memory/24C16SMD.shtml), this info on page 9 should help.
The 16K does not use any device address bits but instead the 3 bits are used for memory
page addressing. These page addressing bits on the 4K, 8K and 16K devices
should be considered the most significant bits of the data word address which follows.
The A0, A1 and A2 pins are no connect.

Since the 3 bits are used to address memory pages, the chip will respond to any address of the form 0101xxx, which is why the scanner gets responses from 0x50 to 0x57.

Don't send me technical questions via Private Message.



you have rigth! I was blind.
There is another addressing method.

Thank you a lot :)

Go Up