Anda di halaman 1dari 29

Embedded Networks Communication Reference Models The OSI Model

Abraham Tezmol P ES FSD GDL

Embedded Networks

Reference Models

Abraham Tezmol, M.S.E.E

Reference Models
A good simple example

OSI

Let's begin with a hypothetical example of a communication problem. We will solve the problem, and at the same time develop our reference model. Here's the problem: Tom and Paula want to communicate, but there are five barriers to communication: They are physically separated They are illiterate

They speak different languages


They are paranoid The path between them creates a harsh delivery environment; i.e., there is a high probability that a message could be damaged enroute

Goal Design a network that solves all these problems so that Tom and Paula, can communicate. This is a big job, and we need to find an organized, methodical, and manageable way to do it. We will begin by building a model starting with their goal.

The model for their goal consists of of icons representing the two of them exchanging ideas. We will refer to this diagram as the application. In the following sections we will address the barriers listed above - one at a time.

Abraham Tezmol, M.S. E.E.

Reference Models
Physical Separation

OSI

Each barrier is overcome by building a layered support structure under the application - one layer per barrier. The first barrier, physical separation, overcome by adding a layer as shown below (Note: From this point on new layers will identified in the diagram by shading)

The purpose of this layer is to provide for the physical delivery of any messages that the application requires. If Tom has a message to send, he writes it down and hands it to Larry. Larry delivers the message to Moe who in turn hands it to Paula who reads it. In summary: Larry is providing a delivery service to Tom. Moe is providing a delivery service to Paula. Larry and Moe are collaborating to provide physical delivery of the message

Abraham Tezmol, M.S. E.E.

Reference Models
Illiteracy

OSI

Now let's impose an additional barrier - Tom and Paula are both illiterate. Consequently Tom is incapable of writing a message, and Paula is incapable of reading one. This barrier is overcome by inserting a layer between the application and the delivery layer as shown below.

Let's assume initially that both Tom and Paula are French speaking. Sylvia will listen as Tom dictates his massage, and then she will write it down on the message form. She will then pass the form down to Larry who will do the same thing he did before - pass the message form to Moe. Moe will also do the same thing he did before pass the message up, but this time to Carol. Carol will then read the message to Paula, and the transaction is complete. In summary: Sylvia is providing a transcription service to Tom Carol is providing a narration service to Paula Sylvia and Carol are collaborating to make sure the message is formatted on the form so that each will understand the content of the form when it arrives. Larry and Moe are doing the same things they did before
Abraham Tezmol, M.S. E.E.

Reference Models
Different Languages

OSI

Now let's turn Paula into a Spanish speaker and leave Tom as a Franch speaker. We will deal with this barrier as before - add a layer to the model.

We add a layer between the existing layers without changing the functionality of the two existing layers. Sylvia hands the message form to Ellen. Ellen translates the message into English, and hands the message form to Larry. On the other side of the added layer Valarie receives the message form from Moe, and translated the message into Spanish. She then hands the message form to Carol who reads the Spanish translation to Paula. In summary, the new layer provides the following functionality:
Ellen is providing a translation service to Sylvia Valarie is providing a translation service to Carol

Ellen and Valarie are collaborating to provide for the delivery of an agreed upon common language (English) for the message that will be delivered across the "network."
Everyone else does the same things they did before
Abraham Tezmol, M.S. E.E.

Reference Models
Paranoia

OSI

Unfortunately Paula has become very distrustful of the alleged source of the message; i.e., she doesn't believe that the massage came from Tom. We need to find a way to authenticate the message so that Paula can relax. The solution consists of adding a layer to the model as illustrated below.

Joe receives the message from Pierre and adds an agreed upon password to the message form. He then hands the message form to Larry. Jim receives the message form from Moe, and then he checks the password. If the password is correct, he passes the message form to Juan. If the password is incorrect, he discards the message form.

Abraham Tezmol, M.S. E.E.

Reference Models
Paranoia In summary, the new layer provides the following functionality: Joe is providing a password annotation service to Ellen Jim is providing a password verification service to Valarie Joe and Jim are collaborating to provide for the authentication of the message. Everyone else does the same things they did before.

OSI

Abraham Tezmol, M.S. E.E.

Reference Models
Harsh Delivery Environment

OSI

