dr. thomas hicks computer science department trinity university

111
1 Dr. Thomas Hicks Computer Science Department Trinity University 1 Data Communication & Networking CSCI 3342

Upload: chelsi

Post on 24-Feb-2016

28 views

Category:

Documents


0 download

DESCRIPTION

Data Communication & Networking CSCI 3342. Digital Transmission. Dr. Thomas Hicks Computer Science Department Trinity University. 4. 1. Digital To Digital Encoding. Major 4 Encoding Methods. Digital-To- Digital. Analog-To- Digital . Digital-To- Analog. Analog-To- Analog. - PowerPoint PPT Presentation

TRANSCRIPT

William Stallings Data and Computer Communications

3Major 4 Encoding Methods Digital-To-DigitalDigital-To-AnalogAnalog-To-Digital Analog-To-AnalogBinary Data Must Be Encoded/Converted To A Form That Will Propagate Over A Wire4

Digital To Digital Encoding Converting Binary 0s and 1s Into A Sequence Of Voltage Pulses That Can Propagate Over A Wire.Transmit Data From Computer To Printer

Digital To Digital Encoding20Only Some Of Major Encoding Methods! UnipolarBipolarPolarNRZRZAMIHDB3B8ZSNRZ-LNRZ-IManchesterDifferentialManchesterETC21NRZ-L

You May Make A 5"x8" Card To Use On Exam(May Include Titles & Images)5 Signal EncodingSignal LevelData Level

6

Signal Level vs. Data Level7 Pulse Rate & Bit Rate8Pulse Rate = No Pulses Per SecondBit Rate = No Bits Per SecondIf the pulse carries only one bit, the Bit Rate = Pulse Rate [Not Always The Case]34Sketch The NRZ-L Encoding For The Signal Below.

NRZ-L Practice37

NRZ-IAn Inversion Of The Voltage Represents 1 If Pos Neg If Neg Pos No Change Represents 0Synchronization Occurs With Every 1 Bit0s Can Still Cause Problem More 1s Than 0s0 First Pos1 First NegNext Bit Is 1Polar Encoding NRZ-I38Sketch The NRZ-I Encoding For The Signal Below.

NRZ-I Practice40

Polar RZRZPositive Voltage Means 1Negative Voltage Means 0 Signal Returns To 0 Voltage Half-ThroughRZ - Return to Zero A Signal Change With Every Bit To Assure Synchronization Several Solutions41

Polar RZRZ 3 Levels Of Amplitude 3 Voltage Levels42Polar RZ PracticeSketch The RZ Encoding For The Signal Below.

Best So Far!46

Polar ManchesterManchesterPositive To Negative Transition For 0 Negative To Positive Transition For 1Two Levels Of AmplitudeInversion At Middle Middle Of Bit Time47

Polar Manchester (cont)ManchesterInversion At Middle Middle Of Bit Time Synch Signal Change Middle Of Each Bit

Green Blue48Polar Manchester PracticeSketch The Manchester Encoding For The Signal Below.

Two Levels Of AmplitudeSame Synchronization As RZ49Manchester I Would Provide KEY

52

Polar Differential Manchester

Differential ManchesterSynch Signal Change Middle Of Each BitInversion At Beginning Of Bit TimeTransition At Start Of Bit Time = 0No Transition At Start Of Bit Time = 12 Signal Changes For 0, 1 Signal Change for 153Polar Differential Manchester PracticeSketch The Differential Manchester Encoding For The Signal Below.

56

BipolarBipolar Three Most Most Common Solutions AMI, B8ZS, & HDB3Uses 3 Voltage LevelsPositive, Negative, ZeroZero Level Is 0Alternating Positive & Negative Are 158

Bipolar - AMIAMI Alternate Mark InversionMark In Telegraphy Means 1 Zero Voltage Represent 0Alternating Positive & Negative Represent 1

Synchronize Long Sequence 1sNo Synchronize Long Sequence 0sDC Component = 059Bipolar AMI PracticeSketch The AMI Encoding For The Signal Below.

60

Bipolar - PseudoternaryA Variation Of Bipolar AMI is called Pseudoternary, In Which Binary 0s Alternate Between Positive & Negative Voltages.

NEW!62

Bipolar BZPSB8ZS Bipolar 8 Zero SubstitutionSame As AMI Until 8 Consecutive 0sUse Chart Below [Will Be Provided On Exam/ Quiz]63Bipolar B8ZS PracticeSketch The B8ZS Encoding For The Signal Below.

Used A Lot In North America64

Bipolar HDB3HDB3 High Density Bipolar 3Similar To B8ZS Except Done In Sets Of 4Use Chart Below [Will Be Provided On Exam/ Quiz]

