Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio...

144
Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system. Model switching techniques: circuit switching, packet switching, and message switching, Data link layer design issues: Services, Framing, Error and flow control, stop-and- wait protocol, sliding window protocol. Multiple Access control sub layer, Aloha, CSMA, CSMA/CD , CA.

Transcript of Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio...

Page 1: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Unit II – overview of wireless Network Wireless transmission: Electromagnetic

spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Model switching techniques: circuit switching, packet switching, and message switching,

Data link layer design issues: Services, Framing, Error and flow control, stop-and-wait protocol, sliding window protocol.

Multiple Access control sub layer, Aloha, CSMA, CSMA/CD , CA.

Page 2: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

The Electromagnetic Spectrum

Page 3: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

The Electromagnetic SpectrumThe EM spectrum is the ENTIRE range of EM waves in order of increasing frequency and decreasing wavelength.

As you go from left right, the wavelengths get smaller and the frequencies get higher. This is an inverse relationship between wave size and frequency. (As one goes up, the other goes down.) This is because the speed of ALL EM waves is the speed of light (300,000 km/s).

Page 4: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Things to RememberThings to RememberThe higher the frequency, the more energy The higher the frequency, the more energy the wave has.the wave has.

EM waves EM waves do not require media do not require media in which to in which to travel or move.travel or move.

EM waves are considered to be EM waves are considered to be transverse transverse waves waves because they are made of vibrating because they are made of vibrating electric and magnetic fields at right angles electric and magnetic fields at right angles to each other, and to the direction the to each other, and to the direction the waves are traveling.waves are traveling.Inverse relationship between wave size and frequency: as wavelengths get smaller, frequencies get higher.

Page 5: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Radio wavesRadio waves: Have the longest wavelengths : Have the longest wavelengths and the lowest frequencies; wavelengths and the lowest frequencies; wavelengths range from 1000s of meters to .001 mrange from 1000s of meters to .001 m

Used in: RADAR, satellite Used in: RADAR, satellite transmissionstransmissions

The Waves (in order…)The Waves (in order…)

Page 6: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Infrared waves Infrared waves (heat): Have a shorter (heat): Have a shorter wavelength, from .001 m to 700 nm, and wavelength, from .001 m to 700 nm, and therefore, a higher frequency.therefore, a higher frequency.

Used for finding people in the dark and in Used for finding people in the dark and in TV remote control devicesTV remote control devices

Visible lightVisible light: Wavelengths range from 700 nm : Wavelengths range from 700 nm (red light) to 30 nm (violet light) with (red light) to 30 nm (violet light) with frequencies higher than infrared waves.frequencies higher than infrared waves.

These are the waves in the These are the waves in the EM spectrum that humansEM spectrum that humanscan see.can see.

Visible light waves are a very Visible light waves are a very small part of the EM spectrum!small part of the EM spectrum!

Page 7: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

ROY G. BVROY G. BV

redred

orangeorange

yellowyellow

greengreen

blueblue

violetviolet

Visible LightVisible Light

Remembering the OrderRemembering the Order

Page 8: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Ultraviolet LightUltraviolet Light: Wavelengths: Wavelengths range from 400 nm to 10 nm; the frequency (and therefore the energy) is high enough with UV rays to penetrate living cells and cause them damage.

Although we cannot see UV light, bees, bats, butterflies, some small rodents and birds can.

UV on our skin produces vitamin D in our bodies. Too much UV can lead to sunburn and skin cancer. UV rays are easily blocked by clothing.

Used for sterilization because they kill bacteria.

Page 9: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

X-RaysX-Rays: Wavelengths from 10 nm to .001 : Wavelengths from 10 nm to .001 nm. These rays have enough energy to nm. These rays have enough energy to penetrate deep into tissues and cause penetrate deep into tissues and cause damage to cells; are stopped by dense damage to cells; are stopped by dense materials, such as bone.materials, such as bone.

