Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Basics of Data Communications Discrete-time Communication vs Continuous-time Communication Is human communication continuous-time or discrete-time ?

Similar presentations


Presentation on theme: "1 Basics of Data Communications Discrete-time Communication vs Continuous-time Communication Is human communication continuous-time or discrete-time ?"— Presentation transcript:

1 1 Basics of Data Communications Discrete-time Communication vs Continuous-time Communication Is human communication continuous-time or discrete-time ? Voice vs. words Any piece of information can be represented in discrete-time signals ! What is Data Communications ? The exchange of digital information between two devices using an electronic transmission system. Using Binary number system to represent digital information

2 2 Basics of Data Communications Question: How to send the word “Yes” from Bob to Alice? Solution-1: Bob writes the letters “Y”, “e”, “s” on a piece of paper. (a 26-symbol alphabet is utilised in this solution) Solution-2: Bob nodes his head down once, and shakes his head to say “No”. (a 2-symbol alphabet is utilised in this solution) Question: Is it a coincidence that “Yes” and “No” are very short words in most human languages? Question: How to send the word “Yes” from computer-1 to computer-2?

3 3 Character Codes Much of the data communication discipline deals with representing information in terms of 0’s and 1’s. (Not as easy as it sounds !) Fact: Computers are digital logic systems that operate on a 2-symbol alphabet : {0, 1}. – Binary Number System There are many ways to represent characters and these different representation s are known as Character Codes. Mostly formed by ‘Zero’ and ‘One’

4 4 Morse Code: A variable-lenght character code “Yes”: -.-- |. | … Examples: silence interval to separate characters Character Codes

5 5 Baudot Code: A fixed-length character code Character Codes Letter code: switch to letters Figure code: switch to figures

6 6 Extended Binary Coded Decimal Interchange Code (EBCDIC): A fixed-length, 8-bit, character code. 256 different combinations of 1’s and 0’s does not utilise all possible combinations only a subset is displayed here no parity Character Codes

7 7 American National Standard Code for Information Exchange (ASCII): A fixed-length, 7-bit, character code. 128 different combinations of 1’s and 0’s only a subset is displayed here can be used with a one-bit parity check 1+7=8 bits =1 byte there is also extended-ASCII that uses 8 bits instead of 7 bits.

8 8 1 byte = 8 bits bit-8 = parity check bit bit-1bit-7 bit-1 to 7 = data bit previous byte … Character Codes Parity check bit – Simplest way of checking error on transmitted bits Only can detect for a single error each time. Two-error may result in invalid parity check. ( Only detect the present of error but not the position )

9 9 Parity Check Odd-Parity = number of bit ‘1’ must be odd bit-1bit-7 1 1 1 1 0 1 bit-8 0 0 bit-7 0 1 0 1 0 1 bit-8 0 0 or bit-1 e.g.1 e.g.2

10 10 Parity Check Even-Parity = number of bit ‘1’ must be even bit-1bit-7 1 1 0 1 0 1 bit-8 0 0 bit-7 0 1 0 1 0 1 bit-8 1 0 or bit-1 e.g.1 e.g.2

11 11 Parity Check Example of one error occurring when using Odd-Parity check bit-1bit-7 0 1 0 1 0 1 bit-8 0 0 bit-7 0 1 0 1 0 1 bit-8 1 0 bit-1 sending receiving One error detected using Odd-Parity check – Action: re-send the byte

12 12 Parity Check Example of two errors occurring when using Even-Parity check bit-1bit-7 1 1 0 1 0 1 bit-8 0 0 bit-7 1 0 0 1 0 1 bit-8 1 0 bit-1 sending receiving or bit-7 1 1 0 1 1 1 bit-8 1 0 bit-1 receiving No error detected ?!! WRONG Data

13 13 Transmission of Digital Data Interfaces and Modems Digital Data Transmission DTE-DCE Interface Other Interface Standards Modems WCB/McGraw-Hill  The McGraw-Hill Companies, Inc., 1998

14 14 WCB/McGraw-Hill

15 15 Parallel Transmission WCB/McGraw-Hill

16 16 Serial Transmission WCB/McGraw-Hill

17 17 Parallel vs. Serial Transmission 1 0 0 0 0 0 1 Parallel Transmission 1000001 Serial Transmission Faster Expensive Suitable for short distances Slower Cheaper Better for long distance

