195
1 COM 360

COM 360

  • Upload
    brede

  • View
    41

  • Download
    0

Embed Size (px)

DESCRIPTION

COM 360. Chapter 2. Direct Link Networks. Network Technologies. Point-to-Point Links Carrier Sense Multiple Access ( CSMA) – (for example the Ethernet) Token Rings – (for example IEEE 802.5 and FDDI ) Wireless – (for which 802.11 is the emerging standard). Problems. - PowerPoint PPT Presentation

Citation preview

Page 1: COM 360

1

COM 360

Page 2: COM 360

2

Chapter 2

Direct Link Networks

Page 3: COM 360

3

Network Technologies

1. Point-to-Point Links2. Carrier Sense Multiple Access ( CSMA)

– (for example the Ethernet)3. Token Rings – (for example IEEE 802.5

and FDDI )4. Wireless – (for which 802.11 is the

emerging standard)

Page 4: COM 360

4

ProblemsConnecting computers is a first step.There are additional problems to solve before

they can exchange packets:• Encoding bits into the transmission medium• Framing the bits so they can be understood• Error detection• Reliable delivery, in spite of occasional errors• Media access control

Page 5: COM 360

5

Hardware Building Blocks

• Networks are constructed from nodes and links• Nodes are general purpose computers such

as workstations, multiprocessors or PCs as well as special purpose switches, routers.– Memory – finite – must be managed– Network Adapter (NIC) and its device driver

• Links implemented on physical media, such as twisted pair, coaxial cable, optical fiber

Page 6: COM 360

6

Nodes

I/O bus

(To network)

CPU

Memory

NetworkadaptorCache

Example workstation architecture

Page 7: COM 360

7

Links• Physical media are used to propagate

signals as electromagnetic waves, traveling at the speed of light.

• Properties of EM waves:– Frequency- or oscillations, measured in hertz– Wavelength – distance between adjacent

maxima and minima, measured in meters

Page 8: COM 360

8

Electromagnetic Waves

• Wavelength = speed / frequency• Voice grade phone lines carry waves ranging

from 300 Hz to 3300 Hz• Voice-grade example: 300Hz in copper wire• Wavelength = Speed in Copper/ Frequency

= 2/3 x 3 x 108 /300 = 667 x 103 meters

Page 9: COM 360

9

Electromagnetic Spectrum

Radio Infrared UVMicrowave

f(Hz)

FMCoax

Satellite

TVAM Terrestrial microwave

Fiber optics

X ray

100

104 105 106 107 108 109 1010 1011 1012 1013 1014 1015 1016

102 106 108 1010 1012 1014 1016 1018 1020 1022 1024104

Gamma ray

Page 10: COM 360

10

Links

• A link is a physical medium carrying signals in the form of electromagnetic waves.

• Binary data is encoded in the signal.– Lower layer is concerned with modulation,

varying the frequency, amplitude or phase of the signal

– Upper layer is concerned with encoding the data

Page 11: COM 360

11

Link Attributes

• Another link attribute is how many bit streams can be encoded on it, at a given time.

• One bit stream- connected nodes share access• Point-to-point – often two bit streams at once

– Full duplex - two directions – simultaneously – Half duplex – one direction at a time – Simplex – one direction

Page 12: COM 360

12

Cables

• Type of cable depends on technology• Coaxial – ( thick and thin) – within buildings• Category 5 ( CAT 5) – twisted pair, thicker

gauge than telephone wire• Fiber –plastic or most often glass, more

expensive, but used to connect buildings, and transmits light instead of electrical waves.

Page 13: COM 360

13

Local Link CablesCable Typical

BandwidthDistances

Cat 5 twisted pair

10-100 Mbps 100 m

Thin-net coax 10-100 Mbps 200 m

Thick-net coax 10-100 Mbps 500 m

Multimode fiber

100 Mbps 2 km

Single-mode fiber

100- 240 Mbps 40 km

Page 14: COM 360

14

Leased Lines

• To connect nodes on opposite sides of the country, or at great distances, you must lease a dedicated line from the telephone company.

• DS1, DS3, T1, and T3 are relatively old technologies, defined for copper

• STS-N links are for optical fiber (Synchronous Transport Signal), also called OC-N for Optical Carrier

• Originally designed for voice, today can carry data, voice and video

Page 15: COM 360

15

Common BandwidthsServices BandwidthDS1 or T1 1.544 MbpsDS3 or T3 44.736 MbpsSTS-1 51.840 MbpsSTS-3 155.250 MbpsSTS-12 622.080 MbpsSTS-48 2488320 GbpsSTS-192 155.250 Mbps

Page 16: COM 360

16

Last-Mile links• Leased lines range in price from $1000/month to “don’t

ask”• Last mile links span the last mile from the network

service provider to the home or office.• Conventional modem- POTS (plain old telephone

service)• ISDN – (Integrated Services Digital Network) – uses

CODEC ( coder/decoder) to encode analog to digital signal

• xDSL (Digital Subscriber Line)• Cable modem- uses cable television (CATV)

infrastructure, available to 95% of US households

Page 17: COM 360

17

Common Available ServicesServices Bandwidth

POTS 28.8 - 56 Kbps

ISDN 64 – 128 Kbps

xDSL 16 Kbps – 52.2 Mbps

CATV 20 –40 Mbps

Page 18: COM 360

18

xDSL

• Collection of technologies, able to transmit data at high speeds over standard twisted pair lines

• ASDL ( Asymmetric Digital Subscriber Line)- different speeds in different directions (upstream and downstream) – called local loop

• VDSL- (Very high rate Digital Subscriber Line)- runs over shorter distances – “fiber to neighborhood”

Page 19: COM 360

19

ADSL

1.554─ 8.448 Mbps

16─ 640 Kbps

Local loopCentraloffice

Subscriberpremises

downstream

upstream

ADSL connects the subscriber to the central office via the local loop.

Page 20: COM 360

20

VDSL

STS-Nover fiber

VDSL at 12.96─ 55.2 Mbps

over 1000─ 4500 feet of copperCentraloffice

Subscriberpremises

Neighborhood opticalnetwork unit

VDSL connects the subscriber to the optical network that reaches the neighborhood.

Page 21: COM 360

21

Shannon’s Theorem

• Shannon’s theorem gives an upper bound to the capacity of a link, in terms of bits per second.

C = B log2 (1+S/N)

where C is channel capacity, B is Bandwidth, S is signal power, N is noise and S/N is the signal to noise ratio expressed in decibels, related as:

dB= 10 x log10 (S/N)

Page 22: COM 360

22

Shannon’s TheoremExample

• dB ratio pf 30 dB• S/N = 1000• Bandwidth = 3000Hz

C = B x log2 ( 1+S/N)C = 3000 x log2 (1001)C = 30 Kbps = roughly the limit of a 28.8 modem

How are 56 Kbps modems possible? See p. 76