Used to look at solid structures, such as Used to look at solid structures, such as bones and bridges (for cracks), and for bones and bridges (for cracks), and for treatment of cancer.treatment of cancer.

Page 10: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Gamma RaysGamma Rays: Carry the most energy and : Carry the most energy and have the shortest wavelengths, less than have the shortest wavelengths, less than one trillionth of a meter (10one trillionth of a meter (10-12-12). ).

Gamma rays have enough energy to go through Gamma rays have enough energy to go through most materials easily; you would need a 3-4 ft thick most materials easily; you would need a 3-4 ft thick concrete wall to stop them!concrete wall to stop them!

Gamma rays are Gamma rays are released by nuclear released by nuclear reactions in nuclear reactions in nuclear power plants, by power plants, by nuclear bombs, and by nuclear bombs, and by naturally occurring naturally occurring elements on Earth.elements on Earth.

Sometimes used in the Sometimes used in the treatment of cancers.treatment of cancers.

Page 11: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Gamma RaysGamma Rays

This picture is a This picture is a “scintigram” “scintigram” It shows an It shows an asthmatic person’s asthmatic person’s lungs.lungs.

The patient was given a slightly radioactive The patient was given a slightly radioactive gas to breath, and the picture was taken gas to breath, and the picture was taken using a gamma camera to detect the using a gamma camera to detect the radiation. radiation.

The colors show the air flow in the lungs.The colors show the air flow in the lungs.

Page 12: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

SPREAD SPECTRUMSPREAD SPECTRUM

In spread spectrum (SS), we combine signals from In spread spectrum (SS), we combine signals from different sources to fit into a larger bandwidth, but our different sources to fit into a larger bandwidth, but our goals are to prevent eavesdropping and jamming. To goals are to prevent eavesdropping and jamming. To achieve these goals, spread spectrum techniques add achieve these goals, spread spectrum techniques add redundancy.redundancy.

Frequency Hopping Spread Spectrum (FHSS)Direct Sequence Spread Spectrum Synchronous (DSSS)

Page 13: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Spread spectrum

Page 14: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Frequency hopping spread spectrum (FHSS)

Page 15: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Frequency selection in FHSS

Page 16: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

FHSS cycles

Page 17: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Bandwidth sharing

Page 18: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

DSSS

Page 19: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

DSSS example

Page 20: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

SwitchingCircuit SwitchingPacket SwitchingMessage Switching

Page 21: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switched Network

Page 22: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 23: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Circuit-Switched Network

Page 24: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switch

Page 25: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Folded Switch

Page 26: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 27: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Crossbar Switch

Page 28: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

l

Multistage Switch

Page 29: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switching Path

Page 30: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switching Path

Page 31: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

TDM without TSI

Page 32: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

TDM with TSI

Page 33: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Time-Slot Interchange

Page 34: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

l

TST Switch

Page 35: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 36: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Datagram Approach

Page 37: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Datagram Approach, Multiple Channels

Page 38: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switched Virtual Circuit

Page 39: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switched Virtual Circuit

Page 40: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Switched Virtual Circuit

Page 41: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Message Switching

Page 42: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

In large networks there might be multiple paths linking sender and receiver. Information may be switched as it travels through various communication channels. There are three typical switching techniques available for digital traffic.

● Circuit Switching ● Message Switching ● Packet Switching

Page 43: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

●Circuit switching is a technique that directly connects the sender and the receiver in an unbroken path.

●Telephone switching equipment, for example, establishes a path that connects the caller's telephone to the receiver's telephone by making a physical connection.

●With this type of switching technique, once a connection is established, a dedicated path exists between both ends until the connection is terminated.

●Routing decisions must be made when the circuit is first established, but there are no decisions made after that time.

Circuit Switching

Page 44: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

