You are on page 1of 164

Unit I

Introduction to
Local Area Network
Dr. Madhavi Belsare
CONTENTS

• TCP/IP Protocol Suite


• Media Access Control
• Wired LAN
• Wireless LAN

WCB/McGraw-Hill  The McGraw-Hill Companies, Inc., 1998


Transit Response
Time Time

WCB/McGraw-Hill
• The transit time is the time a message needs to travel from
the originating end of the network to the intended
destination in the network.
• The response time of a network is the time between a user
making a request for a network service and the network
responding to this request.
ISO standard and OSI model

•An ISO standard that covers all aspects of network


communications is the Open Systems Interconnection
(OSI) model.
•First introduced in late 1970s.
•The purpose is to facilitate communication between
different systems without changing underlying
hardware and software.
OSI Model

WCB/McGraw-Hill
Summary of Layer Functions

WCB/McGraw-Hill
OSI model is generic, protocol independent reference
model.

TCP/IP is an implementation of OSI model based on


standard protocols around which internet has
developed.
TCP/IP PROTOCOL SUITE

•The layers in the TCP/IP protocol suite do not exactly


match those in the OSI model.
•The original TCP/IP protocol suite was defined as having
four layers: host-to-network, internet, transport, and
application.
•However, when TCP/IP is compared to OSI, we can say
that the TCP/IP protocol suite is made of five layers:
physical, data link, network, transport, and application.
TCP/IP and OSI model
OSI(Open System TCP/IP(Transmission
Interconnection) Control Protocol / Internet
Protocol)

1. TCP/IP model is based on


1. OSI is a generic, protocol standard protocols around
independent standard, acting as which the Internet has
a communication gateway developed. It is a
between the network and end communication protocol,
user. which allows connection of
hosts over a network.

2. In TCP/IP model the


2. In OSI model the transport transport layer does not
layer guarantees the delivery of guarantees delivery of packets.
packets. Still the TCP/IP model is more
reliable.

3. Follows vertical approach. 3. Follows horizontal


approach.
4. OSI model has a separate 4. TCP/IP does not have a
Presentation layer and Session separate Presentation layer or
layer. Session layer.
OSI(Open System TCP/IP(Transmission Control
Interconnection) Protocol / Internet Protocol)
5. OSI is a reference model
around which the networks are 5. TCP/IP model is, in a way
built. Generally it is used as a implementation of the OSI model.
guidance tool.
6. Network layer of OSI model 6. The Network layer in TCP/IP
provides both connection oriented model provides connectionless
and connectionless service. service.
7. OSI model has a problem of 7. TCP/IP model does not fit any
fitting the protocols into the protocol
model.
8. Protocols are hidden in OSI 8. In TCP/IP replacing protocol is
model and are easily replaced as not easy.
the technology changes.
9. OSI model defines services, 9. In TCP/IP, services, interfaces
interfaces and protocols very and protocols are not clearly
clearly and makes clear distinction separated. It is also protocol
between them. It is protocol dependent.
independent.
Media Access Control(MAC)
• Many protocols are devised to handle access to a shared link.
• All these protocols belong to a sub layer in data link layer called
MAC that are categorized into three groups.
RANDOM ACCESS

In random access or contention methods, no station is


superior to another station and none is assigned the
control over another.

1. ALOHA
2. CSMA
3. CSMA/CD
4. CSMA/CA
Figure 12.3 Frames in a pure ALOHA network
Figure 12.4 Procedure for pure ALOHA protocol
Vulnerable time for pure ALOHA protocol
Average number of successfully transmitted
frames for pure ALOHA

The throughput for pure ALOHA is


S = G × e −2G .
The maximum throughput
Smax = 0.184 when G= (1/2).

G the average number of frames generated by the system


during one frame transmission time.
If one-half a frame is generated during one frame
transmission time (one frame during two frame
transmission times), then 18.4 percent of these
frames reach their destination successfully.
Example 12.3
A pure ALOHA network transmits 200-bit frames on a
shared channel of 200 kbps. What is the throughput if the
system (all stations together) produces

a. 1000 frames per second?


