Data Encoding 2

download Data Encoding 2

of 53

Transcript of Data Encoding 2

  • 8/8/2019 Data Encoding 2

    1/53

    DATA ENCODINGDATA ENCODING

    Data Encoding refers the various techniques of impressingdata (0,1) or information on an electrical, electromagnetic oroptical signal that would propagate through the physicalmedium making up the communication link between the twodevices.

  • 8/8/2019 Data Encoding 2

    2/53

    ANALOG &DIGITALANALOG &DIGITALDifferencesDifferences

    Analog Data &Digital Data Analog Data Take on continuous values on some

    interval Eg. Voice, Video are continuously varying pattern

    of intensity

    Digital Data take on discrete value

    Eg. Text and integers

    Analog Signal & Digital Signal An analog signal is a continuous varying

    electromagnetic wave propagate over a medium

    Adigital signal is a sequence of voltage pulses

    that may be transmitted over a wire medium

  • 8/8/2019 Data Encoding 2

    3/53

  • 8/8/2019 Data Encoding 2

    4/53

    ADVANTAGE OF ANALOGADVANTAGE OF ANALOG

    SIGNALSIGNAL

    Most mediums support analog

    transmission - used for wirelesscommunication

    The telephone infrastructure provides a

    relatively cheap individual point-to-point transmission

  • 8/8/2019 Data Encoding 2

    5/53

    Information, Data and Signals

    Information Data Signal

    001011101

  • 8/8/2019 Data Encoding 2

    6/53

    Information, Data and Signals Data - A representation of facts,

    concepts, or instructions in a formalizedmanner suitable for communication,interpretation, or processing by humanbeings or by automatic means

    Information - The meaning that iscurrently assigned to data by means ofthe conventions applied to those data

  • 8/8/2019 Data Encoding 2

    7/53

    Computers Use Signals for

    Communcation Computers transmit data using digital

    signals, sequences of specified voltagelevels. Graphically they are oftenrepresented as a square wave.

    Computers sometimes communicate

    over telephone line using analogsignals, which are formed bycontinuously varying voltage levels.

  • 8/8/2019 Data Encoding 2

    8/53

    Figure 5-1

    Different Conversion Schemes

  • 8/8/2019 Data Encoding 2

    9/53

    Digital DataDigital Data -- DigitalDigital

    SignalSignal Signal changes value as the data

    changes value from 0 to 1 and 1 to 0

    Several line encoding schemes arepossible. Each has pros and cons

    Digital-to digital encoding fall underthree broad categories: unipolar, polarand bipolar

  • 8/8/2019 Data Encoding 2

    10/53

    Figure 5-2

    Digital to Digital Encoding

  • 8/8/2019 Data Encoding 2

    11/53

    Encoding SchemesEncoding Schemes Unipolar encoding Polar encoding

    Nonreturn to Zero-Level (NRZ-L) Nonreturn to Zero Inverted (NRZI) Manchester Differential Manchester

    Bipolar AMI Pseudoternary B8ZS HDB3

  • 8/8/2019 Data Encoding 2

    12/53

    Encoding SchemesEncoding Schemes

  • 8/8/2019 Data Encoding 2

    13/53

    Figure 5-3

    Types of Digital to Digital Encoding

  • 8/8/2019 Data Encoding 2

    14/53

    BASIC TERMSBASIC TERMS To Understand different Encoding schemes

    first we will have to understand following

    terminologies Unipolar -All signal elements have same sign

    Polar -One logic state represented bypositive voltage the other by negative voltage

    Data rate- Rate of data transmission in bitsper second

    Duration or length of a bit-Time taken fortransmitter to emit the bit

  • 8/8/2019 Data Encoding 2

    15/53

    BASIC TERMSBASIC TERMS Modulation rate-Rate at which the signal

    level changes

    Measured in baud = signal elements per second Mark and Space- Binary 1 and Binary 0

    respectively

    Differential encoding Signal is decoded

    by comparing the polarity of adjacent signalelements

    Multilevel Binary-Use more than two levels

  • 8/8/2019 Data Encoding 2

    16/53

    Unipolar encoding Unipolar encoding is very simple and

    primitive. It uses only one polarity

    This polarity is assigned to one of thetwo binary states, usually the 1.

    The other state, usually the 0, is

    represented by the zero voltage.

  • 8/8/2019 Data Encoding 2

    17/53

    Figure 5-4

    Unipolar Encoding

  • 8/8/2019 Data Encoding 2

    18/53

    Figure 5-5

    Types of Polar Encoding

  • 8/8/2019 Data Encoding 2

    19/53

    Polar encoding Polar encoding uses two voltage levels;

    one positive and one negative.

    In Polar encoding there are three mostpopular variations:

    Nonreturn to zero (NRZ)

    Return to zero (RZ)

    Biphase

  • 8/8/2019 Data Encoding 2

    20/53

    Polar encoding NRZ refers to Nonreturn to zero, invert (NRZ-I) and nonreturn to zero, level (NRZ-L).

    Biphase also refers to two methods, the firstis the Manchester method used by EthernetLANs.

    And the second is Differential Manchestermethod used by Token Ring LANs.

  • 8/8/2019 Data Encoding 2

    21/53

    Nonreturn to zero encoding In NRZ-I, an inversion of the voltage level

    represents a 1 bit, it is the transition between

    a negative and a positive voltages. A0 bit represented by no change.

    Note: In NRZ-I the signal is inverted if a 1 isencounted.

    In NRZ-L sequence, positive and negativehave specific meanings; positive for 0 andnegative for 1.

  • 8/8/2019 Data Encoding 2

    22/53

    Figure 5-6

    NRZ-L and NRZ-I Encoding

  • 8/8/2019 Data Encoding 2

    23/53

    RZ Encoding RZ encoding uses three values; positive,

    negative and zero.

    In RZ, signal changes not between bitsbut during each bit.

    A1 bit is actually represented by

    positive-to-zero and a 0 bit by negative-to-zero rather than negative andpositive alone.

  • 8/8/2019 Data Encoding 2

    24/53

    Figure 5-7

    RZ Encoding

  • 8/8/2019 Data Encoding 2

    25/53

    Biphase encoding In Biphase method the signal changes

    at the middle of bit interval but does

    not return to zero. Instead it continuesto the opposite pole.

    The two types of Biphase encoding in

    use on networks today are Manchesterand Differential Manchester.

  • 8/8/2019 Data Encoding 2

    26/53

    Manchester encoding Manchester encoding uses the inversion

    at the middle of each bit interval for

    both synchronization and bitrepresentation

    Anegative to positive transition

    represents binary 1 and positive tonegative transition represents thebinary 0.

  • 8/8/2019 Data Encoding 2

    27/53

    Differential Manchester encoding Differential Manchester, the inversion at

    the middle of the bit interval is used for

    synchronization. And the presence or absence of an

    additional transition at the beginning ofthe interval is used to identify the bit.

    A transition means binary 0 and notransition means binary 1.

  • 8/8/2019 Data Encoding 2

    28/53

    Figure 5-8Manchester and Diff. Manchester Encoding

  • 8/8/2019 Data Encoding 2

    29/53

    Bipolar encoding Bipolar encoding, uses three voltage

    levels; positive, negative and zero.

    However the zero level in bipolar encodingused to represent the binary 0.

    The 1s are represented by alternating

    positive and negative voltages.

  • 8/8/2019 Data Encoding 2

    30/53

    Figure 5-9

    Types of Bipolar Encoding

  • 8/8/2019 Data Encoding 2

    31/53

    Bipolar Alternate Mark Inversion

    (AMI) Bipolar Alternate Mark Inversion (AMI)

    is the simplest type of the bipolar

    encoding. AMI means alternate 1inversion.

    A variation of bipolar AMI is called

    pseudoternary in which binary 0alternates between positive andnegative voltage.

  • 8/8/2019 Data Encoding 2

    32/53

    Figure 5-10

    Bipolar AMI Encoding

  • 8/8/2019 Data Encoding 2

    33/53

    Bipolar 8-zero Substitution

    (B8ZS) B8ZS is the conversion to provide

    synchronization of a long string of 0s.

    The B8ZS function identically to bipolar AMI,their different occurs whenever eight or moreconsecutive 0s are encountered in the datastream.

    B8ZS provide the artificial signal changes,called the violations between the 0 string.

  • 8/8/2019 Data Encoding 2

    34/53

    Bipolar 8-zero Substitution

    (B8ZS) Any time eight 0s occur in succession, B8ZS

    introduces changes in the pattern based on

    the polarity of the previous 1. If the previous 1 was positive, the eight 0s

    will be encoded as zero, zero, zero, positive,negative, zero, negative, positive.

    If the polarity of the previous 1 is negative,the pattern of violation is the same but withinverted polarities.

  • 8/8/2019 Data Encoding 2

    35/53

    Figure 5-11

    B8ZS Encoding

  • 8/8/2019 Data Encoding 2

    36/53

    High Density Bipolar 3 (HDB3) The HDB3 convention, introduces

    changes into the bipolar AMI pattern

    every time four consecutive 0s areencountered instead of waiting for theeight expected by B8ZS.

  • 8/8/2019 Data Encoding 2

    37/53

    Figure 5-12

    HDB3 Encoding

  • 8/8/2019 Data Encoding 2

    38/53

    Example 5.1Using B8ZS encode the bit stream

    10000000000100. Assume that the

    polarity of the first 1 is positive.

  • 8/8/2019 Data Encoding 2

    39/53

    Figure 5-13

    Solution to Example 5.1

  • 8/8/2019 Data Encoding 2

    40/53

    Example 5.2Using HDB3, encode the bit stream

    10000000000100. Assume that the

    number of 1s so far is odd and the first1is positive.

  • 8/8/2019 Data Encoding 2

    41/53

    Figure 5-14

    Solution to Example 5.2

  • 8/8/2019 Data Encoding 2

    42/53

    Analog Encoding of DigitalAnalog Encoding of Digital

    DataData Data encoding and decoding technique

    to represent data using the properties

    of analog waves

    Modulation: combining signal wave withcarrier wave

    Demodulation: splitting signal wavefrom carrier wave

  • 8/8/2019 Data Encoding 2

    43/53

    Digital DataDigital Data -- AnalogAnalog

    SignalsSignals Transmitting digital data through PSTN

    300Hz to 3400Hz

    Use modem (modulator-demodulator) Modem is the device used to convert

    digital data to analog signals and viceversa

    Uses a constant-frequency signal known as a carriersignal

    Converts a series of binary voltage pulses into ananalog signal by modulating the carrier signal

    The receiving modem translates the analog signal

    back into digital data

  • 8/8/2019 Data Encoding 2

    44/53

    Analog Encoding of DigitalAnalog Encoding of Digital

    DataDataThere are three techniques to convert

    Digital Data into Analog Signal

    Amplitude shift keying (ASK)

    Frequency shift keying (FSK)

    Phase shift keying (PK)

  • 8/8/2019 Data Encoding 2

    45/53

    Modulation TechniquesModulation Techniques

  • 8/8/2019 Data Encoding 2

    46/53

    Amplitude Shift KeyingAmplitude 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

    Used over optical fiber using LED or LaserTransmitter

  • 8/8/2019 Data Encoding 2

    47/53

    Amplitude Shift Keying

  • 8/8/2019 Data Encoding 2

    48/53

    Amplitude Shift KeyingAmplitude Shift Keying

    (ASK)(ASK) In radio transmission, known as amplitude

    modulation (AM)

    The amplitude (or height) of the sine wavevaries to transmit the ones and zeros

    Major disadvantage - telephone lines are verysusceptible to variations in transmissionquality that affect amplitude

  • 8/8/2019 Data Encoding 2

    49/53

    Frequency Shift KeyingFrequency Shift Keying

    (FSK)(FSK) In radio transmission, known as frequency

    modulation (FM)

    The frequency of the carrier wave varies inaccordance with the signal to be sent

    Signal is transmitted at constant amplitude

    More immune to noise than

    ASK

    Requires more analog bandwidth than ASK

  • 8/8/2019 Data Encoding 2

    50/53

    Frequency Shift KeyingFrequency Shift KeyingValues represented by different

    frequencies (near carrier)

    Less susceptible to error than ASK High frequency radio transmission 3 to

    30 MHz

  • 8/8/2019 Data Encoding 2

    51/53

    Frequency Shift KeyingFrequency Shift Keying

  • 8/8/2019 Data Encoding 2

    52/53

    Phase Shift Keying (PSK)Phase Shift Keying (PSK) Also known as phase modulation (PM)

    Frequency and amplitude of the carrier signal

    are kept constant The carrier is shifted in phase according to

    the input data stream

    Each phase can have a constant value, or

    value can be based on whether or not phasechanges (differential keying) Phase shifted relative to previous transmission

    rather than some reference signal

  • 8/8/2019 Data Encoding 2

    53/53