●Circuit switching in a network operates almost the same way as the telephone system works.●A complete end-to-end path must exist before communication can take place.●The computer initiating the data transfer must ask for a connection to the destination.●Once the connection has been initiated and completed to the destination device, the destination device must acknowledge that it is ready and willing to carry on a transfer.

Circuit Switching

Page 45: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Advantages: ● The communication channel (once established) is dedicated.

Disadvantages: ● Possible long wait to establish a connection, (10 seconds, more on long- distance or international calls.) during which no data can be transmitted. ● More expensive than any other switching techniques, because a dedicated path is required for each connection. ● Inefficient use of the communication channel, because the channel is not used when the connected systems are not using it.

Page 46: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

●With message switching there is no need to establish a dedicated path between two stations.●When a station sends a message, the destination address is appended to the message.●The message is then transmitted through the network, in its entirety, from node to node.●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.

Message Switching

Page 47: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

A message-switching node is typically a general-purpose computer. The device needs sufficient secondary-storage capacity to store the incoming messages, which could be long. A time delay is introduced using this type of scheme due to store- and-forward time, plus the time required to find the next node in the transmission path.

Page 48: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Advantages: ● Channel efficiency can be greater compared to circuit- switched systems, because more devices are sharing the channel. ● Traffic congestion can be reduced, because messages may be temporarily stored in route. ● Message priorities can be established due to store-and-forward technique. ● Message broadcasting can be achieved with the use of broadcast address appended in the message.

Page 49: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Disadvantages ● Message switching is not compatible with interactive applications. ● Store-and-forward devices are expensive, because they must have large disks to hold potentially long messages.

Page 50: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

● Packet switching can be seen as a solution that tries to combine the advantages of message and circuit switching and to minimize the disadvantages of both. ● There are two methods of packet switching: Datagram and virtual circuit.

Page 51: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

● In both packet switching methods, a message is broken into small parts, called packets. ● Each packet is tagged with appropriate source and destination addresses. ● Since packets have a strictly defined maximum length, they can be stored in main memory instead of disk, therefore access delay and cost are minimized.● Also the transmission speeds, between nodes, are optimized.● With current technology, packets are generally accepted onto the network on a first-come, first-served basis. If the network becomes overloaded, packets are delayed or discarded (``dropped'').

Page 52: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

● Datagram packet switching is similar to message switching in that each packet is a self-contained unit with complete addressing information attached. ● This fact allows packets to take a variety of possible paths through the network. ● So the packets, each with the same destination address, do not follow the same route, and they may arrive out of sequence at the exit point node (or the destination). ● Reordering is done at the destination point based on the sequence number of the packets. ● It is possible for a packet to be destroyed if one of the nodes on its way is crashed momentarily. Thus all its queued packets may be lost.

Page 53: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

In the virtual circuit approach, a preplanned route is established before any data packets are sent. • A logical connection is established when ● a sender send a "call request packet" to the receiver and ● the receiver send back an acknowledge packet "call accepted packet" to the sender if the receiver agrees on conversational parameters.The conversational parameters can be maximum packet sizes, path to be taken, and other variables necessary to establish and maintain the conversation. Virtual circuits imply acknowledgements, flow control, and error control, so virtual circuits are reliable.● That is, they have the capability to inform upper-protocol layers if a transmission problem occurs.

Page 54: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

● In virtual circuit, the route between stations does not mean that this is a dedicated path, as in circuit switching. ● A packet is still buffered at each node and queued for output over a line. ● The difference between virtual circuit and datagram approaches:

● With virtual circuit, the node does not need to make a routing decision for each packet.● It is made only once for all packets using that virtual circuit.

Page 55: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

VC's offer guarantees that ●the packets sent arrive in the order sent ●with no duplicates or omissions ●with no errors (with high probability) regardless of how they are implemented internally.

Packet Switching: Virtual Circuit