Page 23: COM 360

23

CATV• A subset of CATV channels are made available for

transmitting digital data• A single CATV channel has a bandwidth of 6 MHz• Like ADSL, CATV is asymmetric with

downstream rates much greater than upstream– 40 Mbps downstream ( 100 Mbps max)– 20 Mbps upstream ( roughly half as much)

• Unlike DSL, bandwidth is shared among all subscribers in a neighborhood.

Page 24: COM 360

24

Network AdaptorSignalling component

Signal

BitsNode NodeAdaptor Adaptor

Signals travel between signaling components.

Bits flow between adaptors.

Network interface cards are called NICs.

Page 25: COM 360

25

Network Adaptors

• Nearly all the functions in this chapter are implemented in the network adaptor (NIC):framing, error detection and the media access protocol.

The exceptions are the point-to-point automatic repeat-request schemes(ARQ), which are implemented at the lowest level protocol running on the host.

Page 26: COM 360

26

Block Diagram of a Network Adaptor

Adaptor

Network linkBusinterface

Linkinterface

Page 27: COM 360

27

Interrupts

• The host only pays attention to the network device when the adaptor interrupts the host, (for example, when a frame has been transmitted or one arrives).

• A procedure is invoked by the operating system, and an interrupt handler is invoked to take the appropriate action.

• While servicing this interrupt, the OS disables other interrupts.

Page 28: COM 360

28

Direct Memory Access vs. Programmed I/O

• There are two ways to transfer the bytes from the frame between the adaptor and host memory:

• Direct Memory Access (DMA)- the NIC directly reads/writes to the host’s memory without CPU involvement, using a pair of buffer descriptor lists.

• Programmed I/O (PIO)- network adaptor (NIC) copies message into its own buffer, until CPU can copy it into the host memory.

Page 29: COM 360

29

Programmed I/O

Host

Adaptor Memory

CPU

Memory

Memory

Page 30: COM 360

30

Memory Bottleneck• Host memory is often a limiting factor in network

performance.• I/O bus speed corresponds to its peak bandwidth (bus

width x clock speed).• Real limitation is the size of the data block being

transferred ( See p. 145)• Memory/CPU bandwidth is same as bandwidth of I/O

bus.• Must be aware of limits memory puts on network

Page 31: COM 360

31

Memory Bandwidth on Modern PC

I/O bus235 Mbps 1056 Mbps

CPU

Memory

Crossbar

Page 32: COM 360

32

Wireless Links

• AMPS- Advance Mobile Phone System- standard for cellular phones

• PCS- Personal communication Services – digital cellular services in US and Canada

• GSM- Global System for Mobile Communication in the rest of the world.

• They use a system of towers to transmit signals and are moving toward ringing the globe with satellites.

Page 33: COM 360

33

Local Wireless Links• Radio and infrared portions of the spectrum can

be used over short distances.• Technology- limited to in-building environments• Radio bands at 5.2 GHz and 17 GHz are

allocated to HIPPERLAN in Europe and 2.4 GHz for use with the IEEE 802.11 standard, which supports data rates up to 54 Mbps.

• Bluetooth – radio, operates in the 2.45 GHz band– Used for all devices, printers, PDAs, phones– Networks of these devices are called piconets

Page 34: COM 360

34

Bit Rates and Baud Rates

• Rate at which the signal changes is called the baud rate.

• When one bit is transmitted on a signal, the bit rate and baud rate may be equal.

• Often multiple bits are encoded onto a signal, where for example with 4 bits per signal, the baud rate may be 4 times the bit rate

Page 35: COM 360

35

Encoding• First step in turning nodes and links into usable building

blocks is to understand how to connect them so that bits can be transmitted.

• Next encode binary data that the source want to send into signals that the links can carry and then decode the data back into the corresponding data at the receiving end.

• The high and low signals correspond to 2 different voltages on a copper based system or 2 different power levels on an optical link.

Page 36: COM 360

36

NRZ Encoding• NRZ – non-return to zero, maps the data value 1 to the

high signal and 0 to the low signal• A sequence of several consecutive 1’s means that the

signal stays high for a prolonged period of time.• Two fundamental problems;

– Baseline wander –makes it difficult to detect a significant change in the signal

– Clock recovery needs frequent changes from high to low to be enabled

• Sender and receiver clock must be precisely synchronized.

Page 37: COM 360

37

NRZ Encoding

Bits

NRZ

0 0 1 0 1 1 1 1 0 1 0 0 0 0 1 0

Page 38: COM 360

38

NRZI Encoding

• NRZI – non-return to zero inverted, addresses the previous problem, by having the sender make a transition from the current signal to encode a 1 and stay at current signal to encode a 0. ( Solves the problem of consecutive 1’s, but not 0’s)

Page 39: COM 360

39

Manchester Encoding• Merges the clock with the signal by transmitting the

exclusive–OR of the NRZ encoded data.• Results in 0 being encoded as a low-to-high transition

and 1 encoded as a high-to-low transition. Because both 0s and 1 result in a transition, the clock can be recovered at the receiver.

• Problem: doubles the rate at which transitions are made on the link, which gives receiver half the time to detect them.

Page 40: COM 360

40

Encoding Strategies

Bits

NRZ

Clock

Manchester

NRZI

0 0 1 0 1 1 1 1 0 1 0 0 0 0 1 0

Page 41: COM 360

41

4B/5B Encoding• Attempts to address the inefficiency of

Manchester encoding.• It inserts extra bits into the bit stream to break

up long sequences of 0s and 1s:– Every 4 bits of data are encoded in a 5 bit code

(See table 4B/5B encoding on p. 79)

Page 42: COM 360

42

Packets and Frames

  Packet is ``generic'' term that refers to a small block of data.

  Each hardware technology uses a different packet format.

  Frame or hardware frame denotes a packet of a specific format used on a specific hardware technology.

Page 43: COM 360

43

Framing• Blocks of data (frames), not bit streams, are

exchanged between nodes.• The network adapter (NIC) enables the nodes to

exchange frames.• Recognizing what set of bits constitutes a frame,

and where the frame begins and ends, is the challenge faced by the network adapter.

Page 44: COM 360

44

Frame Format   Need to define a standard format for data

to indicate the beginning and end of the frame

   Header and trailer used to ``frame'' the data (SOH and EOT)

  Can choose two unused data values for framing for example, if data is limited to printable ASCII characters, you can use

  ``start of header'' (soh)  ``end of text'' (eot)

Page 45: COM 360

45

Frame Format

• Framing in Practice  Incurs extra overhead - soh and eot take time to

transmit, but carry no data  Accommodates transmission problems:  Missing eot indicates sending computer crashed  Missing soh indicates receiving computer missed

beginning of message  Bad frame is discarded

Page 46: COM 360

46

Framing • Suppose A wishes to transmit a frame to B• It tells adapter to transmit a frame from the