The final barrier in our example will be the existence of a harsh delivery environment in which Larry and Moe operate. Lets assume that Larry has to swim through a moat with the message clinched in his teeth. The water in the moat is polluted with harsh chemicals that attack the message form and the ink used to write the message;. The result is that there is a finite probability that the message will damaged during the physical delivery process, and we need a method to detect (not to correct) errors in the message induced by damage to the message form during the delivery process. We will deal with this barrier by (guess what?) adding a layer to our model as illustrated below.

Abraham Tezmol, M.S. E.E.

Reference Models
Harsh Delivery Environment

OSI

Doug receives the message form from Joe, and he counts the number of words in the message. He then writes that number in a field on the message form entitled "Word Count" and passes the message to Larry. At the other end of this layer Vivek receives the message form from Moe, and he counts the number of words in the message. He then compares his word count with the number written in the Word Count field on the message form. If the numbers agree, he passes the message form to Jim. If not he discards the message

Abraham Tezmol, M.S. E.E.

10

Reference Models

OSI

Summary Now we are finished with our hypothetical "Value Added Network" design, and in so doing transformed an exceedingly complex system design into a sequence of five well defined, manageable steps. This example introduced you to the essence of a layered communication protocol. Now we will begin to transition from the hypothetical example we just covered to the real world of real protocols. Stack components A layered protocol, sometimes called a stack, consists of abstractions called layers. Each layer is made up of three components as illustrated below:

Abraham Tezmol, M.S. E.E.

11

Reference Models
Entities

OSI

At each end of a layer there resides an "entity" that performs the functions of the layer. In the example above the entities were: Sylvia & Carol Ellen & Valarie

Joe & Jim


Doug & Vivek Larry & Moe Peer Protocols The entities at either end of a layer execute a protocol with each other, referred to as a peer protocol. The peer protocols executed in the example above were: Formatting Common Language Authentication Error detection Transport

Abraham Tezmol, M.S. E.E.

12

Reference Models
Services

OSI

Each entity in each layer provides a service to the entity in the layer above. The services provided in the example above were: Transcription Translation

Password annotation
Checksum annotation Delivery Checksum verification Password verification Translation Narration

Abraham Tezmol, M.S. E.E.

13

Embedded Networks

The OSI Model

Abraham Tezmol, M.S.E.E

14

The OSI Model Introduction

OSI

In the early years of networking, sending and receiving data across a network was confusing, because large companies such as IBM, Honeywell, and Digital Equipment Corporation had individual standards for connecting computers. It was unlikely that applications operating on different equipment from different vendors could communicate. Vendors, users, and standards bodies needed to agree upon and implement a standard architecture that would allow computer systems to exchange information even though they were using software and equipment from different vendors.
In 1978, the International Standards Organization (ISO) introduced a networking model, called the Open Systems Interconnection (OSI) model, as a first step toward standardizing data communications standards to promote multi-vendor network interoperability. The OSI model consists of layers, each with a specific set of network functions. The model specifies the set of protocols and interfaces to implement at each layer and provides guidelines for implementation of the interfaces between layers.

Abraham Tezmol, M.S. E.E.

15

The OSI Model Layers

OSI

Each layer of the OSI model exists as an independent module. In theory, you can substitute one protocol for another at any given layer without affecting the operation of layers above or below.
The design of the OSI model is based on the following principles: A layer should be created only when an additional level of abstraction is required. Each layer should perform a well-defined function. The function of each layer should be chosen with the goal of defining internationally standardized protocols. The layer boundaries should be chosen to minimize the information flow across the interfaces. The number of layers should be large enough to enable distinct functions to be separated, but few enough to keep the architecture from becoming unwieldy.

Abraham Tezmol, M.S. E.E.

16

The OSI Model Data Flow

OSI

The OSI model presents a standard data flow architecture, with protocols specified in such a way that the receiving layer at the destination computer receives exactly the same object as sent by the matching layer at the source computer

Abraham Tezmol, M.S. E.E.

17

The OSI Model Data Flow

OSI