Page 56: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Advantages: ● Packet switching is cost effective, because switching devices do not need massive amount of secondary storage. ● Packet switching offers improved delay characteristics, because there are no long messages in the queue (maximum packet size is fixed). ● Packet can be rerouted if there is any problem, such as, busy or disabled links. ● The advantage of packet switching is that many network users can share the same channel at the same time. Packet switching can maximize link efficiency by making optimal use of link bandwidth.

Page 57: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Disadvantages: ● Protocols for packet switching are typically more complex. ● It can add some initial costs in implementation. ● If packet is lost, sender needs to retransmit the data.● Another disadvantage is that packet-switched systems still can’t deliver the same quality as dedicated circuits in applications requiring very little delay - like voice conversations or moving images.

Page 58: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

OSI Model

The modelFunctions of the layers

Page 59: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

OSI Model

Page 60: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

OSI Layers

Page 61: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

An Exchange Using the OSI Model

Page 62: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Physical Layer

Page 63: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Data Link Layer

Page 64: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

l

Data Link Layer Example

Page 65: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Network Layer

Page 66: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Data Link Layer Design Issues• Services Provided to the Network Layer• Framing• Error Control• Flow Control

66

Page 67: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Data Link Layer Issues• Functions of the Data Link Layer

Provide service interface to the network layerDealing with transmission errorsRegulating data flow: Slow receivers not

swamped by fast senders

• To accomplish these goals, the data link layer encapsulates the packets into frames.

67

Page 68: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Functions of the Data Link Layer

Relationship between packets and frames.

68

Page 69: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Services Provided to Network Layer

(a) Virtual communication (model used).(b) Actual communication.

69

Page 70: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Services to the Network Layer• Three possible services offered by the data link

layer:Unacknowledged connectionless service:

appropriate for channel with low error rate, real-time traffic, LAN

Acknowledged connectionless service: useful over unreliable channel such as wireless systems

Acknowledged connection-oriented service: used in routing

70

Page 71: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Services Provided to Network Layer

Placement of the data link protocol.

71

Page 72: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Framing• To detect or correct errors in the raw bit

stream from the physical layer, the data link layer breaks the bit stream up into discrete frames and computes the checksum for each frame.

• Four methods can be used to mark the start and end of each frame:Character countFlag bytes with byte stuffingStarting and ending flags, with bit stuffingPhysical layer coding violations

72

Page 73: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Framing

73

A character stream. (a) Without errors. (b) With one error

• Disadvantage: The count may be garbled. Rarely used.

Page 74: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Framing• Flag bytes with byte/character stuffing

Each frame start and end with special bytes – flag byte

If the flag byte occurs in the frame, stuff an extra escape byte (ESC).

Used in PPP (Point to Point Protocol)• Starting and ending flags, with bit stuffing

Each frame begins and ends with a special bit pattern 01111110 whenever the sender sees 5 consecutive 1s, it stuffs a 0.

• Physical layer coding violationsOnly applicable to networks in which the encoding

on the physical medium contains some redundancy. For example, a 1 bit is a high-low pair and a 0 bit is

a low-high pair. High-high and low-low are used for delimiter. 74

Page 75: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Framing

(a) A frame delimited by flag bytes.(b) Four examples of byte sequences before and after stuffing.

75

Page 76: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Framing

Bit stuffing(a) The original data.(b) The data as they appear on the line.(c) The data as they are stored in receiver’s memory

after destuffing.76

Page 77: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Error and Flow Control• Error Control

Detect and/or correct errorsEnsure that all frame are eventually delivered in

order use acknowledgement, timer, and sequence number

• Flow ControlSlow down the sender when the data is coming

too fast for the receiverTwo approaches:

Feedback-based flow control – the receiver sends back permission to the sender.

Rate-based flow control – built-in mechanism that limits senders’ rate. Rarely used in the data link layer.

77

Page 78: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Error Detectionand Correction

Types of ErrorsDetectionCorrection

Page 79: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 80: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Single-bit error

Page 81: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Multiple-bit error

Page 82: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Burst error

Page 83: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Redundancy

