BEC702 – COMPUTER NETWORKS & Protocols
.IN
C
N
SY
U
VT
DEPT. of ECE, ATMECE Page 1
Studied smart, not hard — thanks to [Link]
BEC702 – COMPUTER NETWORKS & Protocols
MODULE 1
Data communications
When we communicate, we are sharing information. This sharing can be local or remote.
Between individuals,
local communication usually occurs face to face, while remote communication takes place over
distance.
The term telecommunication, which includes telephony, telegraphy, and television, means
communication at a distance (tele is Greek for ―far‖). The word data refers to information
presented in whatever form is agreed upon by the parties creating and using the data.
.IN
Data communications are the exchange of data between two devices via some form of
transmission medium such as a wire cable. For data communications to occur, the
communicating devices must be part of a communication system made up of a combination of
hardware (physical equipment) and software (programs). The effectiveness of a data
C
communications system depends on four fundamental characteristics: delivery, accuracy,
timeliness, and jitter.
N
1. Delivery-The system must deliver data to the correct destination. Data must be received by
SY
the intended device or user and only by that device or user.
2. Accuracy- The system must deliver the data accurately. Data that have been altered in
transmission and left uncorrected are unusable.
U
3. Timeliness. The system must deliver data in a timely manner. Data delivered late are useless.
VT
In the case of video and audio, timely delivery means delivering data as they are produced, in the
same order that they are produced, and without significant delay. This kind of delivery is called
real-time transmission.
4. Jitter. Jitter refers to the variation in the packet arrival time. It is the uneven delay in the
delivery of audio or video packets. For example, let us assume that video packets are sent every
30 ms. If some of the packets arrive with 30-ms delay and others with 40-ms delay, an uneven
quality in the video is the result.
DEPT.
` of ECE, ATMECE Page 2
Studied smart, not hard — thanks to [Link]
BEC702 – COMPUTER NETWORKS & Protocols
Components
A data communications system has five components
[Link]-. The message is the information (data) to be communicated. Popular forms of
information include text, numbers, pictures, audio, and video.
.IN
2. Sender-. The sender is the device that sends the data message. It can be a computer,
workstation, telephone handset, video camera, and so on.
C
[Link]-. The receiver is the device that receives the message. It can be a computer,
workstation, telephone handset, television, and so on
N
4. Transmission medium-. The transmission medium is the physical path by which a message
SY
travels from sender to receiver. Some examples of transmission media include twisted-pair wire,
coaxial cable, fiber-optic cable, and radio waves.
5. Protocol-. A protocol is a set of rules that govern data communications. It represents an
U
agreement between the communicating devices. Without a protocol, two devices may be
connected but not communicating, just as a person speaking French cannot be understood by a
VT
person who speaks only Japanese.
Data Representation
Information today comes in different forms such as text, numbers, images, audio, and video.
Text -In data communications, text is represented as a bit pattern, a sequence of bits (0s or 1s).
Different sets of bit patterns have been designed to represent text symbols. Each set is called a
code, and the process of representing symbols is called coding. Today, the prevalent coding
system is called Unicode, which uses 32 bits to represent a symbol or character used in any
language in the world. The American Standard Code for Information Interchange (ASCII),
developed some decades ago in the United States, now constitutes the first 127 characters in
Unicode and is also referred to as Basic Latin.
DEPT.
` of ECE, ATMECE Page 3
Studied smart, not hard — thanks to [Link]
BEC702 – COMPUTER NETWORKS & Protocols
Numbers- are also represented by bit patterns. However, a code such as ASCII is not used to
represent numbers; the number is directly converted to a binary number to simplify mathematical
operations. Appendix B discusses several different numbering systems. Images- are also
represented by bit patterns. In its simplest form, an image is composed of a matrix of pixels
(picture elements), where each pixel is a small dot. The size of the pixel depends on the
resolution.
For example, an image can be divided into 1000 pixels or 10,000 pixels. In the second case, there
is a better representation of the image (better resolution), but more memory is needed to store the
image. After an image is divided into pixels, each pixel is assigned a bit pattern. The size and the
value of the pattern depend on the image. For an image made of only black and- white dots (e.g.,
a chessboard), a 1-bit pattern is enough to represent a pixel. If an image is not made of pure
white and pure black pixels, we can increase the size of the bit pattern to include gray scale. For
.IN
example, to show four levels of gray scale, we can use 2-bit patterns. A black pixel can be
represented by 00, a dark gray pixel by 01, a light gray pixel by 10, and a white pixel by 11.
There are several methods to represent color images. One method is called RGB, so called
C
because each color is made of a combination of three primary colors: red, green, and blue. The
intensity of each color is measured, and a bit pattern is assigned toit. Another method is called
N
YCM, in which a color is made of a combination of three other primary colors: yellow, cyan, and
magenta.
SY
Audio- Audio refers to the recording or broadcasting of sound or music. Audio is by nature
different from text, numbers, or images. It is continuous, not discrete. Even when we use a
microphone to change voice or music to an electric signal, we create a continuous signal.
U
Video- Video refers to the recording or broadcasting of a picture or movie. Video can either be
VT
produced as a continuous entity (e.g., by a TV camera), or it can be a combination of images,
each a discrete entity, arranged to convey the idea of motion.
Data Flow
Communication between two devices can be simplex, half-duplex, or full-duplex as shown in
Figure
simplex mode- the communication is unidirectional, as on a one-way street. Only one of the two
devices on a link can transmit; the other can only receive (see Figure a).
example-Keyboards and traditional monitors are examples of simplex devices. The keyboard can
only introduce input; the monitor can only accept output.
simplex mode can use the entire capacity of the channel to send data in one direction
DEPT.
` of ECE, ATMECE Page 4
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
DEPT. of ECE, ATMECE Page 5
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
DEPT. of ECE, ATMECE Page 6
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protoco
fig: A switched WAN
.IN
LAN VS WAN
1. A LAN is normally limited in size, spanning
an office, a building, or a campus. C
1. A WAN has a wider geographical span,
spanning a town, a state, a country, or even the
N
world
2. A LAN interconnects hosts
SY
2. WAN interconnects connecting devices such
3. A LAN is normally privately owned by the as switches, routers, or modems
organization that uses it
3. a WAN is normally created and run by
U
communication companies and leased by an
organization that uses it.
VT
DEPT. of ECE, ATMECE Page 17
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
fig: An network made of two LAN and point-to-point dedicated WAN
When a host in the west coast office sends a message to another host in the same office, the
router blocks the message, but the switch directs the message to the destination. On the other
.IN
hand, when a host on the west coast sends a message to a host on the east coast, router R1 routes
the packet to router R2, and the packet reaches the destination. Figure shows another internet
with several LANs and WANs connected. One of the WANs is a switched WAN with four
switches.
C
N
SY
U
VT
fig: A heterogeneous network made of four WANs and three LANs
DEPT. of ECE, ATMECE Page 18
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
Switching
An internet is a switched network in which a switch connects at least two links together. A
switch needs to forward data from a network to another network when required. The two most
common types of switched networks are circuit-switched and packet-switched networks.
Circuit-Switched Network
In a circuit-switched network, a dedicated connection, called a circuit, is always available
between the two end systems; the switch can only make it active or inactive(continuous
communication between two telephone). FIG shows a very simple switched network that
connects four telephones to each end. We have used telephone sets instead of computers as an
end system because circuit switching was very common in telephone networks in the past,
.IN
C
N
SY
fig : Circuit-Switched Network
U
The thick line connecting two switches is a high-capacity communication line that can handle
VT
four voice communications at the same time; the capacity can be shared between all pairs of
telephone sets. The switches used in this example have forwarding tasks but no storing
capability.
Let us look at two cases.
In the first case, all telephone sets are busy; four people at one site are talking with four people
at the other site; the capacity of the thick line is fully used.
In the second case, only one telephone set at one side is connected to a telephone set at the
other side; only one-fourth of the capacity of the thick line is used. This means that a circuit-
switched network is efficient only when it is working at its full capacity; most of the time, it is
inefficient because it is working at partial capacity.
DEPT. of ECE, ATMECE Page 19
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
The reason to make the capacity of the thick line four times the capacity of each voice line is that
we do not want communication to fail when all telephone sets at one side want to be connected
with all telephone sets at the other side
Packet-Switched Network
In a computer network, the communication between the two computers is done in blocks of data
called packets
This allows switches to function for both storing and forwarding because a packet is an
independent entity that can be stored and sent later. Fig shows a small packet-switched network
that connects four computers at one site to four computers at the other site.
.IN
C
N
SY
fig: Packet-Switched Network
U
A router in a packet-switched network has a queue that can store and forward the packet.
VT
Example- Now assume that the capacity of the thick line is only twice the capacity of the data
line connecting the computers to the routers.
If only two computers (one at each site) need to communicate with each other, there is no
waiting for the packets. However, if packets arrive at one router when the thick line is already
working at its full capacity, the packets should be stored and forwarded in the order they arrived.
The two simple examples show that a packet-switched network is more efficient than a circuit
switched network, but the packets may encounter some delays.
The Internet
An internet (note the lowercase i) is two or more networks that can communicate with each
other. The most notable internet is called the Internet (uppercase I ), and is composed of
thousands of interconnected networks.
DEPT. of ECE, ATMECE Page 20
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
Figure 1.15 shows a conceptual (not geographical) view of the Internet. The figure shows the
Internet as several backbones, provider networks, and customer networks. At the top level, the
backbones are large networks owned by some communication companies such as Sprint, Verizon
(MCI), AT&T, and NTT. The backbone networks are connected through some complex
switching systems, called peering points. At the second level, there are smaller networks, called
provider networks, that use the services of the backbones for a fee. The provider networks are
connected to backbones and sometimes to other provider networks.
.IN
C
N
SY
U
VT
fig: The internet today
The customer networks are networks at the edge of the Internet that actually use the services
provided by the Internet. They pay fees to provider networks for receiving services. Backbones
and provider networks are also called Internet Service Providers (ISPs). The backbones are often
referred to as international ISPs; the provider networks are often referred to as national or
regional ISP
DEPT. of ECE, ATMECE Page 21
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
Models
Protocol Layering
Protocol defines the rules that both the sender and receiver and all intermediate devices need to
follow to be able to communicate effectively.
When communication is simple, we may need only one simple protocol; when the
communication is complex, we may need to divide the task between different layers, in which
case we need a protocol at each layer, or protocol layering.
Let us develop two simple scenarios to better understand the need for protocol layering.
Scenarios
.IN
First Scenario
In the first scenario, communication is so simple that it can occur in only one layer. Assume
C
Maria and Ann are neighbors with a lot of common ideas. Communication between Maria and
Ann takes place in one layer, face to face, in the same language, as shown in Figure
N
SY
U
VT
fig: single layer protocol
Second Scenario
In the second scenario, we assume that Ann is offered a higher-level position in her company,
but needs to move to another branch located in a city very far from Maria. The two friends still
want to continue their communication and exchange ideas because they have come up with an
innovative project to start a new business when they both retire. They decide to continue their
conversation using regular mail through the post office. However, they do not want their ideas to
be revealed by other people if the letters are intercepted. They agree on an encryption/decryption
technique. The sender of the letter encrypts it to make it unreadable by an intruder; the receiver
of the letter decrypts it to get the original letter.
DEPT. of ECE, ATMECE Page 22
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 50
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 51
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 52
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 53
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 54
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 55
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 56
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 57
Studied smart, not hard — thanks to [Link]
BEC702 - Computer Networks & Protocols
.IN
C
N
SY
U
VT
Department of ECE, ATMECE Page 58
Studied smart, not hard — thanks to [Link]