Data Transmission Data Communications and Networks Mr Greg

  • Slides: 34
Download presentation
Data Transmission Data Communications and Networks Mr. Greg Vogl Uganda Martyrs University Lecture 4,

Data Transmission Data Communications and Networks Mr. Greg Vogl Uganda Martyrs University Lecture 4, 28 March 2003 Data Communications and Networking: Data Transmission

Overview • • Signals, noise and errors Modulation and modems Synchronisation Baseband broadband 28

Overview • • Signals, noise and errors Modulation and modems Synchronisation Baseband broadband 28 March 2003 Data Communications and Networking: Data Transmission 2

Sources • Hodson Ch. 1, 2, 3, 8. 2 • Stamper pp. 67 -75,

Sources • Hodson Ch. 1, 2, 3, 8. 2 • Stamper pp. 67 -75, Ch. 3 • BITDCO lectures 3 -7 – Recommended, easily accessible at UMU – Go to DCN website, click Links – HTML and GIF files all fit on one floppy disk 28 March 2003 Data Communications and Networking: Data Transmission 3

Digitising • Analog digital conversion uses sampling • Amplitude of each sample converted to

Digitising • Analog digital conversion uses sampling • Amplitude of each sample converted to bits • Accuracy of digitised info. depends on – Number of bits in sample – How often the samples are taken (period) – Linear or nonlinear digitising of amplitude – Compression/decompression algorithms • Used for voice, music, photos, video, etc. 28 March 2003 Data Communications and Networking: Data Transmission 4

Signals • Sinusoidal wave is simplest type of wave • Complex wave is mixture

Signals • Sinusoidal wave is simplest type of wave • Complex wave is mixture of sinusoidals • Square wave with bit rate B can be converted to infinite Fourier series – with frequencies (2 n+1)B/2, decreasing amp. • Bandwidth = highest freq. – lowest freq. • Phone system 3400 Hz – 300 Hz = 3. 1 KHz 28 March 2003 Data Communications and Networking: Data Transmission 5

Fundamental Limits • Attenuation – amplitude decreases over distance – due to resistance, dispersion,

Fundamental Limits • Attenuation – amplitude decreases over distance – due to resistance, dispersion, other energy loss – amplifier or repeater restores initial amplitude • Bit rate limited by – Shannon’s law B = H log 2 (1 + S/N) – Bandwidth in Hertz H – Noise or Signal-Noise Ratio S/N 28 March 2003 Data Communications and Networking: Data Transmission 6

Sources of Noise • Impulse noise: spikes/surges, e. g. lightning – Reduced with power

Sources of Noise • Impulse noise: spikes/surges, e. g. lightning – Reduced with power supply/line conditioning • Crosstalk: interference between channels – Reduced with shielding, insulation, separation • Echo: signals reflect at connections/ends – Reduced with terminators, repeaters • White noise: electron thermal energy – Reduced by tuning radio antenna 28 March 2003 Data Communications and Networking: Data Transmission 7

Error Detection and Correction • Sender – compute a check value based on the

Error Detection and Correction • Sender – compute a check value based on the data – append check value to data and sends • Receiver – perform a calculation based on data – compare answer with check value – if they disagree, ask to resend (NAK) • No error detection scheme finds 100% of errors • Usually easier to detect and resend than correct 28 March 2003 Data Communications and Networking: Data Transmission 8

Redundancy Checks • Parity Check or Vertical Redundancy Check – Parity bit makes number

Redundancy Checks • Parity Check or Vertical Redundancy Check – Parity bit makes number of 1 bits even/odd – Does not detect even number of bit errors • Longitudinal Redundancy Check – Used to check a whole block of characters – Check character added to end of block – nth bit checks parity of nth bits of other char’s 28 March 2003 Data Communications and Networking: Data Transmission 9

Cyclic Redundancy Check • • Interpret bits as coefficients of a polynomial Divide by

Cyclic Redundancy Check • • Interpret bits as coefficients of a polynomial Divide by generator polynomial to get remainder Subtract remainder from original bits and transmit Receiver divides received bits by generator – If remainder is 0, no error occurred • Versions (no. of bits R): CRC-12, 16, CCITT, 32 • Detects almost all errors in block transmissions – 1 and 2 bit, odd number of bits, burst errors of <R bits 28 March 2003 Data Communications and Networking: Data Transmission 10

