UNIT-4 HDLC Protocol Overview: Idle)

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 12

UNIT-4 HDLC Protocol Overview High-level data link control (HDLC), documented in ISO 3309, specifies a packitization standard

for serial links. HDLC supports several modes of operation, including a simple sliding window mode for reliable delivery. Since Internet provide retransmission at higher levels (i.e, TCP), most Internet applications use HDLC's unreliable delivery mode, Unnumbered Information. HDLC's frame structure:

The beginning and end of an HDLC frame are marked by flag characters - 01111110 binary. No flag character may appear in the intervening data. To enforce this requirement, the data may need to be modified (in a transparent manner). On bit-synchronous links, a binary 0 is inserted after every sequence of five 1s (bit stuffing). Thus, the longest sequence of 1s that may appear of the link is 0111110 - one less than the flag character. The receiver, upon seeing five 1s, examines the next bit. If 0, the bit is discarded and the frame continues. If 1, then this must be the flag sequence at the end of the frame. At the end of the frame, a Frame Check Sequence (FCS) is used to verify the data integrity. The FCS is a CRC calculated using polynomial x^16 + x^12 + x^5 + 1. Between HDLC frames, the link idles. Most synchronous links constantly transmit data; these links can transmit all 1s during the inter-frame period (mark idle), or all flag characters (flag idle). Many varients of HDLC have been developed. Both PPP and SLIP use a subnet of HDLC's functionality. ISDN's D channel uses a slightly modified version of HDLC. Cisco routers' default serial link encapsulation is HDLC. HDLC Operation Modes: HDLC has three operational modes: 1. Normal Response Mode (NRM - Normal Response Mode is used in unbalanced configurations. In this mode, slave stations (or secondary) can only transmit when specially instructed by the master (primary station). The link may be point-to-point or multipoint. In the latter case only one primary station is allowed. 2. Asynchronous Response Mode (ARM - Asynchronous Response Mode: This mode is used in unbalanced configurations. [unbalanced configurations]. It allows a secondary station to initiate a transmission without receiving permission from the primary station . This mode is normally used with point-to-point configurations and full duplex links and

allows the secondary station to send frames asynchronously with respect to the primary station) 3. Asynchronous Balanced Mode (ABM - The Asynchronous Balanced Mode (ABM), is used mainly on full duplex point-to-point links for computer to computer communications and for connections between a computer and a packed switched data network, in this case each station has an equal status and performs the role of both primary and secondary functions. This mode is used in the protocol set known as X.25.) Frame Classes: In the HDLC protocol , three classes of frames are used : 1. Unnumbered frames - (Unnumbered frames are used for link management, for example they are used to set up the logical link between the primary station and a secondary station, and to inform the secondary station about the mode of operation which is used.) are used for link management. 2. Information frames - (Information frames are those who carry the actual data. The Information frames can be used to piggyback acknowledgment information relating to the flow of Information frames in the reverse direction when the link is being operated in ABM or ARM.) are used to carry the actual data. 3. Supervisory frames - are used for error and flow control. Protocol operation The two basic functions in the protocol are link management and data transfer (which includes error and flow control). Link management . Prior to any kind of transmission (either between two stations connected by a point to point link or between a primary and secondary station a multidrop link) a logical connection (A logical connection between the two communication parties is accomplished by the exchange of two unnumbered frames. The procedure for setting a logical connection (In a multidrop link) is given below:The SNRM is first sent by the primary station with the poll bit set to 1 and the address of the appropriate secondary in the address field. The secondary responds with a UA frame with the final bit set and its own address in the address field. After all the data has been transferred, the link is clears by the primary sending a DISC frame and the secondary responding with a UA) between the two communication parties must be established. Data transfer In NRM all data (information frames) if transferred under the control of the primary station. The unnumbered poll frame with the P bit set to 1 is normally used by the primary to poll a secondary. If the secondary has no data to transmit, it returns an RNR frame with the F bit set. If data is waiting, it transmits the data, typically as a sequence of information frames. The two most important aspects associated with the data transfer phase are error control and flow