Page 84: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 85: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

VRC

Page 86: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

LRC

Page 87: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

VRC and LRC

Page 88: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

CRC

Page 89: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Binary Division

Page 90: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Polynomial

Page 91: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Polynomial and Divisor

Page 92: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Standard Polynomials

Page 93: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Checksum

Page 94: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Data Unit and Checksum

Page 95: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Error Correction

ill

Page 96: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Hamming Code

Page 97: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Hamming Code

Page 98: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Hamming Code

Page 99: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Example of Hamming Code

Page 100: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Single-bit error

Page 101: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Error Detection

Page 102: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Error Detection and Correction• Error-correcting codes/forward error

correction include enough redundant information to enable

the receiver to deduce the correct transmitted data.

Used in unreliable channel such as wireless links

• Error-detecting codes include only enough redundancy to allow the

receiver to request a retransmission.Used in reliable channel such as fiber

102

Page 103: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Data Link Control

Line DisciplineFlow ControlError Control

Page 104: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Data Link Layer

Page 105: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 106: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 107: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

ENQ/ACK

l

Page 108: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

ENQ/ACK

Page 109: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Multipoint Discipline

Page 110: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Select

Page 111: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Poll

Page 112: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 113: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Stop and Wait

Page 114: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Sliding Window

Page 115: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Sender Sliding Window

Page 116: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Receiver Sliding Window

Page 117: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Sliding Window Example

Page 118: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Sender

Page 119: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Receiver

Page 120: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.
Page 121: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Damaged Frame

Page 122: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Lost Frame

Page 123: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Lost ACK

Page 124: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Damaged Frame

Page 125: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Lost Frame

Page 126: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Lost ACK

Page 127: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Selective Reject

Page 128: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

The Medium Access ControlSublayer

• Network Classification 1.Use point-to-point connections - most WANs,

except satellite. 2.Use broadcast channels - most LANs.

• This chapter deals with broadcast networks and their protocol.

• The objective is to allocate the channel to: maximize channel utilization, and minimize channel access delay.

128

Page 129: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Channel Allocation• Static Channel Allocation in LANs and MANs• Dynamic Channel Allocation in LANs and

MANs

129

Page 130: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Static Channel Allocation • In static channel allocation, a subchannel is

statically assigned to each station (computer or terminal).

• For example, in FDM, a frequency band is assigned to each station.

• This is inherently inefficient (w.r.t. channel utilization) for bursty traffic.

• Note, however, the channel access delay is minimal.

130

Page 131: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Static Channel Allocation • We use the queueing system to analyze the above

scheme. • Single station case: Let C = channel capacity (in bps)

T = mean time delay to send one frame (in sec.) λ = arrival rate (in frames/sec.) 1/μ = mean frame size (in bits/frame)

From queueing theory, we obtain: T = 1 / (μ C - λ)

For example, if 1/ μ = 10,000 bits/frame, C = 100 Mbps, and λ = 5000 frames/sec, then T = 1 / ((1/104)(108) - 5000) = 1 / 5000 = 200 μsec. per frame.

131

Page 132: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Static Channel Allocation • N station case:

Divide the channel up into N subchannels, each with capacity C/N.

Let: λ /N = arrival rate at each station (divide the load).

Then, TFDM = 1 / (μ(C/N) - λ/N) = N / (μC - λ) = N T.

So, the N station case is N times worse than the 1 station case.

For example, as above, N = 10 TFDM = 2 msec. per frame.

132

Page 133: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Dynamic Channel Allocation• Assumptions:

1.Station Model – N independent stations generate frames.

2.Single Channel – A single channel is available for all communication.

3.Collision – Frames that overlap in time destroy each other; this is called a COLLISION. All stations can detect collisions. The only errors are those caused by collisions.

133

Page 134: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Dynamic Channel Allocation• Assumptions:

4.Continuous Time means that transmission of frames can begin at any time.