Other Error Detection Schemes • • Check sums/digits (sum of fields) Hash totals (sum

Other Error Detection Schemes • • Check sums/digits (sum of fields) Hash totals (sum group of items) Byte count (message length) Character echoing to user (asynch. e. g. terminal) 28 March 2003 Data Communications and Networking: Data Transmission 11

Error Correction • Usually retransmission of message • Acknowledgment – ACK, NAK, numbered •

Error Correction • Usually retransmission of message • Acknowledgment – ACK, NAK, numbered • Timeout, retry limit • Forward Error Correction – Receiver has enough info to reconstruct original – cost of retransmission > cost of reconstruction – E. g. hamming codes (not used in data comm. ) 28 March 2003 Data Communications and Networking: Data Transmission 12

Sequence Checks • Message sequencing – Messages numbered so none go missing – Messages

Sequence Checks • Message sequencing – Messages numbered so none go missing – Messages not received can then be re-sent • Packet sequencing (packet-switched networks) – Sender divides message into numbered packets – Receiver reassembles using packet numbers • Unnecessary in circuit-switched networks – e. g. phone system uses circuit switching – Connection/session is unbroken stream 28 March 2003 Data Communications and Networking: Data Transmission 13

Connection vs. Connectionless • • • Low data rates High error rates Error correction

Connection vs. Connectionless • • • Low data rates High error rates Error correction Higher OSI levels Wide Area Networks 28 March 2003 • • • High data rates Low error rates Just transmit data Lower OSI levels only Local Area Networks Data Communications and Networking: Data Transmission 14

Modulation (Shift Keying) • digital analog • ac = Ac sin (2 fct +

Modulation (Shift Keying) • digital analog • ac = Ac sin (2 fct + ) • vary one or more: – AM/ASK: A=amplitude – FM/FSK: f=frequency – PM/PSK: =phase • Dibits: 0, 90, 180, -90 • Tribits: 0, 45, 90, etc. 28 March 2003 Data Communications and Networking: Data Transmission 15

Constellation Diagram 90º • Quadrature (QAM) • Modulation of: – Amplitude (radius) – Phase

Constellation Diagram 90º • Quadrature (QAM) • Modulation of: – Amplitude (radius) – Phase (angle) 180º 0º • V. 32, 32 points • 2400 baud, 9600 bps -90º 28 March 2003 Data Communications and Networking: Data Transmission 16

RS 232 C/V. 24 Modem Interface 28 March 2003 Data Communications and Networking: Data

RS 232 C/V. 24 Modem Interface 28 March 2003 Data Communications and Networking: Data Transmission 17

RS 232 C/V. 24 Modem Interface • Tx. D, Rx. D - Transmit and

RS 232 C/V. 24 Modem Interface • Tx. D, Rx. D - Transmit and receive data pins • RTS - Request To Send, from DTE (computer) • CTS - Clear To Send, from DCE (modem) now used for flow control/hardware handshaking • DTR - Data Terminal Ready - computer enabled • DSR - Data Set Ready - modem is turned on • CD - Carrier Detect - this modem is receiving a signal from remote modem 28 March 2003 Data Communications and Networking: Data Transmission 18

Modem Features and Types • • Speed (56 Kbps is most common) Auto/manual dial/redial/answer/disconnect

Modem Features and Types • • Speed (56 Kbps is most common) Auto/manual dial/redial/answer/disconnect Fax, digitised voice (for Internet phone calls) Speaker, indicator lights (external), self-testing MNP 1 -4 error correction, 5 compression Standards (ITU V. 90, EIA, USR, Hayes AT cmds) Mobile (PCMCIA, cellular, RF) HDSL, Cable, ISDN, DSL, Fibre optic 28 March 2003 Data Communications and Networking: Data Transmission 19

The Synchronisation Problem • How to synchronise Sender and Receiver? • Asynchronous – Bit

The Synchronisation Problem • How to synchronise Sender and Receiver? • Asynchronous – Bit (clock) level – Byte (character) level – Frame level • Synchronous - Character and Bit Oriented – Bit level • Clock encoding and extraction • Data encoding and clock synchronisation – Byte level – Frame (block) level Data Communications and 28 March 2003 Networking: Data Transmission 20

Asynchronous Bit Synch. 28 March 2003 Data Communications and Networking: Data Transmission 21

Asynchronous Bit Synch. 28 March 2003 Data Communications and Networking: Data Transmission 21

Asynchronous Bit Synch. • • Resynchronise for each byte (character) Isolated characters received at

Asynchronous Bit Synch. • • Resynchronise for each byte (character) Isolated characters received at random times Transition between voltage levels is a bit 1 start bit, 8 bits for ASCII char. , 1 stop bit Efficiency only 80% (2 bits of overhead) Used in low bit rate, low volume links Used by RS 232 ports on PCs 28 March 2003 Data Communications and Networking: Data Transmission 22

ASCII vs. EBCDIC Codes Character 0 1 2 3 4 5 6 7 8

ASCII vs. EBCDIC Codes Character 0 1 2 3 4 5 6 7 8 9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 28 March 2003 ASCII Representation 00110000 00110001 00110010 00110100 00110101 00110110 00110111 00111000 00111001 01000010 01000011 01000101 01000110 01000111 01001000 01001001010 01001011 01001100 01001101 01001110 01001111 01010000 01010001 01010010 01010011 01010100 01010110 01010111 01011000 01011001 01011010 Data Communications and Networking: Data Transmission EBCDIC Representation 11110000 11110001 11110010 11110011 11110100 11110101 11110110 11110111 11111000 11111001 11000010 11000011 11000100 11000101 11000110 11000111 11001000 11001001 11010011 11010100 11010101 11010110 11010111 11011000 11011001 11100010 11100011 11100100 11100101 11100110 11100111 11101000 11101001 23

Synchronous Bit Synch. • A frame (block of bits) is sent • Preamble uses

Synchronous Bit Synch. • A frame (block of bits) is sent • Preamble uses unique bit sequence 28 March 2003 Data Communications and Networking: Data Transmission 24

HDLC Synchronisation • High-level Data Link Control Protocol • Use 01111110 as start/stop flags

HDLC Synchronisation • High-level Data Link Control Protocol • Use 01111110 as start/stop flags • If 1111111 appears anywhere in data, – Sender inserts a 0 after fifth 1 (“bit stuffing”) – Receiver removes the 0 28 March 2003 Data Communications and Networking: Data Transmission 25

Baseband • • Data and clocking signal combined Single channel (takes whole bandwidth) Usually

Baseband • • Data and clocking signal combined Single channel (takes whole bandwidth) Usually bi-directional (two way) Uses an encoding scheme such as: – – – Manchester Diff. Manchester Phase modulation 4/5 bit 5/6 bit 28 March 2003 Data Communications and Networking: Data Transmission 26

Manchester Encoding • • • Transmitted signal is Data XOR Clock Transition in middle

Manchester Encoding • • • Transmitted signal is Data XOR Clock Transition in middle of each cell Lo hi = 1, hi lo = 0 Often used in Ethernet Preamble for synchronising and start of data If polarity reversal, data misrepresented 28 March 2003 Data Communications and Networking: Data Transmission 27

28 March 2003 Data Communications and Networking: Data Transmission 28

28 March 2003 Data Communications and Networking: Data Transmission 28

Differential Manchester Encoding • Transitions still occur at centre of each bit – 1=no

Differential Manchester Encoding • Transitions still occur at centre of each bit – 1=no transition at data start boundary – 0=transition at data start boundary • Typically used in token ring systems • No need for long preamble • J and K signals have no midpoint transition – used to signal start and end of data 28 March 2003 Data Communications and Networking: Data Transmission 29

Phase Modulation Encoding • Twisted pair provides two channels • Phase difference used to

Phase Modulation Encoding • Twisted pair provides two channels • Phase difference used to signal data values – 0 if a transition in one channel – 1 if a transition in both channels 28 March 2003 Data Communications and Networking: Data Transmission 30

4 bit/5 bit Encoding • Represent each 4 bits as 5 bits • Ensure

4 bit/5 bit Encoding • Represent each 4 bits as 5 bits • Ensure each 5 bit pattern has signal change – Not use all the same bit (00000 or 11111) • Use fixed translation/mapping table • Avoids problem of many repeated 1’s or 0’s • 100 Mbit/s data rate requires 125 Mbit/s signal rate • Used in high-speed fibre optic LANs 28 March 2003 Data Communications and Networking: Data Transmission 31

5 bit/6 bit Encoding • High speed LANs on UTP cable • Copper wire

5 bit/6 bit Encoding • High speed LANs on UTP cable • Copper wire must use low frequencies – US/int’l interference and emission regulations • Two steps used – Quintet scrambler – 5 B/6 B two-level non-return-to-zero encoder • result is 3 1’s and 3 0’s; allows error check 28 March 2003 Data Communications and Networking: Data Transmission 32

Broadband • • Modulated using modem (digital analog) Phase coherent so unidirectional Multiple channels

Broadband • • Modulated using modem (digital analog) Phase coherent so unidirectional Multiple channels divide bandwidth: FDM Channels often 6 MHz wide, 10 Mbit/s The cable uses low freq. 0 -50 Hz for power Used for cable TV or data (cable modems) Carrierband: one channel=whole bandwidth 28 March 2003 Data Communications and Networking: Data Transmission 33

Single vs. Dual Cable Broadband • Single cable – traffic to/from head end (amp/freq

Single vs. Dual Cable Broadband • Single cable – traffic to/from head end (amp/freq translator) – high=outbound 216 -300 MHz – low=inbound 5 -110 MHz • Dual cable – Each cable has 5 -300 MHz bandwidth – Simpler headend (no amp/freq translation) – Higher cost for cabling 28 March 2003 Data Communications and Networking: Data Transmission 34