node’s memory• A sequence of bits is sent over the link• The adapter on B then collects the sequence of

bits arriving on the link and deposits them in B’s memory.

Page 47: COM 360

47

Framing

Frames

BitsNode A Node BAdaptor Adaptor

Bits flow between adaptors, frames between hosts

Page 48: COM 360

48

Framing• There are several approaches to the framing

problem:• Byte-Oriented Protocol (PPP)

– Sentinel Approach (frame start and end)– Byte counting

• Bit –Oriented Approach (HDLC) • Clock-based framing (SONET)

Page 49: COM 360

49

Byte-Oriented protocols• One of the oldest approaches to framing is to view each

frame as a collection of bytes (characters) rather than bits.

• BISYNC (Binary Synchronous Communication) protocol is a byte-oriented approach developed by IBM in 1960’s

• DDCMP ( Digital Data communication Message Protocol) was used in Digital Equipment’s DECNET.

• These are examples of the sentinel approach and the byte counting approach.

Page 50: COM 360

50

Sentinel Approach• A packet is a sequence of labeled fields.• Above each field is a number indicating the number of

bits in the field.• Packets are transmitted beginning with the leftmost

field. The beginning of the frame is the SYN (synchronization) character.

• Data is contained between sentinel characters – STX (start of text) and ETX (end of text).

• The header begins with a SOH (start of header) field.• It ends with a CRC (cyclic redundancy check) field.

Page 51: COM 360

51

BISYNC Frame Format

Header Body8 8 8 8 168

CRC

Page 52: COM 360

52

Framing problem• ETX character may appear in the data.• BISYNC overcomes this by using byte-stuffing

