Multiplexing and Demultiplexing
Multiplexing and Demultiplexing
Physical Topology
The term physical topology refers to the way in which a network is laid out physically. Two or
more devices connect to a link; two or more links form a topology. The topology of a network is
the geometric representation of the relationship of all the links and linking devices (usually
called nodes) to one another.
There are four basic topologies possible: mesh, star, bus, and ring.
Mesh Topology: In a mesh topology, every device has a dedicated point-to-point link to every
other device. The term dedicated means that the link carries traffic only between the two devices
it connects.
We need n (n – 1) physical links in a fully connected mesh network with n nodes. if each
physical link allows communication in both directions (duplex mode),we need n (n – 1) / 2
duplex-mode links.
1. Use of dedicated links guarantees that each connection can carry its own data load, thus
eliminating the traffic problems that can occur when links must be shared by multiple devices.
2. A mesh topology is robust. If one link becomes unusable, it does not incapacitate the entire
system.
Star Topology
In a star topology, each device has a dedicated point-to-point link only to a central controller,
usually called a hub.
The devices are not directly linked to one another. A star topology does not allow direct traffic
between devices. The controller acts as an exchange: If one device wants to send data to another,
it sends the data to the controller, which then relays the data to the other connected device.
Advantages
Bus Topology
A bus topology is multipoint. One long cable acts as a backbone to link all the devices in a network
Nodes are connected to the bus cable by drop lines and taps. A drop line is a connection running
between the device and the main cable.
A tap is a connector that either splices into the main cable or punctures the sheathing of a cable
to create a contact with the metallic core.
Advantages
1. Easy to install.
2. Bus uses less cabling than mesh or star topologies. Only the backbone cable stretches through
the entire facility. Each drop line has to reach only as far as the nearest point on the backbone.
Disadvantages
1. Difficult reconnection and fault isolation.
2. Difficult to add new devices.
Ring Topology
In a ring topology, each device has a dedicated point-to-point connection with only the two
devices on either side of it. A signal is passed along the ring in one direction, from device to
device, until it reaches its destination.
Each device in the ring incorporates a repeater. When a device receives a signal intended for
another device, its repeater regenerates the bits and passes them along.
1) At the application layer, the data to be exchanged is a message. A message does not contain
header or trailer, but if it does, we refer to the whole as the message. The message is passed
to the transport layer.
2) The transport layer takes the message and it adds transport layer header which contains the
identifier of the source and destination application program that wants to communicate plus
some more information that is needed for the end-to end delivery of the message, such as
information needed for flow, error control, or congestion control. The result is the transport
layer packet, which is called the segment (in TCP) and the user datagram (in UDP). The
transport layer then passes the packet to the network layer.
3) The network layer takes segment (user datagram) as data or payload and adds its own header
to the payload. The header contains the addresses of the source and destination hosts and
some more information used for error checking of the header, fragmentation information, and
so on. The result is the network-layer packet, called a datagram. The network layer then
passes the packet to the data-link layer.
4) The data-link layer takes the datagram as data or payload and adds its own header, which
contains the link-layer addresses of the host or the next hop (the router). The result is the
link-layer packet, which is called a frame. The frame is passed to the physical layer for
transmission.
At the destination host, each layer only decapsulates the packet received, removes the payload,
and delivers the payload to the next-higher layer protocol until the message reaches the
application layer. During decapsulation error checking is done.
Addressing:
Any communication between two parties needs two addresses, source address and destination
address. TCP/IP has five layers but we require only four addresses because physical layer does
not need any address.
At application layer, we use names to define the site that provide services such as xyzorg.com or
email address such as [email protected].
At transport layer, addresses are called port numbers, and these define application layer
programs at source and destination. These port numbers allow different application on the same
computer to share network resources immediately.
At network layer, the addresses are global. A network layer address uniquely defines connection
of a device to the internet. A logical address is currently a 32 bit address that defines a host
connection to a network.
The link layer address are local address which define a specific host or router in a network (LAN
or WAN). Physical address change from hop to hop but logical and port address remains same.
Multiplexing means that a protocol at a layer encapsulates a packet from several next-higher
layer protocols (one at a time). Demultiplexing means that a protocol can decapsulates and
deliver a packet to several next higher layer protocol (one at a time).
Figure (a) shows the concept of multiplexing and demultiplexing at the three upper layer,
For multiplexing and demultiplexing, a protocol needs to have a field in its header to identify to
which protocol the encapsulated packets belong.
DLC is the services provided by the data link layer to provide reliable data transfer over the
physical medium. If both the devices transmit the data simultaneously, they will collide and leads
to the loss of information. The data link layer provides the coordination among the devices so
that no collision occurs.
For example in half duplex transmission mode, only one device can transmit data at a time.
Data link control includes three functions; they are framing, flow control and error control.
Framing:
Framing in the data-link layer separates a message from one source to a destination by adding a
sender address and a destination address.
Data link layer takes the packets from network layer and encapsulates them into frames. If the
frame size becomes too large, then the packet is divided into small frames where a smaller sized
frame makes flow control and error control efficient.
If the whole message is packed in one frame, the frame can become very large, which makes
flow and error control inefficient. When a message is carried in a very large frame, even a single
bit error would require retransmission of whole frame.
When a message is divided into smaller frames, a single bit error effects only that frame.
Parts of Frame:
PAYLOAD FIELD
FLAG HEADER TRAILER FLAG
(MESSAGE)
(1) Frame Header: It contains source and destination address of the frame.
(2) Payload field: It contains the message to be delivered.
(3) Trailer: It contains the error detection and error correction bits.
(4) Flag: It marks the beginning and end of the frame.
Types of framing:
Here the size of frame is fixed and frame length act as delimiter. There is no need for defining
the boundaries of the frames; the size itself can be used as a delimiter.
Example: ATM WAN uses frames of fixed size called cells.
The size of each frame to be transmitted is different. Hence we have to define end of one
frame and the beginning of next.
i) Character-oriented framing.
ii) Bit-oriented framing.
Character-Oriented Framing:
In character oriented framing, data is transmitted as a sequence of bytes from an 8 bit (1 byte)
coding system like ASCII. The flag, header and trailer are multiples of 8 bits.
To separate one frame from the next, an 8-bit (1-byte) flag is added at the beginning and the end
of a frame. The flag, composed of protocol-dependent special characters, signals the start or
end of a frame. Figure shows the format of a frame in a character-oriented protocol.
Character oriented protocols are used for transmission of text. The flag is chosen as a character
that is not used for text encoding. When other types of information such as graphs, audio, and
video are used, any character used for the flag could also be part of the information. If this
happens, the receiver, when it encounters this pattern in the middle of the data, thinks it has
reached the end of the frame.
To fix this problem, a byte-stuffing strategy is used. In byte stuffing (or character stuffing), a
special byte is added to the data section of the frame when there is a character with the same
pattern as the flag. The data section is stuffed with an extra byte called the escape character
(ESC).
Whenever the receiver encounters the ESC character, it removes it from the data section and
treats the next character as data, not as a delimiting flag. The figure shows byte stuffing and
unstuffing mechanism.
Byte stuffing is the process of adding one extra byte whenever there is a flag or escape character
in the text or data.
Bit-Oriented Framing:
In bit oriented framing, data is transmitted as a sequence of bits. The flag consists of 8 bits which
contains six 1s. Most protocol uses 8 bit pattern 01111110 as flag as shown in below figure,
Bit stuffing is the process of adding one extra 0 whenever five consecutive 1s follow a 0 in the
data, so that the receiver does not mistake the pattern 0111110 for flag as shown in below figure.