Slotted Time means that time is divided into discrete intervals, and frame transmission always begins at the start of a slot.

5.Carrier Sense means that stations can tell if the channel is in use by listening to the channel.

No Carrier Sense means that stations cannot tell if the channel is in use by listening to the channel.

134

Page 135: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Pure ALOHA• In the Pure Aloha Protocol (by Abramson in

1970s), a station transmits the data whenever there is data to be sent. Then, the station listens to the channel to see if a collision occurred. If the frame was destroyed, the station waits for a random length of time and tries again.

• Systems in which multiple users share a common channel in a way that can lead to conflicts are widely known as contention systems.

135

Page 136: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Pure ALOHAIn pure ALOHA, frames are transmitted at

completely arbitrary times.

136

Page 137: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Pure ALOHA - Analysis• Let FRAME TIME be the time required to

transmit a standard, fixed-length frame; that is, (1/μC).

• Assume there is an infinite population of stations that transmit frames according to a Poisson process with a mean of N frames transmitted per frame time.

• Note, if N>1, the channel will not be able to handle the load. So, we expect 0<N<1. The offered load, G, is the total number of frames sent on the channel per frame time; that is, G = N + (number of retransmissions per frame time).

137

Page 138: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Pure ALOHA

Vulnerable period for the shaded frame.

138

Page 139: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Slotted ALOHA• In slotted Aloha (by Roberts in 1972) A

computer is not permitted to send whenever a carriage return is typed but wait for a time slot.

• Time is divided into fixed slots of one frame time each. A station waits until the start of the next slot before transmitting a frame. Thus, P0 = e-G (the vulnerable period is only one time slot). S = G e-G Note that as G increases, the number of collisions increases exponentially.

• Note, the maximum occurs when G = 1. S = 0.368.

• Slotted Aloha can be used to allocate a shared cable channel.

139

Page 140: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Pure ALOHAThroughput versus offered traffic for ALOHA

systems.

140

Page 141: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Carrier Sense Multiple Access (CSMA) • Protocols in which stations listen for a carrier

(i.e. transmission) and act accordingly are called carrier sense protocols.

1. 1-persistent CSMA Channel Busy Continue sensing until free and

then grab. Channel Idle Transmit with probability 1. Collision Wait for a random length of time and

try again. 2. nonpersistent CSMA: Channel Busy Does not continually sense the

channel. Wait for a random length of time and try again.

Channel Idle Transmit. Collision Wait for a random length of time and

try again. 141

Page 142: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

Carrier Sense Multiple Access (CSMA) 3. p-persistent CSMA: Channel Busy Continue sensing until free (same as

idle). Channel Idle Transmit with probability p, and defer

transmitting until the next slot with probability q = 1-p. Collision Wait for a random length of time and try

again. • The nonpersistent CSMA has better channel utilization

but longer delays than 1-persistent CSMA.• CSMA are an improvement over ALOHA because they

ensure that no station begins to transmit when it senses the channel busy.

• Another improvement is for stations to abort their transmissions as soon as they detect a collision. Quickly terminating damaged frames saves time and bandwidth. This protocol is called CSMA/CD (CSMA with Collision Detection).

142

Page 143: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

CSMA with Collision Detection

CSMA/CD can be in one of three states: contention, transmission, or idle.

143

Page 144: Unit II – overview of wireless Network Wireless transmission: Electromagnetic spectrum, Radio microwaves, Infrared, Lightweight Spread Spectrum system.

CSMA with Collision Detection• Stations detect collisions using analog

hardware and abort transmissions immediately.• Let τ be the propagation delay (the time for a

signal to propagate between the two farthest stations be τ). The contention interval is modeled as a slotted Aloha system with slot width 2τ.

• Then, 2τ is the time required for a station to detect collision with certainty.

For example, on a 1-km long coaxial cable, τ = 5 μsec. 2τ = 10 μsec to detect a collision.

144