46
1 Signal Encoding Lesson 05 NETS2150/2850 http://www.ug.cs.usyd.edu.au/~nets2150/ School of IT, The University of Sydney

Signal Encoding

  • Upload
    walter

  • View
    63

  • Download
    0

Embed Size (px)

DESCRIPTION

Signal Encoding. Lesson 05 NETS2150/2850 http://www.ug.cs.usyd.edu.au/~nets2150/. School of IT, The University of Sydney. Lecture Outline. Encoding schemes for digital data to transmit in digital transmission systems NRZ schemes Manchester schemes in LANs AMI schemes - PowerPoint PPT Presentation

Citation preview

Page 1: Signal Encoding

1

Signal Encoding

Lesson 05

NETS2150/2850http://www.ug.cs.usyd.edu.au/~nets2150/

School of IT, The University of Sydney

Page 2: Signal Encoding

2

Lecture Outline Encoding schemes for digital data to

transmit in digital transmission systems– NRZ schemes– Manchester schemes in LANs– AMI schemes

• With scrambling for WANs use

Encoding schemes for digital data to transmit in analog transmission systems– ASK Scheme– FSK Scheme– PSK Scheme

Page 3: Signal Encoding

3

Various Encoding Techniques

Encoding is the conversion of streams of bits into a signal (digital or analog).

Categories of Encoding techniques:– Digital data, digital signal– Analogue data, digital signal– Digital data, analog signal– Analogue data, analog signal

Digital transmission

Analog transmission

Page 4: Signal Encoding

4

Digital Data, Digital Signal(Digital to Digital)

Digital signal– Discrete, discontinuous voltage pulses– Each pulse is a signal element– Binary data encoded into signal elements

Page 5: Signal Encoding

5

Interpreting Signals

Need to know– Timing of bits - when they start and end– Signal levels

Factors affecting interpretation of signals– SNR– Data rate– Bandwidth

Page 6: Signal Encoding

6

Comparison of Encoding Schemes

Error detection– Can be built into signal encoding

Cost and complexity– Higher signal rate (& thus data rate) lead to higher

costs Clocking

– Synchronizing transmitter and receiver Signal spectrum

– Bandwidth requirement– Presence of dc component

Page 7: Signal Encoding

7

Digital-to-Digital Encoding Schemes 3 Broad Categories: Unipolar, Polar,

and Bipolar

-Nonreturn to Zero-Level (NRZ-L)

-Nonreturn to Zero Inverted (NRZI)

-Manchester

-Differential Manchester

-Bipolar -AMI

-B8ZS

-HDB3

Magnetic Recording

LAN

WAN

Page 8: Signal Encoding

8

Nonreturn to Zero-Level (NRZ-L)

Polar Encoding Two different voltages for 0 and 1 bits Voltage constant during bit interval

– no transition i.e. no return to zero voltage Negative voltage for one value and

positive for the other

Page 9: Signal Encoding

9

Nonreturn to Zero Inverted (NRZI)

Polar Transition (low to high or high to low)

denotes a binary 1 No transition denotes binary 0 This is an example of differential

encoding

Page 10: Signal Encoding

10

NRZ

Page 11: Signal Encoding

11

Differential Encoding

Polar Better encoding technique Data represented by changes rather

than levels More reliable detection of bit in noisy

channels rather than level

Page 12: Signal Encoding

12

NRZ pros and cons

Pros– Easy to engineer– Make good use of bandwidth

Cons– Lack of synchronisation capability– Presence of a dc component

Used for digital magnetic recording Not often used for signal transmission

Page 13: Signal Encoding

13

Biphase Schemes Polar- signal elements have opposite voltage

level (-ve and +ve)

Overcomes the limitations on NRZ codes

Two biphase techniques are commonly used:– Manchester– Differential Manchester

Heavily used in LAN applications

Page 14: Signal Encoding

14

Biphase Scheme1: Manchester

Transition in middle of each bit interval

Low to high represents one High to low represents zero Used by IEEE 802.3 (Ethernet LAN)

Page 15: Signal Encoding

15

Biphase Scheme 2: Differential Manchester

Midbit transition is clocking only Transition at start of a bit interval represents

zero No transition at start of a bit interval

represents one Note: this is a differential encoding scheme Used by IEEE 802.5 (Token Ring LAN)

Page 16: Signal Encoding

16

Page 17: Signal Encoding

17

Biphase Pros and Cons

Cons– At least one transition per bit time and possibly

two– Maximum baud rate is twice NRZ– Requires more bandwidth

Pros– Synchronization on mid bit transition (self clocking)– Error detection

• Absence of expected transition

– No dc component

Page 18: Signal Encoding

18

Multilevel Binary (Bipolar)

Use more than two voltage levels Bipolar-AMI (Alternate Mark Inversion)

– zero represented by no line signal– one represented by positive or negative pulse– ‘one’ pulses alternate in polarity– No loss of sync if a long string of ones (zeros still a

problem)– Lower bandwidth– Easy error detection

Page 19: Signal Encoding

19

Bipolar-AMI Encoding

Page 20: Signal Encoding

20

Trade Off for Multilevel Binary

Not as efficient as NRZ– Receiver must distinguish between three

levels (+A, -A, 0)

Page 21: Signal Encoding

21

Scrambling Technique Used to replace sequences that would produce

constant voltage Produce “filling” sequence that:

– Must produce enough transitions to sync– Must be recognized by receiver and replace with original– Same length as original

Avoid long sequences of zero level line signal No reduction in data rate Error detection capability Two commonly used techniques are: B8ZS, and

