fundamentals of computer networks

132
Fundamentals of Computer Networks

Upload: rona

Post on 05-Jan-2016

118 views

Category:

Documents


4 download

DESCRIPTION

Fundamentals of Computer Networks. Book. Andrew S. Tanenbaum , “Computer Networks”. What is a Network?. A computer network, is a collection of computers and other hardware interconnected by communication channels that allow sharing of resources and information. Uses of Computer Networks. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Fundamentals of Computer Networks

Fundamentals of Computer Networks

Page 2: Fundamentals of Computer Networks

Book

Andrew S. Tanenbaum, “Computer Networks”

Page 3: Fundamentals of Computer Networks

What is a Network?

A computer network, is a collection of computers and other hardware interconnected by communication

channels that allow sharing of resources and information.

Page 4: Fundamentals of Computer Networks

Uses of Computer Networks• Business Applications

– Issue: Resource Sharing

– Goal: Make all programs, equipment, and especially data available to anyone on the network without regard to the physical location of the resource and the user

– Example: A group of office workers can share a common printer

– Sharing information is more important than sharing physical resources such as printers

Page 5: Fundamentals of Computer Networks

Uses of Computer Networks

• Home Applications

– Access to remote information.– Person-to-person communication.– Interactive entertainment.– Electronic commerce.

Page 6: Fundamentals of Computer Networks

Uses of Computer Networks

• Mobile Users

– Notebook Computers– Personal Digital Assistants– Smart Phones

Page 7: Fundamentals of Computer Networks

Network Hardware

• There are two types of transmission technology that are in widespread use

– Broadcast links: Short messages, called packets in certain contexts, sent by any machine are received by all the others. If the packet is intended for the receiving machine, that machine processes the packet.

– Point-to-point links: To go from the source to the destination, a packet on this type of network may have to first visit one or more intermediate machines.

Page 8: Fundamentals of Computer Networks

Network Hardware

Classification of interconnected processors by scale:

Page 9: Fundamentals of Computer Networks

Local Area Network (LAN)

• LANs, are privately-owned networks within a single building or campus of up to a few kilometers in size.

• LANs are distinguished from other kinds of networks by three characteristics:

– Size (Restricted in Size)– Transmission Technology (Cables)– Their topology

Page 10: Fundamentals of Computer Networks

Lan Topologies

Bus Ring

Page 11: Fundamentals of Computer Networks

Bus Network• In a bus network, at any instant at most one machine is the

master and is allowed to transmit. All other machines are required to refrain from sending.

• An arbitration mechanism is needed to resolve conflicts when two or more machines want to transmit simultaneously.

• IEEE 802.3, popularly called Ethernet is a bus-based broadcast network.

• Computers on an Ethernet can transmit whenever they want to; if two or more packets collide, each computer just waits a random time and tries again later.

Page 12: Fundamentals of Computer Networks

Ring Network

• Each bit circumnavigates the entire ring in the time it takes to transmit a few bits, often before the complete packet has even been transmitted.

• As with all other broadcast systems, some rule is needed for arbitrating simultaneous accesses to the ring.

• IEEE 802.5 (the IBM token ring), is a ring-based LAN.

Page 13: Fundamentals of Computer Networks

Static & Dynamic Networks• Depending on how the channel is allocated networks can be

further divided into static and dynamic.

• Static allocation would be to divide time into discrete intervals and use a round-robin algorithm, allowing each machine to broadcast only when its time slot comes up.

• Dynamic allocation methods for a common channel are either centralized or decentralized.

– In the centralized channel allocation method, there is a single entity, for example, a bus arbitration unit, which determines who goes next.

– In the decentralized channel allocation method, each machine must decide for itself whether to transmit.

Page 14: Fundamentals of Computer Networks

Metropolitan Area Networks (MAN)

Page 15: Fundamentals of Computer Networks

Wide Area Networks (WAN)• A WAN, spans a large geographical area, often

a country or continent.• It contains a collection of machines (hosts)

intended for running user programs.

Page 16: Fundamentals of Computer Networks

Wide Area Networks (WAN)

• The hosts are connected by a communication subnet, or just subnet for short.

