You are on page 1of 17

1)Explain the media access control algorithm, CSMA/CD used in Ethernet, Why the same

algorithm cannot be used in wireless LAN?


Media Access Control
Media access control (MAC) protocols enforce a methodology to allow multiple devices access to
a shared media network. Before LANs, communication between computing devices had been
point-to-point. That is, two devices were connected by a dedicated channel. LANs are shared
media networks, in which all devices attached to the network receive each transmission and must
recognize which frames they should accept. Media sharing reduced the cost of the network, but
also meant that MAG protocols were needed to coordinate use of the medium.
CSMA/CD used in Ethernet, Why the same algorithm cannot be used in wireless LAN?
This is because the nodes A and C are out of range of each other(and so cannot detect a collision
while transmitting). Thus, Carrier sense multiple access with collision detection (CSMA/CD) does
not work, and collisions occur. The data received by the access point is corrupted due to the
collision.

Explanation:
Collision Avoidance in wireless networks
We take a close look at so-called WiFi which is also known as IEEE standard 802.11

Consider the situation depicted in the figure, where each of four nodes is able to send and receive
signals that reach just the nodes to its immediate left and right.
For example, B can exchange frames with A and C but it cannot reach D, while C can reach B and
D but not A. (A and D’s reach is not shown in the figure.) Suppose both A and C want to
communicate with B and so they each send it a frame. A and C are unaware of each other since
their signals do not carry that far. These two frames collide with each other at B, but unlike an
Ethernet, neither A nor C is aware of this collision. A and C are said to be hidden nodes with
respect to each other.
According to Wikipedia, the hidden node problem can be defined as “In wireless networking,
the hidden node problem or hidden terminal problem occurs when a node is visible to a wireless
access point (AP), but not to other nodes communicating with that AP.”
Collision cannot be detected in hidden node problem

This is because the nodes A and C are out of range of each other(and so cannot detect a collision
while transmitting). Thus, Carrier sense multiple access with collision detection (CSMA/CD) does
not work, and collisions occur. The data received by the access point is corrupted due to the
collision. To overcome the hidden node problem, RTS/CTS handshaking (IEEE 802.11 RTS/CTS)
is implemented in addition to the Carrier sense multiple access with collision avoidance
(CSMA/CA) scheme.

A related problem, called the exposed node problem, occurs under the following stated
circumstances:
Suppose B is sending to A (as in the above Figure). Node C is aware of this communication
because it hears B’s transmission. It would be a mistake for C to conclude that it cannot transmit
to anyone just because it can hear B’s transmission.
For example, suppose C wants to transmit to node D. This is not a problem since C’s transmission
to D will not interfere with A’s ability to receive from B.
We address these problems by an algorithm known as Multiple Access with Collision Avoidance
(MACA). The sender and receiver exchange frames with each other before transmitting data. This
informs all nearby nodes that a transmission is about to begin. Sender transmits Request to Send
(RTS) frame to receiver .

The receiver then replies with clear to send (CTS) frame back to the sender. Any node that
receives CTS frame knows that it is close to the receiver, therefore, cannot transmit a frame. Any
node that receives RTS frame but not the CTS frame knows that is not close to the receiver to
interfere with it, So it is free to transmit data.

2) Explain the medium access control protocols in detail.


Media access control (MAC) protocols enforce a methodology to allow multiple devices access to
a shared media network. Before LANs, communication between computing devices had been
point-to-point. That is, two devices were connected by a dedicated channel. LANs are shared
media networks, in which all devices attached to the network receive each transmission and must
recognize which frames they should accept. Media sharing reduced the cost of the network, but
also meant that MAG protocols were needed to coordinate use of the medium. There are two
approaches to media access control in LANs: contention and token-passing.
Contention is a first-come, first-serve approach. Carrier sense multiple access/collision detection
(CSMA/CD) is the most used contention-based MAC protocol, used in Ethernet networks. When
a device must transmit, the NIC monitors the network to determine whether or not another device
is transmitting. The NIC cannot transmit if it senses electrical signals on the network that indicate
another device is transmitting. Due to propagation delay (the time it takes a signal to reach a point
from its sender), it is possible for two stations to transmit simultaneously or almost simultaneously,
causing a collision and garbling the messages. When the sending NIC senses that the message
propagating along the network is not identical to that which it is transmitting, transmission ceases.
The sending NICs then wait a random amount of time before resending the data. The busier a
network is, the more often collisions occur and the longer it takes to transmit data.
CSMA/CA (Collision Avoidance) is a contention method designed to prevent collisions. In
CSMA/CA, the NIC monitors the line for a longer time and the line must be idle for a specified
period before a station can transmit. A short handshaking packet is then sent before the message.
If there is a collision due to simultaneous transmissions, only the handshaking packets collide and
the sending stations wait and try again. CSMA/CA is used in wireless networks, since devices are
farther apart in a wireless network than in a wired LAN.

