Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Problem with I2C serial interface for EEPROM

Status
Not open for further replies.

nemolee

Full Member level 3
Joined
Dec 28, 2004
Messages
155
Helped
3
Reputation
6
Reaction score
1
Trophy points
1,298
Activity points
1,467
I2C interface for EEPROM

Does anyone know?
I have one question about serial interface EEPROM. If it is stopped suddenly in reading process because the master is reset but the slave is not reset, even the master send the START condition but no any affect in the slave. The master can't control the slave anymore. Why? How can I modify the master ? Thanks.
 

Re: I2C interface for EEPROM

Try to send short insignificant message to the SLAVE at the beginning of master work after restart. The key moment in this is the STOP condition. After receiving STOP slave have to reset all its internal states to initial values.
 

Re: I2C interface for EEPROM

you can try added start & stop condition before you send data to EEPROM.
 

I2C interface for EEPROM

I dont know vey well about your qustion
the master should already know which slave address it want to send , so after master reset, you need resend start signal then addr(otherwise, which slave he want to control), then all slave will bake to initial state in your State Machine(it should exist in your master and slave RTL code), the slave will wait for address match , then restart the State Machine ,so why you have problem after master reset?
if this really happen
even the master send the START condition but no any affect in the slave
then I dont think your serial is IIC, check and measure clk and sdi make sure you really send a start signal first !!
 

Re: I2C interface for EEPROM

mediatek said:
I dont know vey well about your qustion
the master should already know which slave address it want to send , so after master reset, you need resend start signal then addr(otherwise, which slave he want to control), then all slave will bake to initial state in your State Machine(it should exist in your master and slave RTL code), the slave will wait for address match , then restart the State Machine ,so why you have problem after master reset?
if this really happen
even the master send the START condition but no any affect in the slave
then I dont think your serial is IIC, check and measure clk and sdi make sure you really send a start signal first !!

In read process, master is reset suddently. But the slave is still output its last data and at this time there is no any clock input. The slave may pull the SDA bus to low level. Even if the master send START condition, the SDA is always low.
 

Re: I2C interface for EEPROM

when read , slave sdi pin become output
so no way to detecte start,
this is why you send start not work
but at this time , I do understand why slave pull sck to low, normally slave not ready to receive data (write ) , then it will low clock to pause master send data,
but after slave is ready to accept data , it will return clk control to master.
try
send not ack ( '1' in 9th clk or ...,follow the iic spec. you use) after master reset,
to let sdi pin become input pin.then start....

if slave stll let clock low and cannot detecte start , I think some error let salve state machine endless loop ===> only you can do is reset slave
becsuae it's slave problem , not master .
 

Re: I2C interface for EEPROM

hi,

i think you can try to send "STOP", the "STOP" signal will reset the slave and hence reset the "SDA" to "high". I have designed I2C before, this is how it works for my design.

Good Luck...

Smart
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top