[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Another I2C issue



Hi,

Thanks for all your work on the PCF8563 driver! We have had some minor problems with PCF8563 ourslef lately but has not yet had the time to investigate it. Would it be possible for you to send your latest i2c.c or a diff?

Thanks
/Mikael

-----Original Message-----
From: owner-dev-etrax@xxxxxxx.com">mailto:owner-dev-etrax@xxxxxxx.com] On Behalf Of Pieter Grimmerink
Sent: Friday, June 20, 2003 7:32 PM
To: dev-etrax
Subject: Another I2C issue


I've found another problem with the I2C routines.

Usually, an 'i2c_sendack()' (or nack) follows an 'i2c_inbyte()'. Now i2c_inbyte() leaves the clock high, whereas i2c_sendack() assumes the 
clock to be low.

So I've added 

i2c_clk(I2C_CLOCK_LOW);

to the bottom of the i2c_inbyte()

And finally, my rtc (pcf8563 compatible) works!

Can't forsee what effect this modification to inbyte has on the eeprom driver 
though, because for some silly reason our eeprom (16kb) has the same address 
as the rtc, so we removed the eeprom for a while...

eeprom routines also use series of inbyte / sendack, so I don't see how that 
could have worked.

BTW, all these I2C issues are found in devboard_82, wich I think contains the 
latest released i2c driver code.

Best regards,

Pieter