control. Essentially, error control uses a continues RQ procedure with either a selective repeat or a go back N transmission strategy, while flow controls based on a window mechanism. LAPB: Link Access Procedure Balanced: Link Access Procedure, Balanced (LAPB) is a data link layer protocol used to manage communication and packet framing between data terminal equipment (DTE) and the data circuitterminating equipment (DCE) devices in the X.25 protocol stack. LAPB, a bit-oriented protocol derived from HDLC, is actually the HDLC in BAC mode (Balanced Asynchronous Class). LAPB makes sure that frames are error free and properly sequenced. LAPB shares the same frame format, frame types, and field functions as SDLC and HDLC. Unlike either of these, however, LAPB is restricted to the Asynchronous Balanced Mode (ABM) transfer mode and is appropriate only for combined stations. Also, LAPB circuits can be established by either the DTE or DCE. The station initiating the call is determined to be the primary, and the responding station is the secondary. Finally, LAPB use of the P/F bit is somewhat different from that of the other protocols. In LAPB, since there is no master/slave relationship, the sender uses the Poll bit to insist on an immediate response. In the response frame this same bit becomes the receivers Final bit. The receiver always turns on the Final bit in its response to a command from the sender with the Poll bit set. The P/F bit is generally used when either end becomes unsure about proper frame sequencing because of a possible missing acknowledgement, and it is necessary to re-establish a point of reference. LAPB's Frame Types:

I-Frames (Information frames): Carries upper-layer information and some control information. I-frame functions include sequencing, flow control, and error detection and recovery. I-frames carry send and receive sequence numbers. S-Frames (Supervisory Frames): Carries control information. S-frame functions include requesting and suspending transmissions, reporting on status, and acknowledging the receipt of I-frames. S-frames carry only receive sequence numbers. U-Frames (Unnumbered Frames): carries control information. U-frame functions include link setup and disconnection, as well as error reporting. U-frames carry no sequence numbers.

Protocol Structure - LAPB: Link Access Procedure Balanced The format of LAPB frame is as follows:

1 byte Flag

1 byte Address field

1-2 bytes Control field

Variable Data/Information

2 bytes FCS

1 byte Flag

Flag - The value of the flag is always (0x7E). In order to ensure that the bit pattern of the frame delimiter flag does not appear in the data field of the frame (and therefore cause frame misalignment), a technique known as Bit Stuffing is used by both the transmitter and the receiver. Address field - In LAPB, the address field has no meaning since the protocol works in a point to point mode and the DTE network address is represented in the layer 3 packets. Control field - it serves to identify the type of the frame. In addition, it includes sequence numbers, control features and error tracking according to the frame type. Modes of operation - LAPB works in the Asynchronous Balanced Mode (ABM). This mode is totally balanced (i.e., no master/slave relationship) and is signified by the SABM(E) frame. Each station may initialize, supervise, recover from errors, and send frames at any time. The DTE and DCE are treated as equals. FCS - The Frame Check Sequence enables a high level of physical error control by allowing the integrity of the transmitted frame data to be checked. Window size - LAPB supports an extended window size (modulo 128) where the number of possible outstanding frames for acknowledgement is raised from 8 to 128.

Link Access Protocol D-Channel (LAPD) LAPD Limitations Management of card-level congestion for overload conditions is not supported Removing the CCS I/O card causes the ISDN Series 3 standby card to reset. Redundancy is dropped and the active card becomes single. Removing the CCS I/O of the ISDN Series 3 Active card causes a switchover to the ISDN Series 3 secondary card. You must remove both cards and re-insert if you are performing maintenance on either card. LAP -D is the Layer 2 protocol in the ISDN suite, almost identical to the X.25 LAP-B protocol. The three logical digital communication channels of ISDN perform the following functions:

B-Channel - Carries user service information including: digital data, video, and voice. D-Channel - Carries signals and data packets between the user and the network H-Channel - Performs the same function as B-Channels, but operates at rates exceeding DS-0 (64 Kbps).

The Link Establishment process in ISDN performed by LAP-D is as follows: 1. The TE (Terminal Endpoint) and the Network initially exchange Receive Ready (RR) frames, listening for someone to initiate a connection 2. The TE sends an Unnumbered Information (UI) frame with a SAPI of 63 (management procedure, query network) and TEI of 127 (broadcast) 3. The Network assigns anavailable TEI(in the range 64-126) 4. The TE sends a Set Asynchronous Balanced Mode (SABME) frame with a SAPI of 0 (call control, used to initiate a SETUP) and a TEI of the value assigned by the network 5. The network responds with an Unnumbered Acknowledgement (UA), SAPI=0, TEI=assigned.

The LAPD is defined in CCITT Q.920/921. LAPD works in the Asynchronous Balanced Mode (ABM). This mode is totally balanced (i.e., no master/slave relationship). Each station may initialize, supervise, recover from errors, and send frames at any time. The protocol treats the DTE and DCE as equals. Protocol Structure - LAP-D: ISDN Link Access Protocol- Channel D The format of a standard LAPD frame is as follows:

Flag

Address field

Control field

Information

FCS

Flag

Flag - The value of the flag is always (0x7E). Bit Stuffing technique is used in order to ensure that the bit pattern of the frame delimiter flag does not appear in the data field of the frame. Address field - The first two bytes of the frame after the header flag is known as the address field. The format of the address field is as follows:

7 C/R

8 EA0 EA1

SAPI (6 bits) TEI (7 bits)


o o o

SAPI(Service access point identifier), 6-bits (see below) C/R(Command/Response) bit indicates if the frame is a command or a response EA0(Address Extension) bit indicates whether this is the final octet of the address or not o TEI(Terminal Endpoint Identifier) 7-bit device identifier (see below) o EA1(Address Extension) bit, same as EA0 Control field - The field following the Address Field is called the Control Field and serves to identify the type of the frame. In addition, it includes sequence numbers, control features and error tracking according to the frame type. The following are the Supervisory Frame Types defined in LAPD:

RR REJ RNR

Information frame acknowledgement and indication to receive more. Request for retransmission of all frames after a given sequence number. Indicates a state of temporary occupation of station (e.g., window full).

Some Unnumbered Frame Types supported in LAPD are DISC (Request disconnection), UA (Acknowledgement frame), DM (Response to DISC indicating disconnected mode), FRMR (Frame reject), SABM, SABME, UI and XID. FCS -The Frame Check Sequence (FCS) enables a high level of physical error control by allowing the integrity of the transmitted frame data to be checked. The sequence is first calculated by the transmitter using an algorithm based on the values of all the bits in the frame. The receiver then performs the same calculation on the received frame and compares its value to the CRC. Window size - LAPD supports an extended window size (modulo 128) where the number of possible outstanding frames for acknowledgement is raised from 8 to 128. This extension is generally used for satellite transmissions where the acknowledgement delay is significantly greater than the frame transmission times. The type of the link initialization frame determines the modulo of the session and an "E" is added to the basic frame type name (e.g., SABM becomes SABME). Inter networking devices: Internetworking is the practice of connecting a computer network with other networks through the use of gateways that provide a common method of routing information packetsbetween the networks. The resulting system of interconnected networks is called an internetwork, or simply an internet. These are devices used in connecting individual networks to each other. Examples include: Cables Cabling play an important role in networking and the type of network media used determines how fast the data travels along the media, and also the maximum data rate that can be carried. The four main types of networking media are: Shielded twisted-pair (STP) Cables Repeaters Hubs Bridges Switches Routers

Unshielded twisted-pair (UTP) Coaxial cable Fiber-optic cable

Shielded twisted-pair: This is a type of copper telephone wiring in which each of the two copper wires that are twisted together and are coated with an insulating coating that functions as a ground for the wires.