The sending process passes data to the application layer. The application layer attaches an application header and then passes the frame to the presentation layer.
The presentation layer can transform data in various ways, if necessary, such as by translating it and adding a header. It gives the result to the session layer. The presentation layer is not aware of which portion (if any) of the data received from the application layer is the application header and which portion is actually user data, because that information is irrelevant to the presentation layer's role. The process of adding headers is repeated from layer to layer until the frame reaches the data link layer. There, in addition to a data-link header, a data-link trailer is added. The data-link trailer contains a checksum and padding if needed. This aids in frame synchronization. The frame is passed down to the physical layer, where it is transmitted to the receiving computer. On the receiving computer, the various headers and the data trailer are stripped off one by one as the frame ascends the layers and finally reaches the receiving process. Although the actual data transmission is vertical, each layer is programmed as if the transmission were horizontal. For example, when a sending transport layer gets a message from the session layer, it attaches a transport header and sends it to the receiving transport layer. The fact that the message actually passes through the network layer on its own computer is unimportant.

Abraham Tezmol, M.S. E.E.

18

The OSI Model Vertical Interface Terminology

OSI

In addition to defining an idealized network architecture and the network functions allocated to each layer, the OSI model also defines a standard set of rules that govern the interfaces between layers. The active protocol elements in each layer are called entities, typically implemented by means of a software process. Entities in the same layer on different computers are called peer entities . For example, the TCP/IP protocol suite contains two entities within its transport layer: Transmission Control Protocol (TCP) and User Datagram Protocol (UDP). Layer n-1 , the layer directly below the entities of layer n , implements services that are used by layer n .

For data transfer services, OSI defines the terminology for the discrete data components passed across the interface and between peer entities

Abraham Tezmol, M.S. E.E.

19

The OSI Model Vertical Interface Terminology


The layer- n entity passes an interface data unit (IDU) to the layer-( n 1) entity.

OSI

The IDU consists of a protocol data unit (PDU) and some interface control information (ICI). The ICI is information, such as the length of the SDU, and the addressing information that the layer below needs to perform its function. The PDU is the data that the layer- n entity wishes to pass across the network to its peer entity. It consists of the layer- n header and the data that layer n received from layer (n+1) . The layer- n PDU becomes the layer-( n 1) service data unit (SDU), because it is the data unit that will be serviced by layer n. When layer n 1 receives the layer- n IDU, it strips off and "considers" the ICI, adds the header information for its peer entity across the network, adds ICI for the layer below, and passes the resulting IDU to the layer n 2 entity.

Abraham Tezmol, M.S. E.E.

20

The OSI Model Physical Layer

OSI

The physical layer is the lowest layer of the OSI model. This layer controls the way unstructured, raw, bit -stream data is sent and received over a physical medium. This layer is composed of the electrical, optical, and physical components of the network. The physical layer carries the signals for all of the higher layers. To better accommodate the characteristics of the physical medium and to assist in bit and frame synchronization, data encoding modifies the simple, digital signal pattern (1s and 0s) used by the computer. Data encoding determines: Which signal pattern represents a binary 0 and a binary 1. How the receiving station recognizes when an encoded bit starts. How the receiving station delimits a frame. The physical components (such as wiring, connectors, and pin-outs) determine: Whether an external transceiver is used to connect to the medium. How many pins the connectors have and what role each pin performs. The transmission technique determines whether the encoded bits are transmitted by means of baseband (digital) signaling or broadband (analog) signaling.

The physical means of transmission, such as a network adapter or fiber optic adapter, determines whether it is appropriate to transmit bits as electrical or optical signals.
Abraham Tezmol, M.S. E.E.

21

The OSI Model Data Link Layer

OSI

The data-link layer provides error-free transfer of data frames from one computer to another over the physical layer. The layers above this layer can assume virtually error-free transmission over the network.
The data-link layer provides the following functions: Establishment and termination of logical links (virtual-circuit connection) between two computers identified by their unique network adapter addresses. Control of frame flow by instructing the transmitting computer not to transmit frame buffers. Sequential transmission and reception of frames. Providing and listening for frame acknowledgment, and detecting and recovering from errors that occur in the physical layer by retransmitting non-acknowledged frames and handling duplicate frame receipts. Management of media access to determine when the computer is permitted to use the physical medium. Delimiting of frames to create and recognize frame boundaries. Error-checking of frames to confirm the integrity of the received frame.

Inspection of the destination address of each received frame and determination of whether the frame should be directed to the layer above.

Abraham Tezmol, M.S. E.E.