Carrier Sense Multiple Access (CSMA)

This method was developed to decrease the chances of collisions when two or more stations start
sending their signals over the datalink layer. Carrier Sense multiple access requires that each
station first check the state of the medium before sending.
Vulnerable Time –
Vulnerable time = Propagation time (Tp)

Carrier Sense Multiple Access with Collision Detection (CSMA/CD)


In this method, a station monitors the medium after it sends a frame to see if the transmission was
successful. If successful, the station is finished, if not, the frame is sent again.

In the diagram, A starts send the first bit of its frame at t1 and since C sees the channel idle at t2,
starts sending its frame at t2. C detects A’s frame at t3 and aborts transmission. A detects C’s frame
at t4 and aborts its transmission. Transmission time for C’s frame is therefore and for
A’s frame is .
So, the frame transmission time (Tfr) should be at least twice the maximum propagation time (Tp).
This can be deduced when the two stations involved in collision are maximum distance apart.
Process –
The entire process of collision detection can be explained as follows:
2. Carrier Sense Multiple Access with Collision Avoidance (CSMA/CA) –

The basic idea behind CSMA/CA is that the station should be able to receive while transmitting to
detect a collision from different stations. In wired networks, if a collision has occurred then the
energy of received signal almost doubles and the station can sense the possibility of collision. In
case of wireless networks, most of the energy is used for transmission and the energy of received
signal increases by only 5-10% if a collision occurs. It can’t be used by the station to sense
collision. Therefore CSMA/CA has been specially designed for wireless networks.
These are three types of strategies:
1. InterFrame Space (IFS) – When a station finds the channel busy, it waits for a period
of time called IFS time. IFS can also be used to define the priority of a station or a
frame. Higher the IFS lower is the priority.
2. Contention Window – It is the amount of time divided into slots.A station which is
ready to send frames chooses random number of slots as wait time.
3. Acknowledgments – The positive acknowledgments and time-out timer can help
guarantee a successful transmission of the frame.
Process –
The entire process for collision avoidance can be explained as follows:

3) Explain the architecture of IEEE 802.11 Wireless LAN.

Wireless LANs are those Local Area Networks that use high frequency radio waves instead of
cables for connecting the devices in LAN. Users connected by WLANs can move around within
the area of network coverage. Most WLANs are based upon the standard IEEE 802.11 or WiFi.
IEEE 802.11 Architecture
The components of an IEEE 802.11 architecture are as follows
1) Stations (STA) − Stations comprise all devices and equipments that are connected to the
wireless LAN. A station can be of two types:

• Wireless Access Pointz (WAP) − WAPs or simply access points (AP) are generally
wireless routers that form the base stations or access.
• Client. − Clients are workstations, computers, laptops, printers, smartphones, etc.
Each station has a wireless network interface controller.
2) Basic Service Set (BSS) −A basic service set is a group of stations communicating at physical
layer level. BSS can be of two categories depending upon mode of operation:

• Infrastructure BSS − Here, the devices communicate with other devices through access
points.
• Independent BSS − Here, the devices communicate in peer-to-peer basis in an ad hoc
manner.
3) Extended Service Set (ESS) − It is a set of all connected BSS.
4) Distribution System (DS) − It connects access points in ESS.

(or)
Advantages of WLANs

• They provide clutter free homes, offices and other networked places.
• The LANs are scalable in nature, i.e. devices may be added or removed from the network
at a greater ease than wired LANs.
• The system is portable within the network coverage and access to the network is not
bounded by the length of the cables.
• Installation and setup is much easier than wired counterparts.
• The equipment and setup costs are reduced.
Disadvantages of WLANs

• Since radio waves are used for communications, the signals are noisier with more
interference from nearby systems.
• Greater care is needed for encrypting information. Also, they are more prone to errors. So,
they require greater bandwidth than the wired LANs.
• WLANs are slower than wired LANs.

4) Discuss the MAC layer functions of IEEE802.11.

IEEE 802.11 MAC sub-layer is responsible for coordinating access to the shared physical air
interface so that the Access Point (AP) and Wi-Fi stations in range can communicate
effectively. MAC takes data from a higher sub-layer called LLC, adds header and tail bytes, and
sends them to lower physical layer for transmission. The reverse happens when receiving data
from the physical layer. If a frame is received in error, MAC can retransmit it.