or character-stuffing by preceding the ETX character with an escape character or DLE (data link escape– (similar to \n or \t in programming)

• CRC (cyclic redundancy check) is used to detect transmission errors.

Page 53: COM 360

53

Point-To-Point Connection The first computer communication systems were connected

by communication channels that connected exactly two computers.

 Called a mesh or point-to-point network Had three useful properties:

– 1. Each connection was independent and different hardware could be used. (bandwidth, modems, etc. did not have to be the same)

• Allow for greater flexibility.– 2.  The connected computers have exclusive access and could

decide how to send data across the connection. The can determine the frame format and size, error detection mechanism, etc.

– 3.  Since only two computers share the channel it is private and secure.

Page 54: COM 360

54

Disadvantages of Point-To-Point

• 1.  Number of wires grows as the number of computers increases

• 2.  The total number of connections exceeds the number of computers being connected.

• The number of connections needed is proportional to the square of the number of computers, since the new computer must have a connection to each of the existing computers. So to add the Nth computer requires N-1 new connections.

Page 55: COM 360

55

Disadvantages of Point-To-Point• For N computers: • Connections = (N2 - N)   2

Computers Connections2 13 34 65 10

Page 56: COM 360

56

Point-to-Point Protocol• Point-to-Point Protocol (PPP) is run over dialup

modem links and is similar to BISYNC.• Flag denotes the start-of-text character, address

and control fields contain default values.• The protocol is the high level protocol, such as

IP or IPX.• Payload size is usually 1500 bytes.• Checksum field is either 2 or 4 bytes long.

Page 57: COM 360

57

PPP Frame Format

ProtocolControlAddressFlag Payload88 816168

FlagChecksum

Page 58: COM 360

58

PPP Framing• PPP framing is unusual in that several of the field

sizes are negotiable rather than fixed.• The negotiation is conducted by the LCP (Link

Control Protocol) Protocol.• PPP and LCP work in tandem:

– LCP sends control messages encapsulated in PPP frames denoted by an LCP identifier

– Changes PP’s frame format based on the information contained in the control messages.

– LCP also establishes a link between the peers when both sides detect the carrier signal.

Page 59: COM 360

59

Byte-Counting Approach

• The alternative to detecting the end of a file with a sentinel value is to include the number of items in the file at its beginning.

• This is true in framing- the number of bytes in a frame can be included in the header.

• DDCMP protocol uses this approach and the COUNT field specifies the number of bytes in the frame’s body.

Page 60: COM 360

60

DDCMP Frame Format

Header Body

8 8 4214 168

CRCCount

Page 61: COM 360

61

Framing Errors

• A transmission error could corrupt the COUNT field and the end of the frame would be incorrectly detected.

• A similar problem exists with the ETX field being corrupt.

• This is called a framing error.• The receiver waits for the next SYN character to

collect data for the next frame. • A framing error may cause back-to-back frames to

be incorrectly received.

Page 62: COM 360

62

Bit-Oriented Protocols

• Bit-oriented protocols are not concerned with byte boundaries. It views the frame as a collection of bits.

• Synchronous Data Link Control ( SDLC), developed by IBM is a bit-oriented protocol, later standardized as the High Level Data Link Control (HDLC).

• Uses bit sequence 01111110 to denote beginning and end of a frame.

• It is also transmitted when the link is idle.

Page 63: COM 360

63

HDLC Frame Format

Header Body8 16 16 8

CRCBeginningsequence

Endingsequence

Page 64: COM 360

64

Data Stuffing• Networks usually insert extra bits or bytes

to change data for transmission and this is called Data Stuffing

 Bit stuffing and byte stuffing are two techniques for inserting extra data to encode reserved bytes

 Byte stuffing translates each reserved byte into two unreserved bytes

Page 65: COM 360

65

Byte Stuffing

  Can use esc as prefix, followed by x for soh, y for eot and z for esc:

Page 66: COM 360

66

Byte Stuffing  Sender translates each reserved byte into

the appropriate encoding pair of bytes  Receiver interprets pairs of bytes and

stores encoded byte in buffer• Data still framed by soh and eot

Page 67: COM 360

67

Bit Stuffing• Anytime 5 consecutive 1’s are transmitted, the

sender inserts a 0 before sending the next bit. On the receiving side.

• When the receiver detects 5 consecutive 1’s, it assumes the next 0 was “stuffed” and removes it.

• If the next bit is a 1, either this is the end of frame marker or an error has occurred.

• Size of the frame is dependent on the data being sent in the frame payload.

Page 68: COM 360

68

Clock-Based Framing• Third approach to framing is the Synchronous Optical

Network (SONET) standard, called clock-based framing.• SONET was proposed by Bell Communications

Research (Bellcore) for digital transmission over an optical fiber.

• Addresses the framing and encoding problems as well as multiplexing low speed links onto a high speed link.

• More complex protocol

Page 69: COM 360

69

SONET Framing

• SONET Frame has special information that indicates where the frame starts and ends.

• No bit stuffing is used• How does receiver know where the frame starts and

ends? • Frame consists of 9 rows of 90 bytes each.

– First 3 bytes of each row are overhead. – First two bytes of frame contain special bit pattern – Use of overhead bytes is complex

Page 70: COM 360

70

SONET STS-1 Frame

Overhead Payload

90 columns

9 rows

First two bytes of the frame contain a special bit pattern that indicates the start of the frame

Page 71: COM 360

71

STS-1 Multiplexing

STS-1 STS-1 STS-1

STS-3cHdr

Three STS-1 frames are multiplexed onto one STS-3 frame.

Page 72: COM 360

72

SONET Frames Out of Phase

Frame 0

Frame 1

87 columns

9 rows

Page 73: COM 360

73

Error Detection

• Bit errors occur in frames due to electrical interference or thermal noise.

• Detecting errors is one part of the problem; correcting errors is the other.

• What happens when an error is detected?• Two basic approaches:

– Notify the sender that message is corrupt so the sender can retransmit it; ( most often used in every day applications)

– Use an error-correcting code to reconstruct the correct message

Page 74: COM 360

74

Transmission Errors

 External electromagnetic signals can cause incorrect delivery of data  Data can be received incorrectly   Data can be lost  Unwanted data can be generated

  Any of these problems are called transmission errors

Page 75: COM 360

75

Error Detection• Detecting Transmission Errors: basic idea is

to add redundant information to a frame that can determine if errors have been introduced.

• Two-dimensional parity – based on a simple parity bit added to balance the number of 1’s

• Checksums – code created based on addition• Cyclic Redundancy Check (CRC) – based

on a complex mathematical algorithm and used in nearly all link level protocols.

Page 76: COM 360

76

Parity

  Parity refers to the number of bits set to 1 in the data item

  Even parity - an even number of bits are 1  Odd parity - an odd number of bits are 1  A parity bit is an extra bit transmitted with a data

item,chose to give the resulting bits even or odd parity

  Even parity - data: 10010001, parity bit 1• Odd parity - data: 10010111, parity bit 0

Page 77: COM 360

77

Parity and Error Detection

  If noise or other interference introduces an error, one of the bits in the data will be changed from a 1 to a 0 or from a 0 to a 1

  Parity of resulting bits will be wrong  Original data and parity: 10010001+1 (even parity)  Incorrect data: 10110001+1 (odd number of 1’s)  Transmitter and receiver agree on which parity to

use  Receiver detects error in data with incorrect parity

Page 78: COM 360

78

Limitations of Parity Checking

  Parity can only detect errors that change an odd number of bits

  Original data and parity: 10010001+1 (even parity)

  Incorrect data: 10110011+1 (even parity!)  Parity usually used to catch one-bit errors

Page 79: COM 360

79

Two-Dimensional Parity

• Two-dimensional parity involves adding on extra bit to balance the number of 1’s in each byte (making the total either even or odd).

• Two-dimensional parity does a similar calculation for each bit position across all the bytes in the frame, resulting in adding an extra parity byte for the frame as well as an additional parity bit for each byte.

• Two-dimensional parity catches all the one, two and 3 bit errors and most 4 bit errors.

Page 80: COM 360

80

Two-Dimensional Parity

1011110 1

1101001 0

0101001 1

1011111 0

0110100 1

0001110 1

1111011 0

Paritybits

Paritybyte

Data

Page 81: COM 360

81

Probability and Error Detection  All error detection methods are approximate

and aim at a low probability of accepting corrupted data.

• Parity can detect a single bit error, but not all possible errors, especially where two bits ( or an even number of bits) are changed.

  Many alternative schemes exist:   Detect multi-bit errors   Correct errors through redundant information• Checksum and CRC are two widely used

techniques

Page 82: COM 360

82

Internet Checksum Algorithm

• Simple idea: add up all the words that are to be transmitted and then transmit the sum, called the checksum, with the data.

• The receiver performs the same calculation and compares it to the checksum received. If they do not match, an error has occurred.

• Does not detect all errors…• Algorithm is easy to implement ( See p. 94)

Page 83: COM 360

83

Checksum  Sum of data in message treated as array of

integers  Can be 8-,16- or 32-bit integers  Typically use 1s-complement arithmetic  Example -16-bit checksum with 1's

complement arithmetic

Page 84: COM 360

84

Advantages of Checksum

   Fastest implementations of 16-bit checksum use 32-bit arithmetic and add carries in at end

   Easy to do - uses only addition   Small size of checksum means cost of transmitting it is small.• Ease of computation to create and verify

checksum.

Page 85: COM 360

85

Checksum Limitations

 Does not detect all common errors (like reversed bits)

Page 86: COM 360

86

Cyclic Redundancy Check (CRC)

• CRC uses powerful mathematics ( finite fields) to give strong protection against common bit errors in messages that are thousands of bytes long.

Page 87: COM 360

87

Detecting Errors with Cyclic Redundancy Checks 

 Consider data in message as coefficients of a polynomial

 Divide that coefficient set by a known polynomial Transmit remainder as CRC Good error detection properties Easy to implement in hardware

Page 88: COM 360

88

CRC Hardware  The hardware used to computer a CRC is a shift

register, which act like a tunnel through which bits move in a single file from right to left.

  The shift register holds a fixed number of bits so when a new bit moves in, another bit moves out.

  The output gives the value of the leftmost bit.  When a bit changes, the output changes.  The shift register has two operations: initialize and

shift.  Initialize sets all bits to zero   Shift moves all bits one position to the left.

Page 89: COM 360

89

CRC Hardware

• X-Or and Shift Registers

Page 90: COM 360

90

CRC Hardware• CRC Hardware consists of 3 shift registers

connected with X-Or units.• Output from the leftmost unit goes to 3 places

simultaneously - the • 3 X-Or units.• To compute the CRC values in all registers are

initialized and the bits are shifted one at a time.• One bit of the message is applied to the input unit

and all three registers perform a shift. This repeats for each bit of the message.

Page 91: COM 360

91

CRC Calculation using Shift Registers

x0 x1 XOR gate x2

Message

Page 92: COM 360

92

CRC Computation

• After an entire message has been input, the shift registers contain the 16 bit CRC for the message.

Page 93: COM 360

93

CRC Computation• A CRC can compute more errors that a

simple checksum because:   An input bit is shifted through 3 registers;   The hardware uses feedback so that the

effect from a single bit cycles through the shift registers more than once.

• Mathematically a CRC uses a polynomial to divide the message:

• P(X) = x 16 + X 12 + X 5 + 1

Page 94: COM 360

94

Example CRC• A message is treated as a long binary polynomial, P. • Before transmitting, the data link layer divides P, by a fixed polynomial function G(x), resulting in a whole quotient Q and a remainder R/G. The remainder is appended to the message and transmitted. • It is checked by the receiver to see if R agrees with the

locally generated  value for R. (See Tanenbaum p.208-210 for analysis)  

 

Page 95: COM 360

95

Example CRC

• Frame: P: 1101011011• Generating function G(x): 10011• Message after appending 4 zero bits:

11010110110000• Divide P by G to get remainder R:• 1100001010 with R = 1110  • 10011 | 11010110110000   • Transmitted frame with remainder R appended:

11010110111110

Page 96: COM 360

96

Accuracy of CRC

• CRC actually adds 8, 16, 24, or 32 bits to the message.

• This method detects up to 99.969% of errors with CRC-8 and nearly 99.9% with CRC-16 or CRC-24.  

Page 97: COM 360

97

Another CRC Example

Generator 11011111100110011010000 Message110110011101100011011011110111001101

10001101101 Remainder

See text. Pp. 94-95

Page 98: COM 360

98

Error Correction or Error Detection?

• When error is detected, frame is discarded and resent, using bandwidth and causing latency, waiting for its arrival.

• Error correction requires additional bit to be sent with every frame.

• Correction is useful when – 1) errors are probable or – 2) the cost of retransmission is too high

