ScholarQuill logoScholarQuillUniversity Notes
  • Notes
  • Past Papers
  • Blogs
  • Todo
Login
ScholarQuill logoScholarQuillUniversity Notes
Login
NotesPast PapersBlogsTodo
More
SubjectsDiscussionCGPA CalculatorGPA CalculatorStudent PortalCourse Outline
About
About usPrivacy PolicyReportContact
Notes
Past Papers
Blogs
Todo
Analytics
    Current Subject
    🧩
    Computer Networks
    CSI-417
    Progress0 / 18 topics
    Topics
    1. Analogue and Digital Transmission2. Noise3. Media4. Encoding5. Asynchronous and Synchronous Transmission6. Protocol Design Issues7. Network System Architectures (OSI, TCP/IP)8. Error Control9. Flow Control10. Data Link Protocols (HDLC, PPP)11. Local Area Networks and MAC Layer Protocols (Ethernet, Token Ring)12. Multiplexing13. Switched and IP Networks14. Inter-networking15. Routing16. Bridging17. Transport Layer Protocols (TCP/IP, UDP)18. Network Security Issues
    CSI-417›Data Link Protocols (HDLC, PPP)
    Computer NetworksTopic 10 of 18

    Data Link Protocols (HDLC, PPP)

    6 minread
    1,095words
    Intermediatelevel

    Data Link Protocols: HDLC and PPP

    In computer networks, the Data Link Layer is responsible for establishing, maintaining, and terminating a link between two directly connected nodes. This layer also ensures the reliable transmission of data frames over the physical layer, detecting and possibly correcting errors that may occur during transmission. Data Link Layer protocols such as HDLC (High-Level Data Link Control) and PPP (Point-to-Point Protocol) are widely used for communication between devices over various types of physical media.


    1. HDLC (High-Level Data Link Control)

    HDLC is a bit-oriented synchronous data link layer protocol developed by ISO (International Organization for Standardization) for point-to-point and point-to-multipoint communication. It is one of the most common and widely implemented data link protocols used in both WAN (Wide Area Networks) and LAN (Local Area Networks).

    Key Features of HDLC:

    • Bit-Oriented Protocol: HDLC operates on bit frames, meaning it processes data in terms of bits, rather than characters or bytes.
    • Synchronous Transmission: HDLC supports synchronous communication, meaning that data is transmitted in a continuous stream with timing signals from the sender to the receiver.
    • Error Detection and Correction: HDLC provides error detection using Cyclic Redundancy Check (CRC), which ensures that the transmitted data is error-free. However, error correction is not directly provided by HDLC; it relies on retransmission of data using the ARQ (Automatic Repeat Request) mechanism.
    • Frame Structure: HDLC frames consist of the following fields:
      • Flag: Indicates the beginning and end of a frame, usually represented by 0x7E.
      • Address: Identifies the destination of the frame.
      • Control: Contains control information related to the frame, such as sequencing and acknowledgment.
      • Data: The payload or the actual data being transmitted.
      • FCS (Frame Check Sequence): Contains the CRC for error checking.

    HDLC Frame Types:

    HDLC defines three types of frames:

    1. Information Frame (I-frame): Carries user data and control information.
    2. Supervisory Frame (S-frame): Provides control information, such as flow control, acknowledgment, and error recovery.
    3. Unnumbered Frame (U-frame): Used for link management and control (e.g., establishing or terminating a connection).

    Modes of Operation:

    HDLC operates in three modes:

    1. Normal Response Mode (NRM): The primary station controls the communication, and secondary stations respond to it.
    2. Asynchronous Response Mode (ARM): Similar to NRM, but the secondary station can initiate communication after receiving permission from the primary.
    3. Bit-Stream Mode (ABM): Both stations have equal responsibilities and can initiate communication, typically used in peer-to-peer communication.

    Advantages of HDLC:

    • Reliable error detection.
    • Supports full-duplex communication.
    • Efficient and flexible framing.
    • Suitable for both point-to-point and point-to-multipoint links.

    Disadvantages of HDLC:

    • Complexity in implementation, especially in comparison to simpler protocols like PPP.
    • Primarily used for synchronous communication, not suitable for asynchronous communication.

    2. PPP (Point-to-Point Protocol)

    PPP is another widely-used data link protocol designed to provide a standard method for transmitting data over serial links. It is more commonly used for dial-up connections, VPNs (Virtual Private Networks), and other point-to-point connections, including over telephone lines, fiber-optic cables, and satellite links.

    Key Features of PPP:

    • Character-Oriented Protocol: Unlike HDLC (which is bit-oriented), PPP is a character-oriented protocol, processing data in terms of bytes rather than individual bits.
    • Simplicity and Flexibility: PPP is designed to be simple, flexible, and easy to implement. It provides mechanisms for error detection, link configuration, and negotiation between devices.
    • Support for Multiple Protocols: PPP can transport multiple Layer 3 protocols (like IP, IPX, and AppleTalk) over the same link, making it versatile for different network configurations.
    • Error Detection: PPP uses a Frame Check Sequence (FCS) for error detection, ensuring that any transmission errors can be detected and possibly retransmitted.
    • Link Establishment and Termination: PPP defines a specific sequence for establishing, maintaining, and terminating a connection between two devices.

    PPP Frame Structure:

    A PPP frame is structured as follows:

    1. Flag: Indicates the start and end of the frame (0x7E).
    2. Address: Typically all ones, indicating that the frame is for a point-to-point link (i.e., no address is needed).
    3. Control: Generally all zeros, indicating the frame's control function.
    4. Protocol: Identifies the protocol being used in the data field (e.g., IP, IPX).
    5. Data: The payload, which carries the actual data being transmitted.
    6. FCS (Frame Check Sequence): Used for error detection.

    PPP Encapsulation:

    PPP encapsulates higher-layer protocols (like IP, IPX, or AppleTalk) by including a protocol field in the frame. This allows PPP to support a variety of network layer protocols over the same physical link.

    PPP Link Control Protocol (LCP):

    PPP provides LCP for the negotiation and establishment of a link between two devices. LCP allows the devices to:

    • Authenticate the connection.
    • Configure the link (e.g., maximum frame size, link quality).
    • Determine options like compression, encryption, and IP address assignment.

    PPP Network Control Protocols (NCP):

    PPP also supports NCPs, which are used to establish and configure network layer protocols (e.g., IPCP for IP, IPXCP for IPX).

    Advantages of PPP:

    • Simple, flexible, and easy to configure.
    • Supports multiple Layer 3 protocols (e.g., IP, IPX, AppleTalk).
    • Provides error detection using FCS.
    • Supports dynamic IP address assignment.
    • Provides support for both synchronous and asynchronous links.

    Disadvantages of PPP:

    • Lack of encryption and security features (unless combined with protocols like PPTP or L2TP for VPNs).
    • Not as robust as HDLC in terms of error correction and link management.

    Comparison: HDLC vs. PPP

    Feature HDLC PPP
    Type of Protocol Bit-oriented Character-oriented
    Error Detection CRC (Cyclic Redundancy Check) FCS (Frame Check Sequence)
    Frame Structure More complex Simple and flexible
    Support for Multiple Protocols Limited to Layer 2 (Data Link) Supports multiple Layer 3 protocols (IP, IPX, etc.)
    Configuration and Management Complex Provides LCP for link management and NCP for network protocol configuration
    Used For WAN, synchronous links (e.g., leased lines) Dial-up, VPNs, point-to-point links
    Link Termination Requires manual setup and management Supports automatic link establishment and termination
    Security No built-in security mechanisms Can be combined with additional security protocols (e.g., PAP, CHAP, EAP for authentication)

    Conclusion

    Both HDLC and PPP are widely used data link protocols, but they serve different purposes and have distinct characteristics:

    • HDLC is a more sophisticated, bit-oriented protocol used for high-speed, synchronous communication, often in WANs and leased lines.
    • PPP is a simpler, character-oriented protocol designed for point-to-point connections, offering flexibility and support for multiple Layer 3 protocols and authentication options.

    The choice between HDLC and PPP largely depends on the specific use case, the type of network, and the required features such as protocol support, error detection, or link management.

    Previous topic 9
    Flow Control
    Next topic 11
    Local Area Networks and MAC Layer Protocols (Ethernet, Token Ring)

    Past Papers

    Open this section to load past papers

    Click on Show Past Papers to see past papers.
    On This Page
      Reading Stats
      Est. reading time6 min
      Word count1,095
      Code examples0
      DifficultyIntermediate