Page 251 - Hacking Roomba
P. 251
232 Part III — More Complex Interfacing
Understanding Wi-Fi
In everyday use, Wi-Fi is wireless Internet connectivity. More specifically, Wi-Fi is a market-
ing term for a class of wireless IEEE standards for connecting computers in an Ethernet-like
way via microwave radio transceivers. The most common of these standards are:
802.11a: Up to 54 Mbps data rate on the 5 GHz unlicensed ISM band
802.11b: Up to 11 Mbps data rate on the 2.4 GHz unlicensed ISM band
802.11g: Up to 54 Mbps data rate on the 2.4 GHz unlicensed ISM band
These are all updates to the original 802.11 standard, which had a maximum data rate of
2 Mbps on the 2.4 GHz band. There’s a new standard emerging called 802.11n that promises
speeds up to 540 Mbps.
The 2.4 GHz and 5 GHz radio bands are unlicensed, meaning that you do not need a permit
to operate a radio transmitter on these frequencies. These frequencies are two of the several
industrial, scientific, and medical (ISM) bands that have this freedom. Bluetooth is also in the
2.4 GHz band, as are microwave ovens, cordless phones, wireless video cameras, home automa-
tion protocols, and just about anything else you can think of. It’s a noisy region, but engineers
have found ways to sidestep most of it. Of course, if you have an old-style 2.4 GHz cordless
phone, chances are it’ll cause your Wi-Fi to go down when you use it.
Sometimes the Wi-Fi standards are called Wireless Ethernet, and this is a very apt description.
The designers of Wi-Fi wanted the same sort of simple connectivity and configuration that
Ethernet affords.To connect to an Ethernet network, you simply plug in a cable.To disconnect,
you unplug the cable. The hardware and software attached to the cable automatically figure out
the details of setting up and tearing down pathways for data. To arbitrarily connect and discon-
nect was quite a novel concept when Ethernet was invented, but we’ve come to expect it in every
communication bus we use. Wireless Ethernet works in almost the same way, but actually a bit
better. Figure 12-1 shows typical wired and wireless networks, showing their topological simi-
larity from the users’ perspective. In both cases there’s a resource shared by multiple computers.
In the wired case it’s the Ethernet hub; with wireless it’s the access point. Often the functional-
ity of hub + router and access point + router (or all three) are combined into a single unit.
The problem on a cable that people experience is the same as when they use walkie-talkies or
CBs: No two people can talk at the same time. A CB channel may have many people partici-
pating, but that problem is dealt with by using a protocol of adding “breaker,” “over,” and
“out” to conversations. Ethernet solves the problem in a similar way with a technique called
CSMA/CD: Carrier-sense multiple access with collision detection. This sounds complex, but
you intuitively know how it works. Carrier sense means listen for others before talking. Mutiple
access means there are more than just two devices on the wire. Collision detect means if someone
starts talking at the same time as you, stop and wait a bit before trying again. It’s a simple and
elegant solution.