how to program psoc to read or write a register information from a salve chip through i2c?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

how to realize those timing sequence from below figure?

0 Likes
1 Reply
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

This is a quite normal I2C interface. Use the I2C master component and use a sequence of APIs as

   

Start();

   

WriteByte() Register to write

   

Stop()

   

or when reading

   

Start();

   

WriteByte() Register to read

   

Restart()

   

Readbyte(Ack) when reading multiple bytes

   

ReadByte(NAK) Last byte red is always NAKed

   

Stop()

   

 

   

Happy coding

   

Bob

0 Likes