Unshielded twisted-pair: Unshielded Twisted-pair are not shielded and thus interfere with nearby cables. They are used in LANs to bit rates of 100Mbps and with maximum length of 100m. UTP cables are typically used to connect a computer to a network.

Coaxial cable: Has a grounded metal sheath around the signal conductor. Interference among cables is reduced due to the sheath around signal conductor. Allows higher data rate transfer. Typically they are used at bit rates of 100 Mbps for maximum lengths of 1 km.

Fiber-optic cable: Do not interfere with nearby cables. Give greater security. Allows extremely high bit rates over long distances. They provide more protection from electrical damage by external equipment and greater

resistance to harsh environment. Safer in hazardous environment. Repeaters As a network grows, its cable can easily exhaust the network constraint, and any further loads on this network can leads to attenuation and digital pulse distortion. To overcome these limitations, repeaters are used to increase the maximum interconnection length, and may do the following: Reshape signal pulses Pass all signals between attached segments Boost signal power Possibly translate between two different media (such as between fiber-optic and twistedpair cable) Transmit to more than one network. These are multi-port repeaters and send data frames from any received segment to all the others. Multi-port repeaters do not filter the traffic, as they blindly send received data frames to all the physical connected network segments. (ref)

Hubs A hub is a repeater with multiple ports, and can be thought of as being the centre point of a star topology network. It is often known as a multi-port repeater (or as a concentrator in Ethernet). Hubs can be active (where they repeat signal sent through them) or passive (where they do not repeat, but merely split, signals sent through them). Hub generally: Amplify signals. Propagate the signal through the network. Do not filter traffic. This is a major disadvantage with hubs and repeaters as data arriving at any of the ports is automatically transmitted to all the other ports connected to the hub.

Do not determine path. Centralize the connection to the network. Bridges These examine the destination MAC address (or station address) of the transmitted data frames, and will not retransmit data frames which are not destined for another network segment. They maintain a table with connected MAC address, and do not forward any data frames if the MAC address is on the network that originated it, else it forward to all connected segment. Thus a bridge does not actually determine on which segment the destination is on, and blindly forwards data frames to all other connected segments ref . Bridges are an excellent method of reducing traffic on network segment and it does this by examining the destination address of the frame before deciding how to handle it. Consider the figure below; if the destination address of a data frame (from segment 1) is that of station A or B, then there is no need for the frame to appear on segment 2. But if the destination address (data frame from segment 1) is that of station C or D, or if it is the broadcast address, then the bridge will transmit, or forward the frame on to segment 2. By forwarding packets, the bridge allows any of the four devices in the figure to communicate.

Problems with Bridge They work well when there is not too much inter-segment traffic, but when the intersegment traffic becomes too heavy the bridges can actually become a bottleneck for traffic,

and actually slow down communication. They spread and multiply broadcast. A bridge forwards all broadcast to all other connected segments. If there are too many broadcast, it can result in a broadcast storm.

Switches A switch is a very fast, low-latency, multi-port bridge that is used to segment LANs. They are typically used to increase communication rates between segments with multiple parallel conversation and also communication between different networking technologies (such as between ATM and 100Base-TX). r A vital difference between a hub and a switch is that all the nodes connected to a hub share the bandwidth among themselves, while a device connected to a switch port has the full bandwidth all to itself. For example, if 10 nodes are communicating using a hub on a 10-Mbps network, then each node may only get a portion of the 10 Mbps if other nodes on the hub want to communicate as well. But with a switch, each node could possibly communicate at the full 10 Mbps. Switches forwards received data frames in two ways; Cutting-through switching: the switch reads the destination address before receiving the entire frame. The data is then forwarded before the entire frame arrives. This method has the advantage that there is less delay (latency) between the reception and transmission of a data packet, but has poor error detection, because it does not have a chance to detect any errors, before it has started to transmit the received data frame.r Store-and-forward switching: it involves reading the entire Ethernet frame, before forwarding it, with the required protocol and at the correct speed, to the destination port. This has the advantage of improved error check, protocol filtering and speed matching but has the disadvantage of system delay, as the frames must be totally read before it is transmitted. r

