Please Power Down
“All you bloggers need to turn off your base stations,” an increasingly annoyed Steve Jobs told the crowd at the June 2010 iPhone 4 demo. “If you want to see the demos, shut off your laptops, turn off all these MiFi base stations, and put them on the floor, please.”
In a crowd of 5000 people, roughly 500 Wi-Fi devices were active. It was the wireless apocalypse, and not even a fleet of Silicon Valley’s finest backstage engineers could do a thing about it.
If this example of 802.11 extremity sounds inapplicable to your everyday world, refer back to August 2009, when Tom’s Hardware took its first look at Ruckus Wireless's beamforming technology in Beamforming: The Best WiFi You’ve Never Seen. In that story, we introduced the concepts of beamforming and examined some competitive test results in a big office environment. As enlightening as this was at the time, there is clearly much more of the tale to be told.
This literally came home to me a few months ago after setting up a nettop for my children and using a dual-spectrum (2.4 GHz and 5.0 GHz) Linksys 802.11n USB dongle to connect to my Cisco small business-class 802.11n access point. The wireless performance was horrific. We couldn’t even stream YouTube videos. I assumed the problem was the nettop’s feeble processing and graphics capabilities. One day, I tried substituting the 7811 wireless bridge kit from that previous piece. The difference was instantaneous, and video looked perfectly fluid. It was as if I had plugged in a wired Ethernet connection.
What was going on here? I wasn’t in an auditorium filled with 500 live bloggers crushing my connection. I was using supposedly best-of-breed small business Cisco/Linksys gear that I’d personally tested and knew had higher performance than most competing brands. It wasn’t enough to have switched to the Ruckus-based wireless bridge. That left too many unanswered questions. Why was one product performing better than the other? Why had editor Chris Angelini himself observed in our original article that not only did the up-close proximity between his client and the access point impact performance but so did the shape of the AP itself?
Six months ago, Ruckus tried to set up a test scenario to help us answer those unanswered questions through analysis of RF interference on Wi-Fi performance, but just before the tests were set to begin, the company halted its experiment. Engineers had set up RF noise generators and sample client machines, but a test result measurement taken one minute would come back two minutes later with numbers that were wildly different. Even averaging a set of five results in a given location would be meaningless. This is why you never see real-world interference studies done in the press. It’s so hard to control the environment and the variables that testing is effectively impossible. Vendors can spout all of the performance numbers they like from optimally-configured testing done in RF isolation chambers, but those statistics are meaningless out in the real world.
Frankly, we've never seen these issues explained and explored before, so we chose to pick up the reins, shed some light on Wi-Fi performance, and expose its inner mysteries. This is not going to be a short trip. We have a lot of ground to cover, which is why we’re going to break the story into two pieces. Today, we’ll be exploring the theoretical aspects (how Wi-Fi works at the data and hardware levels). Then we’ll proceed to put this theory to the test in the most extreme wireless environment we’ve ever encountered, which includes 60 notebooks and nine tablets all pounding a single access point. Whose technology will stand up and whose will crumble and cry for mercy? By the time we’re done, you’ll not only have the answer, but you’ll understand why we saw those results and how the technologies behind those results work.
Hang on tight. It’s going to get a bit congested in here.
Congestion Vs. Contention
We normally use the word “congestion” when describing wireless traffic overload situations, but, when you get down into the networking nitty-gritty, congestion doesn’t really mean anything. The better term is “contention.” Packets must contend with each other for permission to send and receive during open opportunities, like gaps in traffic. Remember that Wi-Fi is a half-duplex technology, so at any given moment, only one device on a channel can transmit, either the AP or one of its clients. The more devices on a wireless LAN, the more important contention management becomes, as many clients compete for airtime.
Given the ever-increasing proliferation of Wi-Fi networks, exactly who gets to transmit, and when, is hugely important. There is only one rule: whoever talks into silence wins. If no one else is trying to transmit when you do, then you get to talk unhindered. But if two or more clients try to talk at the same time, you have a problem. It’s like talking to your buddy with a walkie-talkie. When you talk, your friend has to wait and listen. If you both try to talk at the same time, neither one of you will be heard. To communicate with each other effectively, the two of you must manage your airtime access and contention. This is why you say something like “over” when you’re done talking. You signal that the air is free for someone else to talk.
If you’ve ever taken walkie-talkies on a trip, you may have noticed there were only a few available channels—and lots of other people who had the same idea. Especially in the days before cheap cell phones, it felt like everybody was on walkie-talkies. You and your friend might not talk over each other, but that still left every other walkie-talkie user near you who happened to be using the same channel. Every time you wanted to get a word in, someone would already be on your channel, forcing you to wait...and wait...and wait.
This kind of interference is called “co-channel” interference, wherein interferers clog your channel. To get around the problem, you can try moving to another channel, but if nothing better is available, you're stuck with very, very slow communication speeds. You only get to transmit when all of those longwinded so-and-sos around you all have a rare moment of silence. You might only want to say one small thing, like “Holy cow, co-channel interference bites!” But you might have to wait 15 minutes for an opening in which make your quick, pithy statement.
Compounding the co-channel problem is the fact that Wi-Fi traffic flow is never smooth. We have radio frequency (RF) interference randomly interjecting itself into packet paths, striking anywhere at any time for any duration. Interference can come from a wide variety of sources, everything from cosmic rays to competing Wi-Fi networks. For example, microwave ovens and cordless phones are notorious offenders for the 2.4 GHz Wi-Fi spectrum.
To illustrate, imagine you’re playing Hot Wheels cars with a friend, and each car that you shove across the floor to your friend represents a packet. Interference is like your little brother playing marbles with his friend across your line of traffic. A marble might not hit your Hot Wheels rig at any given time, but eventually you will get nailed. When a collision does happen, you have to stop what you’re doing, take the car that got hit back to the starting line, and try sending it again. And just to be a brat, your little brother doesn’t always use marbles. Sometimes he sends in a beach ball or a dog.
Effective wireless networking is all about managing the Wi-Fi or RF spectrum—getting the user on and off the wireless road as quickly as possible. How do you get your Hot Wheels to travel faster and aim more accurately? How do you get more cars passed back and forth and ignore your little brother’s feeble efforts to interfere with your day? Therein lies the secret sauce of wireless networking vendors.
The Difference Between Wi-Fi Traffic And Interference
We’ll come back to this in a bit, but understand up front that the 802.11 standard does many things to regulate how packets get handled. Again, take an automotive metaphor. When you drive a car onto the road, you have lanes, speed laws, and other rules that govern how your car should behave within certain parameters. But if your great grandmother with her Coke bottle glasses and Lawrence Welk eight-track plods down the interstate doing 35 in a 65, the other drivers will get upset and honk. Traffic slows down. But everyone keeps driving, even if at a reduced speed.
This is analogous to what happens when your neighbor’s Wi-Fi traffic enters your own wireless LAN. Because all of the traffic is 802.11, all packets are governed by the same rules. That unwanted traffic gets in your way and slows down overall packet flow, but it doesn’t have the same impact as microwave oven emissions, which play by no rules and simply plow across the various Wi-Fi traffic lanes (channels) like a line of suicidal pedestrians.
Obviously, the relative impact of RF noise in Wi-Fi’s 2.4 or 5.0 GHz ranges is worse than that of competing WLAN traffic, but one of the objects in improving performance is mitigating both. As we’ll see, there are many ways to do this. For now, just keep in mind that all of this competing traffic and interference ultimately becomes background noise. A packet stream that starts out strong at -30 dB will ultimately fade to -100 dB and less over distance. Such levels are far too low to be intelligible to an access point, but it can still disrupt traffic, just like that old lady in the Coke bottle glasses.
All’s Fair In War And Airtime
Let’s talk about how access points (including the access points buried in routers) administer traffic rules. Consider your typical two-lane freeway onramp. You have cars lined up in each lane, and each lane has a stop/go light timed to regulate how traffic enters the main roadway. Each green light lasts for, say, five seconds.
Wi-Fi tweaks this idea slightly with a process called airtime fairness. The access point assesses the number of client devices present and assigns equal time blocks for each device, as if a camera overlooking the onramp could judge the amount of backed up traffic and use that information to decide how long each green light should last. As long as the light is green, cars can keep moving from that onramp into traffic. When the light turns red, that onramp lane stops and the next lane turns green.
Now say we have three lanes in that onramp, one each for 802.11b, 11g, and 11n. Obviously, the packets travel at different speeds, like one lane being for zippy sports cars and another for slow 18-wheelers. You’re going to get more fast packets than slow packets into traffic during a given time period.
Without airtime fairness, traffic sinks to the lowest common denominator. All vehicles line up in one lane, and if a fast car (11n) gets stuck behind a semi (11b), the whole chain slows down to the semi’s speed. This is why, if you’ve done much traffic analysis with consumer routers and APs, you find that performance can tank when you bring an old 11b device onto an 11n network, which is why many APs feature an “11n only” mode. Doing this, of course, forces the AP to ignore the slower device. Unfortunately, most consumer Wi-Fi products do not yet support airtime fairness. This is an increasingly common feature in the enterprise world that will hopefully trickle down to the masses soon.
When Bad Things Happen To Good Packets
Enough about cars. Let’s look at packets and interference in a slightly different way. As said before, interference can strike at any time and last for any amount of time. You see this in the following page’s image with its blue bars, which represent interference. When interference strikes a data packet, the packet becomes corrupted and must be resent, causing latencies and increasing total send time.
When we say we want faster wireless performance, that largely means we want our packets to get from the AP to the client (or vice versa) more quickly. To make this possible, APs tend to use any or all of three tactics: lowering the PHY data rate, lowering transmit power (Tx), and changing the radio channel.
The PHY rate is like a speed limit sign (really, I am trying to back off the car thing). It’s the theoretical data rate at which traffic is supposed to move. When your wireless client says you’ve connected at 54 Mb/s, you’re not actually moving packets at that rate; it’s only the approved speed level at which the access point and client hardware are interoperating. What happens to packets and the real-world performance rates realized after that negotiation remains to be seen.
PHY Rate, Continued
When interference slams into a Wi-Fi stream and starts resulting in packet resends, the access point may opt to lower the PHY rate. This is akin to talking more slowly to someone who doesn’t speak your language fluently, and in the wired networking world, it works pretty well. But take another look at the image to the left. We had a packet that had been previously running at the 150 Mb/s PHY rate get resent at 25 Mb/s. In the face of sporadic interference, what happens to the likelihood that our packet will get hit with another interference blast? It increases, right? The longer a packet is in the air, the higher the probability that it will get hit. So yes, the technique of dropping PHY rates that worked so well in the wired world now becomes a liability with wireless. To make matters worse, lower PHY rates make Wi-Fi channel bonding (in which two channels in a 2.4 or 5.0 GHz band are used in tandem for higher bandwidth) much more difficult because there’s a higher risk of the respective streams working at different rates.
The incredible and sad thing is that the practice of dropping PHY rates in the face of interference is pervasive. Nearly every vendor does it, despite the fact that doing so is counterproductive to performance. It’s as if all of the vendors are facing this rising tide of RF interference, scratching their heads, and muttering, “well, we just don’t know what else to do!”
In a way, wireless networking is just a big shouting match. Imagine you’re at a dinner party. It’s 6:00, and only a few people have shown up. They’re mulling about, chatting quietly. You can hear the whisper and rumble of the room’s air conditioner. Your partner approaches you, and the two of you have no trouble carrying on a conversation. The host’s four-year-old wanders up to you and starts singing the theme to Sesame Street. But even with those three sources of interference, you and your partner have no trouble understanding each other, in part because your partner was raised in a huge family and talks like a bullhorn.
In this example, the sounds of other people chatting and the air conditioning are the “noise floor.” It’s always there, always at that volume. When we talk about how much noise interferes with your conversation, we discount the noise floor. It’s like putting the tray on a food scale and then hitting the button to zero the weight readout. The scale's tray and background noise are constants, just like the background RF noise present all around us. Every environment has its own noise floor.
However, the kid and his Big Bird homage are interference. With a partner speaking loudly, you can still converse effectively, but what happens when a soft-spoken friend walks up and joins the discussion? You find yourself casting annoyed glances at the (previously charming) toddler and asking “what?” to your new conversation mate.
Now consider our graphic. Against a background RF noise floor, we have a cordless phone generating interference measuring -77 dB at our client device’s location. This is our singing four-year-old. If you have a soft-spoken access point that only transmits a -70 dB signal, this is strong enough to be “heard” by the client above the interference, but not by much. The difference between the noise floor and the receive (listening) signal is only 7 dB. However, if we have an access point that broadcasts more loudly, say at -60 dB, then we have a much more generous 17 dB difference between the interference and receive signal. When you can comfortably hear someone, the conversation flows much more effectively than when you can barely make out what someone is saying. Moreover, consider what happens when another four-year-old shows up singing Lady Gaga. The two kids combined will probably swamp your soft-spoken friend, while your more voluble partner is still intelligible.
Say What? Say SINR!
In the radio world, the range from the noise floor to the receive signal is the signal-to-noise ratio (SNR). This is what you see printed on practically every access point, but it’s not really what you care about. It’s the gap from the top of the interference to the receive signal, the signal-to-noise+interference (SINR) measurement, that matters. It’s not that you can ever know in advance what a product’s SINR will be, because you can’t know the level of interference at a given time and place until you measure it. But you can get a sense of a specific environment’s average interference level. And with this, you’ll have a better idea what sort of signal strength an access point needs to maintain in order to function dependably.
Knowing this, you may ask, “why on earth would anyone lower the transmit signal strength (Tx) in the face of interference?” Good question, because it’s one of the three common responses to packet resends. The answer is that dropping Tx power condenses an AP’s zone of coverage. If you have an interference source on the outer edge of your coverage area, effectively eliminating that source from the AP’s awareness frees the AP from having to try and cope with the problem. Assuming that the client is within the reduced coverage zone, this can help significantly decrease co-channel interference and improve total performance. However, if your client is also on the outer range of the AP’s coverage (as with Client 1 in our illustration), then it just dropped off the map. Even in the best case, the transmit power drop just whacked out a big chunk of your SINR and left you more open to impaired data rates.
So Many Channels, So Little To Watch
As we’ve seen, the first two common approaches for dealing with interference are lowering the PHY rate and lowering power. The third approach is one we touched on in the walkie-talkie example: change the wireless channel, which in effect changes the frequency on which the signal is being carried. This is the key idea behind spread spectrum technology, or frequency hopping, which was invented by Nikola Tesla at the turn of the 20th century and gained notable military use during World War II. In one instance, famous and beautiful actress Hedy Lamarr helped invent a frequency hopping approach to thwart enemy jamming of radio-controlled torpedoes. When frequency hopping is employed over a wider range of frequencies than that on which the signal is normally carried, this is known as spread spectrum.
Wi-Fi uses spread spectrum technology primarily to improve bandwidth, reliability, and security. As anyone who’s ever been under the hood of his or her Wi-Fi settings knows, the 2.4 to 2.4835 GHz band has 11 channels. However, because the total bandwidth used for 2.4 GHz Wi-Fi spread spectrum is 22 MHz, you get overlapping between these channels. In reality, you only have three channels in North America—1, 6, and 11—which will not overlap. Europe can use channels 1, 5, 9, and 13. If you’re using 2.4 GHz 802.11n with a “bonded” 40 MHz channel width, your options shrink to only two: channels 3 and 11.
In the 5 GHz range, things improve somewhat. Here, we have eight non-overlapping indoor channels (36, 40, 44, 48, 52, 56, 60, and 64.) Higher-end access points usually integrate both 2.4 GHz and 5.0 GHz radios, and the correct assumption is that there is less interference on the 5.0 GHz band. Just getting rid of 2.4 GHz Bluetooth interference can make a difference. Unfortunately, the end result is inevitable: the 5.0 GHz spectrum is now filling up with traffic, just as the 2.4 GHz spectrum did. With 40 MHz channel bonding used in 802.11n, the number of non-overlapping channels shrinks to just four (dynamic frequency selection, or DFS, channels are excluded due to military worries about conflicting with radar signals), and users are already finding times when there isn’t a decently open channel within range. It’s like having more channels of TV to watch all day but still nothing on except personal hygiene commercials. Nobody wants to see that.