18 18 Synchronous vs. Asynchronous Transmission Synchronous Transmission However the block must be preceded by SYNC bytes or a separate clock line must be provided !

19 19 Synchronous vs. Asynchronous Transmission Asynchronous Transmission

20 20 Synchronous vs. Asynchronous Transmission Total bits sent = data-bits + control_bits Transmission or Throughput

21 21 If a Synchronous transmission involves sending 480 characters plus an overhead of 20 control characters for synchronisation, what is the efficiency of the transmission? If 480 characters are sent using Asynchronous transmission, what is the transmission efficiency? Example Synchronous transmission: Efficiency = 480/(480+20) = 96% Asynchronous transmission: Efficiency = 80% (if 8 bits is used for data bits)

22 22 Transmission Modes: Simplex, Half-Duplex, Full-Duplex Simplex Transmission

23 23 Transmission Modes: Simplex, Half-Duplex, Full-Duplex Half-Duplex Transmission

24 24 Transmission Modes: Simplex, Half-Duplex, Full-Duplex Full-Duplex Transmission

25 25 Tutorial What is a major difference between Morse code and ASCII code? How many characters can Baudot code represent? How many characters can ASCII code represent? What is a parity bit? Which bit is usually used for parity check? What is parallel transmission? When do we use parallel transmission? What is serial transmission? When do we use serial transmission?

26 26 What is asynchronous transmission? What is synchronous transmission? Why asynchronous transmission always has 80% efficiency? If a synchronous transmission involves sending 1000 characters and an overhead of 10 characters are needed for handshake, what is the efficiency of the transmission? What is simplex communication? Give examples. What is half duplex communication? Give examples. What is full duplex communication? Give examples.

27 27 Outline Standards Organisations Interface Standards  The RS-232-C Standard  RS-449, RS-422-A, RS-423-A  USB and FireWire

28 28 Standards Organisations ISO: International Organisation for Standards. It is comprised by national standards organisations from all countries. ANSI: American National Standards Institute. It works under ISO. Standardisation is required to achieve compatibility among different communications hardware and software produced by different companies. IEEE: Institute of Electrical Electronic Engineers (e.g., IEEE 802)

29 29 Standards Organisations ITU: International Telecommunications Union. Before 1992 ITU had a sub-group, CCITT (Comité Consultatif International Téléphonique et Télégraphique), to act as a standardisation group. CCITT does not exist anymore. ITU has assumed the task. IETF: Internet Engineering Task Force. Main standardisation organisation for Internet. EIA: Electronics Industries Association.

30 30 RS-232-C Interface Original name was RS-232-C. It was changed to EIA232 in 1991. Mostly referred to as RS-232 anyway. The standard defines a serial, digital interface between two devices. The RS-232 standard defines a bi-directional interface between exactly two communicators.

31 31 RS-232-C Interface Logic ‘0’ : +3 to +15 volts Logic ‘1’ : – 3 to – 15 volts Sending ‘01000001’

32 32 RS-232-C Interface DB-25 Connectors (25 pins) DB-9 and DB-37 Connectors (9 pins and 37 pins)

33 33 RS-232-C Interface

34 34 RS-232-C Interface Pin 1 Received Line Signal Detector (Data Carrier Detect) Pin 2Received Data Pin 3Transmit Data Pin 4Data Terminal Ready Pin 5Signal Ground Pin 6Data Set Ready Pin 7Request To Send Pin 8Clear To Send Pin 9Ring Indicator

35 35 9 Pin Connector on a DTE device (PC connection) Male RS232 DB9 Pin NumberDirection of signal: 1Carrier Detect (CD) (from DCE) Incoming signal from a modem 2Received Data (RD) Incoming Data from a DCE 3Transmitted Data (TD) Outgoing Data to a DCE 4Data Terminal Ready (DTR) Outgoing handshaking signal 5Signal Ground Common reference voltage 6Data Set Ready (DSR) Incoming handshaking signal 7Request To Send (RTS) Outgoing flow control signal 8Clear To Send (CTS) Incoming flow control signal 9Ring Indicator (RI) (from DCE) Incoming signal from a modem RS-232-C Interface