68

MLT-3 EncodingMLT-3 Encoding Similar to NRZ-IUses 3 Levels Of Signal +1, 0, -1The Signal Transitions From One Level To TheNext At The Beginning Of A 1 BitThere Is No Transition At The Beginning Of A 0 Bit

71

1. Divide Into Groups Of M Bits2. Substitute N-Bit Code For M-Bit GroupN > M3. Use A Line Encoding Scheme To Create A Signal

Block EncodingComes At A Cost - Requires Increase Bandwidth!75Table 4.1 4B/5B encoding (Continued)DataCodeQ (Quiet)00000I (Idle) 11111H (Halt) 00100J (start delimiter)11000K (start delimiter)10001T (end delimiter)01101S (Set)11001R (Reset)001118B/10B EncodingGroups of 8 Bits - Substituted Into A 10 Bit Code - More Efficient & Better Error Detection! Long Table!

79Encoding Methods Review Digital-To-DigitalDigital-To-AnalogAnalog-To-DigitalAnalog-To-AnalogBinary Data Must Be Encoded/Converted To A Form That Will Propagate Over A Wire80Analog To Digital EncodingAnalog To Digital Encoding Digitizing An Analog SignalReducing The Potentially Infinite Number Of Values In An Analog Signal So That They Can Be Represented In A Digital Stream With A Minimum Loss Of Information.

82Codec Coder-DecoderAnalog To Digital Converter Called A Codeccoder decoder codecConversion Requires Two Steps:Pulse Amplitude Modulation (PAM)Pulse Code Modulation (PCM)84Step 1: Pulse Amplitude Modulation (PAM)I. Pulse Amplitude Modulation (PAM)Sample Analog Signal At Regular Intervals Generate Pulses

Accuracy Depends Upon # Of Samples Selected85

Step 2: Pulse Code Modulation (PCM)- 1II. Pulse Code Modulation (PCM)3 Steps Step 1: Quantitize PAM Signals

86

Step 2: Pulse Code Modulation (PCM) - 2II. Pulse Code Modulation (PCM)3 Steps Step 2: Translate Each Value Into 7 Bit Binary Equivalent87Step 2: Pulse Code Modulation (PCM) - 3II. Pulse Code Modulation (PCM)3 Steps Step 3: Convert To Digital Using Appropriate Technique.

ReviewUnipolarBipolarPolar88Complete Analog-To-Digital Conversion Flow Diagram

90NYQUIST TheoremSampling RateRemember : Analog-To-Digital Accuracy Depends Upon # Of Samples SelectedHow Many?Nyquist Theorem : The Sampling Rate Must Be At Least Two Times The Highest Frequency!

91Nyquist In The Real WorldSampling Rate PracticeTelephone Voice Maximum Frequency = 4000 HzSampling Rate = __________ Samples/Second8,000A Bandwidth of 11,000 Is Needed To Transfer A Signal Whose Frequency Range Is 1,000 Hz to 12,000 Hz. Sampling Rate = __________ Samples/Second24,00092Bit RateBit Rate = Sampling Rate x Number Bits Per SampleBit Rate : Also Called The Data Rate93Bit Rate PracticeWant To Digitize Human Voice Using Eight Bit Samples.Sampling Rate = __________ Samples/SecondBit Rate = __________ KbpsHuman Voice Has Frequency Range of 0 to 4 KHz. Sampling Rate = 2 * Highest Frequency (4000 Hz)8,000Bit Rate = Sampling Rate (8,000) * NoBitsPerSample (8)Bit Rate = 64,000 bps6498Data Transmission Parallel AsynchronousSynchronous Serial 44 ManchesterEncoding(Polar)

45In Manchester Encoding, the Transition at the Middle of the Bit is used for both Synchronization and Bit Representation.50 Differential ManchesterEncoding(Polar)

51In Differential Manchester Encoding, the Transition at the Middle of the Bit is used only for synchronization.

The Bit Representation is defined by the Inversion or Non-Inversion at the beginning of the bit.54 Bipolar55In Bipolar Encoding, we use Three Levels: positive, zero, and negative.57 AMIEncoding(Bipolar)61 BZPSEncoding(Bipolar)

65 2B1QEncoding(Bipolar)

66

2B1Q Encoding 2 Binary 1 Quaternary Encoding2B1Q Encoding 2 Binary 1 Quaternary Encoding 4 Voltages

67 MLT-3Encoding(Bipolar)

69 BlockEncoding70Figure 4.15 Block coding

Need Some Kind Of Redundancy To Assure Synchronization!Need Some Of The Chapter 10 Error Detection To Assure Delivery!High Performance!72Figure 4.16 Substitution in block coding