22

The OSI Model Network Layer

OSI

The network layer controls the operation of the subnet. It determines what physical path the data takes based on the network conditions, the priority of service, and other factors. The network layer provides the following functions: Transfer of frames to a router if the network address of the destination does not indicate the network to which the computer is attached. Control of subnet traffic to allow an intermediate system to instruct a sending station not to transmit its frames when the router's buffer fills up. If the router is busy, the network layer can instruct the sending station to use an alternate router. Fragmentation of frames by a router when the size of a link to a downstream router's maximum transmission unit (MTU) is smaller than the frame size. The frame fragments are reassembled by the destination station. Resolution of the logical computer address (on the network layer) with the physical network adapter address (on the data-link layer), if necessary.

Abraham Tezmol, M.S. E.E.

23

The OSI Model Network Layer

OSI

The network layer at the transmitting computer must build its header in such a way that the network layers of the subnet's intermediate systems can recognize the header and use it to route the data to the destination address.
In the network layer and the layers below it, the peer protocols are between each computer and its immediate neighbor, which is often not the ultimate destination. The source and destination computers may be separated by many intermediate systems.

The network layer eliminates the need for higher layers to know anything about the data transmission or intermediate switching technologies used to connect systems. The network layer is responsible for establishing, maintaining, and terminating the connection to intermediate systems in the communication subnet.

Abraham Tezmol, M.S. E.E.

24

The OSI Model Transport Layer

OSI

The transport layer ensures that messages are delivered in the order in which they are sent and that there is no loss or duplication.
Functions of the transport layer include the following: Accepting messages from the layer above and, if necessary, splitting them into segments. Providing reliable, end-to-end message delivery with acknowledgments. Instructing the transmitting computer not to transmit when no reception buffers are available. Multiplexing several process-to-process message streams or sessions onto one logical link and tracking which messages belong to which sessions.

Abraham Tezmol, M.S. E.E.

25

The OSI Model Transport Layer

OSI

The transport layer can accept large messages, but there are strict size limits imposed by the layers at the network level and lower. Consequently, the transport layer must break up the messages into smaller units, called segments , and attach a header to each frame.
If the lower layers do not maintain sequence, the transport header must contain sequence information, which enables the transport layer on the receiving end to present data in the correct sequence to the next higher layer.

Unlike the lower layers that have protocols that are concerned with connecting to immediately adjacent nodes or computers, the transport layer and the layers above it are true source-todestination layers, also known as end-to-end layers. These upper layers are not concerned with the details of the underlying communications facility. Software for these layers communicates with similar software on the destination computer by using message headers and control messages.

Abraham Tezmol, M.S. E.E.

26

The OSI Model Presentation Layer

OSI

The presentation layer serves as the data translator for the network. This layer on the sending computer translates the data sent by the application layer into a common format. At the receiving computer, the presentation layer translates the common format to a format known to the application layer.
The presentation layer provides the following functions: Character-code translation, such as from ASCII to EBCDIC. Data conversion, such as bit order reversal, CR to CR/LF, and integer to floating point. Data compression, which reduces the number of bits that need to be transmitted. Data encryption and decryption, which secures data for transmission across a potentially insecure network. One use of encryption is for transmission of a password to a receiving computer.

Abraham Tezmol, M.S. E.E.

27

The OSI Model Application Layer

OSI

The application layer serves as the window for users and application processes to access network services. The application layer provides the following functions:
Resource sharing and device redirection Remote file access Remote printer access Inter-process communication support Remote procedure call support Network management Directory services

Electronic messaging, including e-mail messaging


Simulation of virtual terminals

Abraham Tezmol, M.S. E.E.

28

The OSI Model References

OSI

ISO/IEC standard 7498-1:1994 (PDF document inside ZIP archive) (requires HTTP cookies in order to accept licence agreement)
ITU-T X.200 (the same contents as from ISO) The ISO OSI Reference Model , Beluga graph of data units and groups of layers OSI Reference Model The ISO Model of Architecture for Open Systems InterconnectionPDF (776 KB), Hubert Zimmermann, IEEE Transactions on Communications, vol. 28, no. 4, April 1980, pp. 425 432. Cisco Systems Internetworking Technology Handbook

Abraham Tezmol, M.S. E.E.

29