HDB3 Used for long distance transmission (WAN)

Page 22: Signal Encoding

22

Bipolar With 8 Zeros Substitution (B8ZS)

Based on bipolar-AMI If octet of all zeros and last voltage pulse

preceding was positive, encode as 000+-0-+ If octet of all zeros and last voltage pulse

preceding was negative, encode as 000-+0+- Causes two violations of AMI code - intentional

– Unlikely to occur as a result of noise Receiver detects and interprets as octet of all

zeros HDB3 – similar but based on 4 zeros

Page 23: Signal Encoding

23

B8ZS

Page 24: Signal Encoding

24

HDB3

High Density Bipolar 3 Zeros Based on bipolar-AMI String of four zeros replaced with one or

two pulses

Page 25: Signal Encoding

25

HDB3 Substitution Rules

# of Bipolar Pulses (ones) since Last Substitution

Polarity of Preceding Pulse

Odd Even

- 000- +00+

+ 000+ -00-

Page 26: Signal Encoding

26

B8ZS and HDB3

Change of polarity

Page 27: Signal Encoding

27

Recap of Digital Signal Encoding Formats

0 1

NRZL High level Low level

NRZI No transition at start of interval

transition

Bipolar-AMI No line signal +ve line signal

Manchester Transition from high to low in the middle of interval

Transition from low to high in the middle of interval

Diff Manchester (always a Transition in the middle of interval)

Tran at start of interval No transition at start of interval

HDB3 Same as bipolar-AMI, except that any string of four zeros is replaced by a string with one code violation

B8ZS Same as bipolar-AMI, except that any string of eight zeros are replaced by a string of two code violations

Page 28: Signal Encoding

28

Digital Data, Analog Signal Some transmission media only transmit

analog signals. Public telephone system

– 300Hz to 3400Hz (voice frequency range)– Use modem (modulator-demodulator)

Page 29: Signal Encoding

29

Digital to Analog modulation techniques:Modulation involves operation on signal

characteristics: frequency, phase, amplitude.

Amplitude shift keying (ASK)

Frequency shift keying (FSK)

Phase shift keying (PSK)

Page 30: Signal Encoding

30

Modulation Techniques (digital data, analog signal)

Page 31: Signal Encoding

31

Amplitude Shift Keying Values represented by different amplitudes

of carrier Usually, one amplitude is zero

– i.e. presence and absence of carrier is used Susceptible to sudden gain changes Inefficient Up to 1200bps on voice grade lines Used over optical fiber

Page 32: Signal Encoding

32

ASK

Page 33: Signal Encoding

33

Relationship between baud rate and bandwidth in ASK

Page 34: Signal Encoding

34

In ASK, baud rate and bit rate are the same. The baud rate is therefore 2000. An ASK signal requires a minimum bandwidth equal to its baud rate. Therefore, the minimum bandwidth is 2000 Hz.

Find the minimum bandwidth for an ASK signal transmitting at 2000 bps. The transmission mode is half-duplex.

SolutionSolution

Example 1Example 1

Page 35: Signal Encoding

35

Example 2Example 2

Given a bandwidth of 5000 Hz for an ASK signal, what are the baud rate and bit rate?

SolutionSolution

In ASK the baud rate is the same as the bandwidth, which means the baud rate is 5000. But because the baud rate and the bit rate are also the same for ASK, the bit rate is 5000 bps.

Page 36: Signal Encoding

36

Example 3Example 3

Given a bandwidth of 10,000 Hz (1000 to 11,000 Hz), draw the full-duplex ASK diagram of the system. Find the carriers and the bandwidths in each direction. Assume there is no gap between the bands in the two directions.

SolutionSolution

For full-duplex ASK, the bandwidth for each direction isBW = 10000 / 2 = 5000 Hz

The carrier frequencies can be chosen at the middle of each band (see Fig. 5.5).

fc (forward) = 1000 + 5000/2 = 3500 Hzfc (backward) = 11000 – 5000/2 = 8500 Hz

Page 37: Signal Encoding

37

Solution to Example 3

Page 38: Signal Encoding

38

Binary Frequency Shift Keying Most common form is binary FSK (BFSK) Two binary values represented by two

different frequencies (near carrier) Less susceptible to error than ASK Up to 1200bps on voice grade lines High frequency radio Even higher frequency on LANs using co-

ax

Page 39: Signal Encoding

39

FSK

Page 40: Signal Encoding

40

Multiple FSK

More than two frequencies used More bandwidth efficient More prone to error Each signalling element represents

more than one bit

Page 41: Signal Encoding

41

FSK on Voice Grade Line

Page 42: Signal Encoding

42

Phase Shift Keying

Phase of carrier signal is shifted to represent data

Binary PSK– Two phases represent two binary digits

Differential PSK– Phase shifted relative to previous

transmission rather than some reference signal

Page 43: Signal Encoding

43

PSK

Page 44: Signal Encoding

44

Differential PSK

Page 45: Signal Encoding

45

Performance of Digital to Analog Modulation Schemes Bandwidth

– ASK and PSK bandwidth directly related to bit rate– FSK bandwidth related to data rate for lower

frequencies, but to offset of modulated frequency from carrier at high frequencies

– (See Stallings for math) In the presence of noise, bit error rate of PSK

and QPSK are about 3dB superior to ASK and FSK

Page 46: Signal Encoding

46

Summary

Various encoding schemes Some used in LANs Others more suitable in WAN with

scrambling Read Stallings Section 5.1 Next: Data link layer functions.