Presentation is loading. Please wait.

Presentation is loading. Please wait.

Prof. Reuven Aviv Dept. of Computer Science Computer Networks Improved Usage of Bandwidth.

Similar presentations


Presentation on theme: "Prof. Reuven Aviv Dept. of Computer Science Computer Networks Improved Usage of Bandwidth."— Presentation transcript:

1 Prof. Reuven Aviv Dept. of Computer Science Computer Networks Improved Usage of Bandwidth

2 contents Review encoding of digital data by FSK, MFSK Frequency Hopping Spread Spectrum (FHSS) Direct Sequence Spread Spectrum (DSSS) Code Division Multiple Access (CDMA) Multiplexing –Ref: Stallings, Ch. 9, 8 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 2

3 Review: Encoding of Digital Data by FSK and MFSK

4 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 4 Analog Encoding of Digital Data: Modulation Computer data over a cable Done by modem modulates a carrier signal A*cos(2  f 0 t +  ) ASK change A FSK changes f PSK change 

5 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 5 Binary and Multi Frequency Shift Keying BFSK: Each bit 1,0 encoded by a different frequencies f i s i (t) = A*cos[2  f i t] for bits i = 1,0 –f i ≡ f 0 ± f d = f 0 + 0.5(b i +1)f d b i = ±1 for bits i = 1,0  MFSK: Each L bits encoded by a different frequencies f i  How many frequencies are used?  Number of frequencies is M = 2 L  Symbol s i (t) = A*cos(2  f i t)  f i = f c + (2i –1 –M) f d 1 <= i <= M

6 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 6 MFSK: M = 4 frequencies; 2-bit symbols T: 1 bit transmission time T s : Symbol (2 bits) transmission time

7 FHSS Frequency Hopping Spread Spectrum Which frequency is “hopping”

8 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 8 Frequency Hopping Spread Spectrum (FHSS) A number of channels allocated for the signal –Each channel has a central (carrier) frequency Sender jumps from channel to channel –E.g. IEEE WLAN (Wifi) every 300 msec – data modulated, using BFSK or MFSK Channel numbers determined by sequence of auxiliary bits - the spreading code –Secret known to sender and receiver Spectrum is much wider than without spreading Receiver similarly hopping between channels

9 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 9 Frequency Hoping Spread Spectrum

10 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 10 FHSS Example: using BFSK Binary data stream fed into BFSK modulator s i (t) = A*cos[2  (f i t)] f i = f 0 + 0.5(b i +1)f d For t in the interval [ iT, (i+1)T ] i = 1, 2,3,… T = one data bit time; b i = ±1 (for bit 1, 0 resp.) Spreading Sequence generator: generates bits Each k-bit number index into a table entries: modulating (carrier) frequencies, f c f c hops every T c sec – how many different carrier frequencies? How much is T c, the time between hoping?