Page 99: COM 360

99

Reliable Transportation

• A data link level protocol that wants to deliver frames reliably must recover from discarded ( lost) frames.

• Acknowledgements - (ack) is a small control frame that a protocol sends back to report that it has received the frame. If the sender does not receive a frame in a reasonable amount of time, it retransmits.

• Timeouts -waiting a reasonable mount of time is called a timeout

Page 100: COM 360

100

Automatic Repeat Request

• Using acknowledgements and timeout to implement reliable delivery is called automatic repeat request (ARQ).

• The simplest ARQ scheme is the Stop and Wait algorithm.

Page 101: COM 360

101

Stop and Wait

• After transmitting one frame the sender waits for an ACK before transmitting the next frame.

• If it does not arrive in a reasonable time, the sender retransmits the original frame.

Page 102: COM 360

102

Stop and Wait AlgorithmSender Receiver

Frame

ACK

Sender Receiver

Frame

ACK

Frame

ACK

Sender Receiver

Frame

ACKFrame

ACK

Sender Receiver

Frame

Frame

ACK

(a) (c)

(b) (d)

a) Arrives

b) Frame lost

c)ACK lost

d) Timeout too soon

Page 103: COM 360

103

Duplicate Frames

• If a frame is late arriving another frame might be retransmitted, resulting in duplicate frames.

• To correct this, a header usually contains a sequence number (0,1), which is used for alternate frames.

• When sender retransmits frame 0, the receiver can see that it is a second copy of frame 0, not frame 1.

Page 104: COM 360

104

Timeline for Stop and WaitSender Receiver

Frame 0

ACK 0

Frame 1

ACK 1

Frame 0

ACK 0

Page 105: COM 360

105

Sliding Window Protocol

 Allows sender to transmit multiple packets before receiving an acknowledgment

 Number of packets that can be sent is defined by the protocol and called the window

 As acknowledgments arrive from the receiver, the window is moved along the data packets; hence ``sliding window''

 Sliding window protocol can increase throughput dramatically

Page 106: COM 360

106

Sliding Window Protocol• Sliding window algorithm allows the transmission of

a frame at about the same time as the ACK arrives.• Sender assigns a sequence number (SeqNum) to

each frame and maintains 3 variables:– Send window size (SWS) - # of unacknowledged frames

that sender can transmit– Last acknowledgement received (LAR)– Last frame sent (LFS)– LFS - LAR <= SWS

Page 107: COM 360

107

Sliding Window

Page 108: COM 360

108

Timeline for Sliding WindowSender Receiver

Page 109: COM 360

109

Sliding Window• When ACK arrives, the sender moves LAR to the right,

allowing the sender to transmit another frame.• Sender buffers up to SWS (send window size) frames (in

case they need to be retransmitted).• It also associates a timer with each frame it transmits, so

it can retransmit if an ACK is not received in time.• LAR – Last Acknowledgement Received• LFS – Last Frame Sent• See pp. 105-115 for details and for interactive demo see• http://www2.rad.com/networks/2004/sliding_window/demo.html

Page 110: COM 360

110

Sliding Window on Sender

< SWS

LAR LFS

■ ■ ■ ■ ■ ■ ─

Page 111: COM 360

111

Sliding window

• The receiver maintains 3 variables:– The receive window size ( RWS) – the upper

bound on the number of out of order frames that the receiver can accept.

– The sequence number of the largest acceptable frame (LAF)

Page 112: COM 360

112

Sliding Window on Receiver

RWS

LFR LAF

■ ■ ■ ■ ■ ■

< ─

Page 113: COM 360

113

Sliding Window Algorithm

• When frame with sequence number SeqNum arrives, the receiver does the following:

• If SeqNum <= LFR or SeqNum >LAF then frame is outside the window and is discarded.

• If LFR < SeqNum <= LAF, then it is accepted.• SeqNumToAck is largest not yet acknowledged• Receiver acknowledges receipt of SeqNumToAck and

sets LFR = SeqNumToAck• LAF=LFR +RWS

Page 114: COM 360

114

Comparison of Sliding Window and Stop & Wait

Page 115: COM 360

115

Frame Order and Flow Control

• Sliding Window can be used for:– To reliably deliver frames on an unreliable link;– To preserve the order in which the frames are

transmitted, using the sequence numbers;– To support flow control- a feedback mechanism

by which the receiver is able to throttle the sender to keep it from overrunning the sender.

Page 116: COM 360

116

Concurrent Logical Channels• ARPANET Data Link protocol, or concurrent

logical channels, is an alternative to sliding window protocol and can keep pipe full while using the simple stop and wait protocol.

• It multiplexes several logical channels onto a single point-to-point link and runs the stop and wait protocol on each.

Page 117: COM 360

117

Ethernet (802.3)• The Ethernet is the most successful local area

networking technology.• 1973- Developed at Xerox Park by Bob Metcalfe

and David Boggs, it is a general form of the Carrier Sense Multiple Access with Collision Detection (CSMA/CD) technology.

• Based on Aloha, early packet network developed at the University of Hawaii to support communication across the islands.

Page 118: COM 360

Bob Metcalfe

118

•Developed the Ethernet with David Boggs• 1979 Founded 3COM Corporation, which makes wirelesss access points• Founded Infoworld•Authored numerous books and articles•Recipient of many awards including the National Medal of Technology (2005) and induction into the National Inventors Hall of Fame for his contributions to the “welfare of mankind”.•Spoke at the CCSCE Conference at SJC, October, 2007 “ETHERNET IS THE ANSWER; WHAT IS THE QUESTION?”

Page 119: COM 360

119

Ethernet (802.3)

• Digital Equipment Corporation (DEC), Intel and Xerox joined to form the 10 Mbps Ethernet standard in 1978.

• This standard formed the basis of the IEEE standard 802.3

• It has recently been extended to include a 100 Mbps version, called Fast Ethernet and a 1000 Mbps version called Gigabit Ethernet.

Page 120: COM 360

120

Ethernet (802.3)• The Ethernet is a multiple-access network meaning that