Multiple access is based on carrier sensing, channel contention and random backoff. Due to
contention, a Wi-Fi network with a large number of active stations can suffer from low throughput
and high latency. IEEE 802.11e and its subset Wi-Fi Multimedia attempt to alleviate this problem.

MAC stands for "Medium Access Control", which implies that it's main function is to control
access to a shared medium. The air interface is a shared medium through which all multiple Wi-
Fi stations and access point (AP) attempt to transfer data. MAC implements the control
mechanisms that allow multiple devices to reliably communicate by sharing the medium as
specified in the standard.

Formally, MAC functions include scanning, authentication, association, power saving and
fragmentation.
Note: MAC protocol used in IEEE 802.11 std is CSMA/CA

Explain about CSMA/CA.

5) Draw the datagram format of IPv4 and explain function of each field in detail.
IPv4 Header Format:
IPv4 is a connectionless protocol used for packet-switched networks. It operates on a best effort
delivery model, in which neither delivery is guaranteed, nor proper sequencing or avoidance of
duplicate delivery is assured. Internet Protocol Version 4 (IPv4) is the fourth revision of the
Internet Protocol and a widely used protocol in data communication over different kinds of
networks. IPv4 is a connectionless protocol used in packet-switched layer networks, such as
Ethernet. It provides a logical connection between network devices by providing identification for
each device. There are many ways to configure IPv4 with all kinds of devices – including manual
and automatic configurations – depending on the network type.
IPv4 is defined and specified in IETF publication RFC 791.
IPv4 uses 32-bit addresses for Ethernet communication in five classes: A, B, C, D and E. Classes
A, B and C have a different bit length for addressing the network host. Class D addresses are
reserved for military purposes, while class E addresses are reserved for future use.
IPv4 uses 32-bit (4 byte) addressing, which gives 232 addresses. IPv4 addresses are written in the
dot-decimal notation, which comprises of four octets of the address expressed individually in
decimal and separated by periods, for instance, 192.168.1.5.

IPv4 Datagram Header


Size of the header is 20 to 60 bytes.

VERSION: Version of the IP protocol (4 bits), which is 4 for IPv4


HLEN: IP header length (4 bits), which is the number of 32 bit words in the header. The minimum
value for this field is 5 and the maximum is 15.
Type of service: Low Delay, High Throughput, Reliability (8 bits)
Total Length: Length of header + Data (16 bits), which has a minimum value 20 bytes and the
maximum is 65,535 bytes.
Identification: Unique Packet Id for identifying the group of fragments of a single IP datagram (16
bits)
Flags: 3 flags of 1 bit each : reserved bit (must be zero), do not fragment flag, more fragments flag
(same order)
Fragment Offset: Represents the number of Data Bytes ahead of the particular fragment in the
particular Datagram. Specified in terms of number of 8 bytes, which has the maximum value of
65,528 bytes.
Time to live: Datagram’s lifetime (8 bits), It prevents the datagram to loop through the network by
restricting the number of Hops taken by a Packet before delivering to the Destination.
Protocol: Name of the protocol to which the data is to be passed (8 bits)
Header Checksum: 16 bits header checksum for checking errors in the datagram header

Source IP address: 32 bits IP address of the sender


Destination IP address: 32 bits IP address of the receiver
Option: Optional information such as source route, record route. Used by the Network administr
ator to check whether a path is working or not.
Due to the presence of options, the size of the datagram header can be of variable length (20 bytes
to 60 bytes).

6) Outline the working principle of Bluetooth technology.


It is a Wireless Personal Area Network (WPAN) technology and is used for exchanging data over
smaller distances. This technology was invented by Ericson in 1994. It operates in the unlicensed,
industrial, scientific and medical (ISM) band at 2.4 GHz to 2.485 GHz. Maximum devices that can
be connected at the same time are 7. Bluetooth ranges upto 10 meters. It provides data rates upto
1 Mbps or 3 Mbps depending upon the version. The spreading technique which it uses is FHSS
(Frequency hopping spread spectrum). A bluetooth network is called piconet and a collection of
interconnected piconets is called scatternet.
Bluetooth Architecture:
The architecture of bluetooth defines two types of networks:
1. Piconet
2. Scatternet

Piconet:

Piconet is a type of bluetooth network that contains one primary node called master node
and seven active secondary nodes called slave nodes. Thus, we can say that there are total of 8
active nodes which are present at a distance of 10 metres. The communication between the primary
and secondary node can be one-to-one or one-to-many. Possible communication is only between
the master and slave; Slave-slave communication is not possible. It also have 255 parked nodes,
these are secondary nodes and cannot take participation in communication unless it get converted
to the active state.
Scatternet:
It is formed by using various piconets. A slave that is present in one piconet can be act as master
or we can say primary in other piconet. This kind of node can receive message from master in one
piconet and deliver the message to its slave into the other piconet where it is acting as a slave. This
type of node is refer as bridge node. A station cannot be master in two piconets.
Bluetooth protocol stack:

1. Radio (RF) layer:


It performs modulation/demodulation of the data into RF signals. It defines the
physical characteristics of bluetooth transceiver. It defines two types of physical link:
connection-less and connection-oriented.

2. Baseband Link layer:


It performs the connection establishment within a piconet.

3. Link Manager protocol layer:


It performs the management of the already established links. It also includes
authentication and encryption processes.

4. Logical Link Control and Adaption protocol layer:


It is also known as the heart of the bluetooth protocol stack. It allows the
communication between upper and lower layers of the bluetooth protocol stack. It
packages the data packets received from upper layers into the form expected by lower
layers. It also performs the segmentation and multiplexing.
5. SDP layer:
It is short for Service Discovery Protocol. It allows to discover the services available
on another bluetooth enabled device.

6. RF comm layer:
It is short for Radio Frontend Component. It provides serial interface with WAP and
OBEX.

7. OBEX:
It is short for Object Exchange. It is a communication protocol to exchange objects
between 2 devices.

8. WAP:
It is short for Wireless Access Protocol. It is used for internet access.

9. TCS:
It is short for Telephony Control Protocol. It provides telephony service.

10. Application layer:


It enables the user to interact with the application.

Advantages:

• Low cost.
• Easy to use.
• It can also penetrate through walls.
• It creates an adhoc connection immediately without any wires.
• It is used for voice and data transfer.
Disadvantages:

• It can be hacked and hence, less secure.


• It has slow data transfer rate: 3 Mbps.
• It has small range: 10 meters.
7)Explain about Wired Ethernet
8) Briefly discuss some of the collision avoidance strategies in CSMA/CA. What is the purpose of
NAV in CSMA/CA?
The network allocation vector (NAV) is a virtual carrier sensing mechanism that forms an
important part of the carrier sense multiple access with collision avoidance (CSMA/CA). It is
implemented in wireless network protocols, IEEE 802.11 and IEEE 802.16, which operates in the
medium access control (MAC) layer.
Technique
The network allocation vector can be considered as a counter that counts down to zero. The
maximum NAV duration is the transmission time required by frame, which is the the time for
which the channel will be busy. At the start of transmission of a frame, the NAV value is set to its
maximum. A non-zero value indicates that the channel is busy, and so no station contends for it.
When the NAV value decrements to 0, it indicates that the channel is free and the other stations
can contend for it.
The following diagram shows NAV used in wireless data communication −
9) Explain how hidden and exposed station problems are addressed in wireless LANs?
We address these problems by an algorithm known as Multiple Access with Collision Avoidance
(MACA). The sender and receiver exchange frames with each other before transmitting data. This
informs all nearby nodes that a transmission is about to begin. Sender transmits Request to Send
(RTS) frame to receiver .

The receiver then replies with clear to send (CTS) frame back to the sender. Any node that
receives CTS frame knows that it is close to the receiver, therefore, cannot transmit a frame. Any
node that receives RTS frame but not the CTS frame knows that is not close to the receiver to
interfere with it, So it is free to transmit data.
10) There are two popular technologies for LAN design, namely IEEE 802.3 Ethernet and IEEE
802.11 WiFi. Use your knowledge of these technologies to answer the following questions:
(i)What Datalink layer service model is provided by each of these LAN technologies? How are
they similar? How are they different?
(ii)List three similarities about LLC frames in Ethernet and WiFi. (iii)Which of these two LAN
technologies has the higher bit error rate, and Why?
(iv)Which LAN technology provides better support for mobile users, and how?
11) (i) Compare the medium of a wired LAN with that of a wireless LAN in today’s
communication environment. Explain why the MAC protocol is more important in wireless LANs
than in wired LANs?
(ii) Explain briefly why collision is an issue in random access protocols but not in controlled access
protocols or channelization protocols.
Three categories of multiple access protocols are random access controlled access channelization
2) Random access: In random access or contention methods, no station is superior to anotherstation
and none is assigned the control over another. Protocols ALOHA. Carrier Sense Multiple Access.
Carrier Sense Multiple Access with Collision Detection 3) Controlled access: the stations consult
one another to find which station has the right to send. A station cannot send unless it has been
authorized by other stations. There are 3 protocols reservation polling token passing 4)
Channelization: is a multiple-access method

You might also like