36 36 RS-232-C Interface Pin 1Protective Ground Pin 2Transmit Data Pin 3Received Data Pin 4Request To Send Pin 5Clear To Send Pin 6Data Set Ready Pin 7Signal Ground Pin 8 Received Line Signal Detector (Data Carrier Detect) Pin 20Data Terminal Ready Pin 22Ring Indicator

37 37 25 Pin Connector on a DTE device (PC connection) Male RS232 DB25 Pin NumberDirection of signal: 1Protective Ground 2Transmitted Data (TD) Outgoing Data (from a DTE to a DCE) 3Received Data (RD) Incoming Data (from a DCE to a DTE) 4Request To Send (RTS) Outgoing flow control signal controlled by DTE 5Clear To Send (CTS) Incoming flow control signal controlled by DCE 6Data Set Ready (DSR) Incoming handshaking signal controlled by DCE 7Signal Ground Common reference voltage 8Carrier Detect (CD) Incoming signal from a modem 20Data Terminal Ready (DTR) Outgoing handshaking signal controlled by DTE 22Ring Indicator (RI) Incoming signal from a modem RS-232-C Interface

38 38 RS-232-C Interface 9-Pin Connector25 Pin Connector Pin 1 DCDPin 8 DCD Pin 2 RDPin 3 RD Pin 3 TDPin 2 TD Pin 4 DTRPin 20 DTR Pin 5 GNDPin 7 GND Pin 6 DSR Pin 7 RTSPin 4 RTS Pin 8 CTSPin 5 CTS Pin 9 RIPin 22 RI

39 39

40 40

41 41

42 42 RS-232 Handshaking 1. The Data Terminal Ready (DTR) pin (Pin 20) gets a voltage when PC is turned on. 2. The Data Set Ready (DSR) pin (Pin 6) gets a voltage when modem is turned on. 3. The PC supplies a voltage to Pin 4 resulting in a Request To Send (RTS). 4. The modem responds by applying voltage to Pin 5 - Clear To Send (CTS). Next it sends out a carrier tone to the other modem. 5. The receiving modem hears the carrier tone and supplies a voltage to Pin 8 (Carrier Detect). 6. The PC sends data via Pin 2 (Transmit Data) to the modem that converts it to sound and sends it to the receiving modem. 7. The receiving modem converts the sounds into digital data which is sent via Pin 3 (Receive Data) to the receiving PC.

43 43

44 44 RS-232-C Interface Advantages: Cheap, well-understood. It has been around for 40+ years. Almost all machines have it. Limitations: Voltage is measured between TD and Signal ground, and RD and signal ground. Over long cables the voltage at both ends of the signal ground is not constant. Thus, bit errors are frequent over long cables. RS-232-C limits the length of the cable to 50 feet (although this limit is often exceeded in practice). RS-232-C limits the transmission rate to 20 kbps. There are more than one type of connectors; DB-9, 25, and 37

45 45 RS-449, RS-423-A, RS-422-A They are all improvements to RS-232-C. (page:67-68, Beyda) RS-449 is the “parent standard” that specifies the functional and mechanical characteristics of the interconnection between DTE and complying EIA signaling standards RS-422 and RS-423. Two pins – Category I signals; (RS-422A) : Balanced Transmission Single pin – Category II signals (RS-423A) : Unbalanced Transmission While RS-232 uses signals with reference to ground, RS449 receivers look for the difference between two wires – less prone to noise problem. RS-422 supports multipoint connections whereas RS-423 supports only point-to-point connections.

46 46 RS-449, RS-423-A, RS-422-A

47 47 RS-423-A DTE DCE TD RD Send ground Receive ground Unlike RS-232 (bi-directional interface), the RS-423 standard defines a uni- directional interface between one transmitter and many receivers: The data direction is always in one direction - Single-ended specification. E.g. a single computer may need to update a number of terminals that are displaying. Unbalanced (Single-Ended) interface; specifies a single, unidirectional driver with multiple receivers (up to 10). RS-423 allows for distances up to 4000 feet but limits data rates to only 100 kb/sec for a maximum of ten receivers.

48 48 RS-422-A DTE DCE TD1 RD1 TD2 RD2 Two lines are used to transmit, and two lines are used to receive. The voltage difference between TD1 (RD1) and TD2 (RD2) is the transmitted signal (received signal). This is known as differential balanced transmission. 100 kbps at 4000 feet. Up to 10 Mbps at 40 feet.

