Sub topic 7
Dynamic Frequency Selection on 5 GHz
This chapter assumes you know that the 5 GHz band is split into 20 MHz channels with numbers such as 36, 52, 100 and 149, and that channels can be bonded into 40, 80 or 160 MHz widths. It explains why some of those channels come with extra rules, what an access point (AP) does on them, and how that affects your channel choices.
Why DFS exists
The 5 GHz band is unlicensed, but Wi-Fi is not its only user. Part of it is shared with radar: weather radar, military radar, and in some regions airport radar. Regulators allow Wi-Fi in those sub-bands only if it yields to radar. Dynamic Frequency Selection (DFS) is the set of rules and mechanisms that makes an AP detect radar pulses and leave the channel.
DFS is mandatory in the regulatory domains that allow these channels. It is not a vendor option. Which channels need it depends on the domain, so check the rules for the country where the AP runs.
Which channels are affected
In most domains the 5 GHz channels fall into four groups. The names UNII-1 to UNII-3 come from the US FCC.
| Group | 20 MHz channels | Frequency range (MHz) | DFS required |
|---|---|---|---|
| UNII-1 | 36, 40, 44, 48 | 5150–5250 | No |
| UNII-2A | 52, 56, 60, 64 | 5250–5350 | Yes |
| UNII-2C | 100 to 144 | 5470–5725 | Yes |
| UNII-3 | 149 to 165 | 5725–5850 | No |
Channels 52 to 144 are therefore the DFS channels. Channel 120, 124 and 128 (5600 to 5650 MHz) cover a weather radar band. Regulators treat them more strictly, and some regions require a much longer wait before use.
A wide channel needs DFS if any of its 20 MHz parts is a DFS channel. An 80 MHz channel at 36 to 48 avoids DFS. A 160 MHz channel at 36 to 64 does not, because it includes 52 to 64.
What an AP does
An AP on a DFS channel follows three steps.
- Channel availability check (CAC). Before transmitting on a DFS channel, the AP listens for 60 seconds. The AP sends no beacons during this time, so no client can see the network. In the European weather radar band, the check lasts 10 minutes.
- In-service monitoring. While operating, the AP keeps looking for radar pulses between and during frames.
- Vacating. If it detects radar, the AP must stop using the channel within a short move time, about 10 seconds in the usual rules. It then cannot use that channel for a non-occupancy period of 30 minutes. It usually announces a move to a new channel in its beacons with a channel switch announcement, so that clients can follow.
Consequences for clients
A client cannot probe actively on a DFS channel, because transmitting a probe request would break the rule that only a verified AP may start transmission there. Clients scan these channels passively and wait for beacons. This makes discovery slower. It also means a device that does not support DFS channels never sees an AP that sits on one. Some older phones and IoT devices behave this way. If one device cannot find your 5 GHz network, check whether the AP is on a DFS channel.
When the AP leaves a channel because of radar, clients lose the link. Clients that handle the channel switch announcement reconnect quickly. Others need a full scan and association, which can take several seconds.
Checking whether a channel needs DFS
This Python function applies the table above for 20, 80 and 160 MHz widths. It treats a wide channel as DFS if any 20 MHz part is in 52 to 144.
# First 20 MHz channel of each bonded block, for the 5 GHz band
BLOCK_STARTS = {
20: None, # any single channel
80: (36, 52, 100, 116, 132, 149),
160: (36, 100),
}
def subchannels(primary, width):
"""Return the 20 MHz channel numbers covered by a 5 GHz channel."""
if width not in BLOCK_STARTS:
raise ValueError(f"unsupported width {width}")
if width == 20:
return [primary]
span = (width // 20 - 1) * 4 # distance from first to last channel number
for start in BLOCK_STARTS[width]:
if start <= primary <= start + span:
return list(range(start, start + span + 1, 4))
raise ValueError(f"channel {primary} is not in a {width} MHz block")
def uses_dfs(primary, width):
return any(52 <= ch <= 144 for ch in subchannels(primary, width))
print(uses_dfs(36, 20)) # False
print(uses_dfs(52, 20)) # True
print(uses_dfs(36, 80)) # False
print(uses_dfs(100, 80)) # True
print(uses_dfs(149, 80)) # False
print(uses_dfs(36, 160)) # TrueOn Linux you can see the radar state of channels with iw. Channels marked as radar detection or no-IR are DFS or passive-only channels.
# List channels with their regulatory flags, such as "radar detection"
iw phy phy0 channelsDecision criteria
DFS channels are attractive because they add many extra channels. On a 5 GHz band with only UNII-1 and UNII-3, an 80 MHz plan has just two non-overlapping channels. With DFS, it has six.
The cost is risk. Use the following guide.
- Dense apartment or office: use DFS channels. The non-DFS channels are crowded, and radar is rarely nearby.
- Near an airport, weather station or coast with ship radar: expect repeated radar events. Prefer non-DFS channels, or use narrower widths there.
- Many legacy or IoT clients: keep the network on UNII-1 or UNII-3.
- Voice or other latency-sensitive traffic: avoid DFS. A radar event interrupts the link for seconds.
- Hardware with background CAC: some APs check another channel while operating, so a move after a radar event is immediate. This is sometimes called zero-wait DFS.
False positives happen. Some other transmitters produce signals that look like radar pulses to the AP. If your AP log shows frequent radar events with no known radar source, move to a different channel group.
Exercise
An AP is set to channel 100 with an 80 MHz width. A user's older tablet cannot see the 5 GHz network, but a recent laptop can. Name two facts about DFS that could explain this, and give a change that would likely fix it.
Show answer
Channel 100 at 80 MHz covers channels 100 to 112, which are DFS channels. Clients scan DFS channels passively, and a device that does not support DFS channels never connects to an AP there. Moving the AP to a non-DFS channel, such as 36 or 149 at 80 MHz, would likely let the tablet see the network.