Module-5
Module-5
o In the OSI model, the data link layer is a 4th layer from the top and 2nd layer from the
bottom.
o The communication channel that connects the adjacent nodes is known as links, and in
order to move the datagram from source to the destination, the datagram must be moved
across an individual link.
o The main responsibility of the Data Link Layer is to transfer the datagram across an
individual link.
o The Data link layer protocol defines the format of the packet exchanged across the nodes
as well as the actions such as Error detection, retransmission, flow control, and random
access.
o The Data Link Layer protocols are Ethernet, token ring, FDDI and PPP.
o An important characteristic of a Data Link Layer is that datagram can be handled by
different link layer protocols on different links in a path. For example, the datagram is
handled by Ethernet on the first link, PPP on the second link.
o Following services are provided by the Data Link Layer:
o Framing & Link access: Data Link Layer protocols encapsulate each network frame
within a Link layer frame before the transmission across the link. A frame consists of a
data field in which network layer datagram is inserted and a number of data fields. It
specifies the structure of the frame as well as a channel access protocol by which frame is
to be transmitted over the link.
o Reliable delivery: Data Link Layer provides a reliable delivery service, i.e., transmits the
network layer datagram without any error. A reliable delivery service is accomplished with
transmissions and acknowledgements. A data link layer mainly provides the reliable
delivery service over the links as they have higher error rates and they can be corrected
locally, link at which an error occurs rather than forcing to retransmit the data.
o Flow control: A receiving node can receive the frames at a faster rate than it can process
the frame. Without flow control, the receiver's buffer can overflow, and frames can get
lost. To overcome this problem, the data link layer uses the flow control to prevent the
sending node on one side of the link from overwhelming the receiving node on another
side of the link.
o Error detection: Errors can be introduced by signal attenuation and noise. Data Link
Layer protocol provides a mechanism to detect one or more errors. This is achieved by
adding error detection bits in the frame and then receiving node can perform an error
check.
o Error correction: Error correction is similar to the Error detection, except that receiving
node not only detect the errors but also determine where the errors have occurred in the
frame.
o Half-Duplex & Full-Duplex: In a Full-Duplex mode, both the nodes can transmit the data
at the same time. In a Half-Duplex mode, only one node can transmit the data at the same
time.
Sub-Layers of The Data Link Layer
The data link layer is further divided into two sub-layers, which are as follows:
Logical Link Control (LLC)
This sublayer of the data link layer deals with multiplexing, the flow of data among applications
and other services, and LLC is responsible for providing error messages and acknowledgments
as well.
Media Access Control (MAC)
MAC sublayer manages the device’s interaction, responsible for addressing frames, and also
controls physical media access. The data link layer receives the information in the form of
packets from the Network layer, it divides packets into frames and sends those frames bit-by-bit
to the underlying physical layer.
Ethernet Basics:
Ethernet is a set of technologies and protocols that are used primarily in LANs. However, Ethernet
can also be used in MANs and even WANs. It was first standardized in the 1980s as IEEE 802.3
standard. Since then, it has gone through four generations, as shown in the following chart
Standard Ethernet is also referred to as Basic Ethernet. It uses 10Base5 coaxial cables for
communications. Ethernet provides service up to the data link layer. At the data link layer,
Ethernet divides the data stream received from the upper layers and encapsulates it into frames,
before passing them on to the physical layer.
Ethernet is the most widely used LAN technology and is defined under IEEE standards 802.3.
The reason behind its wide usability is that Ethernet is easy to understand, implement, and
maintain, and allows low-cost network implementation. Also, Ethernet offers flexibility in terms
of the topologies that are allowed. Ethernet generally uses a bus topology. Ethernet operates in
two layers of the OSI model, the physical layer and the data link layer. For Ethernet, the
protocol data unit is a frame since we mainly deal with DLLs. In order to handle collisions, the
Access control mechanism used in Ethernet is CSMA/CD.
Although Ethernet has been largely replaced by wireless networks. A wired networking still
uses Ethernet more frequently. Wi-Fi eliminates the need for cables by enabling users to
connect their smart phones or laptops to a network wirelessly. The 802.11ac Wi-Fi standard
offers faster maximum data transfer rates when compared to Gigabit Ethernet. However, wired
connections are more secure and less susceptible to interference than wireless networks.
1. Fast Ethernet: This type of Ethernet network uses cables called twisted pair or CAT5. It
can transfer data at a speed of around 100 Mbps (megabits per second). Fast Ethernet uses
both fiber optic and twisted pair cables to enable communication. There are three categories
of Fast Ethernet: 100BASE-TX, 100BASE-FX, and 100BASE-T4.
2. Gigabit Ethernet: This is an upgrade from Fast Ethernet and is more common
nowadays. It can transfer data at a speed of 1000 Mbps or 1 Gbps (gigabit per second).
Gigabit Ethernet also uses fiber optic and twisted pair cables for communication. It often
uses advanced cables like CAT5e, which can transfer data at a speed of 10 Gbps.
3. 10-Gigabit Ethernet: This is an advanced and high-speed network that can transmit
data at a speed of 10 gigabits per second. It uses special cables like CAT6a or CAT7
twisted-pair cables and fiber optic cables. With the help of fiber optic cables, this network
can cover longer distances, up to around 10,000 meters.
4. Switch Ethernet: This type of network involves using switches or hubs to improve
network performance. Each workstation in this network has its own dedicated connection,
which improves the speed and efficiency of data transfer. Switch Ethernet supports a wide
range of speeds, from 10 Mbps to 10 Gbps, depending on the version of Ethernet being used.
Advantages of Ethernet
Speed: When compared to a wireless connection, Ethernet provides significantly more speed.
Because Ethernet is a one-to-one connection, this is the case. As a result, speeds of up to 10
Gigabits per second (Gbps) or even 100 Gigabits per second (Gbps) are possible.
Efficiency: An Ethernet cable, such as Cat6, consumes less electricity, even less than a wifi
connection. As a result, these ethernet cables are thought to be the most energy-efficient.
Good data transfer quality: Because it is resistant to noise, the information transferred is of
high quality.
CSMA/CD:
CSMA/CD (Carrier Sense Multiple Access/ Collision Detection) is a media access control
method that was widely used in Early Ethernet technology/LANs when there used to be
shared Bus Topology and each node (Computers) was connected by Coaxial Cables. Nowadays
Ethernet is Full Duplex and Topology is either Star (connected via Switch or Router) or point-
to-point ( Direct Connection). Hence CSMA/CD is not used but they are still supported though.
Consider a scenario where there are ‘n’ stations on a link and all are waiting to transfer data
through that channel. In this case, all ‘n’ stations would want to access the link/channel to
transfer their own data. The problem arises when more than one station transmits the data at the
moment. In this case, there will be collisions in the data from different stations.
CSMA/CD is one such technique where different stations that follow this protocol agree on
some terms and collision detection measures for effective transmission. This protocol decides
which station will transmit when so that data reaches the destination without corruption.
How Does CSMA/CD Work?
Step 1: Check if the sender is ready to transmit data packets.
Step 2: Check if the transmission link is idle.
The sender has to keep on checking if the transmission link/medium is idle. For this, it
continuously senses transmissions from other nodes. The sender sends dummy data on the
link. If it does not receive any collision signal, this means the link is idle at the moment. If it
senses that the carrier is free and there are no collisions, it sends the data. Otherwise, it
refrains from sending data.
Step 3: Transmit the data & check for collisions.
The sender transmits its data on the link. CSMA/CD does not use an ‘acknowledgment’
system. It checks for successful and unsuccessful transmissions through collision signals.
During transmission, if a collision signal is received by the node, transmission is stopped.
The station then transmits a jam signal onto the link and waits for random time intervals
before it resends the frame. After some random time, it again attempts to transfer the data
and repeats the above process.
Step 4: If no collision was detected in propagation, the sender completes its frame
transmission and resets the counters.
How Does a Station Know if Its Data Collide?
Virtual LAN:
Virtual Local Area Networks or Virtual LANs (VLANs) are a logical group of computers that
appear to be on the same LAN irrespective of the configuration of the underlying physical
network. Network administrators partition the networks to match the functional requirements of
the VLANs so that each VLAN comprise of a subset of ports on a single or multiple switches or
bridges. This allows computers and devices in a VLAN to communicate in the simulated
environment as if it is a separate LAN .
Features of VLANs
A VLAN forms sub-network grouping together devices on separate physical LANs.
VLAN's help the network manager to segment LANs logically into different broadcast
domains.
VLANs function at layer 2, i.e. Data Link Layer of the OSI model.
There may be one or more network bridges or switches to form multiple, independent
VLANs.
Using VLANs, network administrators can easily partition a single switched network into
multiple networks depending upon the functional and security requirements of their
systems.
VLANs eliminate the requirement to run new cables or reconfiguring physical connections
in the present network infrastructure.
VLANs help large organizations to re-partition devices aiming improved traffic
management.
VLANs also provide better security management allowing partitioning of devices
according to their security criteria and also by ensuring a higher degree of control
connected devices.
VLANs are more flexible than physical LANs since they are formed by logical
connections. This aids is quicker and cheaper reconfiguration of devices when the logical
partitioning needs to be changed.
Types of VLANs
Protocol VLAN − Here, the traffic is handled based on the protocol used. A switch or
bridge segregates, forwards or discards frames the come to it based upon the traffics
protocol.
Port-based VLAN − This is also called static VLAN. Here, the network administrator
assigns the ports on the switch / bridge to form a virtual network.
Dynamic VLAN − Here, the network administrator simply defines network membership
according to device characteristics.
Improved network security: VLANs can be used to separate network traffic and limit
access to specific network resources. This improves security by preventing unauthorized
access to sensitive data and network resources.
Better network performance: By segregating network traffic into smaller logical
networks, VLANs can reduce the amount of broadcast traffic and improve network
performance.
Simplified network management: VLANs allow network administrators to group
devices together logically, rather than physically, which can simplify network management
tasks such as configuration, troubleshooting, and maintenance.
Flexibility: VLANs can be configured dynamically, allowing network administrators to
quickly and easily adjust network configurations as needed.
Cost savings: VLANs can help reduce hardware costs by allowing multiple virtual
networks to share a single physical network infrastructure.
Scalability: VLANs can be used to segment a network into smaller, more manageable
groups as the network grows in size and complexity.
The IEEE 802.11 standard, commonly known as Wi-Fi, outlines the architecture and defines the
MAC and physical layer specifications for wireless LANs (WLANs). Wi-Fi uses high-frequency
radio waves instead of cables for connecting the devices in LAN. Given the mobility of WLAN
nodes, they can move unrestricted within the network coverage zone. The 802.11 structure is
designed to accommodate mobile stations that participate actively in network decisions.
Furthermore, it can seamlessly integrate with 2G, 3G, and 4G networks.
The Wi-Fi standard represents a set of wireless LAN standards developed by the Working
Group of IEEE LAN/MAN standards committee (IEEE 802). The term 802.11x is also used to
denote the set of standards. Various specifications and amendments include 802.11a, 802.11b,
802.11e, 802.11g, 802.11n etc.
Infrastructure BSS
Independent BSS
Roaming: In an environment with multiple access points (like a large office building or
campus), a device can move from the range of one AP to another and still maintain its
connection. This is possible due to the underlying architecture of the IEEE 802.11 standard
which allows for roaming between APs.
Authentication and Association: Before a station can send or receive data frames on a
WLAN, it needs to establish its identity with an AP. This process is called authentication.
After authentication, the station then establishes a data link-layer connection with the AP
through a process called association.
The physical Layer is the bottom-most layer in the Open System Interconnection (OSI)
Model which is a physical and electrical representation of the system. It consists of various
network components such as power plugs, connectors, receivers, cable types, etc. The physical
layer sends data bits from one device(s) (like a computer) to another device(s).
Physical Layer Services
1. Bit-by-Bit Transmission
The Physical Layer transmits data in the form of individual bits. It does not organize these bits
into groups such as packets or frames. Instead, it simply ensures that bits are sent from the
sender to the receiver over a medium either guided medium such as coaxial cable, fiber cable
etc. or an unguided medium such as electromagnetic waves( radio waves, infrared,
microwaves).
Example: In an Ethernet connection, data is transmitted in the form of electrical signals (high
and low voltages) representing binary 1s and 0s.
2. Encoding and Decoding
Encoding converts digital data (0s and 1s) into a signal suitable for transmission. The receiving
device then decodes these signals back into digital data. This process ensures that the signals
can travel efficiently and be correctly interpreted at the destination.
3. Signal Transmission
The Physical Layer is responsible for how signals travel through a medium. Data can be
transmitted in two primary forms:
Digital Signals is a signal that represents data using discrete values (0s and 1s).
Analog Signals is a continuous wave that varies over time. It represents information
using changes in amplitude, frequency, or phase.
Since modern networks use digital signals, but some traditional systems still use analog signals.
Hence, these signals are often converted into each other.
Analog-to-Digital Conversion (ADC): Converts analog signals into digital signals for
computer processing.
Digital-to-Analog Conversion (DAC): Converts digital signals into analog signals for
transmission over traditional analog systems
4. Modulation and Demodulation
Modulation is the process of converting digital data into a form that can travel efficiently
over a medium, especially in wireless and analog systems. Demodulation is the reverse
process, extracting the original data from the transmitted signal.
5. Transmission Modes
The Physical Layer defines how data flows between devices.
6. Data Control
The Physical Layer helps manage the timing and flow of data to prevent errors and
inefficiencies in transmission.
(a) Synchronization ensures that the sender and receiver are in sync so that the bits are
interpreted correctly. Example: In video streaming, synchronization prevents delays or
distortions in audio and video playback.
(b) Flow Control manages the speed difference between sender and receiver to ensure
smooth communication.
The speed at which new data is produced each day has both positive and negative effects. In
addition to producing all of this data, we also have the need to transmit data from one location to
another, for which we have a wide variety of options. It is equally important to ensure that the
data is transferred in a quick, safe, and seamless manner.
The terms "bandwidth" and "data rate" are frequently used interchangeably in the field of
telecommunications, which can make things somewhat unclear at times. Every connection to a
network has a data rate, which is the speed at which bits are sent from one node to another, and
a bandwidth, which is the maximum amount of bits that a link may send or receive in one second.
Both of these rates are measured in bits per second.
Bandwidth:
The capacity of a computer network in terms of the amount of data that it can transmit is
measured in bits per second (Bps). The term "bandwidth" can have another meaning too; it can
indicate a person's capabilities to carry out activities or think deeply at a particular time. The
amount of work a user wants to accomplish while surfing the web determines the minimum
amount of bandwidth required to do so without experiencing interruptions.
For instance, a chat using instant messaging can use one kilobit, or one thousand bits, of
bandwidth every single second. In the meantime, an audio conversation, in which the participant's
voice is sent through the use of computer links, utilizes 56 kilobits per second (Kbps).
The amount of data that can be sent via a network is referred to as its bandwidth, and it is
measured in bits per second. The amount of data that can be transmitted varies, which might
reduce the effectiveness of a transmitter such as an Internet connection. To put it another way, the
bandwidth of a connection determines how quickly a device can download data from the Internet.
People in this day and age rely on the Internet to communicate with one another, make purchases,
earn money, learn new things, and entertain themselves. Due to the fact that the technology has
grown more content-heavy, efficient, and occupied throughout the course of time, the total
bandwidth that is necessary for it to function effectively has significantly increased.
Data Rate:
The concepts of "data rate" and "bandwidth" are interchangeable and nearly synonymous with one
another. In order to improve the effectiveness of communication systems, there is a persistently
growing demand for improvements in data transfer speeds as well as service quality. The
engineers in charge of communication have been putting in a lot of effort to improve data transfer
rates. It refers to the maximum number of bits that can be sent over a network in one second.
Therefore, if you are given bandwidth of 5 MHz, the maximum amount of data that may be
transferred to and from your device at one time will be 5 Mbps, but this is not always the case.
The quantity of data that is moved from one device to another device and between peripheral
devices like the computer is referred to as the data rate.
Data rate is measured in terms of the amount of data that is moved in a certain amount of time. To
increase the quantity of data rate, increase the count by 8 and reduce the amount of bandwidth by
that amount.
The term "data rate" refers to the speed at which radio transmission signals travel without being
altered in any way. This speed is typically stated in units of megabits per second (Mbps), however
it's common practice to assess data transfer on computers in terms of bytes per second.
Comparison between Bandwidth and Data Rate
The following table highlights the major differences between Bandwidth and Data Rate
Basic
Bandwidth Data Rate
Comparison
Bandwidth is a measure of the transmission Data rate is used to measure how fast
capacity of a network over a specific period of data is transferred from one point to
Definition
time. It is the rate at which a link may send or another. It refers to the actual amount of
receive bits per second. data transferred.
Encoding is the process of converting information into symbols that can then be modulated onto a
transmission medium to be transmitted. The reverse process is called decoding.
In the context of networking and telecommunications, encoding takes data represented by bits and
converts those bits into symbols that can be modulated onto a carrier wave for transmission
over copper wire or over a wireless link.
An example of an encoding method is Manchester code. For transmission over copper cabling,
each bit is represented by either a "low then high" representing "1" or a "high then low" waveform
representing "0" for each clock cycle. The following diagram shows the relationship between the
clock, the data and the Manchester encoding that is applied to the wire.
for each full clock cycle, either a binary "1" or "0" is transmitted. This is represented on the wire
as a movement from negative voltage to positive voltage (for 1) or positive voltage to negative
voltage (for 0). Thus, the receiver of this signal is able to interpret each of those movements from
positive to negative or negative to positive during a single clock cycle, as a 1 or a 0.
Manchester encoding is used for 10 Mbps Ethernet. More efficient methods of encoding are able
to encode more than just one bit per clock cycle. These encoding methods include:
• Two-binary, one-quaternary (2B1Q) - line code typically used in ISDN encoding two bits
per clock cycle
• 4B/5B - line code encoding 4 bits per clock cycle, used in some forms of Fast Ethernet.
• 8b/10b - line code encoding 8 bits of data per clock cycle, used by some forms of Gigabit
Ethernet
• 64b/66b - line code encoding 64 bits of data per clock cycle, used often in SONET/SDH
implementations
Encoding Techniques:
The data encoding technique is divided into the following types, depending upon the type of data
conversion.
Analog data to Analog signals − The modulation techniques such as Amplitude Modulation,
Frequency Modulation and Phase Modulation of analog signals, fall under this category.
Analog data to Digital signals − This process can be termed as digitization, which is done by
Pulse Code Modulation (PCM). Hence, it is nothing but digital modulation. As we have already
discussed, sampling and quantization are the important factors in this. Delta Modulation gives a
better output than PCM.
Digital data to Analog signals − The modulation techniques such as Amplitude Shift Keying
(ASK), Frequency Shift Keying (FSK), Phase Shift Keying (PSK), etc., fall under this category.
These will be discussed in subsequent chapters.
Digital data to Digital signals − These are in this section. There are several ways to map digital
data to digital signals.
Multiplexing:
Uses of Multiplexing
Multiplexing is used for a variety of purposes in data communications to enhance the efficiency
and capacity of networks. Here are some of the main uses:
Efficient Utilization of Resources: Multiplexing allows multiple signals to share the
same communication channel, making the most of the available bandwidth. This is
especially important in environments where bandwidth is limited.
Telecommunications: In telephone networks, multiplexing enables the simultaneous
transmission of multiple telephone calls over a single line, enhancing the capacity of the
network.
Internet and Data Networks: Multiplexing is used in internet communications to
transmit data from multiple users over a single network line, improving the efficiency and
speed of data transfer.
Satellite Communications: Multiplexing helps in efficiently utilizing the available
bandwidth on satellite transponders, allowing multiple signals to be transmitted and received
simultaneously.
Types of Multiplexing
There are five different types of multiplexing techniques, each designed to handle various types
of data and communication needs.
Types of Multiplexing
Statistical TDM is a more efficient type of time-division multiplexing as the channel capacity is
fully utilized and improves the bandwidth efficiency.
Read about Differences between TDM and FDM
3. Wavelength Division Multiplexing
Wavelength Division Multiplexing (WDM) is a multiplexing technology used to increase the
capacity of optical fiber by transmitting multiple optical signals simultaneously over a single
optical fiber, each with a different wavelength. Each signal is carried on a different wavelength
of light, and the resulting signals are combined onto a single optical fiber for transmission. At
the receiving end, the signals are separated by their wavelengths, demultiplexed and routed to
their respective destinations. It is used in telecommunications, cable TV, ISPs, and data centers
for high-speed, long-distance data transmission.
WDM can be divided into two categories:
Dense Wavelength Division Multiplexing (DWDM) is used to multiplex a large number
of optical signals onto a single fiber, typically up to 80 channels with a spacing of 0.8 nm or
less between the channels.
Coarse Wavelength Division Multiplexing (CWDM) is used for lower-capacity
applications, typically up to 18 channels with a spacing of 20 nm between the channels.
Shift Keying:
Shift Keying means that the amplitude, frequency or phase of the carrier wave is shifted
between two or more discrete values rather than varying continuously like Analog Modulation.
Binary data requires two discrete levels of amplitude, frequency or phase for modulation called
as Binary Shift Keying. A group of bits can be clubbed together to form M-ary Shift Keying.
There are mainly three types of Digital Modulation techniques. They are :
Amplitude Shift Keying
Frequency Shift Keying
Phase Shift Keying
Amplitude Shift Keying
In Amplitude Shift Keying (ASK), each symbol in the message signal gives a unique amplitude
to the carrier wave. There are two types of ASK, Binary and M-ary. In Binary ASK, logic 1 is
associated with certain amplitude of carrier wave e.g. 12V and logic 0 is associated with
different amplitude other than 12V e.g. 0V. In M-ary ASK, a group of log2M bits are
considered together rather than 1 bit at a time and the amplitude level is associated with this
group of bits.
For example, in 16-ary ASK, a group of 4 bits are considered and are given a respective
amplitude. Since there are 16 possible 4 bit binary numbers (24), 16 different amplitude levels
are required for modulation. If all such amplitudes are created using a single carrier wave, then
it is called as coherent ASK. If multiple carrier wave each with different amplitudes are used for
modulation then it is called as non-coherent ASK.
Transmission Media:
o Transmission media is a communication channel that carries the information from the
sender to the receiver. Data is transmitted through the electromagnetic signals.
o The main functionality of the transmission media is to carry the information in the form of
bits through LAN(Local Area Network).
o It is a physical path between transmitter and receiver in data communication.
o In a copper-based network, the bits in the form of electrical signals.
o In a fibre based network, the bits in the form of light pulses.
o In OSI(Open System Interconnection) phase, transmission media supports the Layer 1.
Therefore, it is considered to be as a Layer 1 component.
o The electrical signals can be sent through the copper wire, fibre optics, atmosphere, water,
and vacuum.
o The characteristics and quality of data transmission are determined by the characteristics
of medium and signal.
o Transmission media is of two types are wired media and wireless media. In wired media,
medium characteristics are more important whereas, in wireless media, signal
characteristics are more important.
o Different transmission media have different properties such as bandwidth, delay, cost and
ease of installation and maintenance.
o The transmission media is available in the lowest layer of the OSI reference model,
i.e., Physical layer.
o Bandwidth: All the factors are remaining constant, the greater the bandwidth of a
medium, the higher the data transmission rate of a signal.
o Transmission impairment: When the received signal is not identical to the transmitted
one due to the transmission impairment. The quality of the signals will get destroyed due
to transmission impairment.
o Interference: An interference is defined as the process of disrupting a signal when it
travels over a communication medium on the addition of some unwanted signal.
Causes Of Transmission Impairment:
o Attenuation: Attenuation means the loss of energy, i.e., the strength of the signal
decreases with increasing the distance which causes the loss of energy.
o Distortion: Distortion occurs when there is a change in the shape of the signal. This type
of distortion is examined from different signals having different frequencies. Each
frequency component has its own propagation speed, so they reach at a different time
which leads to the delay distortion.
o Noise: When data is travelled over a transmission medium, some unwanted signal is added
to it which creates the noise.
Guided Media:
o An unguided transmission transmits the electromagnetic waves without using any physical
medium. Therefore it is also known as wireless transmission.
o In unguided media, air is the media through which the electromagnetic energy can flow
easily.
Radio waves
o Radio waves are the electromagnetic waves that are transmitted in all the directions of free
space.
o Radio waves are omnidirectional, i.e., the signals are propagated in all the directions.
o The range in frequencies of radio waves is from 3Khz to 1 khz.
o In the case of radio waves, the sending and receiving antenna are not aligned, i.e., the
wave sent by the sending antenna can be received by any receiving antenna.
o An example of the radio wave is FM radio.
Microwaves
o Terrestrial microwave
o Satellite microwave communication.
o A satellite is a physical object that revolves around the earth at a known height.
o Satellite communication is more reliable nowadays as it offers more flexibility than cable
and fibre optic systems.
o We can communicate with any point on the globe by using satellite communication.
Infrared