b. 500 frames per second?
c. 250 frames per second?
Solution
The frame transmission time is 200/200 kbps or 1 ms.
a. If the system creates 1000 frames per second, or 1 frame per
millisecond, then G = 1. In this case S = G × e −2G = 0.135 (13.5
percent). This means that the throughput is 1000 × 0.135 = 135 frames.
Only 135 frames out of 1000 will probably survive.
b. If the system creates 500 frames per second, or 1/2 frames per
millisecond, then G = ½. In this case S = G × e −2G = 0.184 (18.4
percent). This means that the throughput is 500 × 0.184 = 92 and that
only 92 frames out of 500 will probably survive. Note that this is the
maximum throughput case, percentagewise.
c. If the system creates 250 frames per second, or 1/4 frames per
millisecond, then G = ¼. In this case S = G × e −2G = 0.152 (15.2
percent). This means that the throughput is 250 × 0.152 = 38. Only 38
frames out of 250 will probably survive.
Frames in a slotted ALOHA network
(to improve efficiency of pure ALOHA)

Time slots: Stations forced to send at


beginning of time slot
Note
The throughput for slotted ALOHA is
S = G × e−G .
The maximum throughput
Smax = 0.368 when G = 1.
Figure 12.7 Vulnerable time for slotted ALOHA protocol
Numerical on Throughput
A slotted ALOHA network transmits 200-bit
frames using a shared channel with a 200-kbps
bandwidth. Find the throughput if the system (all
stations together) produces
a. 1000 frames per second.
b. 500 frames per second.
c. 250 frames per second.
CSMA: Sense before transmit or listen before talk

•The chance of collision can be reduced if a station senses the


medium before trying to use it.

•The possibility of collision still exists because of propagation


delay

•a station may sense the medium and find it idle, only because
the first bit sent by another station has not yet been received
Space/time model of the collision in CSMA
t2> t1 C finds
medium idle.
Vulnerable time in CSMA

A send at t1. Frame reaches at end of medium at


t1 + tp
Persistence Methods

What should a station do if the channel is


busy?
What should a station do if the channel
is idle?
Behavior of three persistence methods
Flow diagram for three persistence methods
https://www.youtube.com/watch?v=iKn0GzF5-IU
CSMA/CD
The CSMA method does not specify the procedure
following a collision.
• (CSMA/CD) augments the algorithm to handle the
collision.
In this method, a station monitors the medium after it
sends a frame to see if the transmission was successful. If
so, the station is finished. If, however, there is a collision,
the frame is sent again.
Collision of the first bit in CSMA/CD
At t2
At t1
Collision and abortion in CSMA/CD
Minimum Frame Size

Restriction on the frame size. Before sending the last bit


of the frame, the sending station must detect a collision, if
any, and abort the transmission.
This is so because the station does not keep a copy of the
frame.
Therefore, the frame transmission time Tfr must be at least
two times the maximum propagation time Tp.
Example 12.5

A network using CSMA/CD has a bandwidth of 10 Mbps. If the


maximum propagation time is 25.6 μs, what is the minimum size of
the frame?

Solution
The frame transmission time is Tfr = 2 × Tp = 51.2 μs. This means, in
the worst case, a station needs to transmit for a period of 51.2 μs to
detect the collision. The minimum size of the frame is 10 Mbps ×
51.2 μs = 512 bits or 64 bytes.

** This is actually the minimum size of the frame for Standard


Ethernet.
Flow diagram for the CSMA/CD

Jamming Signal to convey collision to other stations.


Energy level during transmission, idleness, or collision

Energy level twice the


normal

A station that has a frame to send or is sending a frame


needs to monitor the energy level to determine if the
channel is idle, busy, or in collision mode.
CSMA –CA
Carrier Sense Multiple Access With Collision Avoidance
• Interframe Space (IFS) :
When an idle channel is found, the station does not send
immediately. It waits for a period of time called the interframe space or
IFS.
The IFS time allows the front of the transmitted signal by the
distant station to reach this station.
The IFS variable can also be used to prioritize stations or frame
types. For example, a station that is assigned a shorter IFS has a higher
priority.
•Contention Window.
The contention window is an amount of time divided
into slots.
A station that is ready to send chooses a random
number of slots as its wait time.
The number of slots in the window changes
according to the binary exponential backoff strategy.
•Acknowledgment.
With all these precautions, there still may be a collision
resulting in destroyed data. data may be corrupted during
the transmission.
The positive acknowledgment and the time-out timer
can help guarantee that the receiver has received the
frame.
Timing in CSMA/CA
Flow diagram for
CSMA/CA
DIFS: Distributed IFS
RTS: Request To Send CTS: Clear To Send
SIFS: Short Inter frame Space time
NAV: Network Allocation Vector
As one station has acquired access, other stations have to
wait. They create a timer called a network allocation
vector (NAV) that shows how much time must pass
before these stations are allowed to check the channel for
idleness.
Each time a station accesses the system and sends an
RTS frame telling duration of channel access. Based on
this, other stations start their NAV.
CONTROLLED ACCESS