49 49 What do they mean by Balanced line? How does it work? Balanced line operation is a transmission method which helps to eliminate the effects of noise on the cable. In the first diagram a coaxial cable is transmitting a 4V signal, this is unbalanced as all of the 4V signal is carried by the centre core of the coax with respect to the grounded screen. If 1V of noise is introduced, it adds to the signal being transmitted making 5V, this could interfere with our data. Unbalanced line

50 50 Balanced line With a balanced line transmission our 4V signal is split into +2V and -2V on one twisted pair, so we still have 4V between the two. Now when we introduce the 1V of noise, the +2V becomes +3V, and the - 2V becomes -1V, but the potential difference between the two is still 4V. The devices we put on the ends of the cable to make the line balanced are called baluns, this name is derived from the function of the devices of converting between balanced and unbalanced transmission modes Balanced and Unbalanced line

51 51 Balanced and Unbalanced line When the two identical but opposite polarity signals carried on the balanced line are input to a differential amplifier in the component receiving the signal, noise picked up by the interconnect is rejected. (Note that a differential amplifier amplifies only the difference between the two signals). If noise is introduced into the line, the noise will be common to both conductors and the differential amplifier will reject the noise. This phenomenon of rejecting noise signals common to both conductors in a balanced line is called common- mode rejection.

52 52 The RS232 standard had some problems: The data transmission rate was limited to 20 kbps. The distance for transmission is limited to 50 ft. The standard does not specify a connector, which led to some 25-pin designs not compatible with each other. Only one conductor per circuit is used, with only one signal return for both directions of transmission. The interface uses unbalanced transmitters and receivers (unbalanced circuit is less desirable (relative to performance) than a balanced circuit). The interface can generate considerable crosstalk among its component signals. The overall interface design is for discrete component technology. The RS449 standards had to achieve the following goals: Maintain compatibility with the old RS-232-C. Support a higher signaling rate bandwidth over longer distances than the RS-232-C. Resolve the mechanical interface problems that were caused from the lack of connector specifications in the old standard (9, 25, 37 pins). – standard 37 pins throughout. Improve the electrical characteristics of the interface by providing for balanced circuits.

53 53 USB (Universal Serial Bus) Interface Inside a USB cable: There are two wires for power -- +5 volts (red) and ground (brown) -- and a twisted pair (yellow and blue) of wires to carry the data. The cable is also shielded. Ideal interface to all peripheral devices. USB 1.1 offers up to 12 Mbps transmission rate. USB 2.0 provides up to 480 Mbps. More Information: http://www.beyondlogic.org/usbnutshell/usb1.htm

54 54 USB (Universal Serial Bus) Interface It is expected to replace parallel and serial ports. Power lines are to provide power for peripheral devices. One USB Bus can support up to 127 devices. Supports plug-n-play, and hot-plugging. The computer can guarantee bandwidth by reserving time slots in a 1500-byte frame every millisecond. 10 % bandwidth is reserved for control signaling. Supports real-time devices such as video cameras Cable length is up to 5 meters. Allows device-to-host connection only.

55 55 IEEE 1394 (FireWire) Interface Functionally similar to USB. IEEE 1394.a offers 400 Mbps, IEEE 1394.b offers 800 Mbps. One IEEE 1394 port can support up to 63 devices. FireWire is the brand name chosen by Apple for its implementation of IEEE 1394. Other brands are i.link by Sony, etc. Length up to 5 metres. Also allows device-to-device connection. More Information - http://firewirestuff.com/whatis.html or http://developer.apple.com/devicedrivers/firewire/index.html

56 56 IEEE 1394 (FireWire) Interface

57 57 1- What is handshaking? What are the basic common pins required for serial communication in RS-232? 5- What are the limitations of RS-232-C standard? 3- Draw and describe the connection from DTE to DCE 2- How is handshaking being carried out for the RS-232-C standard? 4- Draw and describe the connection from DTE to DTE 6- What is the major difference between RS-232-C and RS-449 standard? 7- What is the major difference between IEEE 1394 and USB interfaces? Tutorial


Download ppt "1 Basics of Data Communications Discrete-time Communication vs Continuous-time Communication Is human communication continuous-time or discrete-time ?"

Similar presentations


Ads by Google