a set of nodes send and receive frames over a shared link.• The “carrier sense” means that the nodes can distinguish

between a busy and idle link.• “Collision detect” means that a node listens as it

transmits and can detect when a transmitting frame has interfered (collided) with a frame transmitted by another node.

• When a collision occurs, both nodes back off, wait a random amount of time and then attempt to send again.

Page 121: COM 360

121

Physical Properties• An Ethernet is typically implemented on coaxial

cables of up to 500 meters.• (On older versions, called thick-net or 10Base5, a

transceiver connected hosts to the cable and then to the network adapter or NIC card.)

• Newer versions, 10Base2, connect directly through the NIC, where all the logic is contained.

• 10BaseT, for twisted pair, uses Cat 5 cable and is limited to 100meter.

• “Base” refers to the baseband system.

Page 122: COM 360

122

Ethernet Transceiver and AdapterTransceiver

Ethernet cableAdaptor

Host

Page 123: COM 360

123

Thick Ethernet Wiring  Uses thick coax cable   AUI cable (or transceiver or drop cable connects from NIC to transceiver   AUI cable carries digital signal from NIC to transceiver   Transceiver generates analog signal on coax • Wires in AUI cable carry digital signals, power and other control signals

Page 124: COM 360

124

Ethernet Wiring       Uses thin coax that is cheaper and easier to install than thick Ethernet coax     Transceiver electronics built into NIC; NIC connects directly to network medium • Coax cable uses BNC connector

Page 125: COM 360

125

Ethernet Wiring   Coax runs directly to back of each connected computer

• T connector attaches directly to NIC

  Useful when many computers are located close to each other

  May be unreliable - any disconnection disrupts entire net

Page 126: COM 360

126

Twisted Pair Ethernet•  Variously called 10Base-T, twisted pair or TP

Ethernet •  Replaces AUI cable with twisted pair cable • Replaces thick coax with hub

Page 127: COM 360

127

Physical Properties• Multiple Ethernet segments are joined by repeaters,

which forward a digital signal.• No more than 4 repeaters may be connected to any pair

of hosts, limiting an Ethernet to a maximum of 2500 meters.

• An Ethernet can support a maximum of 1024 hosts.• Any signal placed on the Ethernet is broadcast to all

hosts.• Terminators are attached to the end of each segment to

absorb the signal.• The Ethernet uses Manchester encoding.

Page 128: COM 360

128

Ethernet repeaters

Repeater

Host

■ ■ ■

■ ■ ■

■ ■ ■

■ ■ ■

Page 129: COM 360

129

Ethernet Hubs

Hub Hub

The common 10BaseT configuration is to have several point-to-point segments connected to a hub or switch. This is also true for 100Mbps Ethernet, but not for Gigabit Ethernet.

Page 130: COM 360

130

HUBS

Page 131: COM 360

131

Access Protocol• On an Ethernet, all hosts are competing for

access to the same shared link.• The media access control (MAC) algorithm

controls access to the link.• It is implemented in hardware on the

network adapter.

Page 132: COM 360

132

Network Adapter Cards (NIC)

  CPU can't process data at network speeds   Computer systems use special purpose

hardware for network connection   Typically a separate card in the backplane   Network adapter card or network interface card

(NIC)   Connector at back of computer then accepts

cable to physical network

Page 133: COM 360

133

Network Interface Hardware

Page 134: COM 360

134

NIC Cards

The sockets for the NIC cards are usually located near the back of the cabinet and a network cable attaches to the end of the NIC.

Page 135: COM 360

135

NIC Cards and WiringNICS can provide all three connection technologies

Page 136: COM 360

136

Ethernet Frame Format

Destaddr

64 48 32CRCPreamble Src

addr Type Body1648

•Taken from the Digital-Intel-Xerox Ethernet Standard

•Each Ethernet frame is defined by the following format where the preamble allows the receiver to synchronize with the signal.

•Both source and destination hosts are identified by addresses

•Packet type identifies the protocol

•Each packet can contain up to 1500 bytes of data (46bytes minimum)

•32-bit CRC for error detection

Page 137: COM 360

137

Addresses

• Each host on an Ethernet has a unique Ethernet address.

• Technically the address belongs to the adaptor, not to the host and is usually burned into the NIC card ROM.

• Each NIC card has a unique prefix and makes sure it assigns unique addresses

• Addresses can be assigned statically, dynamically or can be configurable and assigned by the network administrator

Page 138: COM 360

138

Assigning AddressesStatic: Hardware manufacturer assigns permanent

address to each interface - doesn't change

Manufacturer must ensure every interface has a unique address

Configurable: Address can be set by end user, either through switches or jumpers, or electronically ( EPROM) or through software  

System administrators must coordinate to avoid conflict

Dynamic: Interface automatically assigns hardware address each time it is powered up (tries random number)

Automatic scheme must be reliable to prevent conflicts

Page 139: COM 360

139

Addressing Scheme Comparison

 Static:

 Ease of use and permanence

 Less flexibility

 

Configurable: 

Small permanent addresses hardware easily replaced

Requires initial configuration

 

Dynamic: 

Smaller addresses and Vendors do not have to coordinate to assign

them

Lack of permanence and potential conflict

Addressing Scheme Advantages Disadvantages

Page 140: COM 360

140

Address Types• Each frame on an Ethernet is received by every

connected adaptor.• Each adaptor recognizes the frames addressed to it and

passes those frames to it host. These are unicast addresses.

• A broadcast address, consisting of all 1’s, is recognized by all NIC cards.

• A multicast address, with first bit set to 1, is recognized by a subset of NIC cards.

• Running in promiscuous mode, means that a NIC card will pass all messages to its host.

Page 141: COM 360

141

Ethernet Address Summary

• An Ethernet adaptor receives all frames and accepts:– Frames addressed to its own address– Frames addresses to the broadcast address– Frames addressed to a multicast address, if it is

part of that subset– All frames if it is in promiscuous mode

Page 142: COM 360

142

Transmitter Algorithm• Receiver side is simple.• Sender side implements Ethernet protocol.• When NIC has frame to send and the line is busy, it waits

for the line to become idle.• Because there is no centralized control, two (or more)

adaptors may send at once, causing a collision. When a collision is detected, a jamming sequence is sent to stop transmission.

• The adaptors wait a random amount of time before trying again.

• Each time there is a collision, the delay interval doubles – called exponential backoff.

Page 143: COM 360

143

Worst Case Scenario

(a)

(b)

(c)

A B

A B

A B

A B

(d)

Page 144: COM 360

144

Success of the Ethernet

• Extremely easy to administer, no switches to fail, no routing or configuration tables

• Easy to add additional hosts• It is inexpensive, since cables are relatively

cheap.• Most new LAN switching technology is

based on the Ethernet

Page 145: COM 360

145

Token Rings (802.5, FDDI, RPR)

• Token Rings are the other significant class of shared media networks.

• IBM Token Ring, was the original – followed by the IEEE 802.5 standard, which was nearly identical, and finally the newer FDDI (Fiber Distributed Data Interface) Standard, which is declining in use.

• Resilient Packet Ring or RPR (802.17) is nearly standardized.

Page 146: COM 360

146

Token Ring• Token ring Network consists of a set of nodes connected

in a ring.• Data flows in a particular direction around the ring so

that each node receives a packet from its upstream neighbor and forwards it to its downstream neighbor.

• Similar to Ethernet in that it involves an algorithm which controls when a node can transmit, and all nodes see all frames.

• Sending a message differs from that of the Ethernet.

Page 147: COM 360

147

Token Ring Network

Page 148: COM 360

148

Implementing a Token Ring

Page 149: COM 360

149

Tokens• Access to the network is controlled by a token.• A ‘token” is a special sequence of bits, which

circulates around the ring.• Each node receives the token, and when it has

the token, that node may send a packet and then forward the token to the next node in a round-robin fashion.

• This is fair, since each node gets a turn to send.

Page 150: COM 360

150

Physical Properties

• Any link or node failure makes the whole network useless.

• When relay is open, the station is included in the ring; if the relay closes, the ring bypasses the node.

• Several relays are packed into a single multi-station access unit ( MSAU) – required by IBM token ring.

• Data rate is 4 or 16 Mbps and uses Manchester differential encoding

• Twisted pair is required for IBM and not specified for 802.5

Page 151: COM 360

151

Relay on Token Ring

Host

From previoushost

To nexthost

Relay(a)

Host

Host Host

From previoushost

To nexthost

Relay(b)

a) Relay open – host active b) Relay closed-host bypassed

