Professional Documents
Culture Documents
In
Library Service [Theory]
LISC: 557
Prepared by
Mahendra Prasad Adhikari
CENTRAL DEPARTMENT
Master's Level of Library & Information Science
TRIBHUVAN UNIVERSITY
Kathmandu
2076
1
Data Computer and networking
LISc. 557: Data Communication and Computer Network in Library Service [Theory]
Full Marks: 60
Lecture Hrs.: 48
Credit Hrs.: 3
Course Objectives
The objectives of the course is to develop skills in library science students in designing
analyzing troubleshooting and general knowledge and maintained knowledge of use of
computer network in the network of library and library network.
2
Data Computer and networking
13. Network Models - Physical Layer: Digital, Analog, Transmission modes, Line
configurational, Duplexity 3
Suggested Readings:
Boss, Kausik: Information Networks in India: Problems and Prospects, New Delhi;
ESS ESS Publications, 1994.
Stalling W. Stevens, W.R. : Data and Computer Communications. 5th ed. PHI, 1997. TCP/IP
Illustrated, Vol. 1, Vol. 2, Vol. 3. Addisen Wesely.
Tanebaum, A.S.: Computer Networks. 3rd ed., PHI, 1996.
3
Data Computer and networking
Contents
6
Data Computer and networking
Unit-1
Introduction to computer networks:
What is a computer network?
A computer network is a group of two or more computers connected with each other for sharing
resources and information. A simple computer network can be built only from two computers
while a complex computer network can be built from several thousand computers. A computer
network can be categorized based on geographical location and characteristic. Based on
geographical location, computer networks are outlined below.
Types (Classification) of computer network
a. LAN (Local Area Network)
b. Man (Metropolitan area networks)
c. Wan (Wide Area Network)
a. LAN: Local area network usually is confined to one building or campus. A LAN is a
computers network which spans over a small geographical area such as home, a building,
office, etc. In LAN, computers are placed relatively close. Since computers are located within
small distance, they do not need special devices and cables to connect with each other.
A LAN (Local Area Network), also known as an intranet, is a collection of computers on an
enclosed network.
In other words A Local Area Network (LAN) is a group of computers and associated devices
that share a common communications line or wireless link. Typically, connected devices share
the resources of a single processor or server within a small geographic area. A LAN is useful
for sharing resources like files, printers, games or other applications. A LAN in turn often
connects to other LAN‘s, and to the Internet or other WAN.
7
Data communication and Computer networking
smaller than WAN.
Some technologies used for this purpose are ATM, mobile banking, Fiber Data Distributed
Interface (FDDI), and Switched Multimegabit Data Service (SMDS).
c. WAN (Wide Area Network) = Wide area network, usually is over VPN's (Virtual
private networks) or point to point networks over a larger area.
WAN is a computer network which spans over a large geographical area such as state, region,
country etc. WANs are typically used to connect two or more LANs or MANs which are
located relatively very far from each other.
For example, if one computer is located in Delhi and other computer is located in Mumbai,
connecting these two computers is the example of WAN networking.
Internet
This is the largest computer network ever created by mankind. It interconnects thousands of
millions of computing devices including PCs, Laptops, Workstations, Server, Smartphones,
tablets, TVs, Webcams, Environmental devices, Automobiles, Security cameras and many
mores.
internet
The internet sounds similar to Internet but it is different. The word Internet starts with capital I,
while the word internet begins with small i. Any group of network which is connected with
external network through a gateway such as broader gateway protocol(BGP) is considered
as internet. Usually this type of network is setup to provide the connectivity between two
companies.
Intranet= is usually a Private network of web pages over a LAN or a WAN
Intranet is a computer network which is controlled and administered by a single entity such as
company or organization. In Intranet, external users are not allowed to connect. Usually in this
network, proper authorization is required to access any resources. Further each access is
monitored and logged to ensure that only authorized users get access.
Extranet
An Extranet is an extended Intranet where external users are allowed to access a small portion
of network. Normally this access is filtered and secured by several security implementations on
both hardware and software levels.
8
Data communication and Computer networking
A network based on Web technologies that links selected resources of the intranet of a company
with its customers, suppliers, or other business partners.
WHAT IS NETWORK TOPOLOGY?
• The Network topology is the arrangement of the nodes and various networking elements
like network links, computers, switches, nodes, Wi-Fi access points, laptops and other
network devices in a computer network. Topology the way in which constituent parts are
interrelated or arranged. Topology defines how data flows from one device to another.
• A network is possible by physical and logical connection with different devices.
• Logical Topology: Logical Topology describes how the data flows from one device to
another. A logical network topology is a conceptual representation of how devices
operate at particular layers of abstraction.
• Physical topology: It details how devices are physically connected. Logical and physical
topologies can both be represented as visual diagrams. Physical Topology describes how
devices are physically connected to together (wired). Physical relationship between
devices in a LAN
Here we are studying only Bus, Ring, Star, and Mesh Topology
Topology Description
In the bus network topology, every node is connected in series along a
Bus topology
linear path.
In the star network topology, a central node has a direct connection to all
Star topology
other nodes.
In the ring network topology, the nodes are connected in a closed loop
Ring topology
configuration.
Mesh topology This topology is a point-to-point connection to all other nodes or devices.
Linear Bus Topology:
In the linear bus topology, all the nodes are connected to the single backbone or bus
with some medium such as twisted pair, coaxial cable etc.
9
Data communication and Computer networking
When a node wants to communicate with the other nodes in the network, it simply sends a
message to the common bus. All the nodes in the network then receive the message but the
node for which it was actually sent only processes it. The other nodes discard the message.
1. All devices are connected to a single cable.
2. It transmits data only in one direction.
3. The signal travel through the bus to both ends.
4. Terminator is used at the end of the bus to kill the signal.
5. Terminator prevent the signals from reflecting back
6. Any medium failure cause whole network defunct.
Advantages of Bus Topology
The linear bus topology usually requires less cabling.
The linear bus topology is relatively simple to configure and install.
In the linear bus topology, the failure of one computer does not affect the other
computers in the network.
Disadvantages of Bus Topology
1. Cables fails then whole network fails.
2. If network traffic is heavy or nodes are more the performance of the network
decreases.
3. Cable has a limited length.
4. It is slower than the ring topology.
5. The bus topology is difficult to reconstruct in case of faults.
RING Topology
It is called ring topology because it forms a ring as each computer is connected to another
computer, with the last one connected to the first. Exactly two neighbours for each device.
10
Data communication and Computer networking
In the ring topology, the nodes are connected in the form of a ring with the help of twisted
pair cable.
Each node is connected directly to the other two nodes in the network. The node, which
wants to send a message, first passes the message to its consecutive node in the network.
Data is transmitted in the clockwise direction from one node to another. Each node
incorporates a repeater, which passes the message to next node when the message is
intended for another node.
Star Topology:
In this type of topology all the computers are connected to a single hub through a cable. This
hub is the central node and all others nodes are connected to the central node.
1. Every node has its own dedicated connection to the hub.
2. Hub acts as a repeater for data flow.
3. Can be used with twisted pair, Optical Fibre or coaxial cable.
4. This topology allows easy error detection and correction.
5. In the star topology, the failure of one computer does not affect the other computers in
the network.
6. Star topology is easy to install.
11
Data communication and Computer networking
12
Data communication and Computer networking
15
Data communication and Computer networking
NUMBER SYSTEMS:
Binary, Decimal, Octal, Hexadecimal and transformation
There are infinite ways to represent a number. The four commonly associated with modern
computers and digital electronics are: decimal, binary, octal, and hexadecimal.
Decimal (base 10) is the way most human beings represent numbers. Decimal is sometimes
abbreviated as dec.
Decimal Digit = 4567
Position 4th 3rd 2nd 1st
weight 103 102 101 100
1000 100 10 1
Digit 4 5 6 7
value 4000 500 60 7
Result 4000+500+60+7=4567
Decimal counting goes:
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, and so on.
Binary (base 2) is the natural way most digital circuits represent and manipulate numbers.
(Common misspellings are ―bianary‖, ―bienary‖, or ―binery‖.) Binary numbers are
sometimes represented by preceding the value with '0b', as in 0b1011. Binary is sometimes
abbreviated as bin. Binary counting goes:
0, 1, 10, 11, 100, 101, 110, 111, 1000, 1001, 1010, 1011, 1100, 1101, 1110, 1111, 10000,
10001, and so on.
Position 5th 4th 3rd 2nd 1st
weight 24 23 22 21 20
16 8 4 2 1
Digit 1 0 1 0 1
16 8 4 2 1
value 16 0 4 0 1
Result 16+0+4+0+1= 21
Octal (base 8) was previously a popular choice for representing digital circuit numbers in a
form that is more compact than binary. Octal is sometimes abbreviated as octal.
Octal counting goes: 0, 1, 2, 3, 4, 5, 6, 7, 10, 11, 12, 13, 14, 15, 16, 17, 20, 21, and so on.
Position 4th 3rd 2nd 1st
3
Weight 8 82 81 80
512 64 8 1
Digit 3 4 7 1
value 1536 256 56 1
Result 1536+256+56+1=1849
16
Data communication and Computer networking
Hexadecimal (base 16) is currently the most popular choice for representing digital circuit
numbers in a form that is more compact than binary. (Common misspellings are
―hexdecimal‖, ―hexidecimal‖, ―hexedecimal‖, or ―hexodecimal‖.) Hexadecimal numbers are
sometimes represented by preceding the value with '0x', as in 0x1B84. Hexadecimal is
sometimes abbreviated as hex.
Hexadecimal counting goes: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F, 10, 11, and so on.
17
Data communication and Computer networking
BINARY TO HEXADECIMAL
An equally easy way to convert from binary to hexadecimal is to group binary digits into
sets of four, starting with the least significant (rightmost) digits. Binary to Hexadecimal to
change a number we first group the binary digit from right to left by four.
Binary: 11100101 = 1110 0101
18
Data communication and Computer networking
4. Otherwise, multiply the result by 2.
5. Go to step 2.
Here is an example of converting 11100000000 binary to decimal:
Binary Digits Operation Decimal Result Operation Decimal Result
11100000000 +1 1 ×2 2
1100000000 +1 3 ×2 6
100000000 +1 7 ×2 14
00000000 +0 14 ×2 28
0000000 +0 28 ×2 56
000000 +0 56 ×2 112
00000 +0 112 ×2 224
0000 +0 224 ×2 448
000 +0 448 ×2 896
00 +0 896 ×2 1792
0 +0 1792 done.
3. Decimal Number Conversion
A repeated division and remainder algorithm can convert decimal to binary, octal, or
hexadecimal.
1. Divide the decimal number by the desired target radix (2, 8, or 16).
2. Append the remainder as the next most significant digit.
3. Repeat until the decimal number has reached zero.
DECIMAL TO BINARY
Here is an example of using repeated division to convert 1792 decimal to binary:
Binary
Decimal Number Operation Quotient Remainder
Result
1792 ÷2= 896 0 0
896 ÷2= 448 0 00
448 ÷2= 224 0 000
224 ÷2= 112 0 0000
112 ÷2= 56 0 00000
56 ÷2= 28 0 000000
28 ÷2= 14 0 0000000
14 ÷2= 7 0 00000000
19
Data communication and Computer networking
7 ÷2= 3 1 100000000
3 ÷2= 1 1 1100000000
1 ÷2= 0 1 11100000000
0 done.
78 ÷2= 39 1 0
10
39 ÷2= 19 1
19 ÷2= 9 1 110
9 ÷2= 4 1 1110
4 ÷2= 2 0 01110
2 ÷2= 1 0 001110
1 = 1001110
DECIMAL TO OCTAL
Here is an example of using repeated division to convert 1792 decimal to octal:
Octal
Decimal Number Operation Quotient Remainder
Result
1792 ÷8= 224 0 0
224 ÷8= 28 0 00
28 ÷8= 3 4 400
3 ÷8= 0 3 3400
0 done.
78 ÷8= 9 6 6
9 ÷8= 1 1 16
1 ÷8= 1 116
DECIMAL TO HEXADECIMAL
Here is an example of using repeated division to convert 1792 decimal to hexadecimal:
Hexadecimal
Decimal Number Operation Quotient Remainder
Result
1792 ÷ 16 = 112 0 0
112 ÷ 16 = 7 0 00
20
Data communication and Computer networking
7 ÷ 16 = 0 7 700
0 done.
78 ÷ 16 = 4 14 14=E
4 ÷ 16 = 4 4E
The only addition to the algorithm when converting from decimal to hexadecimal is that a
table must be used to obtain the hexadecimal digit if the remainder is greater than decimal 9.
Decimal: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Hexadecimal: 0 1 2 3 4 5 6 7 8 9 A B C D E F
The addition of letters can make for funny hexadecimal values. For example, 48879 decimal
converted to hex is:
Hexadecimal
Decimal Number Operation Quotient Remainder
Result
48879 ÷ 16 = 3054 15 F
3054 ÷ 16 = 190 14 EF
190 ÷ 16 = 11 14 EEF
11 ÷ 16 = 0 11 BEEF
0 done.
Other fun hexadecimal numbers include: AD, BE, FAD, FADE, ADD, BED, BEE, BEAD,
DEAF, FEE, ODD, BOD, DEAD, DEED, BABE, CAFE, C0FFEE, FED, FEED, FACE,
BAD, F00D, and my initials DAC.
4. OCTAL NUMBER CONVERSION
OCTAL TO BINARY
Converting from octal to binary is as easy as converting from binary to octal. Simply look up
each octal digit to obtain the equivalent group of three binary digits.
Octal: 0 1 2 3 4 5 6 7
Binary: 000 001 010 011 100 101 110 111
Octal = 3 4 5 345
Binary = 011 100 101 = 011100101 binary
OCTAL TO HEXADECIMAL
When converting from octal to hexadecimal, it is often easier to first convert the octal
number into binary and then from binary into hexadecimal. For example, to convert 345
octal into hex:
21
Data communication and Computer networking
Octal = 3 4 5 345
Binary = 011 100 101 = 011100101 binary
Octal 1 1 6 116
Binary 001 001 110 1001110
Drop any leading zeros or pad with leading zeros to get groups of four binary digits (bits):
Binary 011100101 = 1110 0101
Then, look up the groups in a table to convert to hexadecimal digits.
Binary: 0000 0001 0010 0011 0100 0101 0110 0111
Hexadecimal: 0 1 2 3 4 5 6 7
Binary: 1000 1001 1010 1011 1100 1101 1110 1111
Hexadecimal: 8 9 A B C D E F
OCTAL TO DECIMAL
The conversion can also be performed in the conventional mathematical way, by showing
each digit place as an increasing power of 8.
345 octal = (3 * 82) + (4 * 81) + (5 * 80) = (3 * 64) + (4 * 8) + (5 * 1) = 229 decimal
5. HEXADECIMAL NUMBER CONVERSION
HEXADECIMAL TO BINARY
Converting from hexadecimal to binary is as easy as converting from binary to hexadecimal.
Simply look up each hexadecimal digit to obtain the equivalent group of four binary digits.
Hexadecimal: 0 1 2 3 4 5 6 7
Binary: 0000 0001 0010 0011 0100 0101 0110 0111
Hexadecimal: 8 9 A B C D E F
Binary: 1000 1001 1010 1011 1100 1101 1110 1111
Hexadecimal = A 2 D E
Binary = 1010 0010 1101 1110 = 1010001011011110 binary
22
Data communication and Computer networking
HEXADECIMAL TO OCTAL
When converting from hexadecimal to octal, it is often easier to first convert the
hexadecimal number into binary and then from binary into octal. For example, to convert
A2DE hex into octal:
(from the previous example)
Hexadecimal = A 2 D E
Binary = 1010 0010 1101 1110 = 1010001011011110 binary
Add leading zeros or remove leading zeros to group into sets of three binary digits.
Binary: 1010001011011110 = 001 010 001 011 011 110
Then, look up each group in a table:
Binary: 000 001 010 011 100 101 110 111
Octal: 0 1 2 3 4 5 6 7
A2DE hexadecimal:
= (A) * 163) + (2 * 162) + ((D) * 161) + (E) * 160)
= 41694 decimal
23
Data communication and Computer networking
How to Calculate Hexadecimal to Decimal
Hexa is a base 16 number and decimal is a base 10 number. We need to know the decimal
equivalent of every hexa number digit. See below of the page to check the hexa to decimal
chart.
Here are the steps to convert hexa to decimal:
Get the decimal equivalent of hexa from table.
Multiply every digit with 16 power of digit location.
(zero based, 7DE: E location is 0, D location is 1 and the 7 location is 2)
Sum all the multipliers.
Here is an example:
24
Data communication and Computer networking
Meanwhile, the digit 6 after the decimal point is in the tenths (1/10, which is 10 -1) and 7 is
in the hundredths (1/100, which is 10-2) position
Thus, the number 2345.67 can also be represented as follows: (2 * 103) + (3 * 102) + (4 *
101) (5*100)+ (6 * 10-1) + (7 * 10-2)
25
Data communication and Computer networking
Unit-2
NETWORKING MODELS:
(OSI, TCP/IP reference Model)
26
Data communication and Computer networking
27
Data communication and Computer networking
LAYERS OF OSI MODEL
Prerequisite: Basics of Computer Networking
OSI stands for Open Systems Interconnection. It has been developed by ISO –
‗International Organization of Standardization‗, in the year 1984. It is a7 layer
architecture with each layer having specific functionality to perform. All these 7 layers work
collaboratively to transmit the data from one person to another across the globe.
Physical layer: Media, Signal & Binary transmission. Bit stream: physical medium, method
of representing bits. Send data on to the physical wire. Generation / convert of electrical
signal and send. Signal levels, connections, wires, fiber, wireless. Example: Ethernet,USB,
DSL, 8 02.11 ,WIFI, Bluetooth,IEEE, 802.11, Hubs, NICS, Cable, physical structure, coax,
Fiber, Wireless, Hubbs, Repeaters.
28
Data communication and Computer networking
a. Bit synchronization: The physical layer provides the synchronization of the bits by
providing a clock. This clock controls both sender and receiver thus providing
synchronization at bit level.
b. Bit rate control: The Physical layer also defines the transmission rate i.e. the number
of bits sent per second.
c. Physical topologies: Physical layer specifies the way in which the different,
devices/nodes are arranged in a network i.e. bus, star or mesh topolgy.
d. Representation of Bits: Data in this layer consists of stream of bits. The bits must be
encoded into signals for transmission. It defines the type of encoding i.e. how 0's and
1's are changed to signal.
e. Interface: The physical layer defines the transmission interface between devices and
transmission medium.
f. Line Configuration: This layer connects devices with the medium: Point to Point
configuration and Multipoint configuration.
g. Topologies: Devices must be connected using the following topologies: Mesh, Star,
Ring and Bus.
h. Transmission Modes: Physical Layer defines the direction of transmission between
two devices: Simplex, Half Duplex, Full Duplex.
i. Deals with baseband and broadband transmission.
29
Data communication and Computer networking
The packet received from Network layer is further divided into frames depending on the
frame size of NIC(Network Interface Card). DLL also encapsulates Sender and Receiver‘s
MAC address in the header.
Packages raw bits from the Physical layer into frames (logical, structured packets for
data).
Provides reliable transmission of frames
o It waits for an acknowledgment from the receiving computer.
o Retransmits frames for which acknowledgement not received
a. Framing: Framing is a function of the data link layer. It provides a way for a sender
to transmit a set of bits that are meaningful to the receiver. This can be accomplished
by attaching special bit patterns to the beginning and end of the frame.
b. Physical addressing: After creating frames, Data link layer adds physical addresses
(MAC address) of sender and/or receiver in the header of each frame.
c. Error control: Data link layer provides the mechanism of error control in which it
detects and retransmits damaged or lost frames.
d. Flow Control: The data rate must be constant on both sides else the data may get
corrupted thus , flow control coordinates that amount of data that can be sent before
receiving acknowledgement.
e. Access control: When a single communication channel is shared by multiple devices,
MAC sub-layer of data link layer helps to determine which device has control over the
channel at a given time.
Packet in Data Link layer is referred as Frame.
Data Link layer is handled by the NIC (Network Interface Card) and device drivers
of host machines.
Switch & Bridge are Data Link Layer devices.
Examples PPP, FDDI, ATM, IEEE 802.5/ 802.2, IEEE 802.3/802.2, HDLC, and Frame Relay.
Ethernet, ARP, CDD,FDDI,FRAM RELAY, HDLC, MPLS, STP, TOKENRING, switches,
Frames, Bridge
a. Transport layer is high level manager responsible for delivery between two
applications. Application –to-application
b. Network layer is a low-level manager responsible for delivery between the two
computers. Source-to-destination
c. Manages addressing/routing of data within the subnet
o Addresses messages and translates logical addresses and names into physical
addresses.
o Determines the route from the source to the destination computer
o Manages traffic problems, such as switching, routing, and controlling the
congestion of data packets.
d. Routing can be:
o Based on static tables
o determined at start of each session
o Individually determined for each packet, reflecting the current network load.
Routing: The network layer protocols determine which route is suitable from source to
destination. This function of network layer is known as routing.
Logical Addressing: In order to identify each device on internetwork uniquely, network layer
defines an addressing scheme. The sender & receiver‘s IP address are placed in the header by
network layer. Such an address distinguishes each device uniquely and universally.
Segment in Network layer is referred as Packet.
Network layer is implemented by networking devices such as routers.
32
Data communication and Computer networking
Transport layer is operated by the Operating System. It is a part of the OS and
communicates with the Application Layer by making system calls.
Transport Layer is called as Heart of OSI model.
Examples: SPX, TCP, UDP, UTP, End to end connections.
5. SESSION LAYER (LAYER 5):
This layer is responsible for establishment of connection, maintenance of sessions,
authentication and also ensures security.
All the below 3 layers (including Session Layer) are integrated as a single layer in the
TCP/IP model as ―Application Layer‖.
Implementation of these 3 layers is done by the network application itself. These are also
known as Upper Layers or Software Layers.
33
Data communication and Computer networking
6. PRESENTATION LAYER (LAYER 6):
Presentation layer is also called the Translation layer. The data from the application layer is
extracted here and manipulated as per the required format to transmit over the network.
The functions of the presentation layer are:
34
Data communication and Computer networking
TCP/IP Reference Model
TCP/IP means Transmission Control Protocol and Internet Protocol. It is the network model
used in the current Internet architecture as well. Protocols are set of rules which govern every
possible communication over a network. These protocols describe the movement of data
between the source and destination or the internet. They also offer simple naming and
addressing schemes.
36
Data communication and Computer networking
TCP/IP REFERENCE MODEL (in details)
1. Application Layer: The application layer handles high-level protocols, representation,
encoding, and dialog control. The TCP/IP protocol suite combines all application related issues
into one layer. It ensures that the data is properly packaged before it is passed on to the next
layer. TCP/IP includes Internet and transport layer specifications such as IP and TCP as well as
specifications for common applications. TCP/IP has protocols to support file transfer, e-mail,
and remote login, in addition to the following:
• File Transfer Protocol (FTP) – FTP is a reliable, connection oriented service that uses TCP
to transfer files between systems that support FTP. It supports bi-directional binary file
and ASCII file transfers.
• Trivial File Transfer Protocol (TFTP) – TFTP is a connectionless service that uses the User
Datagram Protocol (UDP). TFTP is used on the router to transfer configuration files and
Cisco IOS images, and to transfer files between systems that support TFTP. It is useful in
some LANs because it operates faster than FTP in a stable environment.
• Network File System (NFS) – NFS is a distributed file system protocol suite developed by
Sun Microsystems that allows file access to a remote storage device such as a hard disk
across a network.
• Simple Mail Transfer Protocol (SMTP) – SMTP administers the transmission of e-mail
over computer networks. It does not provide support for transmission of data other than
plain text.
• Telnet – Telnet provides the capability to remotely access another computer. It enables a
user to log into an Internet host and execute commands. A Telnet client is referred to as a
local host. A Telnet server is referred to as a remote host.
• Simple Network Management Protocol (SNMP) – SNMP is a protocol that provides a way
to monitor and control network devices. SNMP is also used to manage configurations,
statistics, performance, and security.
• Domain Name System (DNS) – DNS is a system used on the Internet to translate domain
names and publicly advertised network nodes into IP addresses.
2. Transport Layer:
The transport layer provides a logical connection between a source host and a destination host.
Transport protocols segment and reassemble data sent by upper-layer applications into the same
data stream, or logical connection, between end points.
• Creates packet from bytes stream received from the application layer.
• Uses port number to create process to process communication.
• Uses a sliding window protocol to achieve flow control.
• Uses acknowledgement packet, timeout and retransmission to achieve error control.
37
Data communication and Computer networking
• The primary duty of the transport layer is to provide end-to-end control and reliability as
data travels through this cloud. This is accomplished through the use of sliding windows,
sequence numbers, and acknowledgments.
• The transport layer also defines end-to-end connectivity between host applications.
• Transport layer protocols include TCP and UDP.
• TCP is a connection-oriented transport layer protocol that provides reliable full-duplex data
transmission.
• TCP is part of the TCP/IP protocol stack.
• In a connection-oriented environment, a connection is established between both ends
before the transfer of information can begin.
• TCP breaks messages into segments, reassembles them at the destination, and resends
anything that is not received.
• TCP supplies a virtual circuit between end-user applications.
TCP Header Format: TCP uses only a single type of protocol data unit, called a TCP segment.
The header is shown in Figure . Because one header must serve to perform all protocol
mechanisms, it is rather large, with a minimum length of 20 octets.
Bit 0 Bit 15 Bit 16 = Bit 31
Source port (16) Destination Port (16) 8 Bites
Sequence number (32)
Acknowledge number (32)
Header Length(4) reserved(6)code Bits(6) Window(16)
Checksum(16) Urgent (16)
Option (0 or 32 if any)
Data (varies)
The following protocols use TCP Transport layer:
• FTP
• HTTP
• SMTP
• Telnet
The following are the definitions of the fields in the TCP segment:
UDP does not use windows or ACKs. Reliability is provided by application layer protocols.
UDP is designed for applications that do not need to put sequences of segments together. The
following protocols use UDP:
TFTP
SNMP
DHCP
DNS
The following are the definitions of the fields in the UDP segment:
Source port – Number of the port that sends data
Destination port – Number of the port that receives data
Length – Number of bytes in header and data
Checksum – Calculated checksum of the header and data fields
Data – Upper-layer protocol data
TCP vs UDP:
S.No TCP - Transmission Control Protocol UDP - User Datagram Protocol
1 connection-oriented, reliable (virtual connectionless, unreliable, does not
circuit) check message delivery
39
Data communication and Computer networking
2 Divides outgoing messages into segments sends ―datagrams‖
3. Internet Layer:
The purpose of the Internet layer is to select the best path through the network for packets to
travel. The main protocol that functions at this layer is IP. Best path determination and packet
switching occur at this layer. The following protocols operate at the TCP/IP Internet layer:
IP provides connectionless, best-effort delivery routing of packets. IP is not concerned
with the content of the packets but looks for a path to the destination.
Internet Control Message Protocol (ICMP) provides control and messaging capabilities.
Address Resolution Protocol (ARP) determines the data link layer address, or MAC
address, for known IP addresses.
Reverse Address Resolution Protocol (RARP) determines the IP address for a known
MAC address.
40
Data communication and Computer networking
INTERNET MODELS
Application layer: it takes the responsibility of 3 top most layer of OSI model (OSI‘s
Application, Presentation and Session)
Transport layer: some of the duties of session layer go to Transport layer.
A. Application layer
• It has several protocols and programs to access the resources of remote system.
• These protocols serve the duties of presentation and session layers in OSI model.
B. Transport layer
• It contains two protocols
• TCP: Transmission control protocol
• UDP: User Datagram Protocol
TCP:
• It is a reliable protocol
• It makes possible to communicate between two applications
• Divides stream of bytes into manageable segments at source
• Creates a stream of bytes from a received segment for the use of the application layer at
destination.
• It takes duties of transport layer and also perform responsibility of session layer in OSI,
e.g. it creates a two-way connection (a dialog) between two applications
Hub to Hub In the context of package delivery, a "hub" is like a post office. In fact it might be
a post office. It is a local center where packages are collected for dispatch to their destination.
So a courier or local agent will collect a package from the sender, send it on to its local hub for
sorting.
UNIT-3
SWITCHING TECHNIQUES AND NETWORIKING DEVICES
(Circuit switching, packet switching, message switching)
Switched communication networks are those in which data transformed from source to
destination is routed between various intermediate nodes. Eg. Star topology.
There are mainly three typical Switching Techniques available for digital traffic:
1. Circuit Switching
2. Message Switching
3. Packet Switching
43
Data communication and Computer networking
1) Circuit Switching
a. Circuit Switching is a technique that directly connects the sender and the receiver in an
unbroken path.
b. Example of Telephone: switching equipment establishes a path that connects the caller‘s
and receiver's voice traffic in addition to digital data by making a physical connection.
c. Routing decisions in circuit must be made when the circuit is first established, but there
are no decisions made after that time.
d. A complete end to end path must exist before communication can take place.
e. Once the connection has been initiated and completed, the destination device must
acknowledge that it is ready and able to carry on a transfer.
Advantages:
The communication channel is end to end dedicated
Disadvantages:
a. More high speed bandwidth is required.
b. Connection establishment time is more.
c. More expensive than any other switching techniques because a dedicated path is required
for each connection.
d. Inefficient use of communication channel.
44
Data communication and Computer networking
2) Message Switching
a. In message switching there is no dedicated path required between two communicating
devices, because the message switching is the follow the connectionless data network.
b. With message switching there is no need to establish dedicated path between two stations
and use network layer
c. When a station sends a message, the destination address is appended to the message.
d. The message is then transmitted through the network in its entirety, from node to node.
e. Each node receives the entire message, stores it in its entirety on disk and then transmits
the message to the next node. This type of network is called a store and forward network.
Advantages:
a. Efficient traffic management.
b. Large storing capacity required.
Disadvantages:
a. Is not compatible with interactive applications.
b. Store and forward devices are example.
45
Data communication and Computer networking
3) Packet Switching
a. In packet switching message are broken up into packet.
b. Each packet is tagged with appropriate header with source and destination node address.
c. Individual packets take different routes to reach the destination through network layer.
Packet switching: Datagram
a. Datagram packet switching is a packet switching technology by which each packet is
treated as a separate entity and is called as datagram.
b. Packets have their own complete addressing information attached.
c. Each packet follows different routes to reach the destination.
d. So, the packets may arrive at different times, and may be in a disturbed order. In this case
reordering is done.
Packet switching: Virtual
a. In this type of switching a preplanned route is established before the packets are sent.
b. Sender sends a "call request packet" to establish a logical connection and receiver sends
back an acknowledgement packet "packet accepted".
c. It is a cross between circuit switching network and packet switching network.
Advantages:
a. Packet switching is cost effective.
b. Offers improved delay characteristics.
c. Packet can be rerouted if any problem occurs.
Disadvantages:
a. Packet switching protocols are typically more complex.
b. If packet gets lost sender needs to resend the data.
46
Data communication and Computer networking
Difference between Circuit Switching and Packet Switching
CIRCUIT SWITCHING PACKET SWITCHING
In circuit switching, each data unit know the In Packet switching, each data unit just
entire path address which is provided by the knows the final destination address
source intermediate path is decided by the routers.
Delay between data units in circuit switching Delay between data units in packet switching
is uniform. is not uniform.
47
Data communication and Computer networking
COMPARISON IN CHART
BASIS FOR
CIRCUIT SWITCHING PACKET SWITCHING
COMPARISON
48
Data communication and Computer networking
NETWORK DEVICES
(Hub, Repeater, Bridge, Switch, Router, Gateways and Brouter)
Common Network Connectivity Devices:
1. WAN Devices
The connectivity devices are:
The Network Interface card (NIC) Transceivers
The hub Wireless access points
The switch The router
The bridge The gateway
Network Interface Card (NIC): The Network Interface Card (NIC) used connect the
computer to the external network. It will normally have a PCI connector (Edge connector) to
connect to one of the PC expansion slots, and an RJ-45 connector to connect to external
Ethernet. Note that the interface connectors may differ depending upon the expansion bus
being used (for example, PCI, ISA, EISA, USB etc.), and the networking media being used
(for example, 10Base2, 10Base5, 10BaseT, etc.). Each of these have their own interface
specifications. Almost all NICs have LED indicators showing the network connectivity.
A commonly used Network Interface Card is shown in the figure below.
49
Data communication and Computer networking
about repeaters is that they do not amplify the signal. When the signal becomes weak, they copy
the signal bit by bit and regenerate it at the original strength. It is a 2 port device.
Repeater is use to regenerate the signal. It works as an amplifier
2. Hub – A hub is basically a multiport repeater. A hub connects multiple wires coming from
different branches, for example, the connector in star topology which connects different
stations. Hubs cannot filter data, so data packets are sent to all connected devices. In other
words, collision domain of all hosts connected through Hub remains one. Also, they do not
have intelligence to find out best path for data packets which leads to inefficiencies and
wastage.
HUB
Hub is a central device. It is use to just connect the system in a network
Hub is a broadcast device.
It divide the bandwidth means if you have 100 mbps speed and 4 port in a hub then it divide
into 25+25+25+25.
There are minimum 8 and maximum 24 ports in a hub.
Types of Hub
1. Active Hub:- These are the hubs which have their own power supply and can clean,
boost and relay the signal along with the network. It serves both as a repeater as well as
wiring center. These are used to extend the maximum distance between nodes.
2. Passive Hub: - These are the hubs which collect wiring from nodes and power supply
from active hub. These hubs relay signals onto the network without cleaning and boosting
them and can‘t be used to extend the distance between nodes. There are no external
power supplies. It have minimum 4 port there are uplink port.
50
Data communication and Computer networking
In other words A Bridge functions very similar to a Switch. It segments a given network
according to the requirements. Segmentation using a Bridge enables keeping un-intended traffic
from entering different segments of a network. Both Bridge and Switch are OSI layer-2 devices.
Bridges filter traffic based on the destination address of the frame. If a frame's destination is a
node on the same segment where it originated, it is not forwarded. If it is destined for a node on
another LAN, it is connected to corresponding bridge port and forwarded to that port.
Types of Bridges
Transparent Bridges: - These are the bridge in which the stations are completely unaware
of the
bridge‘s existence i.e. whether or not a bridge is added or deleted from the network,
reconfiguration of
the stations is unnecessary. These bridges make use of two processes i.e. bridge forwarding
and bridge learning.
Source Routing Bridges: - In these bridges, routing operation is performed by source
station and the frame specifies which route to follow. The hot can discover frame by
sending a special frame called discovery frame, which spreads through the entire network
using all possible paths to destination.
A bridge is a device that separates two or more network segments within one logical
network.
It have minimum 4 and maximum 12 port
It works on Mac address.
A bridge is usually placed between two separate groups of computers that talk with each other,
but not that much with the computers in the other group. A good example of this is to consider a
cluster of Macintosh‘s and a cluster of UNIX machines. Both of these groups of machines tend
51
Data communication and Computer networking
to be quite chatty amongst themselves, and the traffic they produce on the network causes
collisions for the other machines who are trying to speak to one another.
Transceivers: Transceivers are commonly used with co-axial media using 10Base2 or 10Base5
networking standards. It allows a Network Interface Card to connect to a coax, providing
necessary translation of signals.
Wireless Access Points (WAP): A wireless access point allows mobile users to connect to a
central network node without using any wires. Wireless connectivity is useful for mobile
workstations, since there is no wiring involved. The wireless access standards are broadly
divided into 802.11a, 802.11b, and 802.11g. 802.11g is most popular among these due to high
bandwidth that it provides, and the availability of hardware. A commercially available wireless
access point is shown in the figure below.
o Switch – A switch is a multiport bridge with a buffer and a design that can boost its
efficiency (a large number of ports imply less traffic) and performance. A switch is a data
link layer device. The switch can perform error checking before forwarding data, that
makes it very efficient as it does not forward packets that have errors and forward good
packets selectively to correct port only. In other words, switch divides collision domain
of hosts, but broadcast domain remains same.
Switch is a central device. It is use to connect the system in a network
Switch is a multi-broadcast device.
It doesn‘t divide the bandwidth
52
Data communication and Computer networking
There are minimum 24 and maximum 48 ports in a hub
We can configure a switch
A computer networking device that is used to connect devices together on a computer network.
A switch is considered more advanced than a hub because a switch will only send a message to
the device that needs or requests it, rather than broadcasting the same message out of each of its
ports.
48-port Switch
5. Routers – A router is a device like a switch that routes data packets based on their IP
addresses. Router is mainly a Network Layer device. Routers normally connect LANs and
WANs together and have a dynamically updating routing table based on which they make
decisions on routing the data packets. Router divide broadcast domains of hosts connected
through it.
A device which connect two or more different network and decide the best route that is router.
We have to configure a router. Means Assign Name, IP, Password and Route.
A router is a device that forwards data packets along networks. A router is connected to at least
two networks, commonly two LANs or WANs or a LAN and its ISP‘s and they
use protocols such as ICMP to communicate with each other and configure the best route
between any two networks. Routers are located at gateways, the places where two or more
networks connect.
Routers use headers and forwarding tables to determine the best path for forwarding the packets
hosts.
53
Data communication and Computer networking
Router
6. Gateway – A gateway, as the name suggests, is a passage to connect two networks together
that may work upon different networking models. They basically work as the messenger agents
that take data from one system, interpret it, and transfer it to another system. Gateways are also
called protocol converters and can operate at any network layer. Gateways are generally more
complex than switch or router.
In other words Gateways are the most complex devices with respect to the functionality. They
typically work at the upper most layers of OSI model. A gateway is used to connect two
different environments, such as a Frame-Relay network and an X.25 network.
7. Bridge (Brouter) – It is also known as bridging router is a device which combines features
of both bridge and router. It can work either at data link layer or at network layer. Working as
router, it is capable of routing packets across networks and working as bridge, it is capable of
filtering local area network traffic.
8. WiFi:
WiFi stands for Wireless Fidelity. WiFi uses Radio waves to provide wireless high-speed
internet and network connections. A WiFi connection is established using a wireless adapter to
create hotspots. WiFi antennas size small enough to be placed on a very small router. WiFi can
be used to connect with printer, computers, gaming consoles and many more.
9. WiMax:
WiMax stands for Wireless Inter-operability for Microwave Access. WiMax uses licensed or
unlicensed spectrum to deliver connection to network. WiMax handle a larger inter-operable
network. WiMax can be used to provide internet services such as mobile data and WiFi spots.
54
Data communication and Computer networking
The Term Modem is the acronym of Modulator/DE Modulator. There are several types of
modems.
Modem: A modem is a hardware networking device that converts data to a signal so it can be
easily sent and received over a phone line, cable, or satellite connection. In the case of
transmission over an analog telephone line, which was once the most popular way to access the
internet, the modem converts data between analog and digital formats in real time for two-
way network communication. In the case of the high-speed digital modems popular today, the
signal is much simpler and doesn't require the analog-to-digital conversion.
These include:
1. Dial-up Analog Modem
2. Broadband Modem
Analog modems are widely used to connect to the Internet using normal telephone lines. These
modems use the same frequencies used for voice transmission. Therefore, you cannot make a
call or receive a call (voice call) when using this modem to connect to the Internet.
Broadband modems use a different technology to connect to the central office. They do not
use the voice frequencies to communicate over the telephone wire. As a result, you can make or
receive voice call when using broadband modem. Another advantage using broadband modem
is speed. Speeds of several megabits per second are typical using broadband modems, where as
it is limited to 56 kbps (or so) when using analog modems.
A broadband modem is shown in the figure below.
DSL Modem
ISDN terminal adapters: ISDN is short for Integrated Service Digital Network (ISDN). It
delivers digital services over conventional telephone wires. You can connect your phone to an
ISDN line using a terminal adapter (TA). An ISDN modem provides higher speeds compared to
analog modems, but far less speed when compared to broadband modems.
CSU/DSU: CSU/DSU stands for Channel Service Unit/Data Service Unit. These are commonly
used for leased lines from Telcos. The CSU terminates the line at the customer's side. The DSU
does the transmission of signal through the CSU.
55
Data communication and Computer networking
Unit-4
NETWORK CONNECTIVITY
(Types of Internet Connections)
(Dial-up, Leased line, Wireless and RF, DSL, ADSL, Fiber, Cable, ISDN)
Internet connections are of different types depending upon the cost, speed, availability, etc.
56
Data communication and Computer networking
What is a Leased Line?
A leased line is a dedicated, fixed-bandwidth, symmetric data connection. It is used to link two
locations together.
The first location is typically a corporate office. The second location is typically another
corporate office, a data center that‘s connected to the Internet or a data center that‘s connected
to the company‘s existing Wide Area Network.
57
Data communication and Computer networking
to carry a number of different types of data traffic (Internet traffic, phone calls, corporate VPN
traffic).There‘s no requirement to buy Internet access on a leased line.
If we do get Internet access, there‘s no requirement that you get enough to fill the leased line.
For example, we might choose to get 15Mbit/s of Internet access on a 20Mbit/s leased line,
which in turn could be provisioned over a 100Mbit/s circuit. We could use 5Mbit/s for WAN
traffic and VoIP calls, and there would be 80Mbit/s spare for future usage.
What is a Leased Line Likely to deliver, Speed-wise?
2Mbps, 10Mbps and 100Mbps are the most popular connection speeds, though connections of
10,000 Mbit/s (10 Gigabits per second) are possible if money is no object.
What is a leased line likely to cost you? As a rough rule of thumb, 10Mbps connections cost
twice as much as 2Mbps connections. And 100Mbps connections cost twice as much as
10Mbps connections.
Advantages of a Dedicated Connection (compared to ADSL)
a. Faster download speeds are usually c. Connections that don‘t slow down at
available peak times
b. Faster upload speeds d. Greater reliability
e. Better support
Disadvantages of a Dedicated Connection (compared to ADSL)
Cost – Leased line costs have fallen, but leased lines are still a LOT more expensive than
3. ISDN (Integrated Service Digital Network):
ISDN stands for Integrated Service Digital Network. This connection is nearly similar to the
DSL. ISDN is a set of international communication standards designed in 1980 and improved in
the 1990s.
It is a digital network to transmit voice, image, video, and text over the existing circuit-switched
PSTN telephone network.
Different types of devices, such as analog phone, a fax machine, or a computer, are connected
to an ISDN terminal adaptor, which converts different types of data into ISDN format so that
they can share the same digital PSTN network.
58
Data communication and Computer networking
There are two major types of ISDN:-
BRI
PRI
I) BRI – Basic Rate Interface (2B+D)
– Two 64 kbit/s bearer (B) channels (For data)
– One 16 kbit/s signaling (D) channels ( For call setup and breakdown)
II) PRI- Primary Rate Interface
23B Channel- 64 Kbits/s (Mainly uses in North America)
1D channel- 64 Kbits/s (signaling and setup)
This connection is commonly used as connectivity from PSTN to large phone systems (PBX).
Dial-up and ISDN are the old types of internet connections.
4. Wireless and RF connection
The wireless network is built with the help of several hardware components like wireless excess
point or router and user devices like mobile phone, tablets, laptop, etc. which are equipped with
the wifi adaptor.
On the other hand, a wireless router is connected to the internet via a physical connection i.e.
with the fiber cable or analog line which uses a telephone and modem, after that connected to
the router.
The wireless router is then connected to the devices via radio waves established an end to end
internet connection.
A router receives the data from the internet and translates it is to a radio signal and sends it to
the wireless network to the connected devices.
The identical process also happens in reverse.
RF Wireless Technology
A radio frequency (RF) signal refers to a wireless electromagnetic signal used as a form of
communication, if one is discussing wireless electronics. Radio waves are a form of
59
Data communication and Computer networking
electromagnetic radiation with identified radio frequencies that range from 3kHz to 300 GHz.
RF communication is used in many industries including television broadcasting, radar systems,
computer and mobile platform networks, remote control, remote metering/monitoring, and
many more.
While individual radio components such as mixers, filters, and power amplifiers can be
classified according to operating frequency range, they cannot be strictly categorized by
wireless standard (e.g. Wi-Fi, Bluetooth, etc.) because these devices only provide physical layer
(PHY) support. In contrast, RF modules, transceivers, and SoCs often include data link layer
support for one or more wireless communication protocols. These products are organized by
wireless technology and can be browsed under the "Solutions" tab.
Bluetooth Solutions
ZigBee Solutions
Wi-Fi Solutions
GPS Solutions
5. DSL: (ADSL, SDSL, VDSL, CABLE Connection)
6. Fiber
A fiber internet connection provides the fastest internet speed today. It can provide download
and upload speed of up to 1000 Mbps. It uses light to transfer the data through the optical fiber
cable. In other forms of internet, connection data is transferred in electrical form, so signal get
weaker and weaker at large distances because singles in the copper cable can be affected by
electromagnetic interference. But in the fiber optic cable, signal transfers in the glass in the
form of light, it can travel to long distances without any losses. Fiber is more expensive than the
DSL and cable.
7. Satellite
Satellite internet is the internet which uses the path of the outer space. Satellite internet signal
travels more than 46,000 miles (From ISP to user through satellite).
In rural area satellite internet will be the best option for high speed, it is a faster option than
dial-up. Still, large-scale improvements are going on for making it more usable and reliable in
61
Data communication and Computer networking
the field of infrastructure and technology. At many places, its speed is less than the cable and
DSL connection. Satellites are orbiting directly over the equator, means it is a geostationary
satellite.
Working:
In this internet connection when you search about anything, on your internet devices, its signal
send to the satellite via a satellite dish and from satellite to NOC (Network Operation Center)
retrieves data on earth, and sends it back to the satellite, the whole process take place in reverse.
Distance from satellite ISP to satellite or from satellite to the user is more than 23000 miles. It
means data travels more than 46,000 miles. This process takes place in a fraction of seconds.
High Latency represents a bad signal in satellite internet connection. For browsing and
downloading, latency does not affect much but during gaming and streaming it affects lots.
8. Cellular
In this network, radio waves are used for transfer signal to and from the mobile phone.
In cellular technology geographic area is divided into hexagonal cells, with it each cell having
its tower and frequency slot.
Generally, these cellular towers are connected through a wire or more specifically optical fiber
cable. These optical fiber cables are laid under the ground or ocean for providing national or
international connectivity.
During the use of the internet; Smartphone transmits a signal in the form of electromagnetic
waves.
The electromagnetic wave produces by your phone are picked up by the tower and system on
the tower convert them high-frequency light pulses.
These light pulses are further transferred to the base transceiver for the further signal
transferring.
After that signal transferred to the destination server, for what you searched, after that reverse
process takes place.
62
Data communication and Computer networking
9. Hotspot
A hotspot is a technology which is relatively similar to the wifi. Hotspot provides internet
access to users via WLAN in the specific area to their location.
For illustration; router and modem are like hotspots which transfer the data in the form of a
radiofrequency wave in the surrounding of its centralized position.
Like Smartphone and mobile hotspots, here you can share your data with your friends.
You can say that by the help of a hotspot we can create wifi.
They are of two types: Passwords protected and free to uses.
But beware that free hotspots are most of the time on the target of the hackers.
10. Broadband
Broadband is also known as a wideband because during communication it uses and provides a
wide band of frequencies. The wider the bandwidth of a channel, the greater will be the
information-carrying capacity.
Here you can achieve speed up to 100 Mbps, it typically depends upon the cables we use like in
case of coaxial cable data transfer speed may vary but in optical fiber cables speed will be high.
Generally, its speed in Mbit/sec but it can be Gbit/sec. (Found during testing in optical fiber
cable)
ADSL broadband is used in homes and offices.
These are well-known types of internet connections, which generally people use.
63
Data communication and Computer networking
Unit- 5
NETWORK ADDRESSING
64
Data communication and Computer networking
Port address
• The transport layer assign temporary address to the client port and it has table that maps
to well-known port address.
• Client port address 46017
• Well known port address 80
• The address at the transport layer are called port number
• Client port number and server port number are involved when client communicates.
• The port number is between 0 to 65,535.
• This range is large enough to allow thousands of clients or servers to run at the same time
on a computer.
IP address
• Addresses used in the Internet are called IP address.
• An IP address is made of 4 bytes (32 bits)
• Each byte can have a value between 0 and 255.
• The notation is referred to as dotted-decimal notation.
Domain name and Address:
Domain names
• The internet uses an address to identify an entity.
• Each computer connected to the Internet needs to be uniquely identified.
• The full domain name is a sequence of labels separated by dots.
• Generic domain names and country domain name are two categories.
• https://www.tucl.org.np/
• https://www.ku.edu.np/
Domain address (name)
• gov - Government agencies
• edu - Educational institutions
• org - Organizations (nonprofit)
• mil - Military
• com - commercial business
• net - Network organizations
• biz – business and firms
• coop- cooperative organizations
• Info – information service provider
• ca - Canada
• th - Thailand
65
Data communication and Computer networking
Unit-6
NETWORK PROTOCOLS AND SERVICES
Protocol
• The rules of data communication among entities (bits of data).
• Entities are anything capable of sending and receiving information.
• The entities must agree on a protocol.
• A protocol is a set of rules that governs data communications.
• A protocol defines what is communicated, how it is communicated, and when it is
communicated.
Three elements of protocol
• Syntax: structure of data. Meaning the order in which they are presented. E.g. the first 8
bits of data is the address of the sender. The second 8 bits data is the address of the
receiver, and the rest of the stream to be the message itself.
• Semantics: the meaning of each section of bits. How the particular pattern to be
interpreted, and what action to be based on that interpretation?
• Timing: When data should be sent and how fast they can be sent? E.g. if a sender
transmits data at 100Mbps but the receiver receive data at only 1 Mbps, the transmission
will overload the receiver and data will be largely lost
66
Data communication and Computer networking
• It establishes a connection before data transfer and terminates the connection after data
transfer.
• It provides damage control, loss control, order control, and duplicate control
• Most of the application protocols, SMTP, HTTP, FTP, and TELNET, use the services of
TCP
Stream Control Transmission Protocol (SCTP)
• SCTP is new reliable message oriented transport layer protocol that combined the best
feature of UDP and TCP.
Internet protocol (IP)
• IP is the transmission mechanism
• IP is an unreliable and connectionless datagram protocol.
• IP provides no error checking or tracking.
• If reliability is important, IP must paired with a reliable protocol TCP
Application layer protocols
• Mail Access Protocols
• The stored mail remains in the mail server until it is retrieved by the recipient through the
access protocol
Post Office Protocol (PoP)
• The client PoP software is installed on the recipient computer; the server PoP software is
installed on the mail server.
• Mail access starts with the client when the user needs to download the received email
from the mailbox on the mail server.
• Does not allow the user to organize mail on their on the server
• The user can not have different folders on the server.
• It does not allow the user to check the contents of the mail before downloading.
Internet mail access protocol (IMAP)
• A user can check the email header prior to downloading
• A user can search the contents of the email prior to downloading
• A user can create a hierarchy of mailboxes in folder for email storage.
• The version of IMAP in use today is version 4
68
Data communication and Computer networking
Unit -7
TRANSMISSION MEDIA:
Guided: Twisted-pair, Coaxial, Optical Fiber
Types of Transmission Media
In data communication terminology, a transmission medium is a physical path between the
transmitter and the receiver i.e it is the channel through which data is sent from one place to
another. Transmission Media is broadly classified into the following types:
1. GUIDED MEDIA:
• Guided media, which are those that provide a physically limited path for the signal,
include twisted-pair cable, coaxial cable, and fiber-optic cable
Features:
High Speed
Secure
Used for comparatively shorter distances
There are 3 major types of Guided Media:
69
Data communication and Computer networking
iv. Consists of two conductors (usually copper), each with its own colored plastic insulation
for identification.
v. Colors are used both to identify the specific conductors in a cable and to indicate which
wires belong in pairs and how they relate to other pairs in a larger bundle.
vi. Twisting decrease the effect of noise on the signal being carried by the cable by creating
two equal effects that cancel each other out when they arrive at the destination
Advantages:
Cheaper
Ease to install
Flexible
High speed capacity
Higher grades of UTP are used in many LAN technologies, including Ethernet and Token
Ring
Disadvantages:
Susceptible to external interference
Lower capacity and performance in comparison to STP
Short distance transmission due to attenuation
i. It has a metal foil or braided-mesh covering that encases each pair of insulated
conductors.
ii. The metal casing prevents the penetration of electromagnetic noise. It also eliminate a
phenomenon called crosstalk.
iii. It is more costly than UTP, but less susceptible to noise.
Advantages:
Better performance at a higher data rate in comparison to UTP
Eliminates crosstalk
Comparatively faster
Disadvantages:
70
Data communication and Computer networking
Comparatively difficult to install and manufacture
More expensive
Bulky
Advantages:
High Bandwidth
Better noise Immunity
Easy to install and expand
Inexpensive
Disadvantages:
Single cable failure can disrupt the entire network
Advantages:
Increased capacity and bandwidth
Light weight
71
Data communication and Computer networking
Less signal attenuation
Immunity to electromagnetic interference
Resistance to corrosive materials
Disadvantages:
Difficult to install and maintain
High cost
Fragile
Unidirectional, ie, will need another fiber, if we need bidirectional communication
2. UNGUIDED MEDIA:
It is also referred to as Wireless or Unbounded transmission media.No physical medium is
required for the transmission of electromagnetic signals.
Features:
Signal is broadcasted through air
Less Secure
Used for larger distances
There are 3 major types of Unguided Media:
(i) Radiowaves –
These are easy to generate and can penetrate through buildings. The sending and receiving
antennas need not be aligned. Frequency Range:3KHz – 1GHz. AM and FM radios and cordless
phones use Radiowaves for transmission.
Further Categorized as (i) Terrestrial and (ii) Satellite.
(ii) Microwaves –
It is a line of sight transmission i.e. the sending and receiving antennas need to be properly
aligned with each other. The distance covered by the signal is directly proportional to the height
of the antenna. Frequency Range:1GHz – 300GHz. These are majorly used for mobile phone
communication and television distribution.
(iii) Infrared –
Infrared waves are used for very short distance communication. They cannot penetrate through
obstacles. This prevents interference between systems. Frequency Range:300GHz – 400THz. It
is used in TV remotes, wireless mouse, keyboard, printer, etc.
72
Data communication and Computer networking
Unit-8
NETWORK SECURITY:
Authentication, Digital signatures, Firewalls
Introduction
• User expects confidentiality and data integrity.
• Network security involves four aspects
• Privacy (confidentiality)
• Authentication
• Integrity
• Nonrepudiation
Privacy, Authentication, Integrity and Nonrepudiation
• Privacy: Receiver expect confidentiality. The transmitted message must make sense to
only the intended receiver
• Authentication: receiver is sure of the sender‘s identity
• Integrity: data must arrive at the receiver exactly as it was sent
• Nonrepudiation: It means that a receiver must be able to prove that a received message
came from a specific sender.
Privacy
• The message must be meaningless for unauthorized receiver.
• The data to be encrypted at the sender site is called plaintext.
• The encrypted data is called ciphertext and is decrypted at the receiver.
• There are two methods for encryption/decryption :
• Secret key method
• Public key method
Secret-key and public key encryption/decryption
• The same key is used by the sender (for encryption) and the receiver (for decryption).
The key is shared.
• The private key is kept by the receiver and public key is announced to the public
• The private key is used to decrypt the message.
Digital signature
• The idea is similar to the signing of a document. When we send a document
electronically.
• We can sign the entire document or we can sign a condensed version of the document
Signing the whole document
• Public-key encryption can be used to sign a document.
• The sender uses her private key to encrypt, the receiver use the public key of the sender
to decrypt.
73
Data communication and Computer networking
• Digital signature can provide integrity, authentication, and nonrepudiation
Firewalls
• One way an organization can protect itself from the outside world is through a firewall.
• A firewall is a router installed between the internal network of an organization and the
rest of the internet.
• It is designed to forward some packets and filter others.
• E.g. firewall may filter all incoming packets destined for a specific host or specific
server.
74
Data communication and Computer networking
Unit-9
NETWORK MODELS: (INTERNET)
Application Layer
• Client Server Paradigm
• Application layer program are based on the concept of clients and servers.
• Client: one to request a service. Application program runs at local site
• Server: one to provide a service. Application program runs at remote site
• Should the application program be able to request as well as provide services?
• Client application program request a service from another application program
called server. But requesting a service and providing a service are separate from
each other.
• They work in pair called client-server model
Client-server paradigm
• Should an application program provide service for only one specific program installed
elsewhere or should it provide service for any application program that requests this
service?
• The client-server relationship is many-to-one.
• When should an application program be running?
• Generally, a client program runs only when it is needed. Server program runs all
the time.
• Should there be just one universal application program that can provide any type of
service a user wants? Or should there be one application Program for each type of
service?
• There is both specific and general application program that can provide any type of
service. If the server is overloaded by user then server uses specific application program
to provide service.
Client and Server
Client server
• Client is a program running on the local • A server is a program running on the
machine remote machine providing service to the
• Client opens the communication channel, client.
sends its request, receives the response, • It opens the door for incoming requests
and closes the channel. from clients, but it never initiates a
• Multiple requests are allowed service until it is requested to do
Addressing
• A client and a server communicate with each other through addresses.
• Request must include address of destination and source
75
Data communication and Computer networking
• While responding request, server address becomes source address and client will be
destination address.
• Each application has its own address format.
• E.g. email address: lilanyaichyai@tucdlis.edu.np
• Web page: www.tucdlis.edu.np • Domain
• Local Part
Here edu.np is Domain and lilanyaiichyai is local part.
Email
• Email is a store-and-forward application. This means a message can be sent to someone
not currently connected to the Internet.
• Email supports:
• Sending a single message to one or more recipients
• Sending message and include text, voice, video or graphics
Components of Email
• User Agents (UAs)
• UA is software installed in user computer. Read, reply, forward, save and compose
message. E.g. Berkeley mail, Pine, and Elm were text based. Eudora, Microsoft‘s
outlook, and Netscape‘s messenger use a GUI (graphic user interface)
• Not responsible to sending and receiving mail
• Mail transfer agents (MTAs)
• Sent email. To send there must me a client MTA and a system must have a server MTA.
Client MTA is installed in users‘ computer. Mail server must have both client and server
MTA
• Simple Mail Transfer Protocol (SMTP)
Data Communication (Questions)
1. In the client server mode, what is the role of the program? What is the role of the server
program?
2. What application program allows connection to a remote system in such a way that the local
terminal appears to be a terminal appears at the remote system?
3. What is the function of SMTP?
4. Why is TELNET needed?
5. What is the difference between UA and MTA?
6. What is application to application delivery?
7. What are the phases in connection oriented delivery?
8. What is the term reliable service mean?
9. Which specific application use UDP?
10. Which specific application use ICT?
11. What is a three-way handshake and when it is used?
76
Data communication and Computer networking
Unit-10
NETWORK MODELS
Transport Layer
• Application-to-application delivery/ process-to-process delivery
• A transport layer protocol takes a message from an application program
• Deliver packets from client application program to server application program
Function / Duties of transport layer
• Packetizing
• Creating connection
• Addressing
• Providing reliability
Packetizing
• Dividing large messages
– A long message may be larger than the maximum size that can be handled by the
lower layer protocols
– Divided into sections with each section inserted (encapsulated) into a separate
packet
• Adding a header
– A header is added to allow the transport layer to perform its other functions
Creating connection
• Connection Establishment
– Connection request packet to the intended receiver
– Responding computer returns a confirmation packet
– Returns a packet acknowledging the confirmation
• Data Transfer
– Send data and forth
– Packets are numbered to preserve the ordered relationship between the packets
• Connection Termination
– Sends termination request packet to the other party
– Second party acknowledge the receipt of the termination
– Request to terminate the connection in the opposite direction
– The first party acknowledges the receipt of the termination request
Connectionless Delivery
• No session or no virtual connection between two application programs
• A connectionless transport-layer protocol is used when an application needs to send one
packet quickly without the overhead of connection establishment and termination
Internet Protocols
• Composition of TCP and UDP
77
Data communication and Computer networking
TCP and UDP
• User datagram protocol UDP
– Connectionless, unreliable transport protocol
– Adds a small header called checksum to the data received from application layer
• Checksum allow the receiver to detect errors. If error detected, it is simply
discarded with no notification of sender
– Packetizing
– Adding header
• Used for quick action
User Datagram
• UDP packets is called user datagram
• Consists header (64 bits)
Technical focus of datagram
78
Data communication and Computer networking
79
Data communication and Computer networking
Unit 11
NETWORK MODELS
Network Layer:
(Addressing, routing, packetizing, fragmenting)
• Computer-to-computer or host-to-host delivery/ source computer to the destination
computer
• A network-layer protocol takes a message from a computer and delivers it to another
computer
Duties of network layer
• Internetworking • Packetizing
• Addressing • Fragmenting
• Routing
Addressing
• Uniquely identify each device on the Internet to allow global communication between all
devices.
• The network addresses must be unique.
• Network layer must uniquely and universally (addressing system must be accepted by
any host that that wants to be connected to the Internet) define the connection of a host
(computer) or a router to the Internet.
• If a device has two connections to the Internet, it has to addresses.
IP address
• Addresses used in the Internet are called IP addresses
• IP address is made of 4 bytes (4*8=32 bits)
• Each byte can have a value between 0 and 255 ( in decimal number)
• The bytes are separated by a dot (.) e.g. 10.34.234.8 (in decimal number)
• Convert 10.34.234.8 into binary digit?
• If Internet uses 32-bit addresses=232 (4,294,967,296) more than 4 billion addresses. More
than 4 billion devices could be connected.
Address hierarchy
• The Internet has two or three levels of hierarchy in addressing.
• Two –level address: Network and host
• In the case of single network, two levels of addressing is adequate.
• First part of address is the same for each host; the second part differs to define each host.
• The common part of the address is called the netid (or prefix); the variable part is called
the hosted (or suffix)
• The first address in a group is called the network address.
Three-level address: network (netid), sub-network (subnetid), and host (hostid)
• Usually there is the need of more than on network. There are smaller networks formed.
80
Data communication and Computer networking
• IP addresses is made up of 32bits = 4 bytes (value between 0 and 255)
• Three level address includes
• Network address: first 2 bytes is defined as network address, which is same for all
networks
• Sub-network address : 3rd byte can be defined a subnet address. It is same for all
computers connected to same subnet
• Host address: 4th byte is host address and it is unique for each computer.
Address resolution
Application layer address Transport layer address Network layer
81
Data communication and Computer networking
Routing
83
Data communication and Computer networking
84
Data communication and Computer networking
Unit 12
NETWORK MODELS
Data Link Layer: (Duties, Data link layer)
• It is Hop-to-hop delivery. It provides services to network layer. Services are:
• Hop-to-hop delivery • Error control
• Packetizing • Flow control
• addressing • Medium access control
Hop-to-Hop Delivery
• A packet to reach its destination, it must pass through several LANs and WANs and the
router that connect them.
• Hop-to-hop delivery is the responsibility of data link layer
Packetizing
• Encapsulate in the appropriate packet at the data link layer
• Most LANs called such packet as frames
• For packetizing, it is called framing in data link layer of the underlying LANs and WANs
• Header and trailer are added in the packet
• Header: addressing information and information about upper-layer protocol
• Trailer: extra data added to detect error
Addressing
• Physical address is called MAC address. Media Access Control address. Hardware
identification number.
• A LAN address is 6 bytes(48 bites)
• A WAN address is usually longer than LAN
• The physical address for most computers on LAN is imprinted on the network card that is
installed in the computer.
• If the network card is changed, the physical address of the computer is also changed.
85
Data communication and Computer networking
How a router knows the address of next hop? Address resolution
• IP address (logical address) of next hop and the physical address of the next hop are
stored statically in a routing table.
• Physical address is corresponded with logical address.
• But statically performing such task is difficult so such address mapping can be done
dynamically.
• Address Resolution Protocol (ARP) is employed to solve this problem of identifying
physical address.
• Sender (router) sends ARP query packet to the destination
• Physical and IP addresses of the sender
• IP address of the receiver
ARP Operation
86
Data communication and Computer networking
• These services include hop-to hop delivery, packetizing, addressing, error control,
flow control, and medium access control.
A. HOP-TO-HOP DELIVERY
87
Data communication and Computer networking
– Every time a physical address is changed, the table must be updated.
– Updating tables on all machines at frequent intervals is a very demanding task.
• The mapping, however, can be done dynamically, which means that the sender asks the
receiver to announce its physical address when needed.
– The Address Resolution Protocol (ARP) is designed for this purpose.
ARP operation
Anytime a host, or a router, needs to find the physical address of another host or router
on its network, it sends an ARP query packet.
The packet includes the physical and IP addresses of the sender and the IP address of the
receiver.
Because the sender does not know the physical address of the receiver, the query is
broadcast over the network.
D. ERROR CONTROL
Data can be corrupted during transmission. For reliable communication, errors must be
prevented, or detected and corrected.
• Source Of Errors
– White Noise
– Impulse Noise
– Crosstalk
– Echo
– Jitter
– Attenuation
– Distortion
• Types Of Errors
– Data are sent from one device to another in the form of binary data (0s and 1s).
– Two types of errors may happen:
• Single-bit errors
• Burst errors
• In a single-bit error, only 1 bit in the data unit has changed.
Single-bit error
88
Data communication and Computer networking
• Burst error does not necessarily mean that the errors occur in consecutive bits.
• The length of the burst is measured from the first corrupted bit to the last corrupted
bit.
• Some bits in between may not have been corrupted.
Error detection
Error detection uses the concept of redundancy, which means adding extra bits for detecting
errors at the destination.
Redundancy
• The key to error detection is redundancy, a short group of bits appended to or inserted
to each unit of data.
• This technique is called redundancy because the extra bits are redundant to the
information.
• They are discarded as soon as the accuracy of the transmission has been determined.
89
Data communication and Computer networking
Detection methods
• Three types of redundancy checks are used in the data link layer:
o Vertical redundancy check (VRC)
o Longitudinal redundancy check (LRC)
o Cyclic redundancy check (CRC)
In vertical redundancy check (VRC), a parity bit is added to every data unit so that the
total number of 1s becomes even.
Even parity VRC concept
• The most common and least expensive mechanism for error detection.
• Often called a parity check.
• In this technique, a redundant bit, called a parity bit, is appended to every data unit so that
the total number of 1s in the unit(including the parity bit)becomes even.
LRC
• The most powerful of the redundancy checking techniques is the cyclic redundancy
check (CRC).
• Unlike VRC and LRC, which are based on addition, CRC is based on binary division.
• Instead of adding bits together to achieve a desired parity, a sequence of redundant
bits, called the CRC or the CRC remainder, is appended to the end of a data unit so
that the resulting data unit becomes exactly divisible by a second, predetermined
binary number.
• A remainder indicates that the data unit has been damaged in transit and therefore
must be rejected.
Error Correction Using Retransmission
• Error correction using retransmission follows a very simple rule.
• If the sender has not received positive news in due time, the frame is retransmitted.
• Frames are retransmitted in three cases:
– The frame is damaged.
– The frame is lost.
– Acknowledgment is lost.
• There are two protocols for retransmission:
– Stop-and-wait automatic repeat request.
– Sliding-window automatic repeat request.
Stop and wait ARQ
91
Data communication and Computer networking
Stop-and-wait ARQ is very slow.
• The Sender stops sending until it hears about the fate of the one frame sent.
Technical Focus: Procedure for Stop-And-Wait ARQ
The sending device keeps a copy of the last frame transmitted until it receives an
acknowledgment for that frame
Both data frames and ACK frames are numbered 0 and 1 alternately. A data 0 frame is
acknowledged by an ACK 1 frame.
If an error is discovered in a data frame, a negative acknowledgment (NAK) frame is
returned.
If an expected acknowledgment is not received within an allotted time period, the
sender assumes that the last data frame was lost in transit and sends it again.
Sliding-window ARQ
92
Data communication and Computer networking
o Sliding-window ARQ provides flow control because the size of the sending
window can be matched to the size of the receiver buffer.
F. MEDIUM ACCESS CONTROL
• When computers use a shared medium (cable or air), there must be a method to control
access to the medium at any moment.
• If there is no rule to specify which vehicle has the right-of-way, there may be a conflict or
even a collision.
• To prevent this conflict or collision on a network, there is a need for a medium access
control (MAC) method.
• The use of a regulated method ensures that there is no conflict among the station.
Medium access methods
Several methods for access control have been devised in the past.
They can be divided into two broad categories.
Select
Poll
The poll/select method is mostly used in time-sharing systems when a central computer is
used to control other computers.
93
Data communication and Computer networking
Token passing network
Random Access
• To avoid access conflict or to resolve it when it does happen, each station follow
certain steps to access the medium:
1. The station checks to make sure the medium is idle. This is called carrier sense.
This is analogous to the rules in an assembly. If a person wants to speak, he must first
listen to make sure no one else is talking.
2. If the medium is idle, the station can send data.
3. Even through steps 1and steps 2 are followed, there is still a potential for collision.
• For example: two stations may be checking the medium at the same time;
neither senses that the medium is in use and both send at the same time.
• To avoid collision the sending stations can make a reservation for use of the
medium.
• To detect collision (and send the data again), the station need to continue
monitoring the medium.
CSMA/CD
CSMA/CA
Token passing is used mostly by local area networks (LANs).
CSMA/CD is used in the Ethernet LAN.
CSMA/CA is used in the wireless LANs.
DATA LINK PROTOCOLS
A data link protocol is a set of specifications used to implement the data link layer.
In a character-oriented protocol, the frame is interpreted as a series of characters. In a
bit-oriented protocol, the frame or packet is interpreted as a series of bits.
All bit-oriented protocols are related to high-level data link control (HDLC), a bit-
oriented protocol.
94
Data communication and Computer networking
Unit-13
NETWORK MODELS
Physical layer: (Digital, Analog, Transmission modes, Line configurationally, Duplicity)
Physical layer:
• Physical layer positioned between data link layer and transmission medium
• Give service to data link layer
• Physical layer must also take care of transmission medium
• Transmission medium is a passive entity; it has no internal program or logic for control
like other layers
Physical layer positioned between data link layer and transmission medium. Give service to
data link layer.
Physical layer is the bottom-most layer of the Internet Model and is responsible for the
interaction with the transmission media i.e. the physical part of the network which connects the
components together. As a result of this the layer is responsible for carrying information from
one node to the other.
Of the many tasks that are performed by the physical layer, one is to provide service to the data
link layer. This layer consists of 0s and 1s which are organized into frames and need to be
transmitted across the transmission medium. Thus the physical layer has to convert these binary
values into signals so that it can be transmitted. This layer also needs to decide the total number
of logical channels required for transmitting the data. It is so because the transmission medium
in itself is passive and can't decide the flow direction on its own.
95
Data communication and Computer networking
Digital signal and analog signal
• Data must be transformed to electromagnetic energy (signal) to be acceptable to the
transmission media
• Just like data, signal can be digital and analog.
• Eg. A 1can be encoded as a positive voltage and a 0 as zero level of energy.
Bit interval and bit rate
• Bit interval is the time required to send one single bit.
• Bit rate is the number of bit intervals per second.
• Bit rate is usually expressed in bits per second (bps)
Units of bits rate
Analog signal
• Simple signal
• Composite signal
Analog and Digital are the different forms of signals. Signals are used to carry information from
one device to another. Analog signal is a continuous wave that keeps on changing over a time
period. Digital signal is discrete in nature. The fundamental difference between analog and
digital signal is that analog signal is represented by the sine waves whereas, the digital signal is
represented by square waves.
Definition of Analog Signal
Analog signal is a kind of continuous wave form that changes over time. A simple analog signal
is a sine wave that cannot be decomposed further. An analog signal is described using
amplitude, period or frequency and phase. Amplitude marks the maximum height of the signal.
Frequency marks the rate at which signal is changing. Phase marks the position of the wave
with respect to time zero.
Digital signals are easier to transmit and are more reliable when compared to analog signals.
Digital signal has a finite range of values. The digital signal consists 0s and 1s.
Comparison Chart
BASIS FOR
ANALOG SIGNAL DIGITAL SIGNAL
COMPARISON
97
Data communication and Computer networking
DATA TRANSMISSION
Data transmission refers to the process of transferring data between two or more digital devices.
Data is transmitted from one device to another in analog or digital format. Basically, data
transmission enables devices or components within devices to speak to each other.
Data is transferred in the form of bits between two or more digital devices. There are two
methods used to transmit data between digital devices:
A. Serial transmission and
B. Parallel transmission
Serial data transmission sends data bits one after another over a single channel. Parallel data
transmission sends multiple data bits at the same time over multiple channels.
A. SERIAL TRANSMISSION
When data is sent or received using serial data transmission, the data bits are organized in a
specific order, since they can only be sent one after another. The order of the data bits is
important as it dictates how the transmission is organized when it is received. It is viewed as a
reliable data transmission method because a data bit is only sent if the previous data bit has
already been received.
1. Asynchronous and
2. Synchronous
98
Data communication and Computer networking
In Asynchronous Transmission data flows in a half-duplex mode, 1 byte or a character at a
time. It transmits the data in a continuous stream of bytes. In general, the size of a character sent
is 8 bits to which a parity bit is added, i.e. a start and a stop bit that gives the total of 10 bits. It
does not require a clock for synchronization; rather it uses the parity bits to tell the receiver how
to interpret the data. These parity bits are known as start and stop bits which control the transfer
of data.
It uses character-based synchronization so that the receiving terminal could synchronize itself
with the receipt of data on a character. It is simple, fast, and economical and does not require a
2-way communication. Letters, emails, forums, televisions and radios are some of the
examples of Asynchronous Transmission. The voice-band channels that are of a narrow type
and operate on a slower speed are utilized in the asynchronous transfer. Here, the transmitting
device works manually or intermittently.
99
Data communication and Computer networking
Synchronous Transmission is efficient, reliable and is used for transferring a large amount of
data. It provides real-time communication between connected devices. Chat Rooms, Video
Conferencing, telephonic conversations, as well as face to face interactions, are some of the
examples of Synchronous Transmission.
The voice-band and broad-band channels are usually used in the synchronous transmission
modes as it provides a faster speed up to 1200 bps and serves the purpose of high data transfer
speed.
Difference between synchronous and asynchronous
Serial Transmission data is sent bit by bit, in such a way that each bit follows another. It is of
two types namely, Synchronous and Asynchronous Transmission. One of the major
differences is that in Synchronous Transmission, the sender and receiver should have
synchronized clocks before data transmission. Whereas Asynchronous Transmission does not
require a clock, but it adds a parity bit to the data before transmission.
Furthermore, the synchronous transmission uses synchronization characters while asynchronous
method employs start/stop bits, in order to alert the modem when data are being sent and when
these transmissions are completed are known as message characters.
Key Differences between Synchronous and Asynchronous Transmission
1. In Synchronous Transmission, data is transferred in the form of frames. On the other hand, in
Asynchronous Transmission data is transmitted 1 byte at a time.
2. Synchronous Transmission requires a clock signal between the sender and receiver so as to
inform the receiver about the new byte. In contrast, in Asynchronous Transmission sender
and receiver does not require a clock signal as the data sent here has a parity bit attached to it
which indicates the start of the new byte.
3. Data transfer rate of Asynchronous Transmission is slower than that of Synchronous
Transmission.
4. Asynchronous Transmission is simple and economical, whereas Synchronous Transmission
is complicated and expensive.
5. Synchronous Transmission is efficient and has lower overhead as compared to the
Asynchronous Transmission.
6. In asynchronous data transfer, the line is kept at a stable value (logic 1) if no data is
transmitted through the line. As against, in synchronous transfer, the end of the data is
indicated by the sync character(s). Further than the sync characters, the line can be either
high or low.
Conclusion
Both Synchronous and Asynchronous Transmission have their advantages and disadvantages.
Asynchronous is simple, economical and used for transmitting a small amount of data.
Conversely, Synchronous Transmission is used for transferring the bulk of data as it is efficient
and has less overhead. Hence, we conclude that both Synchronous and Asynchronous
Transmission are necessary for data transmission.
100
Data communication and Computer networking
Comparison Chart
BASIS FOR SYNCHRONOUS ASYNCHRONOUS
COMPARISON TRANSMISSION TRANSMISSION
Transmission starts with the block It uses start bit and stop bit
Meaning header which holds a sequence of preceding and following a
bits. character respectively.
B. PARALLEL TRANSMISSION
When data is sent using parallel data transmission, multiple data bits are transmitted over
multiple channels at the same time. This means that data can be sent much faster than using
serial transmission methods.
101
Data communication and Computer networking
Example of Parallel Data Transmission
Given that multiple bits are sent over multiple channels at the same time, the order in which a
bit string is received can depend on various conditions, such as proximity to the data source,
user location, and bandwidth availability. Two examples of parallel interfaces can be seen
below. In the first parallel interface, the data is sent and received in the correct order. In the
second parallel interface, the data is sent in the correct order, but some bits were received faster
than others.
102
Data communication and Computer networking
A scenario where parallel transmission is used to send data is video streaming. When a video is
streamed to a viewer, bits need to be received quickly to prevent a video pausing or buffering.
Video streaming also requires the transmission of large volumes of data. The data being sent is
also time-sensitive as slow data streams result in poor viewer experience.
a) Serial transmission requires a single line to send data. Parallel transmission requires
multiple lines to send data.
b) There are fewer errors and less noise in serial transmission, since the transmission is done
one bit at a time. There are more errors and noise in parallel transmission, since the
transmission is done multiple bits at a time.
c) Serial transmission is slower since data flows through a single line; conversely, parallel
transmission is faster since data flows through multiple lines.
d) Serial transmission is ‗full duplex‘ since the sender can send and receive data at the same
time. Parallel transmission is ‗half duplex‘ since the data can be sent or received at any
given time.
e) The cables used in serial transmission are thinner, longer, and more economical
compared to the cables used in parallel transmission.
f) Serial transmission is reliable and straightforward. Parallel transmission is unreliable and
complicated.
103
Data communication and Computer networking
TRANSMISSION MODE
A given transmission on a communications channel between two machines can occur in several
different ways. The transmission is characterized by:
the direction of the exchanges
the transmission mode: the number of bits sent simultaneously
synchronization between the transmitter and receiver
Types of Transmission mode
Simplex
Half Duplex
Full Duplex
Simplex
A simplex connection is a connection in which the data flows in only one direction, from the
transmitter to the receiver. This type of connection is useful if the data do not need to flow in
both directions (for example, from your computer to the printer or from the mouse to your
computer...).
Half Duplex
A half-duplex connection (sometimes called an alternating connection or semi-duplex) is a
connection in which the data flows in one direction or the other, but not both at the same time.
With this type of connection, each end of the connection transmits in turn. This type of
connection makes it possible to have bidirectional communications using the full capacity of the
line.
Full Duplex
A full-duplex connection is a connection in which the data flow in both directions
simultaneously. Each end of the line can thus transmit and receive at the same time, which
means that the bandwidth is divided in two for each direction of data transmission if the same
transmission medium is used for both directions of transmission.
104
Data communication and Computer networking
Comparison Chart
Basis for
Simplex Half Duplex Full Duplex
Comparison
105
Data communication and Computer networking
Multipoint Configuration
Multipoint Configuration also known as Multi drop line configuration one or more than
two specific devices share a single link capacity of the channel is shared.
More than two devices share the Link that is the capacity of the channel is shared now. With
shared capacity, there can be two possibilities in a Multipoint Line Config:
Spatial Sharing: If several devices can share the link simultaneously, its called Spatially
shared line configuration
Temporal (Time) Sharing: If users must take turns using the link , then its called
Temporally shared or Time Shared Line Configuration
106