In 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.

1. Reservation
2. Polling
3. Token Passing
Reservation Access

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.
Reservation access method

Start Frame

If there are N stations in the system, there are exactly N


reservation minislots in the reservation frame. Each
minislot belongs to a station. When a station needs to send
a data frame, it makes a reservation in its own minislot.
Polling
Polling works with topologies in which one device is
designated as a primary station and the other devices are
secondary stations.
All data exchanges must be made through the primary
device even when the ultimate destination is a secondary
device.
The primary device controls the link; the secondary devices
follow its instructions.
Select and poll functions in polling access method

Select Poll
Token Passing
•stations in a network are organized in a logical ring.
In other words, for each station, there is a predecessor and a
successor.
•a special packet called a token circulates through the ring.
• When a station has some data to send, it waits until it
receives the token from its predecessor.
•It then holds the token and sends its data.
•When the station has no more data to send, it releases the
token, passing it to the next logical station in the ring.
Logical ring and physical topology
in token-passing access method
CHANNELIZATION

Available bandwidth of a link is shared in time,


frequency, or through code, between different stations.

1. Frequency-Division Multiple Access (FDMA)


2. Time-Division Multiple Access (TDMA)
3. Code-Division Multiple Access (CDMA)
Frequency-division multiple access (FDMA)
In FDMA, the available bandwidth
of the common channel is divided into bands
that are separated by guard bands.
Time-division multiple access (TDMA)
In TDMA, the bandwidth is just one channel
that is timeshared between different stations.
Oral Question:
Compare TDMA with TDM and FDMA with
FDM with reference to computer Networks.
Code Division Multiple Access (CDMA)

In CDMA, one channel carries all transmissions


simultaneously.

The assigned codes have two properties.


1. If we multiply each code by another, we get 0.
2. If we multiply each code by itself, we get the
number of stations.
Simple idea of communication with code
Chip sequences

CDMA is based on coding theory. Each station is


assigned a code, which is a sequence of numbers called
chips,
They are called orthogonal sequences and have the
following properties:
1. Each sequence is made of N elements, where N is the
number of stations.
2. If we multiply a sequence by a number, every element
in the sequence is multiplied by that element.
This is called multiplication of a sequence by a scalar. For
example, 2 • [+1 +1 −1 −1] = [+2 +2 −2 −2]
3. The inner product of two equal sequences.
[+1 +1 −1 −1] • [+1 +1 −1 −1] = 1 + 1 + 1 + 1 = 4
= N, no. of elements in sequence= No. of stations
4. Inner product of two different sequences.
[+1 +1 −1 −1] • [+1 +1 +1 +1] = 1 + 1 − 1 − 1 = 0
5. Adding two sequences
[+1 +1 −1 −1] + [+1 +1 +1 +1] = [+2 +2 0 0]
Sharing channel in CDMA
Digital signal created by four stations in CDMA
Decoding of the composite signal for one in CDMA
General rule and examples of creating Walsh tables
Fig. 1

Each row represents sequence of chips


Two Basic rules

1. one-chip sequence has one row and one


column

2. If we know the table for N sequences WN


, we can create the table for 2N
sequences W2N
The number of sequences in a Walsh table needs
to be N = 2m.
Example 12.6

Find the chips for a network with


a. Two stations b. Four stations

Solution
We can use the rows of W2 and W4 from Fig. 1
a. For a two-station network, we have
[+1 +1] and [+1 −1].

b. For a four-station network we have


[+1 +1 +1 +1], [+1 −1 +1 −1],
[+1 +1 −1 −1], and [+1 −1 −1 +1].
Example 12.7

