Also I have placed two 10k ohm resistors between VCC -> SCL and VCC ->SDA
I2C2.setup({scl:B10,sda:B11});
var eeprom=require("AT24").connect(I2C2, 8, 256, 0);
console.log(eeprom.write(0x64,"Merhaba"));
console.log(eeprom.read(0x64,7));
line console.log(eeprom.write(0x64,"Merhaba")); outputs 7
but console.log(eeprom.read(0x64,7)); delays 10-12 seconds and outputs this error;
Uncaught InternalError: Timeout on I2C Read Receive Mode
at line 2 col 2
b)}
^
in function "read" called from line 1 col 31
console.log(eeprom.read(0x64,7));
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Yes, I had many mistakes on code; Also I had misakes on wiring.
Here is the correct one
EEPROM VCC -> Board 5V
EEPROM CSS -> Board Ground
EEPROM SCL -> Board SCL (B10)
EEPROM SDA -> Board SDA (B11)
Also I have placed two 10k ohm resistors between VCC -> SCL and VCC ->SDA
line console.log(eeprom.write(0x64,"Merhaba")); outputs 7
but console.log(eeprom.read(0x64,7)); delays 10-12 seconds and outputs this error;