Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over...

36
Chapter 5 Signal Encoding Techniques

Transcript of Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over...

Page 1: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Chapter 5

Signal Encoding Techniques

Page 2: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Reading Materials

Data and Computer Communications,

William Stallings

Page 3: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Encoding Techniques

Digital data→Digital signal

Analog data→Digital signal

Digital data→Analog signal

Analog data→Analog signal

Page 4: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Digital Data → Digital Signal

Digital signal

– Discrete, discontinuous voltage pulses

– Each pulse is a signal element

– Binary data encoded into signal elements

Page 5: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Terms

Unipolar

– All signal elements have same sign

Polar

– One logic state represented by positive voltage

the other by negative voltage

Data rate

– Rate of data transmission in bits per second

Duration or length of a bit

– Time taken for transmitter to emit the bit

Modulation rate

– Rate at which the signal level changes

– Measured in baud = signal elements per second

Page 6: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Encoding Schemes

Page 7: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Nonreturn to Zero-Level (NRZ-L)

Two different voltages for 0 and 1 bits

Voltage constant during bit interval

– no transition i.e. no return to zero voltage

e.g. absence of voltage for zero, constant positive

voltage for one

More often, negative voltage for one value and

positive for the other

This is NRZ-L

Page 8: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Nonreturn to Zero Inverted

Nonreturn to zero inverted on ones

Constant voltage pulse for duration of bit

Data encoded as presence or absence of signal

transition at beginning of bit time

Transition (low to high or high to low) denotes a binary 1

No transition denotes binary 0

An example of differential encoding

Page 9: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Multilevel Binary

Use more than two 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)

Page 10: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Pseudoternary

One represented by absence of line

signal

Zero represented by alternating

positive and negative

No advantage or disadvantage over

bipolar AMI

Page 11: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Biphase

Manchester

– Transition in middle of each bit period

– Transition serves as clock and data

– Low to high represents one

– High to low represents zero

– Used by IEEE 802.3

Differential Manchester

– Mid-bit transition is clocking only

– Transition at start of a bit period represents zero– No transition at start of a bit period represents one

– Note: this is a differential encoding scheme

– Used by IEEE 802.5

Page 12: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Manchester Encoding

Page 13: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Scrambling

Use scrambling to replace sequences that would

produce constant voltage

Filling sequence

– Must produce enough transitions to synchronize

– Must be recognized by receiver and replace with

original

– Same length as original

No DC component

No long sequences of zero level line signal

No reduction in data rate

Error detection capability

Page 14: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

B8ZS

Bipolar with 8 Zeros Substitution

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

Unlikely to occur as a result of noise

Receiver detects and interprets as octet of all zeros

Page 15: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

HDB3

High Density Bipolar 3 zeros

Based on bipolar-AMI

String of four zeros replaced with one

or two pulses

Page 16: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

B8ZS and HDB3

Page 17: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition
Page 18: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Digital Data→Analog Signal

Amplitude Shift Keying (ASK)

Frequency Shift Keying (FSK)

Phase Shift Keying (PSK)

Quadrature Amplitude Modulation (QAM)

Page 19: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Modulation Techniques

Page 20: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

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 21: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

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

Even higher frequency on LANs using coaxial cable

Page 22: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Full-Duplex FSK

Page 23: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

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 24: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Differential PSK

Page 25: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Quadrature PSK

More efficient use by each signal element

representing more than one bit

– e.g. shifts of π/2 (90o )

– each element represents two bits

Page 26: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

PSK Constellation

Page 27: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Quadrature Amplitude Modulation

QAM used on fast modems and asymmetric

digital subscriber line (ADSL)

Combination of ASK and PSK

Page 28: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Time Domain for an 8-QAM Signal

Page 29: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Analog Data → Digital Signal

Page 30: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Analog Signal to PCM Digital Code

Page 31: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Nyquist Theorem

The sampling rate must be at least 2 times

the highest frequency.

Page 32: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

PCM Example

Page 33: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Page 34: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Problems

Page 35: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Draw the digital encoded signals of the following bit stream using

Manchester, Differential Manchester, and HDB3 encoding schemes.

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

Modulate the above digital bit stream to analog signal using BFSK, BPSK and

differential BPSK modulation techniques.

Draw 8-QAM signal of the following bit stream.

111 010 100 001 101 010 100 011 101 010 110 000

At least how many PAM samples are required to quantize the above signal? If

each of the PAM sample is quantized to any of 16 different levels, what would

be the PCM code of the signal?

Page 36: Chapter 5cseku.ac.bd/faculty/~kazi/files/cn/chapter5.pdf · No advantage or disadvantage over bipolar AMI . Biphase Manchester –Transition in middle of each bit period –Transition

Courtesy

Professor Jiying Zhao, University of Ottawa