• The hosts are owned by the customers (e.g., people's personal computers), whereas the communication subnet is typically owned and operated by a telephone company or Internet service provider.

• The job of the subnet is to carry messages from host to host, just as the telephone system carries words from speaker to listener.

Page 17: Fundamentals of Computer Networks

Wide Area Networks (WAN)

• In most wide area networks, the subnet consists of two distinct components

– Transmission Lines– Switching Elements.

• Transmission lines move bits between machines.

• Switching elements are specialized computers that connect three or more transmission lines.

Page 18: Fundamentals of Computer Networks

Routing

Page 19: Fundamentals of Computer Networks

Wireless Networks• Wireless networks can be divided into three

main categories:

– System interconnection (short-range radio)– Wireless LANs.– Wireless WANs.

Page 20: Fundamentals of Computer Networks

Home Networks

• Home networking is on the horizon.

• The fundamental idea is that in the future most homes will be set up for networking.

• Every device in the home will be capable of communicating with every other device, and all of them will be accessible over the Internet.

Page 21: Fundamentals of Computer Networks

Internetworks• Many networks exist in the world, often with different hardware

and software.

• People connected to one network often want to communicate with people attached to a different one.

• The fulfillment of this desire requires that different, and frequently incompatible networks, be connected, sometimes by means of machines called gateways to make the connection and provide the necessary translation.

• A collection of interconnected networks is called an internetwork or internet.

Page 22: Fundamentals of Computer Networks

Network Software – Protocol Hierarchies

• To reduce their design complexity, most networks are organized as a stack of layers.

• Each layer is a kind of virtual machine, offering certain services to the layer above it.

• Layer n on one machine carries on a conversation with layer n on another machine. The rules and conventions used in this conversation are collectively known as the layer n protocol.

• Basically, a protocol is an agreement between the communicating parties on how communication is to proceed.

Page 23: Fundamentals of Computer Networks

Network Software – Protocol Hierarchies

Page 24: Fundamentals of Computer Networks

Network Software – Protocol Hierarchies

Page 25: Fundamentals of Computer Networks

Network Software – Protocol Hierarchies

Page 26: Fundamentals of Computer Networks

Connection-Oriented and Connectionless Services

• To use a connection-oriented network service, the service user first establishes a connection, uses the connection, and then releases the connection.

• Connectionless service is modeled after the postal system. Each message carries the full destination address, and each one is routed through the system independent of all the others.

Page 27: Fundamentals of Computer Networks

Connection-Oriented and Connectionless Services

Page 28: Fundamentals of Computer Networks

Service Primitives (Operations)

Page 29: Fundamentals of Computer Networks

Reference Models

• OSI reference model– Protocols associated with the OSI model are rarely

used– The model itself is actually quite general and still

valid• TCP/IP reference model– The model itself is not of much use– The protocols are widely used

Page 30: Fundamentals of Computer Networks

OSI Reference Model• Developed by the

International Standards Organization (ISO)

• The model is called the ISO OSI (Open Systems Interconnection) Reference Model

Page 31: Fundamentals of Computer Networks

OSI Reference Model• A layer should be created where a different abstraction is needed.

• Each layer should perform a well-defined function.

• The function of each layer should be chosen with an eye toward defining internationally standardized protocols.

• The layer boundaries should be chosen to minimize the information flow across the interfaces.

• The number of layers should be large enough that distinct functions need not be thrown together in the same layer out of necessity and small enough that the architecture does not become unwieldy.

Page 32: Fundamentals of Computer Networks

OSI Reference Model

• OSI model itself is not a network architecture because it does not specify the exact services and protocols to be used in each layer.

• ISO has also produced standards for all the layers, although these are not part of the reference model itself.

Page 33: Fundamentals of Computer Networks

The Physical Layer

• Task: Transmitting raw bits over a communication channel.

– Making sure that when one side sends a 1 bit, it is received by the other side as a 1 bit, not as a 0 bit

– How many volts should be used to represent a 1 and how many for a 0

– How many nanoseconds a bit lasts

Page 34: Fundamentals of Computer Networks

The Data Link Layer

• Task: To transform a raw transmission facility into a line that appears free of undetected transmission errors to the network layer.

– Input data is divided into data frames (typically a few hundred or a few thousand bytes) and these frames are transmitted sequentially

– How to keep a fast transmitter from drowning a slow receiver in data

Page 35: Fundamentals of Computer Networks

The Network Layer

• Task: The network layer controls the operation of the subnet.

– How packets are routed from source to destination– The quality of service provided is a network layer

issue– In broadcast networks, the routing problem is

simple, so the network layer is often thin or even nonexistent!

Page 36: Fundamentals of Computer Networks

The Transport Layer• Task: Accept data from above, split it up into smaller units

if need be, pass these to the network layer, and ensure that the pieces all arrive correctly at the other end.

– Determines what type of service to provide to the session layer– The transport layer is a true end-to-end layer.– A program on the source machine carries on a conversation with

a similar program on the destination machine, using the message headers and control messages.

– In the lower layers, the protocols are between each machine and its immediate neighbors, and not between the ultimate source and destination machines

Page 37: Fundamentals of Computer Networks

The Session Layer

• Task: allows users on different machines to establish sessions between them.

– Keeping track of whose turn it is to transmit– Preventing two parties from attempting the same

critical operation at the same time

Page 38: Fundamentals of Computer Networks

The Presentation Layer

• Task: Presentation layer is concerned with the syntax and semantics of the information transmitted

– Allows higher-level data structures to be defined and exchanged.

Page 39: Fundamentals of Computer Networks

The Application Layer

• HTTP (Hypertext Transfer Protocol)• File transfer,• Electronic Mail

Page 40: Fundamentals of Computer Networks

The TCP/IP Reference Model

• Goals– Network must be able to survive loss of subnet

hardware, with existing conversations not being broken off

– A flexible architecture was needed since applications with divergent requirements were envisioned (Transferring files, realtime speech transmission)

Page 41: Fundamentals of Computer Networks

The TCP/IP Reference Model

Page 42: Fundamentals of Computer Networks

TCP/IP The Internet Layer

• Permit hosts to inject packets into any network and have them travel independently to the destination (potentially

• Packets may arrive in a different order than they were sent, in which case it is the job of higher layers to rearrange them, if in-order delivery is desired.

Page 43: Fundamentals of Computer Networks

TCP/IP The Transport Layer

• TCP (Transmission Control Protocol)– Allows a byte stream originating on one machine to be

delivered without error on any other machine in the internet

– Handles flow control to make sure a fast sender cannot swamp a slow receiver with more messages than it can handle.

• UDP (User Datagram Protocol)– A protocol for applications that do not want TCP's

sequencing or flow control and wish to provide their own

Page 44: Fundamentals of Computer Networks

Protocols in the TCP/IP model

Page 45: Fundamentals of Computer Networks

TCP/IP Application Layer

• TELNET (Virtual Terminal)• FTP (File Transfer Protocol)• SMTP (Simple Mail Transfer Protocol)• DNS (Domain Name System)• HTTP (Hypertext Transfer Protocol)

Page 46: Fundamentals of Computer Networks

The Hybrid Reference Model

Page 47: Fundamentals of Computer Networks

The Theoretical Basis: Fourier Analysis

Any reasonably behaved periodic function, g(t) with period T can be constructed as the sum of a (possibly infinite) number of sines and cosines

Page 48: Fundamentals of Computer Networks

Transmission of ‘b’

• The example of the transmission of the ASCII character ''b'' encoded in an 8-bit byte.

• The bit pattern that is to be transmitted is 01100010.

Page 49: Fundamentals of Computer Networks

Transmission of ‘b’

Page 50: Fundamentals of Computer Networks

Bandwidth• No transmission facility can transmit signals without losing some power

in the process.

• If all the Fourier components were equally diminished, the resulting signal would be reduced in amplitude but not distorted.

• Unfortunately, all transmission facilities diminish different Fourier components by different amounts, thus introducing distortion.

• Usually, the amplitudes are transmitted undiminished from 0 up to some frequency fc with all frequencies above this cutoff frequency attenuated.

• The range of frequencies transmitted without being strongly attenuated is called the bandwidth.

• In practice, the cutoff is not really sharp.

Page 51: Fundamentals of Computer Networks

Bandwidth• Given a bit rate of b bit/s, the time required to send 8

bits is 8/b sec, so the frequency of the first harmonic is b/8 Hz.

• An ordinary telephone line, often called a voice-grade line, has an artificially-introduced cutoff frequency just above 3000 Hz.

• This restriction means that the number of the highest harmonic passed through is roughly 3000/(b/8) or 24,000/b

Page 52: Fundamentals of Computer Networks

The Maximum Data Rate of a Channel

• In 1924, an AT&T engineer, Henry Nyquist, realized that even a perfect channel has a finite transmission capacity.

• He derived an equation expressing the maximum data rate for a finite bandwidth noiseless channel.

H: BandwidthV: Signal Levels

Page 53: Fundamentals of Computer Networks

Guided Transmission Media

• Magnetic Media– One of the most common ways to transport data

from one computer to another is to write them onto magnetic tape or removable media.

– It is often more cost effective, especially for applications in which high bandwidth or cost per bit transported is the key factor.

Page 54: Fundamentals of Computer Networks

Guided Transmission Media

• Twisted Pair– For many applications an on-line connection is need.

– A twisted pair consists of two insulated copper wires, typically about 1 mm thick. The wires are twisted together in a helical form.

– The most common applications of the twisted pair are the telephone systems and Ethernet Networks.

– The bandwidth depends on the thickness of the wire and the distance traveled.

Page 55: Fundamentals of Computer Networks

Guided Transmission Media

• All of the twisted pair wiring types are often referred to as UTP (Unshielded Twisted Pair)

Page 56: Fundamentals of Computer Networks

Guided Transmission Media

• Shielded Twisted Pair– Cables are often shielded in an attempt to prevent

electromagnetic interference.– This shielding can be applied to individual pairs, or

to the collection of pairs.

Page 57: Fundamentals of Computer Networks

Name Type Bandwidth Applications

Level 1 0.4 MHz Telephone and modem lines

Level 2 4 MHz Older terminal systems, e.g. IBM 3270

Cat3 UTP 16 MHz 10BASE-T and 100BASE-T4 Ethernet

Cat4 UTP 20 MHz 16 Mbit/s Token Ring

Cat5 UTP 100 MHz 100BASE-TX & 1000BASE-T Ethernet

Cat5e UTP 100 MHz 100BASE-TX & 1000BASE-T Ethernet

Cat6 UTP 250 MHz 10GBASE-T Ethernet

Cat6a 500 MHz 10GBASE-T Ethernet

Class F S/FTP 600 MHz Telephone, CCTV, 1000BASE-TX in the same cable. 10GBASE-T Ethernet.

Class Fa 1000 MHz Telephone, CATV, 1000BASE-TX in the same cable. 10GBASE-T Ethernet.

Most Common Twisted-Pair Cables

Page 58: Fundamentals of Computer Networks

Guided Transmission Media

• Coaxial Cable– It has better shielding than twisted pairs, so it can

span longer distances at higher speeds.

Page 59: Fundamentals of Computer Networks

Guided Transmission Media

• Coaxial Cable– A good combination of high bandwidth and

excellent noise immunity– Modern cables have a bandwidth of close to 1 GHz– Coaxial cables used to be widely used within the

telephone system for long-distance lines but have now largely been replaced by fiber optics.

– Coax is still widely used for cable television

Page 60: Fundamentals of Computer Networks

Guided Transmission Media

• Fiber Optics– An optical transmission system has three key components

• the light source• the transmission medium• the detector.

– Conventionally, a pulse of light indicates a 1 bit and the absence of light indicates a 0 bit.

– The detector generates an electrical pulse when light falls on it.– By attaching a light source to one end of an optical fiber and a

detector to the other, we have a unidirectional data transmission system that accepts an electrical signal, converts and transmits it by light pulses, and then reconverts the output to an electrical signal at the receiving end.

Page 61: Fundamentals of Computer Networks

Guided Transmission Media

• Multimode Fiber• Single Mode Fiber– Single-mode fibers are more expensive but are widely

used for longer distances.– Currently available single-mode fibers can transmit data

at 50 Gbps for 100 km without amplification

Page 62: Fundamentals of Computer Networks

Guided Transmission Media• Transmission of Light through Fiber

Page 63: Fundamentals of Computer Networks

Guided Transmission Media• Fiber Cables– In multimode fibers, the core is typically 50 microns

in diameter, about the thickness of a human hair.– In single-mode fibers, the core is 8 to 10 microns.

Page 64: Fundamentals of Computer Networks

Connections of Fiber Cables• They can be connected in three different ways:– They can terminate in connectors and be plugged

into fiber sockets.• Connectors lose about 10 to 20 percent of the light, but

they make it easy to reconfigure systems.

– They can be spliced mechanically.• Mechanical splices just lay the two carefully-cut ends next

to each other in a special sleeve and clamp them in place.• Mechanical splices take trained personnel about 5 minutes

and result in a 10 percent light loss.

– Two pieces of fiber can be fused (melted) to form a solid connection.• A fusion splice is almost as good as a single drawn fiber,

but even here, a small amount of attenuation occurs

Page 65: Fundamentals of Computer Networks

Transmitter and Receiver• Two kinds of light sources are typically used to do the

signaling– LEDs (Light Emitting Diodes)– Semiconductor Lasers

• The receiving end of an optical fiber consists of a photodiode, which gives off an electrical pulse when struck by light.

• The typical response time of a photodiode is 1 ns, which limits data rates to about 1 Gbps.

Page 66: Fundamentals of Computer Networks

Fiber Optic Networks• Two types of interfaces are used.

– Passive Interface– Active Repeater

A fiber optic ring with active repeaters.

Page 67: Fundamentals of Computer Networks

Comparison of Fiber Optics and Copper Wire

• Advantages of Fiber (Comparing fiber to copper)– It can handle much higher bandwidths than copper.– Due to the low attenuation, repeaters are needed only about every 50 km on

long lines, versus about every 5 km for copper.– Fiber also has the advantage of not being affected by power surges,

electromagnetic interference, or power failures– Fiber is much lighter than copper. 1000 twisted pairs 1 km long weigh 8000 kg.

Two fibers have more capacity and weigh only 100 kg, which greatly reduces the need for expensive mechanical support systems that must be maintained.

– Fibers do not leak light and are quite difficult to tap. These properties gives fiber excellent security against potential wiretappers.

• Disadvantages of Fiber– Fibers can be damaged easily by being bent too much.– Since optical transmission is inherently unidirectional, two-way

communication requires either two fibers or two frequency bands on one fiber.

– Fiber interfaces cost more than electrical interfaces.

Page 68: Fundamentals of Computer Networks

Wireless Transmission• When electrons move, they create electromagnetic waves that

can propagate through space.• When an antenna of the appropriate size is attached to an

electrical circuit, the electromagnetic waves can be broadcast efficiently and received by a receiver some distance away.

• In vacuum, all electromagnetic waves travel at the same speed, no matter what their frequency. This speed, usually called the speed of light.

• In copper or fiber the speed slows to about 2/3 of this value and becomes slightly frequency dependent.

• The fundamental relation between f (frequency) , λ (Wavelength) , and c (Speed of Light in Vacuum) is

Page 69: Fundamentals of Computer Networks

The Electromagnetic Spectrum

Page 70: Fundamentals of Computer Networks

Radio Transmission• Advantages

– Easy to generate– Can travel long distances– Can penetrate buildings easily– Radio waves also are omnidirectional, meaning that they

travel in all directions from the source, so the transmitter and receiver do not have to be carefully aligned physically.

• Disadvantages– At low frequencies, radio waves pass through obstacles well,

but at high frequencies, radio waves tend to travel in straight lines and bounce off obstacles.

– They are absorbed by rain

Page 71: Fundamentals of Computer Networks

Radio Transmission• In the VLF, LF, and MF bands, radio waves follow the ground.

• The main problem with using these bands for data communication is their low bandwidth.

• In the HF and VHF bands, the waves that reach the ionosphere, a layer of charged particles circling the earth at a height of 100 to 500 km, are refracted by it and sent back to earth.

• Military communicates in the HF and VHF bands

Page 72: Fundamentals of Computer Networks

Microwave Transmission

• Above 100 MHz, the waves travel in nearly straight lines and can therefore be narrowly focused.

• Concentrating all the energy into a small beam by means of a parabolic antenna (like the familiar satellite TV dish) gives a much higher signal-to-noise ratio, but the transmitting and receiving antennas must be accurately aligned with each other.

• Before fiber optics, for decades these microwaves formed the heart of the long-distance telephone transmission system.

Page 73: Fundamentals of Computer Networks

Infrared and Millimeter Waves

• Unguided infrared and millimeter waves are widely used for short-range communication.

• The remote controls used on televisions, VCRs, and stereos all use infrared communication.

• They are relatively directional, cheap, and easy to build but have a major drawback: they do not pass through solid objects.

Page 74: Fundamentals of Computer Networks

Lightwave Transmission

Page 75: Fundamentals of Computer Networks

Communication Satellites

Page 76: Fundamentals of Computer Networks

Structure of the Telephone System

Page 77: Fundamentals of Computer Networks

Structure of the Telephone System

• By 1890, the three major parts of the telephone system were in place:– The switching offices– The wires between the customers and the

switching offices– The long-distance connections between the

switching offices

Page 78: Fundamentals of Computer Networks

Structure of the Telephone System

Page 79: Fundamentals of Computer Networks

Structure of the Telephone System

• In summary, the telephone system consists of three major components:– Local loops: analog twisted pairs going into houses

and businesses.– Trunks: digital fiber optics connecting the

switching offices.– Switching offices: where calls are moved from one

trunk to another.

Page 80: Fundamentals of Computer Networks

The Local Loop: Modems, ADSL, and Wireless

Page 81: Fundamentals of Computer Networks

The Local Loop: Modems, ADSL, and Wireless

• When a computer wishes to send digital data over an analog dial-up line, the data must first be converted to analog form for transmission over the local loop.

• This conversion is done by a device called a modem.• At the telephone company end office the data are

converted to digital form for transmission over the long-haul trunks.

• If the other end is a computer with a modem, the reverse conversion—digital to analog—is needed to traverse the local loop at the destination.

Page 82: Fundamentals of Computer Networks

The Local Loop: Modems, ADSL, and Wireless

• Transmission lines suffer from three major problems:– Attenuation,– Delay Distortion– Noise.

• Attenuation is the loss of energy as the signal propagates outward. Energy lost depends on the frequency.

• To see the effect of this frequency dependence, imagine a signal not as a simple waveform, but as a series of Fourier components.

• Each component is attenuated by a different amount, which results in a different Fourier spectrum at the receiver.

• Different Fourier components also propagate at different speeds in the wire. This speed difference leads to distortion of the signal received at the other end.

Page 83: Fundamentals of Computer Networks

Modems• The square waves used in digital signals have a wide frequency

spectrum and thus are subject to strong attenuation and delay distortion.

• To get around the problems associated with DC signaling, especially on telephone lines, AC signaling is used.

• A continuous tone in the 1000 to 2000-Hz range, called a sine wave carrier, is introduced.

• Its amplitude, frequency, or phase can be modulated to transmit information.– In amplitude modulation, two different amplitudes are used to

represent 0 and 1, respectively.– In frequency modulation, also known as frequency shift keying, two

different tones are used.– In the simplest form of phase modulation, the carrier wave is

systematically shifted 0 or 180 degrees at uniformly spaced intervals.

Page 84: Fundamentals of Computer Networks

Amplitude modulation, Frequency Modulation and Phase Modulation

Page 85: Fundamentals of Computer Networks

Modems Cont’d• A device that accepts a serial stream of bits as

input and produces a carrier modulated by of these methods (or vice versa) is called a modem.

• The modem is inserted between the (digital) computer and the (analog) telephone system.

Page 86: Fundamentals of Computer Networks

Combination of Modulation Techniques

QPSK QAM-16 QAM-64

(Quadrature Phase Shift Keying) (Quadrature Amplitude Modulation).

Page 87: Fundamentals of Computer Networks

Digital Subscriber Lines

• The reason that modems are so slow is that telephones were invented for carrying the human voice and the entire system has been carefully optimized for this purpose.

• In the end office, the wire runs through a filter that attenuates all frequencies below 300 Hz and above 3400 Hz.

• The trick that makes xDSL work is that when a customer subscribes to it, the incoming line is connected to a different kind of switch, one that does not have this filter, thus making the entire capacity of the local loop available.

• The limiting factor then becomes the physics of the local loop, not the artificial 3100 Hz bandwidth created by the filter.

Page 88: Fundamentals of Computer Networks

Potential Bandwidth as a Function of Distance

Page 89: Fundamentals of Computer Networks

Operation of ADSL using Discrete Multitone modulation.

• The available 1.1 MHz spectrum on the local loop into 256 independent channels.– Channel 0 is used for POTS (Plain Old Telephone Service).– Channels 1–5 are not used, to keep the voice signal and data

signals from interfering with each other.– Of the remaining 250 channels, one is used for upstream

control and one is used for downstream control.– The rest are available for user data.

Page 90: Fundamentals of Computer Networks

ADSL

• A 50–50 mix of upstream and downstream is technically possible.

• However most providers allocate something like 80%–90% of the bandwidth to the downstream channel since most users download more data than they upload.

• This choice gives rise to the ''A'' in ADSL.

Page 91: Fundamentals of Computer Networks

A Typical ADSL Equipment Configuration

DSLAM: Digital Subscriber Line Access MultiplexerISP: Internet Service Provider

Page 92: Fundamentals of Computer Networks

Frequency Division Multiplexing

Page 93: Fundamentals of Computer Networks

Wavelength Division Multiplexing

Page 94: Fundamentals of Computer Networks

PCM (Pulse Code Modulation)

• The analog signals are digitized in the end office by a device called a codec (coder-decoder), producing a series of 8- bit numbers.

• The codec makes 8000 samples per second because the Nyquist theorem says that this is sufficient to capture all the information from the 4-kHz telephone channel bandwidth.

• This technique is called PCM (Pulse Code Modulation).

Page 95: Fundamentals of Computer Networks

Time Division Multiplexing

Page 96: Fundamentals of Computer Networks

Delta Modulation

Page 97: Fundamentals of Computer Networks

Switching• When you or your computer places a telephone call, the switching

equipment within the telephone system seeks out a physical path all the way from your telephone to the receiver's telephone.

• This technique is called circuit switching. Once a call has been set up, a dedicated path between both ends exists and will continue to exist until the call is finished.

Page 98: Fundamentals of Computer Networks

Message Switching

• An alternative switching strategy is message switching.

• When this form of switching is used, no physical path is established in advance between sender and receiver.

• Instead, when the sender has a block of data to be sent, it is stored in the first switching office (i.e., router) and then forwarded later, one hop at a time.

• Each block is received in its entirety, inspected for errors, and then retransmitted.

Page 99: Fundamentals of Computer Networks

Packet Switching

• With message switching, there is no limit at all on block size, which means that routers must have disks to buffer long blocks.

• It also means that a single block can tie up a router-router line for minutes, rendering message switching useless for interactive traffic.

• To get around these problems, packet switching was invented.

Page 100: Fundamentals of Computer Networks

Comparison of Circuit-Switched and Packet-Switched Networks.

Page 101: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• Mobile radiotelephones were used for maritime and military communication during the early decades of the 20th century.

• The first system for car-based telephones:– This system used a single large transmitter on top of a tall

building and had a single channel, used for both sending and receiving

– To talk, the user had to push a button that enabled the transmitter and disabled the receiver.

– In the 1950s CB-radio, taxis, and police cars often use these push-to-talk systems.

Page 102: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• In the 1960s, IMTS (Improved Mobile Telephone System) was installed.

• It used a high-powered transmitter, on top of a hill, but now had two frequencies, one for sending and one for receiving.

• Push-to-talk button was no longer needed.

• Mobile users could not hear each other.

Page 103: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• AMPS (Advanced Mobile Phone System), invented by Bell Labs.

• In all mobile phone systems, a geographic region is divided up into cells, which is why the devices are sometimes called cell phones.

• In AMPS, the cells are typically 10 to 20 km across; in digital systems, the cells are smaller.

• Each cell uses some set of frequencies not used by any of its neighbors.

Page 104: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• The cellular design increases the system capacity, more as the cells get smaller.

• Furthermore, smaller cells mean that less power is needed, which leads to smaller and cheaper transmitters and handsets.

Page 105: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• At the center of each cell is a base station to which all the telephones in the cell transmit.

• The base station consists of a computer and transmitter/receiver connected to an antenna.

• In a small system, all the base stations are connected to a single device called an MTSO (Mobile Telephone Switching Office) or MSC (Mobile Switching Center).

• In a larger one, several MTSOs may be needed, all of which are connected to a second-level MTSO, and so on.

• The MTSOs communicate with the base stations, each other, and the PSTN using a packet-switching network.

Page 106: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• Transferring ownership to the cell getting the strongest signal is called Handoff.

• Handoffs can be done in two ways:– Soft handoff– Hard Handoff

• The AMPS system uses 832 full-duplex channels, each consisting of a pair of simplex channels.– There are 832 simplex transmission channels from 824 to 849

MHz and 832 simplex receive channels from 869 to 894 MHz.– Each of these simplex channels is 30 kHz wide.

Page 107: Fundamentals of Computer Networks

First-Generation Mobile Phones: Analog Voice

• The 832 channels are divided into four categories:– Control (base to mobile) to manage the system.– Paging (base to mobile) to alert mobile users to calls for

them.– Access (bidirectional) for call setup and channel

assignment.– Data (bidirectional) for voice, fax, or data.

• Since the same frequencies cannot be reused in nearby cells, the actual number of voice channels available per cell is much smaller than 832.

Page 108: Fundamentals of Computer Networks

Second-Generation Mobile Phones: Digital Voice

• Four different systems are in use– D-AMPS (The Digital Advanced Mobile Phone

System)– GSM (The Global System for Mobile

Communications)– CDMA (Code Division Multiple Access)– PDC (Personal Digital Cellular)

Page 109: Fundamentals of Computer Networks

D-AMPS

• In D-AMPS, a new frequency band was made available to handle the expected increased load.– The upstream channels were in the 1850–1910 MHz

range, and the corresponding downstream channels were in the 1930–1990 MHz range, again in pairs, as in AMPS.

– In this band, the waves are 16 cm long, leading to smaller phones.

• Many D-AMPS phones can use both the 850-MHz and 1900-MHz bands to get a wider range of available channels.

Page 110: Fundamentals of Computer Networks

D-AMPS

• In D-AMPS, three users can share a single frequency pair using time division multiplexing.

Page 111: Fundamentals of Computer Networks

Handoff in D-AMPS• In AMPS, the MTSO manages handoff completely without help from

the mobile devices.

• In D-AMPS, 1/3 of the time a mobile is neither sending nor receiving.

• During the idle of the mobile telephone periods, the mobile telephone monitors other radio channels for signal strength.

• The mobile telephone can report these measurements along with its own received signal strength and channel back to the base station.

• The base station can use this information along with other information to determine if a new radio channel should be assigned and which channel to assign the mobile telephone to.

• This technique is called MAHO (Mobile Assisted HandOff)

Page 112: Fundamentals of Computer Networks

GSM• GSM channels are much wider than the AMPS channels

– 200 KHz in GSM– 30 KHz. in AMPS and D-AMPS

Page 113: Fundamentals of Computer Networks

GSM

Also a 51-slot multiframe is also used to manage the system.

Page 114: Fundamentals of Computer Networks

CDMA

• The key to CDMA is to be able to extract the desired signal while rejecting everything else as random noise.

• Each station is assigned a unique m-bit code called a chip sequence.– To transmit a 1 bit, a station sends its chip sequence.– To transmit a 0 bit, it sends the one's complement of its chip

sequence.• No other patterns are permitted. Thus, for m = 8, if

station A is assigned the chip sequence 00011011, it sends a 1 bit by sending 00011011 and a 0 bit by sending 11100100.

Page 115: Fundamentals of Computer Networks

CDMA

(a) Binary chip sequences for four stations.

(b) Bipolar chip sequences.

(c) Six examples oftransmissions.

(d) Recovery of station C's signal.

Page 116: Fundamentals of Computer Networks

CDMA

• To see why this works, just imagine that two stations, A and C, both transmit a 1 bit at the same time that B transmits a 0 bit.

• The receiver sees the sum

• And computes

• The first two terms vanish because all pairs of chip sequences have been carefully chosen to be orthogonal.

Page 117: Fundamentals of Computer Networks

Third-Generation Mobile Phones: Digital Voice and Data (3G)

• 3G finds application in wireless voice telephony, mobile Internet access, fixed wireless Internet access, video calls and mobile TV.

• The basic services that the IMT-2000 (International Mobile Telecommunications-2000) network is supposed to provide to its users are– High-quality voice transmission.– Messaging (replacing e-mail, fax, SMS, chat, etc.).– Multimedia (playing music, viewing videos, films, television,

etc.).– Internet access (Web surfing, including pages with audio and

video).

Page 118: Fundamentals of Computer Networks

Third-Generation Mobile Phones: Digital Voice and Data

• While waiting for the fighting over 3G to stop, some operators are gingerly taking a cautious small step in the direction of 3G by going to what is sometimes called 2.5G– EDGE (Enhanced Data rates for GSM Evolution)

• It is just GSM with more bits per baud.• The trouble is, more bits per baud also means more errors per baud.

– GPRS (General Packet Radio Service)• It is an overlay packet network on top of D-AMPS or GSM.• It allows mobile stations to send and receive IP packets in a cell

running a voice system.• When GPRS is in operation, some time slots on some frequencies are

reserved for packet traffic.• The number and location of the time slots can be dynamically

managed by the base station, depending on the ratio of voice to data traffic in the cell.

Page 119: Fundamentals of Computer Networks

4G Mobile Phones: IMT Advanced

• An IMT-Advanced system provides a comprehensive and secure all-IP based mobile broadband solution to laptops, wireless modems, smartphones and other mobile devices.

• Conceivable applications include amended mobile web access, IP telephony, gaming services, high-definition mobile TV, video conferencing and 3D television.

Page 120: Fundamentals of Computer Networks

4G Mobile Phones: IMT Advanced• Specific requirements of the IMT-Advanced report included:

– Based on an all-Internet Protocol (IP) packet switched network– Interoperability with existing wireless standards– A nominal data rate of 100 Mbit/s while the client physically

moves at high speeds relative to the station, and 1 Gbit/s while client and station are in relatively fixed positions.

– Dynamically share and use the network resources to support more simultaneous users per cell.

– Scalable channel bandwidth 5–20 MHz, optionally up to 40 MHz– Seamless connectivity and global roaming across multiple

networks with smooth handovers– Ability to offer high quality of service for multimedia support

Page 121: Fundamentals of Computer Networks

Data Link Layer

• The data link layer has a number of specific functions it can carry out. These functions include:– Providing a well-defined service interface to the

network layer.– Dealing with transmission errors.– Regulating the flow of data so that slow receivers

are not swamped by fast senders.

Page 122: Fundamentals of Computer Networks

Services Provided to the Network Layer

Page 123: Fundamentals of Computer Networks

Service Types

• Three services that are commonly provided are:– Unacknowledged connectionless service.

• Unacknowledged connectionless service consists of having the source machine send independent frames to the destination machine without having the destination machine acknowledge them.

– Acknowledged connectionless service.• Each frame sent is individually acknowledged.

– Acknowledged connection-oriented service.• The source and destination machines establish a

connection before any data are transferred.

Page 124: Fundamentals of Computer Networks

Framing• It is up to the data link layer to detect and, if necessary, correct

transmission errors.

• The usual approach is for the data link layer to break the bit stream up into discrete frames and compute the checksum for each frame.

• There are four methods for framing except inserting time gaps between them.– Character count.– Flag bytes with byte stuffing.– Starting and ending flags, with bit stuffing.– Physical layer coding violations

Page 125: Fundamentals of Computer Networks

Character Count

Page 126: Fundamentals of Computer Networks

Flag Bytes (Byte Stuffing)

Page 127: Fundamentals of Computer Networks

Bit Stuffing

Page 128: Fundamentals of Computer Networks

Physical Layer Coding Violations

• If every data bit has a transition in the middle, it makes the receiver to locate the bit boundaries easily.

• The combinations high-high and low-low are not used for data but are used for delimiting frames in some protocols.

Page 129: Fundamentals of Computer Networks

Error Control• The usual way to ensure reliable delivery is to provide

the sender with some feedback about what is happening at the other end of the line.

• An additional complication comes from the possibility that hardware troubles may cause a frame to vanish completely. In this case, the receiver will not react at all, since it has no reason to react.

• This possibility is dealt with by introducing timers into the data link layer

Page 130: Fundamentals of Computer Networks

Flow Control• What to do with a sender that systematically wants to

transmit frames faster than the receiver can accept them

• Two approaches are commonly used:– Feedback-based flow control: the receiver sends back

information to the sender giving it permission to send more data or at least telling the sender how the receiver is doing.

– Rate-based flow control: the protocol has a built-in mechanism that limits the rate at which senders may transmit data, without using feedback from the receiver

Page 131: Fundamentals of Computer Networks

Error Correction

• Hamming Distance:– Given any two codewords, say, 10001001 and 10110001,

it is possible to determine how many corresponding bits differ.

– To determine how many bits differ, just exclusive OR the two codewords.

– The number of bit positions in which two codewords differ is called the Hamming distance

Page 132: Fundamentals of Computer Networks

Error Correction

• If two codewords are a Hamming distance d apart, it will require d single-bit errors to convert one into the other.

• As a simple example of an error-correcting code, consider a code with only four valid codewords:– 0000000000, 0000011111, 1111100000, and 1111111111– This code has a distance 5, which means that it can correct

double errors.– If the codeword 0000000111 arrives, the receiver knows that

the original must have been 0000011111.– If, however, a triple error changes 0000000000 into

0000000111, the error will not be corrected properly.