Device/board Level or On Board Communication Interfaces

Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

1.

Device/board level or On board communication interfaces:

The Communication channel which interconnects the various components within an embedded
product is referred as Device/board level communication interface (Onboard Communication
Interface)

These are classified into

1.1 I2C (Inter Integrated Circuit) Bus

1.2 SPI (Serial Peripheral Interface) Bus

1.3 UART (Universal Asynchronous Receiver Transmitter)

I2C (Inter Integrated Circuit) Bus:

Inter Integrated Circuit Bus (I2C) is a synchronous bi-directional half duplex (one-directional
communication at a given point of time) two wire serial interface bus. The concept of I2C bus was
developed by Philips Semiconductors in the early 1980s. The original intention of I2C was to provide
an easy way of connection between a microprocessor/microcontroller system and the peripheral chips
in Television sets.

The I2C bus is comprised of two bus lines, namely; Serial Clock – SCL and Serial Data – SDA.

SCL line is responsible for generating synchronization clock pulses and SDA is responsible for
transmitting the serial data across devices.I2C bus is a shared bus system to which many number of
I2C devices can be connected. Devices connected to the I2C bus can act as either Master device or
Slave device.

The Master device is responsible for controlling the communication by initiating/terminating data
transfer, sending data and generating necessary synchronization clock pulses.

Slave devices wait for the commands from the master and respond upon receiving the commands.
Master and Slave devices can act as either transmitter or receiver. Regardless whether a master is
acting as transmitter or receiver, the synchronization clock signal is generated by the Master device
only. I2C supports multi masters on the same bus.
Serial Peripheral Interface (SPI) Bus:

The Serial Peripheral Interface Bus (SPI) is a synchronous bi-directional full duplex four wire serial
interface bus. The concept of SPI is introduced by Motorola. SPI is a single master multi-slave system.

It is possible to have a system where more than one SPI device can be master, provided the condition
only one master device is active at any given point of time, is satisfied.

SPI is used to send data between Microcontrollers and small peripherals such as shift registers,
sensors, and SD cards.
SPI requires four signal lines for communication. They are:

Master Out Slave In (MOSI): Signal line carrying the data from master to slave device. It is also known
as Slave Input/Slave Data In (SI/SDI)

Master In Slave Out (MISO): Signal line carrying the data from slave to master device. It is also known
as Slave Output (SO/SDO)

Serial Clock (SCLK): Signal line carrying the clock signals

Slave Select (SS): Signal line for slave device select. It is an active low signal.

The master device is responsible for generating the clock signal.

Master device selects the required slave device by asserting the corresponding slave devices slave
select signal LOW.

The data out line (MISO) of all the slave devices when not selected floats at high impedance state

The serial data transmission through SPI Bus is fully configurable.

SPI devices contain certain set of registers for holding these configurations.

The Serial Peripheral Control Register holds the various configuration parameters like master/slave
selection for the device, baudrate selection for communication, clock signal control etc.

The status register holds the status of various conditions for transmission and reception. SPI works
on the principle of Shift Register.

The master and slave devices contain a special shift register for the data to transmit or receive.

The size of the shift register is device dependent. Normally it is a multiple of 8.


Difference between SPI and I2C

UART:

UART means Universal Asynchronous Receiver Transmitter Protocol, hence UART refers to a protocol
in which serial data communication will happen without clock signal.

UART is a Universal Asynchronous Receiver Transmitter protocol that is used for serial communication.
Two wires are established here in which only one wire is used for transmission whereas the second
wire is used for reception. Data format and transmission speeds can be configured here. So, before
starting with the communication define the data format and transmission speed. Data format and
transmission speed for communication will be defined here and we do not have a clock over here
that’s why it is referred to as asynchronous communication with UART protocol. Here we will see how
this protocol is designed physically.
Here, DEVICE A that is having transmitter PIN and a receiver pin; DEVICE B is having a receiver and
transmission pin. The Transmitter of DEVICE A is one that should be connected with the receiver pin
of DEVICE B and the transmitter pin of DEVICE B should be connected with the receiver pin of DEVICE
A we just need to connect two wires for communication.

If DEVICE A wants to send data, then it will be sending data on the transmitter’s pin and here receiver
of this DEVICE B will receive it over and if DEVICE A wants to receive the data, then that is possible on
the RX line that will be forwarded by TX of DEVICE B. On comparing this serial communication of UART
with parallel then it can be observed that in parallel multiple buses are required. Based on the number
of lines bus complexity of UART is better but parallel communication is good in terms of speed.

You might also like