Carrier Sense Multiple Access
Before transmitting a packet, sense carrier.
If it is idle, send.
After waiting for one DCF inter frame spacing (DIFS).
If it is busy, then:
Wait for medium to be idle for a DIFS (DCF IFS) period.
Go through exponential backoff, then send.
Want to avoid that several stations waiting to transmit automatically collide.
Wait for ACK.
If there is one, you are done.
If there isn’t one, assume there was a collision, retransmit using exponential backoff.
Exponential Backoff
Force stations to wait for random amount of time to reduce the chance of collision.
Backoff period increases exponential after each collision.
Similar to Ethernet.
If the medium is sensed busy:
Wait for medium to be idle for a DIFS (DCF IFS) period.
Pick random number in contention window (CW) = backoff counter.
Decrement backoff timer until it reaches 0.
But freeze counter whenever medium becomes busy.
When counter reaches 0, transmit frame.
If two stations have their timers reach 0; collision will occur.
After every failed retransmission attempt:
increase the contention window exponentially.
2^i –1 starting with CWmin up to CWmax e.g., 7, 15, 31, ...
CSMA/CA
Collision Avoidance
Difficult to detect collisions in a radio environment.
While transmitting, a station cannot distinguish incoming weak signals from noise – its own signal is too strong.
Why do collisions happen?
Near simultaneous transmissions.
Period of vulnerability: propagation delay.
Hidden node situation: two transmitters cannot hear each other and their transmission overlap at a receiver.
Request-to-Send and Clear-to-Send
Before sending a packet, a station first sends a RTS.
The receiving station responds with a CTS.
RTS and CTS are smaller than data packets.
RTS and CTS use shorter IFS to guarantee access.
Stations that hear either the RTS or the CTS “remember” that the medium will be busy for the duration of the transmission.
Based on a Duration ID in the RTS and CTS.
Virtual Carrier Sensing: stations maintain Network Allocation Vector (NAV).
Time that must elapse before a station can sample channel for idle status.
RTS/CTS: NAV
NAV: Network Allocation Vector.
NAV acts as a distributed (in each node) resource allocation register.
RTS/CTS.
Not a “major” concern.
Synchronization
Timing synchronization function (TSF).
Beacons of the AP are sent in well-defined instants.
Content of packet is the exact instant when it goes to the network.
Used also for power management.
All clocks of all stations ins the BSS are synchronized.
This allows STA to wake-up to check if packets exist.
Last updated