I2 c protocol

12
I2C PROTOCOL (TUTORIAL) …….by Azad Mish ra

Transcript of I2 c protocol

Page 1: I2 c protocol

I2C PROTOCOL(TUTORIAL)

…….by

Azad Mishra

Page 2: I2 c protocol

I2C = Inter IC = Inter Integrated Circuit Developed by Philips semiconductor (Now NXP) Two serial wire: 1.serial data(SDA) 2.serial clock(SCL) Since dedicated SCL and SDA it support

synchronous communication Bidirectional data transfer (not simultaneously)

Introduction

Page 3: I2 c protocol

Multi master support Byte oriented transfer(byte) Wide range of Bus speed1.Standard mode = 100 kbps2.Fast mode = 400 kbps3.High speed mode = 1 mbps4.High speed mode = 3.4 mbps5.Ultra fast mode = 5 mbps

Contd………

Page 4: I2 c protocol

Signal definition

Page 5: I2 c protocol
Page 6: I2 c protocol
Page 7: I2 c protocol

Operation

Page 8: I2 c protocol

All the transition from 0 to 1 or 1 to 0,the should happen only when clk is low..

As the start and stop condition is defined when clk is high ,so all the data transition shroud happen only when clk is low.

So that receiving device could sample its pin ,when clk is high.

So when clk is high the data line will be stable. Lets say we want to transmit 0xAA = 1010

1010 So msb bit goes frist

RULES

Page 9: I2 c protocol

Star conditionIn start condition master send 1 byte in which (8 bit)So first 7 bit is slave device address and 8th bit is define its read or write operationIf 8th bit 0 = write operationIf 8th bit 1 = read operationAfter start condition master continuously send data or receive data. Stop condition Note- i2c will send 1 byte at a time on 7 bit

address line or 10 bit address line.

R/D and W/R operation

Page 10: I2 c protocol

Termination of operation

Page 11: I2 c protocol

https://drive.google.com/file/d/0BwDvWYgN9s0cTHl5WlppcFItaEE/view?usp=sharing

For more detail refer bellow document

Page 12: I2 c protocol