What is the number of sequences if we have 90 stations in


our network?

Solution
The number of sequences needs to be 2m. We need to
choose m = 7 and N = 27 or 128.
We can then use 90 of the sequences as the chips.
Example 12.8

Prove that a receiving station can get the data sent by a


specific sender if it multiplies the entire data on the channel
by the sender’s chip code and then divides it by the number
of stations.

Solution
Let us prove this for the first station, using our previous
four-station example. We can say that the data on the
channel
D = (d1 ⋅ c1 + d2 ⋅ c2 + d3 ⋅ c3 + d4 ⋅ c4).
The receiver which wants to get the data sent by station 1
multiplies these data by c1.
Example 12.8 (continued)

When we divide the result by N, we get d1 .


1. Check to see if the following set of chips can belong to
an orthogonal system.

[+1, +1] and [+1, −1]

2. Alice and Bob are experimenting with CDMA using a


W2 Walsh table

Alice uses the code [+1, +1] and


Bob uses the code [+1, −1].
Assume that they simultaneously send a hexadecimal digit
to each other. Alice sends (6)16 and Bob sends (B)16

Show how they can detect what the other person has sent.
Quiz Time

https://quizizz.com/join/quiz/5f2f70bf906409001b05d487/start
IEEE has subdivided data link layer into two sub layers : LLC
and MAC
LLC protocol can provide interconnectivity between different
LANs because it makes the MAC sub layer transparent
Logical Link Control
•Flow Control
•Error Control
•Part of framing duties
MAC
•Part of framing function
Defines different access methods for different LANs
•CSMA/CD for Ethernet LAN
•Token passing method for token ring and token bus
LAN
Standard Ethernet Characteristics:

• Connectionless and Unreliable Service


• connectionless service: each frame sent is independent
of the previous or next frame.
• unreliable:
•If a frame is corrupted during transmission and the
receiver finds out about the corruption, which has a high
level of probability of happening because of the CRC-32,
the receiver drops the frame silently. It is the duty of
high-level protocols to find out about it.
Physical Layer Header

Preamble for synchronization.


Type: defines upper layer protocol, IP/ARP…
CRC 32 for error detection. If the receiver calculates
the CRC and finds that it is not zero (corruption in transmission), it
discards the frame.
Minimum frame length: 64 bytes
Maximum frame length: 1518 bytes

Minimum data length: 46 bytes


Maximum data length: 1500 bytes
Source address is always Unicast Address. (Frame comes only
from one station)
Destn. Addr. : Unicast,Multicast, Broadcast
Multicast address is a logical identifier for a group of hosts in a
computer network.
Transmission in std ethernet is always broadcast.
10BaseX : 10 = 10Mbps; Base: Baseband i.e. Digital Signal
X= 5: 500 meters; 2= 200 metres; T =Unshielded
Twisted Pair; F= Fiber Optic
(Thick Ethernet or Thicknet)
(Thin Ethernet or Cheapernet)
1. Capacity shared by each station= 10/12 Mbps

2. Capacity shared by each station= 10/7 Mbps


Collision Domain smaller so less probability of collision
FAST ETHERNET (100 MBPS)

Goals of Fast Ethernet


1. Upgrade the data rate to 100 Mbps.
2. Make it compatible with Standard Ethernet.
3. Keep the same 48-bit address.
4. Keep the same frame format.
Auto negotiation

• allows two devices to negotiate the mode or data


rate of operation.
Access Method

If the minimum frame size is still 512 bits, and it is


transmitted 10 times faster, the collision needs to be detected
10 times sooner, which means the maximum length of the
network should be 10 times shorter (the propagation speed
does not change).
Two solutions
1. use a passive hub and star topology but make the
maximum size of the network 250 meters instead of
2500 meters as in the Standard Ethernet. This approach
is kept for compatibility with the Standard Ethernet.

2. The second solution is to use a link-layer switch


with a buffer to store frames and a full-duplex
connection to each host to make the transmission
medium private for each host. No need for CSMA/CD
Block Coding
• Division : In the division step, a sequence of bits is divided into
groups of m bits. For example, in 4B/5B encoding, the original bit
sequence is divided into 4-bit groups.

• Substitution: In substitution step, we substitute an m-bit group for


