In the MAC (Medium Access Control) sub-layer, multiple devices may need to share the same communication medium.
Controlled Access is a method in which devices do not compete randomly for the channel. Instead, a mechanism controls which device is allowed to transmit.
The two important controlled-access methods are:
- Polling
- Token Passing
1. Polling
Polling is a controlled-access method in which one device acts as a central controller and asks other devices, one by one, whether they have data to transmit.
The central device is often called the:
- Primary station
- Controller
The other devices are called:
- Secondary stations
Basic Structure
Controller
|
┌──────────┼──────────┐
↓ ↓ ↓
Device A Device B Device C
↓
Device D
The controller controls access to the shared channel.
Working of Polling
Suppose there are four devices:
A, B, C and D
The controller polls them one by one.
Controller → A: Do you have data?
A → Controller: No
Controller → B: Do you have data?
B → Controller: Yes
B → Controller: Sends data
Controller → C: Do you have data?
C → Controller: No
Controller → D: Do you have data?
D → Controller: Yes
D → Controller: Sends data
Thus, only the device that is given permission can transmit.
Types of Polling
1. Roll-Call Polling
The controller asks each device individually.
Controller
↓
A
↓
B
↓
C
↓
D
The controller checks each device in a sequence.
2. Hub Polling
The controller sends a message asking whether any device wants to transmit.
A device that needs to transmit responds.
Advantages of Polling
- No collisions because only the selected device can transmit.
- Easy to control.
- Suitable for centralized networks.
- Fair access can be provided to different devices.
- Useful when a central controller already exists.
Disadvantages of Polling
- Polling overhead: time is spent asking devices whether they have data.
- If there are many devices, polling can become slow.
- The controller can become a single point of failure.
- If the controller fails, communication may stop.
- Devices that have nothing to send still consume some polling time.
2. Token Passing
Token Passing is another controlled-access method.
Instead of having a central controller, a special small frame called a token circulates among the devices.
Only the device that possesses the token is allowed to transmit.
Basic Structure
A
↙ ↘
D B
↖ ↘
C
The token moves from one device to another.
For example:
A → B → C → D → A → B → ...
Working of Token Passing
Suppose four computers are connected:
A → B → C → D → A
Initially, the token is with A.
Step 1
A receives the token.
Token → A
If A has data, it transmits.
A ─────────► Data
Step 2
A finishes transmission and passes the token to B.
A → Token → B
Step 3
B can now transmit if it has data.
B ─────────► Data
Then B passes the token to C.
B → Token → C
The process continues.
A → B → C → D → A → ...
Important Rule
Only the station holding the token can transmit.
Therefore, two stations normally cannot transmit simultaneously, so collisions are avoided.
Token Ring
One famous implementation of token passing was Token Ring.
The devices are logically arranged in a ring:
A
/ \
D B
\ /
C
The token travels around the ring.
Another example is FDDI (Fiber Distributed Data Interface), which also used token-passing principles.
Advantages of Token Passing
1. No collisions
Only the token holder can transmit.
2. Fairness
Every device gets an opportunity to use the channel.
3. Predictable access
A device does not have to compete randomly with other devices.
4. Good under heavy traffic
Unlike random-access methods, performance can remain predictable when many devices have data to send.
Disadvantages of Token Passing
1. Token loss
If the token is lost or damaged, the network needs a mechanism to generate a new token.
2. Token duplication
If two tokens accidentally exist, more than one device may transmit, causing problems.
3. Maintenance overhead
The network must maintain the correct token-passing mechanism.
4. Delay
A device may have to wait for the token to travel around the network before it gets another opportunity.
Polling vs Token Passing
| Feature | Polling | Token Passing |
|---|---|---|
| Control | Central controller | Distributed |
| Special mechanism | Polling messages | Token |
| Central controller required | Yes | No |
| Collision | Avoided | Avoided |
| Access method | Controller selects station | Token holder gets access |
| Failure problem | Controller failure | Token loss/duplication |
| Fairness | Depends on polling strategy | Generally very good |
| Overhead | Polling messages | Token circulation |
| Suitable for | Centralized systems | Distributed networks |
Controlled Access vs Random Access
This is important for understanding the whole MAC sub-layer.
| Random Access | Controlled Access |
|---|---|
| Stations compete for channel | Access is controlled |
| Collision can occur | Collisions are generally avoided |
| Suitable for unpredictable traffic | Suitable when controlled access is desirable |
| Examples: ALOHA, CSMA | Examples: Polling, Token Passing |
Easy Real-Life Example
Imagine four students sharing one microphone.
Polling
A teacher controls the microphone:
Teacher → A: Speak?
A → No
Teacher → B: Speak?
B → Yes
B → speaks
Teacher → C: Speak?
The teacher decides who speaks.
This is Polling.
Token Passing
There is one microphone/token:
A → Microphone → B → Microphone → C → Microphone → D
Whoever has the microphone can speak.
This is Token Passing.
⭐ Exam Summary
Remember:
Polling
Central controller asks each station whether it wants to transmit.
Key word: Controller
Token Passing
A special token circulates among stations, and only the station holding the token can transmit.
Key word: Token
One-line comparison
Polling = Controller gives permission.
Token Passing = Token gives permission.
