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

Re: [oc] I2C polling question




Hi Filip, I assume you want the sequence of commands issued to the  I2C
core to do a write or a read. Below I am listing the command sequence to
do a 1 byte read from a I2C slave (bracket figures indicate specific
initialisation I've done) :

1) Initialise PRER to proper value (0x00A5).
2) Initialise CTR (0x00C0).
3) Write to transmit register TXR (0xE500).
4) Read status register SR (optional)
 -- the Busy/TIP bits should not be set !
5) Write to command register CR (0x00E9).
6) Again read SR 
 -- this time Busy/TIP bits should be set !

Thats all. After the read of 8 bits from the slave, the I2C core will be
giving ACK with proper timing.
Regards, Ujjal.
--------------------------
Ujjal Bose
Digital Design Engineer
ATM Division, C-DOT
Bangalore-52
Ph : 91-80-2384495
Fax : 91-80-2384496
E-mail : u_bose@lycos.com

On Thu, 8 Nov 2001, Filip Miletic wrote:

> 
> Dear all,
> 
> Has anyone been trying to get the I2C core work? I would appreciate 
> if he would share the polling technique, i.e. the sequence of 
> commands issued to I2C to get the ACK resolved correctly.
> 
> greetings.
> --
> To unsubscribe from cores mailing list please visit http://www.opencores.org/mailinglists.shtml
> 

--
To unsubscribe from cores mailing list please visit http://www.opencores.org/mailinglists.shtml