Routers These are network devices that examine the network address (IP address) field and determine the best route for a data packet, and will only transmit it out of a network segment if it is destined for a node on another network. Routers do the following: Do not forward broadcast Do not forward traffic to unknown addresses Modify data packet header
Build tables of network addresses. Routing Routing is the process of selecting paths in a network along which to send network traffic.

Routing is performed for many kinds of networks, including the telephone network (Circuit switching), electronic data networks (such as the Internet), and transportation networks. This article is concerned primarily with routing in electronic data networks using packet switchingtechnology.

X.25 protocol:
X.25 is an ITU-T standard protocol suite for packet switched wide area network (WAN) communication. An X.25 WAN consists ofpacket-switching exchange (PSE) nodes as the networking hardware, and leased lines, Plain old telephone service connections or ISDN connections as physical links. X.25 is a family of protocols that was popular during the 1980s with telecommunications companies and in financial transaction systems such as automated teller machines. X.25 is one of the oldest packet-switched services available. It was developed before the OSI Reference [3] Model. The protocol suite is designed as three conceptual layers, which correspond closely to the lower [4] three layers of the seven-layer OSI model. It also supports functionality not found in the OSI Network Layer. The general concept of X.25 was to create a universal and global packet-switched network. Much of the X.25 system is a description of the rigorous error correction needed to achieve this, as well as more efficient sharing of capital-intensive physical resources. Physical layer: This layer specifies the physical, electrical, functional and procedural characteristics to control the physical link between a DTE and a DCE. Common implementations use X.21, EIA-232, EIA-449 or other serial protocols. Data link layer: The data link layer consists of the link access procedure for data interchange on the link between a DTE and a DCE. In its implementation, the Link Access Procedure, Balanced (LAPB) is a data link protocol that manages a communication session and controls the packet framing. It is a bit-oriented protocol that provides error correction and orderly delivery.

Packet layer: This layer defined a packet-layer protocol for exchanging control and user data packets to form a packet-switching network based on virtual calls, according to thePacket Layer Protocol.

X.25 was developed in the era of dumb terminals connecting to host computers, although it also can be used for communications between computers. Instead of dialing directly into the host computer which would require the host to have its own pool of modems and phone lines, and require non-local callers to make long-distance calls the host could have an X.25 connection to a network service provider.

Error control
Error recovery procedures at the packet layer assume that the data link layer is responsible for retransmitting data received in error. Packet layer error handling focuses on resynchronizing the information flow in calls, as well as clearing calls that have gone into unrecoverable states: Level 3 Reset packets, which re-initializes the flow on a virtual call (but does not break the virtual call) Restart packet, which clears down all virtual calls on the data link and resets all permanent virtual circuits on the data link

X.25 details
The network may allow the selection of the maximal length in range 16 to 4096 octets (2 values only) per virtual circuit by negotiation as part of the call setup procedure. The maximal length may be different at the two ends of the virtual circuit. Data terminal equipment constructs control packets which are encapsulated into data packets. The packets are sent to the data circuit-terminating equipment, using LAPB Protocol. Data circuit-terminating equipment strips the layer-2 headers in order to encapsulate packets to the internal network protocol.
[34] n

X.25 facilities
X.25 provides a set of user facilities defined and described in ITU-T Recommendation X.2. user facilities fall into five categories: essential facilities; additional facilities; conditional facilities; mandatory facilities; and, optional facilities. The X.2

X.25 also provides X.25 and ITU-T specified DTE optional user facilities defined and described in ITU-T [35] Recommendation X.7. The X.7 optional user facilities fall into four categories of user facilities that require: subscription only; subscription followed by dynamic invocation; subscription or dynamic invocation; and, dynamic invocation only.

You might also like