Media Access Control (MAC): Random Access, Polling, and Token Passing
When multiple computers share the same broadcast wire (like a bus or radio channel), two computers might try to send data at the exact same moment. Their electrical signals will collide and turn into corrupted garbage.
Media Access Control (MAC) protocols define the traffic rules that determine who gets to transmit and what to do if collisions occur.
1. Classification of MAC Protocols
2. The ALOHA Protocol (Pure vs. Slotted)
Invented at the University of Hawaii in 1970 to connect remote islands via radio:
- Stations transmit whenever they have a frame ready.
- Zero coordination; massive collision rate!
- Vulnerable period = 2 × Tfr.
- Max Efficiency: Only 18.4% (S = G · e^-2G where G = 0.5).
- Time is divided into discrete equal slots.
- Stations can only start transmitting at the beginning of a time slot.
- Vulnerable period is halved = Tfr.
- Max Efficiency: Doubles to 36.8% (S = G · e^-G where G = 1).
3. CSMA (Carrier Sense Multiple Access) - “Listen Before You Talk!”
Instead of blindly transmitting like ALOHA, CSMA requires a station to listen (sense the carrier) first:
- If the wire is busy, wait.
- If the wire is idle, transmit.
The Famous CSMA/CD (Collision Detection - Used in Ethernet):
- Listen: Station checks if wire is idle.
- Transmit & Continue Listening: While transmitting, the station monitors the wire voltage.
- Collision Detected: If voltage spikes (two signals collided), the station aborts transmission immediately, broadcasts a Jamming Signal to notify everyone, and waits for a random time using the Binary Exponential Backoff Algorithm.
4. Controlled Access: Polling vs. Token Passing
In controlled access, stations take turns; zero collisions ever happen!
1. Polling (Master-Slave System)
- One central primary device acts as the Master.
- The Master asks each slave device in sequence: “Device 1, do you have data? No? Device 2, do you have data?”
- If Device 2 responds “Yes”, it transmits. Once finished, Master moves to Device 3.
2. Token Passing (Token Ring)
- A special bit pattern called a Token continuously circulates around a physical or logical ring.
- If a computer wants to send data, it must wait until the token arrives, grab the token, attach its data frame, and send it into the ring.
- No other station can transmit while one station holds the token. Once the frame circulates back, the station releases the token for the next computer.
💡 DAVV Exam Tip
Question (10 Marks): “Explain CSMA/CD working principle with a flowchart. Differentiate between Pure and Slotted ALOHA.”
- Give the maximum throughput formulas: Pure ALOHA = 18.4%, Slotted ALOHA = 36.8%.
- Explain CSMA/CD: Sense -> Transmit -> Detect Collision -> Send Jamming Signal -> Backoff.
- Mention that CSMA/CD is the core MAC protocol of wired Ethernet (IEEE 802.3).