an n-bit group. For example, in 4B/5B encoding we substitute a 5-
bit code for a 4-bit group.

• Combination: The n-bit groups are combined together to form a


stream. The new stream has more bits than the original bits.
Substitution in 4B/5B block
coding

111
Multitransition: MLT-3 scheme
1. If the next bit is 0, there is no transition.
2. If the next bit is 1 and the current level is not 0, the next level is 0.
3. If the next bit is 1 and the current level is 0, the next level is the
opposite of the last nonzero level.

The signal rate is the same as that for NRZ-I, but with greater complexity
(three levels and complex transition rules). It turns out that the shape of
the signal in this scheme helps to reduce the required bandwidth.
8B/6T
• 8 data bits are sent as 6 ternary (one of three voltage levels).

• The incoming data stream is split into 8 bit patterns.

• Each 8 bit pattern with two voltage levels 0 volts and V


volts is examined.

• This 8 bit pattern is then converted into a 6 bit pattern but


using three voltage levels –V, 0 and V volts.
GIGABIT ETHERNET Standard 802.3z.

Goals of the Gigabit Ethernet

1. Upgrade the data rate to 1 Gbps.


2. Make it compatible with Standard or Fast Ethernet.
Use the same 48-bit address.
4. Use the same frame format.
5. Keep the same minimum and maximum frame lengths.
6. Support auto negotiation as defined in Fast Ethernet.
SX: Short Range Fiber
LX: Long Range Fiber
CX: Short haul Copper
Encoding Explained

8B10B: 8bit symbol to 10bit symbol

4DPAM5: 4 dimensional five level PAM with levels

-2,-1,0,1,2Volts

Four symbols transmitted simultaneously on four pair of


wires.
SR: Short Range (Multimode fiber 300m), LR: Long
reach(Single mode fiber 10km) EW: Extended reach for
SONET
Wireless LAN : IEEE 802.11 project
A BSS without an AP is called an ad hoc
network;
a BSS with an AP is called an infrastructure
network.

BSS : Basic Service Set :made of stationary or mobile wireless


stations and an optional central base station, known as the access
point (AP).
AP: Access Point
Figure 14.2 Extended service sets (ESSs)
Figure 14.3 MAC layers in IEEE 802.11 standard

DCF uses CSMA/CA


Point Coordination Function (PCF)

•an optional access method that can be implemented in an


infrastructure network. It is implemented on top of the
DCF and is used mostly for time-sensitive transmission.
•PCF has a centralized, contention-free polling access
method
•The AP performs polling for stations that are capable of
being polled. The stations are polled one after another,
sending any data they have to the AP.
MAC layer frame
Subfields in FC field
• D. This field defines the duration of the transmission that is used to set the
value of NAV. In one control frame, it defines the ID of the frame.
• Addresses. There are four address fields, each 6 bytes long. The meaning
of each address field depends on the value of the To DS and From DS
subfields
• Sequence control. This field, often called the SC field, defines a 16-bit
value. The first four bits define the fragment number; the last 12 bits
define the sequence number, which is the same in all fragments.
• Frame body. This field, which can be between 0 and 2312 bytes, contains
information based on the type and the subtype defined in the FC field.
• FCS. The FCS field is 4 bytes long and contains a CRC-32 error-detection
• sequence.
Frame types

1. Management frame
2. Data frame
3. Control Frame
For control frames the value of the type field is 01
Control frame format
Values of subfields in control frames
Addresses
Addressing mechanisms
Case 1: 00 In this case, To DS = 0 and From DS = 0. This means that the frame is
not going to a distribution system (To DS = 0) and is not coming from a
distribution system (From DS = 0). The frame is going from one station in a BSS
to another without passing through the distribution system.
Case 2: 01 In this case, To DS = 0 and From DS = 1. This means that the frame is
coming from a distribution system (From DS = 1). The frame is coming from an
AP and going to a station.
Case 3: 10 In this case, To DS = 1 and From DS = 0. This means that the frame
is going to a distribution system (To DS = 1). The frame is going from a station
to an AP. The ACK is sent to the original station.
Case 4: 11 In this case, To DS = 1 and From DS = 1. This is the case in which the
distribution system is also wireless. The frame is going from one AP to another
AP in a wireless distribution system.
Hidden station problem

