Multiple Access Protocols in Computer Networks: Managing Shared Channels

Explore various multiple access protocols used in computer networks to manage shared communication channels. This tutorial explains different categories of protocols (random access, controlled access, channelization), their mechanisms for preventing collisions, and their respective strengths and weaknesses.



Multiple Access Protocols in Computer Networks: Managing Shared Channels

Introduction to Multiple Access Protocols

In many network environments, multiple devices share a single communication channel (like an Ethernet cable or a wireless frequency). This requires a mechanism to coordinate access to the channel to prevent collisions (two or more devices transmitting simultaneously), which leads to data corruption. Multiple access protocols provide these mechanisms, ensuring efficient and reliable data transmission.

Types of Multiple Access Protocols

Multiple access protocols can be categorized into several types, each with its own approach to managing channel access:

A. Random Access Protocols

In random access protocols, devices can attempt to transmit data at any time. This is simple but can lead to collisions.

1. ALOHA:

A very simple protocol. Devices transmit whenever they have data, without checking if the channel is busy. Collisions are handled by retransmission after a random delay.

  • Pure Aloha: Transmit anytime.
  • Slotted Aloha: Transmit only at the start of predefined time slots.

B. Carrier Sense Multiple Access (CSMA) Protocols

CSMA protocols improve upon ALOHA by having devices check if the channel is busy before transmitting. This reduces collisions but doesn't eliminate them.

CSMA Access Modes:
  • 1-Persistent: Continuously check until the channel is clear.
  • Non-Persistent: Check periodically; if busy, wait a random time before checking again.
  • p-Persistent: Transmit with a probability p if the channel is clear.
  • 0-Persistent: Wait for a turn to transmit.

C. CSMA/CD (Carrier Sense Multiple Access with Collision Detection)

CSMA/CD enhances CSMA by detecting collisions. If a collision occurs, devices send a jam signal to alert other devices and then retransmit after a random delay.

CSMA/CD Example (Illustrative)

if (channelIsIdle()) {
    sendData();
} else {
    waitForClearChannel();
    if (collisionDetected()) {
        sendJamSignal();
        // ... (random backoff) ...
        retransmit();
    }
}

D. CSMA/CA (Carrier Sense Multiple Access with Collision Avoidance)

CSMA/CA is used in wireless networks to avoid collisions. It uses mechanisms such as a Request To Send/Clear To Send (RTS/CTS) handshake and a backoff algorithm to minimize collisions.

E. Controlled Access Protocols

These protocols use a central authority to manage access, preventing collisions. Types include:

  • Reservation: Devices reserve time slots.
  • Polling: A central device polls other devices.
  • Token Passing: A token is passed between devices.

F. Channelization Protocols

These protocols divide the bandwidth into separate channels for different devices:

  • FDMA (Frequency Division Multiple Access): Assigns unique frequencies to each device.
  • TDMA (Time Division Multiple Access): Assigns unique time slots to each device.
  • CDMA (Code Division Multiple Access): Allows simultaneous transmission using unique codes.

Conclusion

Multiple access protocols are vital for managing shared communication channels efficiently. The choice of protocol depends on the characteristics of the network and the application's requirements. While random access is simple, controlled access methods and channelization techniques often provide better performance and reduce collisions.