5 lpc2103 I2C
5 lpc2103 I2C
START STOP
I2C. Byte transfer
• The device who listen to data must left SDAhigh
• Slave devices must assert ACK(SDAlow) after reading a byte
(address or data)
• The master must assert ACKon data read. In this case the last
byte of the frame is followed by NACK instead ofACK
I2C. Frame
• Write frame
• Read frame
Hardware I2C controller. Registers
Register Access Description
I2CONSET R/W Write: Set bits in Control Reg.
I2CONCLR WO Write: Clear bits in Control Reg.
I2STAT RO Status Reg.
I2DAT R/W Data reg.
I2ADR R/W I2C slave address (only used in slave mode)
I2SCLH R/W SCLhigh time (PCLKcycles)
I2SCLL R/W SCLlow time (PCLKcycles)