11 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 11 FHSS System II  Modulating (carrier) Signal: C c (t) = cos(2  f c t)  The resulting signal, during the i’th bit :  P(t) = s i (t)*C c (t) = A*cos[2  (f i t]* cos(2  f c t)  P(t) = 0.5A*cos[2  (f i + f c )t] + (f c  -f c ) (filter)  Signal sent: S(t) = 0.5A*cos[2  (f i + f c )t]  f i changes (or not) according to bit value every T sec  f c change according to Spreading Sequence generator  T c does not have to be equal to T

12 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 12 FHSS Transmitter

13 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 13 FHSS Receiver Exercise: Prove that the receiver recovers the original data

14 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 14 Spread Spectrum What are the advantages and disadvantages of spread spectrum? BFSK/MFSK

15 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 15 Advantages of Spread Spectrum Immunity from various kinds of noise –E.g. Fixed frequency noise why this is so? Can be used for hiding and encrypting signals – how do we do that Several users can independently use the same higher bandwidth with very little interference –Code Division Multiple Access (CDMA) –“Orthogonal” spreading Sequences – Used by cellular phone systems

16 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 16 Reminder: MFSK: M = 4 frequencies; 2 bits symbols

17 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 17 FHSS using MFSK (1)  Before spreading:  L-bit symbols, each encoded by a frequency f i  Number of frequencies is M = 2 L  s i (t) = A*cos(2  f i t) for symbol type i  f i = f c + (2i –1 –M) f d 1 <= i <= M  FHSS changes f c (and hence f i ) every T C seconds  2 Timing parameters:  T = 1 bit time  T s = duration of a symbol (L-bits) = LT  T c = Hopping time

18 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 18 FHSS Using MFSK (2) MFSK signal uses a new channel (frequency) every T c seconds by modulating (multiplying and filtering) the MFSK signal with the FHSS carrier signal data rate R bps  what are T,T s ? duration of a bit: T = 1/R seconds duration of a symbol: T s = L/R seconds T c  T s - slow-frequency-hop spread spectrum T c < T s - fast-frequency-hop spread spectrum

19 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 19 SLOW FHSS T c = 2T s = 4T Num of PN bits k=2 Example: Slow FHSS with MFSK: T c = 2T s = 4T M= 4, k = 2

20 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 20 FHSS Bandwidth increase Length of the table = Number of hopping channels = 2 k –example above k = 2; 4 hopping channels Bandwidth of original MFSK signal –W d = Mf d –Example above M = 4 Bandwidth of transmitted signal –W s = 2 k * Mf d –Example above: W s = 4*4*f d

21 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 21 Example: Fast FHSS with MFSK: T c = 0.5T s = T (M=4, K=2) Chipping interval K = 2 T c = T = 0.5*T s

22 Direct Sequence Spread Spectrum

23 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 23 Direct Sequence Spread Spectrum (DSSS) data-bit (1, 0) encoded by a series of PN bits (1, 0) –Encoding: XOR data bits stream with a faster, repeating sequence of Pseudo-Noise bits Transmission: Modulate result with fixed frequency carrier The new stream has wider bandwidth –Spread is in direct proportion to number of PN bits

24 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 24 Direct Sequence Spread Spectrum (DSSS) Encoding: Data bit 1 inverts the PN bits Data bit 0 leaves the PN bits unchanged

25 Example: DSSS with Binary Phase Shift Keying  Recall Simple BPSK  bits encoded by 2 different phases  s d (t) = A*cos(2  f c t +  )  = 0,  for bits 1,0  s d (t) = A*d(t) cos(2  f c t)  where d(t) = ± 1 for bits 1,0  DSSS:  Multiply by PN bit stream c(t) = [ +1, -1, …]  s(t) = A d(t)c(t) cos(2  f c t) Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 25

26 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 26 DSSS Using BPSK: Implementation 1.Modulate data 2.Multiply by PN bits 3.transmit Exercise: Prove that the receiver recovers original data

27 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 27 Example: DSSS using BPSK

28 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 28 Spectrum DSSS BPSK Data rate R = 1/T Symbol rate 2/T why? Bandwidth before spreading B T ≈ 2/T Bandwidth of PN ≈ 2/T c Bandwidth of transmitted signal ≈ 2(1/T + 1/T c )

29 Code Division Multiple Access

30 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 30 Code-Division Multiple Access (CDMA)  Sources are allocated k-bit “code vector” c i  Source i transmit c i or -c i  c A = (1,-1,-1,1,-1,1)  c B = (1,1,-1,-1,1,1)  c C = (1,1,-1,1,1,-1)  How much is (c A ·c B )?  How much is (c B ·c C )?

31 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 31 CDMA Example  Receiver: knows sender’s code c A = c 1,c 2,c 3,c 4,c 5,c 6  Assume received vector d =  Receiver calculates s A (d) ≡ (d· c A )  Example: A sends one bit, 1 or 0  Receiver gets d = 1,-1,-1,1,-1,1 or –1,1,1,-1,-1,1,-1  S A (d) = (d· c A ) = 6 or -6  What if d was sent by someone else?  Any other d gives |s A (d)| < 6 prove it

32 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 32 CDMA Example: Single bit transmission User A sends 1 d A = c A = User B sends 1 d B = c B = User C sends 1 d C = c C = Receivers decode with several codes, s K (d L ) –s A (c A ) = 6, s A (c B ) = 0, s A (c C ) = 0 –s B (c A ) = 0, s B (c B ) = 6, s B (c C ) = 2 –s C (c C ) = 6, s C (c B ) = 2 s C (c C ) = 6 Receiver received sequence d (one bit sequence): –calculates s K (d) for all K. –One K gives s K (d) = 6 or -6 –means that the sender was K  and the bit was 1 or -1

33 Sending a bit by several sources Linearity: s K (d L + d M ) = s K (d L ) + s K (d M ) Suppose B and C transmit bit 1, -1 resp. Receiver gets d= c B + (-c C ) Receiver calculates s A (d), s B (d) and s C (d) s A (d) = s A (c B ) + s A (-c C ) = 0 + 0 = 0 s B (d) = s B (c B ) + s B (c C ) = 6 + (-2) = 4 s C (d) = s C (c B ) + s C (c C ) = 2 + 6 = 8 Receive identifies senders B (bit1) and C (bit -1). Interference shows up as “small” noise Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 33

34 Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 34 Walsh Codes To decrease noise, We want “orthogonal codes” s K (c L ) = 0 for K ≠ L Start from Walsh matrix, defined recursively –W 1 = (0) Every row is orthogonal to every other row Every row is orthogonal to the logical not of every other row CDMA: allocate 1 sequence per mobile user

35 Multiplexing

36 What if data on a channel does not utilize full capacity of the physical link? –Put multiple channels on 1 physical line common on long-haul, high capacity, links –Fiber, coax, microwave links –FDM, TDM, STDM alternatives – What is FDM?

37 Frequency Division Multiplexing (FDM) Examples: Radio transmission Analog TV (each channel 6 MHz)

38 FDM System Overview Data signals Modulated signals Another Modulation

39 FDM Voiceband Example

40 Analog Carrier Systems long-distance links use an FDM hierarchy AT&T (USA) and ITU-T (International) variants Group –12 voice channels (4kHz each) = 48kHz –range 60kHz to 108kHz Supergroup –FDM of 5 group signals supports 60 voice channels –carriers between 420kHz and 612 kHz Mastergroup –FDM of 10 supergroups supports 600 channels original signal can be modulated many times

41 Synchronous Time Division Multiplexing

42 TDM System Overview Several Digital signals carrying digital Data Each bit/character buffered; Buffers scanned Each source gets a predefined time slot

43 TDM Link Control no headers and trailers Flow and error control detected & handled on individual channel not by the multiplexors –Done by an HDLC type protocol –If receiver of a channel is overflowed, corresponding sender is quenched –Errors identified by individual receivers, providing ack/nack responses

44 Data Link Control on TDM Source 1: HDLC frames with 2 Bytes data each Source 2: HDLC frames with 3 Bytes data each Frames reassembled by receivers Multiplexing transparent to sources/receivers

45 Synchronization between MUX sender & receiver no flag or SYNC chars bracketing TDM frames synchronizing between clocks of the MUX source and destination: –Digit framing –one control bit added to each TDM frame  identifiable bit pattern used as control channel alternating pattern 101010…, unlikely to be contained in the data –receivers compare incoming bits of frame position to the expected pattern

46 Synchronization between data sources Data Sources clocks not synchronized Data rates are not multiple integers of a basic rate Solution: Make outgoing rate higher than input –MUX adds extra dummy bits into each input stream until its rate (excluding framing bits) is equal to its local clock rate  Pulse stuffing

47 Example of TDM 3 analog sources, sampled (4K/sec, 8K/sec, 4K/sec), then digitized (4bit/sample)  64kbps 8 digital sources : 7.2 kbps each –Each raised by pulse stuffing to 8 kbps

48 Example of TDM (cont’d): Frame Design Ratio between rates of each of the digital source to the analog source 1/8 Example frame structure: 8 bytes of the analog source, 8 one-byte from the digital sources –Frame size L = 16 bytes (128 bits) – what is the frame transmission time? Assume required transmission rate R = 128*10 6 bps Frame transmission time T F = L/R T F = 1  sec Oct. 2007 Prof. Reuven Aviv:Spread Spectrum 48

49 DS-1 Transmission Format

50 DS-1 Frames 24 channels, 8 bit each, + 1 framing bit –L = 192 + 1 = 193 bits T F = 125  sec (8000 frames/sec) –R = L/T F = 193/125 = 1.544 Mbps

51 DS-1 usage for digital data Voice transmission: –8 bits is exactly one sample –(each 6’th frame uses 7 bits/sample. Extra bit is signaling bit, used for link administration) Data transmission: –23 channels data. Last channel sync byte –Within a channel:  7 bits data  1 bit user/control data indicator (start/end communication)  7X8000  56 Kbps data rate

52 Statistical TDM (STDM) In TDM time slots are wasted STDM allocate time slots on demand For n input line, k (< n) time slots in a frame Input: Scan input buffers, collect data; send

53 Statistical TDM: Data attributes Each input source has a buffer Data must have ID and length identifiers Source ID: relative ID (1, 2, …N) –relative to previous one Length: 2 bits, identify if 1, 2, 3 Bytes –11 means special length field included Popular STDM: one character per source that has data. Frame begins with a bitmap identifying senders

54 STDM in Cable Modem data service: Mostly downstream (web pages) –A group of subscribers is allocated two 5MHz channels. One downstream, one upstream –Each channel multiplex subscribers data –Downstream has grant packets for requesting time slots in upstream channel

55 Cable Spectrum Division Cable provider support TV & data service Spectrum divided to 3 ranges, each subdivided to 6 MHz channels network data (upstream): 5 - 40 MHz television delivery (downstream): 50 - 550 MHz network to user data (downstream): 550 - 750 MHz


Download ppt "Prof. Reuven Aviv Dept. of Computer Science Computer Networks Improved Usage of Bandwidth."

Similar presentations


Ads by Google