Continue to previous review.
An ideal multiple access protocol
Given: broadcast channel of rate R bps
Desiderata:
- When one node wants to transmit, it can send at rate R.
- When M nodes want to transmit, each can send at average rate R/M
- The protocol is fully decentralized:
- No special node to coordinate transmissions
- No synchronization of clocks, time slots
- No master node that represents a single point of failure
- The protocol is simple, so that inexpensive to implement
MAC protocols: 3 classes
- Channel Partitioning (TDMA, FDMA, CDMA)
- Divide channel into smaller "pieces" (in terms of time slots, frequency, code, etc.)
- Allocate each piece to a node for exclusive use
- Random Access
- Channel is not divided, allow collisions
- "Recover" from collisions
- Taking Turns
- Nodes take turns, but nodes with more to send can take longer turns
TDMA: Time division multiple access
- Access to channel in "rounds" (I slot in time frame)
- Each station gets fixed length slot (length = pkt trans time) in each round
- Unused slots go idle
- Example: 6-station LAN, 1, 3, 4 have pkt, slots, 2, 5, 6 idle
- For example, blue slots belong to station
FDMA: Frequency division multiple access
- Channel spectrum divided into frequency bands
- Each station assigned fixed frequency band
- Unused transmission time in frequency bands go idle
- Example: 6-station LAN, 1, 3, 4 have pkt, frequency bands 2, 5, 6 idle.
- Example: User I always can use the blue band.
Three classes of MAC protocols
- Channel partitioning protocols
- Time Division, Frequency Division, Code Division
- Random access protocols
- ALOHA, S-ALOHA, CSMA, CSMA/CD, CSMA/CA
- Carrier sensing: easy in some technologies (wire), hard in others (wireless)
- CSMA/CD used in Ethernet
- CSMA/CA used in 802.11
- Taking turns protocols
- Polling from central site
- FDDI: token ring
Random access protocols
- When node has packet to send
- Transmit at full channel data rate R
- Not a prior coordination among nodes
- If two or more transmitting nodes -> "Collision"
- Random access MAC protocol specifies:
- How to detect collisions
- How to recover from collisions (for example, via delayed retransmissions)
- Examples of Random access MAC protocols:
- Slotted ALOHA, ALOHA
- CSMA, CSMA/CD, CSMA/CA
Slotted ALOHA
Assumption:
- All data-frames same size
- Time divided into equal size slots (time to transmit I data-frame)
- Nodes start to transmit only at beginning of slot
- Nodes are synchronized
- If 2 or more nodes transmit in the same slot, all nodes detect collision
Operation:
- When a node obtains fresh frame, transmits in next slot
- If no collision: successful transmission!
- If collision: node retransmits frame in each subsequent slot with some random probability p until success.
Here is pros and cos for ALOHA.
'Computer Science ๐ > Network Programming ๐ฐ๏ธ' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
MAC Protocols (3) (0) | 2023.05.06 |
---|---|
MAC protocol (1) (0) | 2023.05.04 |
TCP (2) (0) | 2023.05.02 |
TCP (1) (0) | 2023.04.29 |
UDP (0) | 2023.04.27 |