Computer Networks UNIT-3 Media Access Control
Computer Networks UNIT-3 Media Access Control
Media Access Control: Random Access: ALOHA, Carrier sense multiple access (CSMA), CSMA with
Collision Detection, CSMA with Collision Avoidance, Controlled Access: Reservation, Polling, Token
Passing, Channelization: frequency division multiple Access (FDMA), time division multiple
access(TDMA), code division multiple access(CDMA).
Wired LANs: Ethernet, Ethernet Protocol, Standard Ethernet, Fast Ethernet(100 Mbps), Gigabit
Ethernet, 10 Gigabit Ethernet.
If there is a dedicated link between the sender and the receiver then data link control layer
is sufficient, however if there is no dedicated link present then multiple stations can access
the channel simultaneously.
Hence multiple access protocols are required to decrease collision and avoid crosstalk.
They help manage the network traffic so that all devices can share the communication
channel smoothly and effectively.
1. Data Link Control
2. Multiple Access Control
A data link control is a reliable channel for transmitting data over a dedicated link using
various techniques such as framing, error control and flow control of data packets in the
computer network.
• When a sender and receiver have a dedicated link to transmit data packets, the data link
control is enough to handle the channel.
• Suppose there is no dedicated path to communicate or transfer the data between two
devices. In that case, multiple stations access the channel and simultaneously transmits the
data over the channel.
• It may create collision and cross talk. Hence, the multiple access protocol is required to
reduce the collision and avoid crosstalk between the channels.
Controlled Access
• In controlled access, devices communicate with each other, and devices consult each other
about which device has the right to send.
• By controlling channel access, network performance is increased, and frame collisions are
reduced.
1. Random Access Protocol:
In this, all stations have same superiority that is no station has more priority than another
station. Any station can send data depending on medium’s state( idle or busy).
It has two features
1. There is no fixed time for sending data.
2. There is no fixed sequence of stations sending data.
The following are the types of Random access protocols
1.ALOHA
2.CSMA
3.CSMA/CD
4.CSMA/CA
1. ALOHA
o It is designed for wireless LAN (Local Area Network) but can also be used in a shared
medium to transmit data.
o In this, multiple stations can transmit data at the same time and can hence lead to
collision and data being garbled.
o It can be categorized into two types
1. Pure ALOHA
2. Slotted ALOHA
1. Pure ALOHA
Pure ALOHA allows stations to transmit whenever they have data to be sent.
When a station sends data it waits for an acknowledgement. If the
acknowledgement doesn’t come within the allotted time then the station
waits for a random amount of time called back-off time (Tb) and re-sends
the data.
Since different stations wait for different amount of time, the probability of
further collision decreases.
Whenever two frames try to occupy the channel at the same time ,there will
be a collision and both will be garbled.
If the first bit of a new frame overlaps with just the last bit of a frame almost
finished ,both frames will be totally destroyed and both will have to be
retransmitted later.
Throughput = G*e-2G
2. Slotted Aloha
The slotted Aloha is designed to overcome the pure Aloha's efficiency
because pure Aloha has a very high possibility of frame hitting.
In slotted Aloha, the shared channel is divided into a fixed time interval
called slots. So that, if a station wants to send a frame to a shared channel,
the frame can only be sent at the beginning of the slot, and only one frame
is allowed to be sent to each slot.
And if the stations are unable to send data to the beginning of the slot, the
station will have to wait until the beginning of the slot for the next time.
However, the possibility of a collision remains when trying to send a frame
at the beginning of two or more station time slot.
Vulnerable Time = Frame transmission time
Throughput = G*e-G
Where G is the number of stations wish to transmit in the same time
Maximum throughput = 0.368 for G=1
Carrier Sense Multiple Access ensures fewer collisions as the station is required to first sense
the medium (for idle or busy) before transmitting data.
If it is idle then it sends data, otherwise it waits till the channel becomes idle.
However there is still chance of collision in CSMA due to propagation delay.
For example, if station A wants to send data, it will first sense the medium. If it finds the
channel idle, it will start sending data. However, by the time the first bit of data is
transmitted (delayed due to propagation delay) from station A, if station B requests to send
data and senses the medium it will also find it idle and will also send data. This will result in
collision of data from station A and B.
CSMA access modes
1. 1-persistent: The node senses the channel, if idle it sends the data, otherwise it
continuously keeps on checking the medium for being idle and transmits
unconditionally(with 1 probability) as soon as the channel gets idle.
2. Non-Persistent: The node senses the channel, if idle it sends the data, otherwise it
checks the medium after a random amount of time (not continuously) and transmits
when found idle.
3. P-persistent: The node senses the medium, if idle it sends the data with p probability. If
the data is not transmitted ((1-p) probability) then it waits for some time and checks the
medium again, now if it is found idle then it send with p probability. This repeat
continues until the frame is sent. It is used in Wi-Fi and packet radio systems.
4. O-persistent: Superiority of nodes is decided beforehand and transmission occurs in that
order. If the medium is idle, node waits for its time slot to send data.
3. CSMA/CD
4. CSMA/CA
• Carrier sense multiple access with collision avoidance (CSMA/CA) is a network multiple
access method in which carrier transmission in wireless networks.
• Like wired networks, wireless networks also need to avoid collisions in network.
• In this method when a computer wants to send data it will first sense if there are any other
transmissions happening and if it detects any other transmission, it will wait for a short
amount of time before checking the channel again.
• When it checks the channel again and if it doesn’t sense any transmission it will wait a short
random amount of time and then it will go ahead and send its data
• Once the destination device receives the data, it will respond to the sending computer with
an acknowledgement informing the sender that is has received the data.
• But if the sending computer does not receive an acknowledgment from the destination ,
• In controlled access, devices communicate with each other, and devices consult each other
about which device has the right to send.
• By controlling channel access, network performance is increased, and frame collisions are
reduced.
1. Reservation:
• In the reservation method, a station needs to make a reservation before sending data.
• Time is divided into intervals. In each interval, a reservation frame precedes the data frames
sent in that interval.
• If there are N stations in the system, there are exactly N reservation mini slots in the
reservation frame. Each mini slot belongs to a station. When a station needs to send a data
frame, it makes a reservation in its own mini slot. The stations that have made reservations
can send their data frames after the reservation frame.
• Figure shows a situation with five stations and a five-mini slot reservation frame. In the first
interval, only stations 1, 3, and 4 have made reservations. In the second interval, only station
1 has made a reservation.
2. Polling
• In the polling system, one primary station and several secondary stations are connected on a
single channel. So that, all the data exchange is done through the primary station by
controlling the channel.
• The primary station controls the channel, while the secondary stations follow its instructions
for communication. The primary station decides which station is allowed to access the
channel to communicate.
• The primary station allowed a secondary station to use the channel at a given time to
communicate.
• In simple words, we can say that the primary station is the originator of the communication.
• When the primary station wants to communicate and receive data, it asks secondary
stations if they have data to send, this method is known as polling.
• If a primary station wants to send data, it tells the secondary station that it sends data and
secondary have to be ready, this is known as the select function.
• The diagram below explains the working of polling method and its functions.
• As shown in the figure, there is one primary station and two secondary stations connected
on a channel.
• The primary station wants to send data to secondary station B. It sends the SEL (SELECT)
function to the secondary station.
• When Secondary Station B receives the SEL, it will send an acknowledgment to the Primary
Station to inform that it is ready to receive data.
• Therefore, the primary station sends the data to the secondary station B, and the secondary
station sends a reply acknowledgment for the received data to the primary station.
• Figure on the right side, the primary station wants to receive data from secondary station-A.
Therefore, it will send the poll function to station-A.
• But, station-A sends a negative acknowledgment (NAK), so the primary station will
understand that it does not want to communicate. Therefore, the primary station sends the
poll function to secondary station B.
• As soon as station B receives the poll function, it accepts the primary station’s request for
data. So, in response, station B sends data to the primary station, and the primary station
sends an acknowledgment for the successful arrival of the data.
3. Token Passing
• In token passing, each station has a predecessor and a successor station, they are arranged
in a logical ring. The current station is using the channel for communication, as it gets access
to the channel from the predecessor. This right is passed to the successor station when the
current station does not have data to send on the channel.
• In token passing, a packet called a token passes through the ring, which gives the
station access to the channel.
• The token is transmitted over a channel, and whichever station has the token has
the right to access the channel for communication.
• When a station has data to send, it has to wait until it receives a token from its
predecessor station. Until the data is sent, one station retains the token, and after
completing the task of sending the data, it sends the token to its successor station.
• The station is not able to send data until the token is received again in the next
round.
• On a channel, it may be possible that the station receives the token but has no data
to send, so in this case, it only sends the token to the next station.
• However, in the token passing method, the tokens are monitored to ensure that it is
not lost or destroyed. For example, if a station is holding a token and it fails due to
unavoidable circumstances, the token will disappear from the network.
• Also, the token function assigns priority based on the type of data the station has. To
release the tokens from low-priority stations to high-priority stations, token
management is required.
Channelization
Channelization is a multi access method in which the available bandwidth of a link is shared in
time, frequency or through code to multiple stations to access channel simultaneously.
• The available bandwidth is divided into equal bands so that each station can be allocated its
own band. Guard bands are also added so that no two bands overlap to avoid crosstalk and
noise.
• The FDMA is a data link layer protocol that uses FDM at the physical layer
Time Division Multiple Access (FDMA)
• In TDMA ,the bandwidth is just one channel that is time shared between different stations.
CDMA differs from FDMA because only one channel occupies the entire bandwidth of the link.
If differs from TDMA because all stations can send data simultaneously ;there is no time sharing.
Ethernet
LOCAL AREA NETWORK (LAN) is a computer network that is designed for a limited
geographic area such as a building or a campus. Most LANs today are also linked to a wide
area network (WAN) or the Internet.
The LAN market has seen several technologies such as Ethernet, Token Ring, Token Bus,
FDDI, and ATM LAN. Some of these technologies survived for a while, but Ethernet is by far
the dominant technology.
The IEEE Standard Project 802, designed to regulate the manufacturing and interconnectivity
between different LANs. Ethernet has changed to meet the market needs and to make use
of the new technologies.
It operates in the data link layer and the physical layer.
Ethernet is a network protocol that controls how data is transmitted over a LAN. Technically
it is referred to as the IEEE 802.3 protocol.
It is belongs to the family of networking technologies that are defined in the IEEE 802.11 and
IEEE 802.3 standards.
It supports data bandwidth of 10,100,1000,10,000,40,000 and 100,1000 mbps(100 mbps).
Ethernet is a set of technologies and protocols that are used primarily in LANs. It was first
standardized in 1980s as IEEE 802.3 standard. Ethernet is classified into two categories:
History of Ethernet
The original Ethernet was created in 1976 at Xerox's Palo Alto Research Center (PARC). Since then, it
has gone through four generations:
1. Standard Ethernet
The Standard Ethernet defines several physical layer implementations; four of the most
common
1. 10Base5: Thick Ethernet
Note that the collision here occurs in the thin coaxial cable. This implementation is
more cost effective than 10Base5 because thin coaxial cable is less expensive than
thick coaxial and the tee connections are much cheaper than taps. Installation is
simpler because the thin coaxial cable is very flexible. However, the length of each
segment cannot exceed 185 m (close to 200 m) due to the high level of attenuation in
thin coaxial cable.
• Although there are several types of optical fiber 10-Mbps Ethernet, the most
common is called 10Base-F. 10Base-F uses a star topology to connect stations to a
hub. The stations are connected to the hub using two fiber-optic cables
The common varieties of fast Ethernet are 100-Base-TX, 100-BASE-FX and 100-Base-
T4.
1. 100-Base-T4
o This has four pairs of UTP of Category 3, two of which are bi-directional and
the other two are unidirectional.
o In each direction, three pairs can be used simultaneously for data
transmission.
o Each twisted pair is capable of transmitting a maximum of 25Mbaud data.
Thus the three pairs can handle a maximum of 75Mbaud data.
o It uses the encoding scheme 8B/6T (eight binary/six ternary).
2. 100-Base-TX
o This has either two pairs of unshielded twisted pairs (UTP) category 5 wires
or two shielded twisted pairs (STP) type 1 wires. One pair transmits frames
from hub to the device and the other from device to hub.
o Maximum distance between hub and station is 100m.
o It has a data rate of 125 Mbps.
o It uses MLT-3 encoding scheme along with 4B/5B block coding.
3. 100-BASE-FX
o This has two pairs of optical fibers. One pair transmits frames from hub to
the device and the other from device to hub.
o Maximum distance between hub and station is 2000m.
o It has a data rate of 125 Mbps.
o It uses NRZ-I encoding scheme along with 4B/5B block coding.
3. Gigabit Ethernet
In computer networks, Gigabit Ethernet (GbE) is the family of Ethernet technologies that
achieve theoretical data rates of 1 gigabit per second (1 Gbps). It was introduced in 1999 and
was defined by the IEEE 802.3ab standard.
4. 10-Gigabit Ethernet
In computer networks, 10-Gigabit Ethernet is the family of Ethernet technologies
that achieve maximum rates up to 10 gigabits per second (10 Gbps). It is also known
as 10GE, 10GbE or 10 GigE. It is defined by the IEEE 802.3ae-2002 standard.
10GE is a thousand times faster than standard Ethernet and supports only full-
duplex communication. Multimode fiber having 0.85μ frequency is used for medium
distances and single-mode fiber having 1.5μ frequency is used for long distances.
2.10GBase-LR
3.10GBase-ER
4.10GBase-CX4
4.10GBase-T