Page 152: COM 360

152

Multimedia Access Unit

Host

Host

Host

Host

From previousMSAU

To nextMSAU

MSAU

Used only in electrical rings to compensate for node failure.

Page 153: COM 360

153

Token Ring Media Access Control

• Network adapter contains a receiver, transmitter, and one or more bits of data storage.

• When no node is sending, the token circulates.• A sending station, “seizes” the token and sends data.

Token holding time (THT) is the time the node can hold the token. Default THT = 10ms.

• 802.5 also supports a strict priority scheme• Sending node can reinsert token immediately following its

frame (early) or after the frame circles the ring and is removed (delayed) release.

Page 154: COM 360

154

Token Release

Token

Frame Token Frame

(a) (b)

a) early b) delayed

Page 155: COM 360

155

Token Ring Maintenance• Token rings have a station designated as the monitor.• Procedures are defined to elect a monitor when the ring is

first connected or when the monitor fails.• Monitor must make sure there is always a toke in the ring

and that there is sufficient delay.• It also checks for corrupted or orphaned frames.• It also checks for “dead” stations.

Page 156: COM 360

156

Token Ring Frame Format

Body ChecksumSrcaddr

Variable48Destaddr

48 32Enddelimiter

8Framestatus

8Framecontrol

8Accesscontrol

8Startdelimiter

8

•Uses differential encoding codes in start and end delimiters.

•Access control byte includes the frame priority

•Frame control byte identifies the higher-level protocol

•Like Ethernet, addresses are 48 bytes long

•Includes a 32- bit CRC and A and C bits for reliable delivery

Page 157: COM 360

157

FDDI• Fiber Distributed Data Interface (FDDI) is similar to

802.5 and IBM token ring.• Significant differences are that it runs on fiber, not

copper and makes use of some newer innovations• It is usually a dual ring – where each ring transmits

in the opposite direction.• The second ring is only used if the primary ring fails

and there is a “loop back” toform a complete ring.• Instead of a monitor all nodes participate equally in

maintaining the ring.

Page 158: COM 360

158

Dual Fiber Ring

(a) (b)

a) Normal operation b) Failure of primary ring

Page 159: COM 360

159

Physical Properties• FDDI network consists of a dual ring- two rings that

transmit data in opposite directions. The second ring is only used if the primary ring fails.

• Nodes attach to the ring with a single cable called single attachment stations (SAS). A concentrator attaches several SASs to the ring.

• FDDI is a 100 Mbps network and is limited to 500 hosts.• FDDI uses 4B/5B encoding• Token holding algorithms are more complex than 802.5

Page 160: COM 360

160

FDDI Frame Format

Control8 8 8 24

CRCStart offrame

End offrame

Destaddr Body

4848Srcaddr Status

32

•Similar to 802.5 with these exceptions:

•Uses 4B/5B encoding instead of Manchester

•Has a bit in the header to distinguish synchronous from asynchronous traffic

•Lacks the access control bits present in 802.5

Page 161: COM 360

161

Resilient Packet Ring (RPR)• Relatively recent technology – IEEE (802.17)• Resiliency- the ability to recover quickly from a

link or node failure was its key design goal.• Other goals were bandwidth efficiency and

Quality of Service (QoS) support.• Like FDDI it uses 2 rings, but unlike FDDI ,

both are used for normal service.• Uses buffer insertion instead of a token.• Used in MAN’s but “metro Ethernet” is

coming…

Page 162: COM 360

162

Wireless• Wireless is the rapidly evolving technology for

connecting communication devices:– Bluetooth – Wi-Fi -802.11 – Wi-MAX – 802.16 – and 3G cellular wireless

• They differ in how much bandwidth they can provide, how far apart nodes can be and which part of the electromagnetic spectrum they use.

Page 163: COM 360

163

Wireless TechnologiesBlueTooth Wi-Fi WiMAX 3G Cell

Link Length

10m 100m 10 km

Bandwidth 2.1 MbpsShared

54 MbpsShared

70 MbpsShared

384+KbpsPer connection

Use/link To notebook

Notebook to base

Building to tower

Phone to tower

Anology USB Ethernet Coaxial DSL

Page 164: COM 360

164

Wireless

• The most widely used wireless links are asymmetric – the two endpoints are different kinds of nodes

• One endpoint acts as a base station and has no mobility and is wired to the Internet or other network.

• The client not is often mobile and relies on its link to the base station to communicate with other nodes.

Page 165: COM 360

165

Page 166: COM 360

166

Wireless

• Notice that wireless naturally supports point to multipoint communications becaues radiio waves sent out by one device can be simultaneously received by many devices

• However communication between client nodes is routed through the base node

Page 167: COM 360

167

Example Wireless Network

A B C D

Page 168: COM 360

168

Levels of Mobility

• No mobility- when a receiver must be in a fixed location to receive a directional transmission from a base station (true of the initial WiMAX)

• Mobility within the range of a base as in the case of Bluetooth

• Mobility between bases as is the case with cell phones and Wi-Fi

Page 169: COM 360

169

Mesh or Ad hoc Network

• A wireless mesh is an alternative topology• Nodes are peers ( there is no base station)• Messages are forwarded through a chian of

peers as long as each peer is within range of the preceeding node.