73 4B5B8B10BEncoding74Table 4.1 4B/5B encoding -- Not All 5 Bit Codes Used!DataCodeDataCode0000111101000 1001000010100110011001100101010010101011000111010110111011101000101011001101001010101111011101101100111011101110001110111111111110176 8B6TEncoding77

8B/6T Block EncodingTake Advantage Of Speed & Error Detection Of Block EncodingRequires Much Less Bandwidth8 Binary Bits Substituted Into A 6 Bit Ternary Table8 Bits Translated Into 6 Bit of +1, 0, -1 [Table In Appendix D]28 8-Bit Sequences 36 Ternary 256 729 78 Analog To DigitalEncoding81 CodecPAMPCM83Pulse Amplitude Modulation has some applications, but it is not used by itself in data communication. However, it is the first step in another very popular conversion method called Pulse Code Modulation.89 NyquistAccording to the Nyquist Theorem, the Sampling Rate must be at least 2 times the Highest Frequency.94Example 4What sampling rate is needed for a signal with a bandwidth of 10,000 Hz (1000 to 11,000 Hz)? SolutionThe sampling rate must be twice the highest frequency in the signal: Sampling rate = 2 x (11,000) = 22,000 samples/s95Example 5A signal is sampled. Each sample requires at least 12 levels of precision (+0 to +5 and -0 to -5). How many bits should be sent for each sample?SolutionWe need 4 bits; 1 bit for the sign and 3 bits for the value. A 3-bit value can represent 23 = 8 levels (000 to 111), which is more than what we need. A 2-bit value is not enough since 22 = 4. A 4-bit value is too much because 24 = 16. 96Example 6We want to digitize the human voice. What is the bit rate, assuming 8 bits per sample?SolutionThe human voice normally contains frequencies from 0 to 4000 Hz. Sampling rate = 4000 x 2 = 8000 samples/s

Bit rate = sampling rate x number of bits per sample = 8000 x 8 = 64,000 bps = 64 Kbps97 TransmissionModes99Parallel TransmissionParallel Transmission Eight or More Lines Are Bundled Together To Send One Byte At A Time

100Serial TransmissionSerial Transmission Requires Only One Communication Channel

101Serial or Parallel TransmissionWhich Is Faster?

102Serial or Parallel TransmissionWhich Is Least Expensive?

Usually Limited To Short Distances103In Asynchronous Transmission, we send 1 start bit (0) at the beginning and 1 or more stop bits (1s) at the end of each byte. There may be a gap between each byte.104Serial TransmissionAsynchronous - 1Asynchronous Information Sent & Received In Agreed Upon Patterns; Timing Is Unimportant!

105Serial TransmissionAsynchronous - 2Asynchronous Serial TransmissionStart Bit [0] Is Sent To Alert Receiver8 Bits 1 Byte Of Data Transmitted1-2 Stop Bits [1s] Is/Are Sent To Let User Know FinishedA Brief Time Gap Often FollowsSome Type Of Synchronization Must Be Embedded Within DataCheap/Effective Choice For Low Speed Communication [Great For Terminal Computer!]106Asynchronous here means asynchronous at the byte level, but the bits are still synchronized; their durations are the same.107Serial TransmissionSynchronous - 1Synchronous Information Combined Into Frames [Multiple Bytes]; Timing Is Essential!

108Serial TransmissionSynchronous - 2Synchronous Serial TransmissionNo Gaps Unbroken String 1s & 0sGaps Generally Filled In With Agreed Upon Sequences Of 1s & 0s IdleTiming EssentialMuch Faster Than Asynchronous109In Synchronous Transmission, we send bits one after another without start/stop bits or gaps.

It is the responsibility of the receiver to group the bits.110Good Practice Problem

Sketch The Encoding Of Signal 11000011 With Each Of The Following On A New Page. Write NothingElse On This/These Pages Except Encoding Type & Your Name(s). Each Person On Team Must Do Their Own Copy Of This Problem!A. UnipolarB. NRZ-LC. NRZ-ID. RZE. ManchesterF. Differential ManchesterG. AMIH. PseudoternaryI. B8ZSJ. Quaternary 2B1QK. MLT-3L. 4B5BM. 8B6T111Data Communications & NetworkingCSCI 3342Dr. Thomas E. HicksComputer Science DepartmentTrinity University

Textbook: Computer NetworksBy Andrew TanenbaumTextbook: Data Communications & NetworkingBy Behrouz Forouzan

Special Thanks To WCB/McGraw-Hill For Providing Graphics For Many Text Book Figures For Use In This Presentation.