Chapter One: Introduction to Data Communication Outline Introduction Components of a Data Communication System Performance of Data Communication System Protocols and Architectures OSI Reference Model Introduction • Data communication is the exchange of data between two devices through some form of transmission media. • The data Communication system is composed of hardware (physical equipment) and software (programs) components. • The transfer of data in digital form began around 1832 with the advent of Morse code, a systematic code that represents the printable characters of a language using a form of binary data. Cont... • These characters are letters, numbers, or punctuation marks and are called alphanumeric as a class. • Combinations of dashes (long signals) and dots (short signals) were used to code each character. • A collection of these combinations is known as a character code. • The earliest forms of data communications Morse code were binary in nature. • Binary codes: Baudot code(5 bit code), ASCII code (7 bit code) and EBCDIC (8 bit code). Serial Transmission Most digital messages are vastly longer than just a few bits. Because it is neither practical nor economic to transfer all bits of a long message simultaneously, the message is broken into smaller parts and transmitted sequentially. Bit-serial transmission conveys a message one bit at a time through a channel. Each bit represents a part of the message. The individual bits are then reassembled at the destination to compose the message. In general, one channel will pass only one bit at a time. Thus, bit-serial transmission is necessary in data communications if only a single channel is available. Bit-serial transmission is normally just called serial transmission and is the chosen communications method in many computer peripherals. when communicating with a timesharing system over a modem, only a single channel is available, and bit-serial transmission is required. Parallel Transmission Byte-serial transmission conveys eight bits at a time through eight parallel channels. Although the raw transfer rate is eight times faster than in bit-serial transmission, eight channels are needed, and the cost may be as much as eight times higher to transmit the message. When distances are short, it may nonetheless be both feasible and economic to use parallel channels in return for high data rates. The popular Centronics printer interface is a case where byte-serial transmission is used. As another example, it is common practice to use a 16-bit-wide data bus to transfer data between a microprocessor and memory chips; this provides the equivalent of 16 parallel channels. Cont... • There is data communication over analog network and digital (data) network. • The easiest way for data communication was using the exiting analog telephone with Modems. • A modem is a device used to modulate digital signal to analog and to demodulate analog signal in to its digital. Cont... Figure: Data Communication System Components of Data Communications System A data communication system has five components: • Message: The message is the information (data) to be communicated. Popular forms of information include text, numbers, pictures, audio, and video. • Sender: The sender is the device that sends the data message. It can be a computer, workstation, telephone handset, video camera and so on. • Receiver: The receiver is the device that receives the message. It can be a computer, workstation, telephone handset, television and so on. Cont... • Transmission medium: is the physical path by which a message travels from sender to receiver. Some example: twisted-pair wire, coaxial cable, fiber-optic cable, and radio waves. • Protocol: is a set of rules that govern data communications. It represents an agreement between the communicating devices. Without a protocol, two devices may be connected but not communicating, just as a person speaking French cannot be understood by a person who speaks only Japanese. Figure: Components of Data Communication System Data Representation • Is a method to represent data and encode it in a computer system. • Generally, a user inputs numbers, text, images, audio and video types of data to process but the computer converts this data to machine language first and then processes it. Five different forms of information: Text Image Number Video Audio Data Flow Communication between two devices can be simplex, half-duplex or full-duplex. Simplex • In simplex mode, the communication is unidirectional, as on a one-way street. Only one of the two devices on a link can transmit; the other can only receive. E.g, Keyboards and Traditional monitors • Radio stations and TV broadcasts work as Simplex data communication. The point to be noted here is that there is no ability by the receiver to respond to the message in the simplex channel. Half-Duplex • In half-duplex mode, each station can both transmit and receive, but not at the same time. When one device is sending, the other can only receive, and vice versa. • The half-duplex mode is like a one-lane road with traffic allowed in both directions. • In a half-duplex transmission, the entire capacity of a channel is taken over by whichever of the two devices is transmitting at the time. E.g Walkie-talkies Full Duplex • In full-duplex mode, both stations can transmit and receive simultaneously. • The full-duplex mode is like a two way street with traffic flowing in both directions at the same time. • One common example of full-duplex communication is the telephone network. When two people are communicating by a telephone line, both can talk and listen at the same time. Performance of Data Communication System The effectiveness of a data communications system depends on four fundamental characteristics: delivery, accuracy, timeliness and jitter. Delivery: The system must deliver data to the correct destination. Data must be received by the intended device or user and only by that device or user. Accuracy: The system must deliver the data accurately. Data that have been altered in transmission and left uncorrected are unusable. Timeliness: The system must deliver data in a timely manner. Data delivered late are useless. In the case of video and audio, timely delivery means delivering data as they are produced, in the same order that they are produced, and without Significant delay. This kind of delivery is called real-time transmission. Jitter: Jitter refers to the variation in the packet arrival time. It is the uneven delay in the delivery of audio or video packets. For example, let us assume that video packets are sent every 30ms. If some of the packets arrive with 30ms delay and others with 40ms delay, an uneven quality in the video is the result. Channel Capacity The rate at which data can be transmitted over a given communication path, or channel, under given conditions, is referred to as the channel capacity. There are four concepts: • Data rate: is the rate, in bits per second (bps), at which data can be communicated. • Bandwidth: is the frequency of the transmitted signal as constrained by the transmitter and by the nature of the transmission medium, expressed in cycles per second, or hertz. • Noise: The average level of noise over the communications path. • Error rate: The rate at which errors occur, where an error is the reception of a 1 when a 0 was transmitted, or the reception of a 0 when a 1 was transmitted. In general, the maximum data rate a channel can support is directly proportional to the channel's bandwidth and inversely proportional to the channel's noise level. Bandwidth Vs Bit rate: let a pulse has freq. f and its positive pulse represent binary 1 and a negative pulse represent binary 0. Then, the waveform represents the binary stream 1010. . . . The duration of each pulse is 1/2f; thus, the data rate is 2f bits per second (bps). Channel Efficiency • The channel efficiency is the number of bits of useful information passed through the channel per second. (Calculated as a ratio of data or information bits to total bits) • It does not include framing, formatting and error detecting bits that may be added to the information bits before a message is transmitted and will always be less than one. • Channel efficiency is determined by the protocol design rather than by digital hardware considerations. • Note that there is a trade-off between channel efficiency and reliability protocols that provide greater immunity to noise by adding error-detecting and correcting codes must necessarily become less efficient. Protocols and Architectures Network protocols are sets of established rules that dictate how to format, transmit and receive data so computer network devices from servers and routers to endpoints can communicate regardless of the differences in their underlying infrastructures, designs or standards. Why Protocol Layering? When communication is simple, we may need only one simple protocol; when the communication is complex, we may need to divide the task between different layers, in which case we need a protocol at each layer, or protocol layering. 26 Communication Scenario one One layer: Face to Face communication Even it is simple scenario, we have a set of rules. First, Mr X and Mr Y should greet each other. Second, they should confine their vocabulary to the level of their friendship. Third, they know one should refrain from speaking when the other is speaking. Fourth, each party knows that the conversation should be a dialog, not a monolog. Fifth, they should exchange some nice words when they leave. 27 Advantages of Protocol layering Compatibility Enhanced life Expectancy Cost Effectiveness Task Classification Scalability Standardized and Certified Modularity 28 Implementation of Protocols Specification compliance: the implementation must adhere to the formal specifications of the protocol, which define how data should be formatted, transmitted and processed. Interoperability: It should be compatible with other systems or devices that utilize the same protocol, ensurign seamless communication and data exchange. Performance: Should be efficient to meet performance requirements, such as latency, throughput and resource usage, based on the application’s needs. Security: Include encryption, authentication and integrity checks to protect cont... Error handling: Must include mechanisms for detecting & managing errors to ensure reliable communication. Scalability: the design should accommodate varying potential for growth in the number of users or data volume without significant degradation in performance Maintainability: the code should be well documented & organized to facillitate updates, debugging and enhancements over time. Testing and validation OSI Reference Model OSI model is developed by the International Standards Organization (ISO). • ISO is a multinational body dedicated to worldwide agreement on international standards. Open Systems Interconnection (OSI) model is an ISO standard that covers all aspects of network communications. The OSI reference model was developed by ISO as a model for a computer protocol architecture and as a framework for developing protocol standards. 31 7-Layers of OSI Model 32 Layer 7: The Application layer Provides interface to the end-user. Collects information from the client & pursue further. Displays the incoming information coming from the other ends. Enables communication via lower layers to connect its system with the application running on the other end. It represents the services that directly support applications such as software for file transfers, database access, email and network games. e.g. Mozilla Firefox, Internet Explorer, Google Chrome... Layer 6-The Presentation layer This is a layer: • That converts incoming and outgoing data from one presentation format to another (for example, from a text stream into a popup window with the newly arrived text). • Manages security issues by providing services such as data encryption and compression. • It’s sometimes called the syntax layer. 34 Layer 5-The Session layer This layer: • Manages and synchronize the conversation between two different applications. • Establishes dialog control between the two computers in a session, regulating which side transmits, and when and how long it transmits. (i.e. require setup along with strong coordination) E.g. VPN Connection 35 Layer 4-The Transport layer This layer: • It decides the amount of data to be sent, the rate of data sending and the data route. • Manages end-to-end control (for example, determining whether all packets have arrived) and error-checking. • It ensures complete data transfer. E.g. TCP, UDP 36 Layer 3-The Network layer This layer helps: • Enables the actual communication means used for forwarding the data packets. i.e. Defines the path which the packets will follow or be routed to reach the destination. E.g. IP Address 37 Layer-2 The Data Link layer This layer: • Package raw bit from the Physical layer into frames (logical, structures packets for data). • It is responsible for transferring frames from one computer to another, without errors. • After sending a frame, it waits for an acknowledgment from the receiving computer. • Sublayers are: MAC (Media Access Control) & LLC (Logical Link Control) 38 Layer 1-The Physical layer This layer: • Transmits bits from one computer to another. • Regulates the transmission of a stream of bits over a physical medium. • Defines how the cable is attached to the network adapter and what transmission technique is used to send data over the cable. E.g. Wifi, cables, Voltages Regulation in routers & switches. 39 . 40 Layer 1, 2 and 3 i.e. physical, data link, and network are network support layers. Layer 4, Transport layer provides end to end reliable data transmission. Layer 5, 6 and 7 i.e. Session, Presentation, and Application layer are user support layers. 41 Advantages of OSI reference model OSI model distinguishes well between the services, interfaces and protocols. Protocols of OSI model are very well hidden. Protocols can be replaced by new protocols as technology changes. Supports connection-oriented services as well as connectionless service. Drawbacks of OSI reference model Less adaptable and Scalable (i.e. it has more layers and rules) Does not support many of the protocols and applications that are used on the internet.( E.g. HTTP, FTP, TCP, UDP, IP & Ethernet) Fitting of protocols is tedious task. It is just used as a reference model.