FPGA Implementation of I2C and SPI Protocols
FPGA Implementation of I2C and SPI Protocols
Abstract- I2C and SPI are the serial communication protocols digital electronics systems, and they might probably will
that are commonly used for both intra-chip and inter-chip continue to compete in the future, I2C and SPI both are
low/medium bandwidth data transfer. It can support bi- actually complementary for this kind of communication. The
directional data transfers at up to 100 Kbit/s in the standard- I2C and SPI protocol specifications are well defined.
mode, up to 400 Kbit/s in the Fast-mode, up to 1 M bit/s in the Consequently, they will not be discussed here. But, a quick
Fast-mode plus, or up to 3.4 M bit/s in the High-speed mode. overview is provided in table 1.
These protocols have a preferable speed and power Although the literature of I2C and SPI is old (early 1980), to
consumption capability when implemented with different the best of the writers knowledge there is no comprehensive
devices but their speed is low, when used with BIST or comparison of I2C and SPI problem. By comprehensive
checksums. comparison we mean a treatment that start from Philips and
Motorola specifications and goes down to the actual ASIC or
In the earlier systems speed and delay was not taken FPGA implementation, linguistics the two designs and then
into the consideration and the protocol was implemented as it considering similarities of the obtained results based on
is in the standard mode. We are about to implement the I2C included protocol features.
and SPI protocols efficiently so that the speed of the data
transfer increases and there delay is reduced. In order to do
so we have proposed a design in which we are using pipelined
buffer in between Master and Slave so that it will reduce the
delay and there would be synchronization and increase in the
speed of data transfer as the delay in data transfer decreases.
The pipelined buffer results in the speed enhancement for the
critical paths. Using this pipelined buffer the data transferred
from master is first stored in buffer and then transferred to the
slave and vice-versa. The delay is in the form of nanoseconds
in which when used pipelined buffer in the system route delay
is neglected and only logic delay is considered. The speed is
calculated using the delay of the system in the form of Mbps or
Gbps depending on the delay. The delay report for both the
protocols are taken from synthesis report generated in the
Xilinx software and the simulation of the system is done in the
model-sim software.
I. INTRODUCTION
There are many software applications developed in
Today, at the low end of the communication
the implementation of the communication protocols SPI and
protocols we can find two worldwide standards: Inter
I2C. In general, these researches are focused on the
integrated circuits (I2C) and serial peripheral interface (SPI).
comparisons and implementations of different architectures in
Both protocols are well specified for communication between
order to meet characteristics required by current technologies.
integrated circuits for low or medium data transfer speed with
onboard peripherals. The two protocols co-exist in modern
Page | 16 www.ijsart.com
IJSART - Volume 2 Issue 10 –OCTOBER 2016 ISSN [ONLINE]: 2395-1052
Page | 17 www.ijsart.com
IJSART - Volume 2 Issue 10 –OCTOBER 2016 ISSN [ONLINE]: 2395-1052
Below is the proposed design for I2C Protocol. TABLE 2: Signal Description
The proposed system of SPI protocol consist of the Fig 4.Simulation Result of Standard I2C Protocol.
master and slave in whom we have introduced a pipelined
buffer in the bus MOSI and MISO. The 1 bit address is used 4.1 Simulation Result for I2C Protocol with Pipelined
as an input to the system. The buffer stores the data transferred Buffer
from the master .Due to which there is no data lose in between
the data transfer. As the delay of the system gates reduced the The below is the simulation result of the I2C protocol
speed of the data transfer or Transfer rate of the system which comprises of the pipelined buffer. In this result will are
increase. able to see the transmitted address getting fully received and
also some data stored in buffer.
Below is the proposed design for SPI Protocol.
Table 3: Signal Description for I2C Protocol with Pipelined
Buffer
4.2 Comparison
Table 4: Comparison
Fig 6
5.2 Comparison
Page | 19 www.ijsart.com
IJSART - Volume 2 Issue 10 –OCTOBER 2016 ISSN [ONLINE]: 2395-1052
REFERENCES
Fig 8.Graphical Representation of Delay and Speed with the [3] Zheng-Wei HU in “I2C Protocol Design for Reusability”
proposed Design of the system containing Pipelined buffer. 978-0-7695-4261-4/10 2010 IEEE.
Page | 20 www.ijsart.com