• This allows a wireless portion of a network to extend beyond the limited range of a single radio.

Page 170: COM 360

170

Page 171: COM 360

171

Bluetooth• Bluetooth provides very short range communication

between mobile phones, PDAs, notebook computers and other peripheral devices.

• It is a convenient alternative to connecting with a wire.• It has a range of only 10 m and operates at 2.45 GHz • Because devices usually blong to an individual or

group it is often called a PAN ( personal area network)

• Network connects up to 7 devices to a master and is called a piconet.

Page 172: COM 360

172

Bluetooth piconet

Page 173: COM 360

173

Wireless ( 802.11)

• Like Ethernet and Token Ring, 802.11 is designed for use in a limited geographical area (homes, office buildings, campuses).

• Primary challenge is to mediated shared access through space.

• 802.11 supports additional features (time-bound services, power management and security)

Page 174: COM 360

174

Physical Properties• 802.11 was designed to run over three different media-

two based on spread spectra and one based on diffused infrared.

• The radio based versions run at 11 and 54 Mbps.• A chipping sequence spreads the signal over a wide

frequency using a random sequence and makes the signal look like noise to any receiver that does not know the sequence.

• Infrared signals are diffused so the sender and receiver do not need to be aimed at each other, but must be within buildings.

Page 175: COM 360

175

4-Bit Chipping Sequence

Random sequence: 0100101101011001

Data stream: 1010

XOR of the two: 1011101110101001

0

0

0

1

1

1

Page 176: COM 360

176

Collision Avoidance• The protocol is more complex than Ethernet,

since all nodes are not always within reach. • Consider 4 nodes A,B,C,D that are able to send

to a node to its immediate left or right,so B can reach A and C but not D.

• If A and C both send to B they collide, but are unaware of each other and are called hidden nodes.

Page 177: COM 360

177

Hidden node problem

A & C can collide at B

Page 178: COM 360

178

Collision Avoidance

• Another related problem is the exposed node problem.

• Suppose B is sending to A and C is aware of this. It is a mistake for C to think it cannot transmit.

• It is not a problem for C to transmit to D because it will not interfere with A’s ability to receive from C

Page 179: COM 360

179

Exposed node problem

B can transmit to A and C can transmit to D

Page 180: COM 360

180

Collision Avoidance• 802.11 addresses these two problems with a Multiple

Access Collision Avoidance algorithm. (MACA)• Sender and receiver exchange control frames before

transmitting data• Sender sends a request to transmit (RTS) frame.• Receiver relies with a clear to send (CTS) frame.• Receiver also sends an ACK after successfully receiving

the frame. All nodes must wait for this before trying to transmit.

• CTS frames can collide and both must wait before transmitting, similar to Ethernet backoff.

Page 181: COM 360

181

Distribution System• Since an advantage of a wireless system is that

nodes are free to move around, reachable nodes may change over time.

• Some nodes may roam and some, called Access Points (AP) are connected to the network infrastructure by a distribution system.

• Distribution system runs at layer 2 of the ISO architecture and does not depend on higher layers.

Page 182: COM 360

182

Access Points connected to a Distribution Network

BH

AF

G

D

AP-2AP-3AP-1

C E

Distribution system

Each node associates itself with one access point.

Page 183: COM 360

183

Communication Example

• For node A to communicate with node E• A first sends a frame to its access point AP-1,

which forwards the frame across the distribution system to AP-3, which finally transmits the frame to E

Page 184: COM 360

184

Selecting an APTechnique called scanning:1. The node sends a Probe frame2. All APs within reach reply with a Probe Response

Frame3. The nodes selects one of the access points and sends

that AP an Association Request Frame.4. The AP replies with an Association Response Frame

A node uses this when it joins the network and when it becomes unhappy with current AP ( weak signal, etc.)

Page 185: COM 360

185

Active and Passive Scanning

• After a node has probed the network, it associates itself with an Access Point. This is called active scanning.

• APs also periodically send a Beacon Frame that advertise the capabilities of the Access Point, including transmission rates. A node can change to this point by sending an Association Request Frame to the access Access Point . This is called passive scanning.

Page 186: COM 360

186

Node Mobility

BH

AF

G

D

AP-2AP-3AP-1

ECC

Distribution system

Page 187: COM 360

187

802.11 Frame Format

Addr4 PayloadSeqCtrlAddr3Addr2Addr1 CRC0Ð18,4964816 32484848

Duration16

Control16

48 bit Source and Destination addresses ( addr1, addr2)

Two additional address fields depends on the ToDS, From DS settings

Control fields: Type, ToDS, FromDS

Type fields indicates whether the frame is RTS, CTS or data

CRC for error detection

Page 188: COM 360

188

802.11 Frame Format

Page 189: COM 360

189

WiMAX (802.16)

• WiMAX stands for Worldwide Interoperability for Microwave Access

• It is a metropolitan area network(MAN) with a range of 1-30 miles.

• It odes not yet inclued mobility, but that will be added as 802.16e

• Its clients are multiplexers for a building and to adapt to different frequencies it uses different physical layer protocols.

Page 190: COM 360

190

Cell Phone Technologies• Frequency bands vary around the world:

– Europe 900 and 1800 MHz bands– North America 850 and 1900 MHz bands

• Cost is high to users because of licensed spectrum• Incompatible cell phone standards• Phones designed to carry voice now carry video,

and audio which require high bandwidth

Page 191: COM 360

191

Cell Phone Technologies

• Relies on use of base stations that are part of a wired network

• Geographic area served by the base station’s antenna is called a cell

• Cells overlap and a base station can serve more than one cell using multiple antennae.

Page 192: COM 360

192

Handoff

• As a phone begins to leave a cell, it moves into an area of overlap with other cells

• The current base station senses the weakening signal and give control to whichever base station is receiving the stronger signal from it.

• If a phone is receiving a call, the call must be transferred over to the new base station in what is called a handoff.

Page 193: COM 360

193

Cell Phone Generations

• 1G – analog• 2G – digital -most of the current technology, some

are referred to as 2.5 G – not quite third generation, but more advanced. These are GSM- Global System for Mobile Communications

• 3G – Based on CDMA (code division Multiple Access

• Satphones- class of phones that are not cellular, but are satellite phones

Page 194: COM 360

194

Summary• Five key problems so that links can exchange information:• Encoding problem for physical links carrying signals;• The framing problem determines how to package bits into

frames;• The error detection problem using CRC, parity, and

checksums• Problem of recovering lost frames discarded because of

errors• Problem of mediating access on shared media (Ethernet,

token ring and wireless)

Page 195: COM 360

195

Further Reading

• Metcalfe, Robert. and Boggs, David, “Ethernet: Distributed Packet Switching For Local Computer Networks”, Communications of the ACM, 19(7):395-403, July, 1976

• http://standards.ieee.org/ for status of IEEE standards

• See p. 145 for more complete list…