Station B and C are not in each other’s range


Collision may occur but not be detected.
The CTS frame in CSMA/CA handshake can
prevent collision from
a hidden station.
Figure 14.11 Use of handshaking to prevent hidden station problem
Exposed station problem
handshaking in exposed station problem
Physical layer Specifications

802.11n MIMO
Figure 14.14 Industrial, scientific, and medical (ISM) band
Figure 14.15 Physical layer of IEEE 802.11 FHSS
Figure 14.16 Physical layer of IEEE 802.11 DSSS
Figure 14.17 Physical layer of IEEE 802.11 infrared
Figure 14.18 Physical layer of IEEE 802.11b
BLUETOOTH - IEEE 802.15.1

• Bluetooth is a wireless LAN technology designed to


connect devices of different functions such as
telephones, notebooks, computers, cameras, printers,
coffee makers, and so on.
• A Bluetooth LAN is an ad hoc network, which means
that the network is formed spontaneously.

•Bluetooth defines two types of networks piconet and


scatternet.
Piconet : Small Net

Can have upto 8 stations. One primary other secondaries. Additional secondaries
can be in parked state. For communication at a time 7 secondaries can be in
active state.
Scatternet (piconets combined together)

Secondary in piconet can be primary in scatternet.


Bluetooth Devices

• A Bluetooth device has a built-in short-range radio


transmitter.
• The current data rate is 1 Mbps with a 2.4-GHz
bandwidth.
• This means that there is a possibility of interference
between the IEEE 802.11b wireless LANs and
Bluetooth LANs.
Bluetooth layers / Architecture

L2CAP: Logical Link Control and Adaptation Protocol : Roughly equivalent to LLC
sublayer in wired LAN
The L2CAP has specific duties: multiplexing, segmentation and reassembly, quality of
service (QoS), and group management.
Baseband Layer

The baseband layer is roughly equivalent to the MAC sub


layer in LANs. The access method is TDMA

TDMA
TDD-TDMA is a kind of half-duplex Communication in which the
sender and receiver send and receive data, but not at the same
time (half-duplex); however, the communication for each
direction uses different hops. This is similar to walkie-talkies using
different carrier frequencies.
Radio Layer: Physical layer, max range : 10m
Band: 2.4 GHz band divided into 79 channels of 1MHz each.
Uses FHSS at Physical layer (1600 hops per second)
Modulation: GFSK: FSK with Gaussian Bandwidth Filtering

Link Manager Protocol (LMP) − LMP establishes logical links between


Bluetooth devices and maintains the links for enabling communications.
The other main functions of LMP are device authentication, message
encryption, and negotiation of packet sizes
Service Discovery Protocol (SDP)− SDP takes care of service-related
queries like device information so as to establish a connection between
contending Bluetooth devices.
AT Commands − ATtention command set.
Single-Secondary Communication

If the piconet has only one secondary, the TDMA operation is very
simple.
The time is divided into slots of 625 μs. The primary uses even-
numbered slots (0, 2, 4, . . .); the secondary uses odd-numbered slots
(1, 3, 5, . . .).
TDD-TDMA : half-duplex mode.
In slot 0, the primary sends and the secondary receives
In slot 1, the secondary sends and the primary receives. The cycle is
repeated.
Figure 14.22 Single-secondary communication
Multiple-Secondary Communication

Again, the primary uses the even-numbered slots, but a


secondary sends in the next odd-numbered slot if the packet
in the previous slot was addressed to it.

All secondaries listen on even-numbered slots, but only one


secondary sends in any odd-numbered slot. Figure shows a
scenario.
Figure 14.23 Multiple-secondary communication
Contents beyond Syllabus
Bluetooth vs. WiFi vs. ZigBee vs. Others

COPYRIGHT © 2012 DSR CORPORATION 162


TCP/IP Protocol Suite T1 35-45

Media Access Control: Random Access, T1 325-352


Controlled Access, Channelization. Chapter 12

Wired LAN: Ethernet Protocol, Standard T1 361-383


Ethernet, Fast Ethernet, Gigabit Ethernet, Chapter 13
10 Gigabit Ethernet.
Introduction, Wireless LANS: IEEE 802.11 T1 435-458
project, Bluetooth, Zigbee Chapter 15
Thank You!

You might also like