Silicon ChipGetting Into WiFi, Pt.2 - June 2005 SILICON CHIP
  1. Outer Front Cover
  2. Contents
  3. Publisher's Letter: Photocopying is a huge cost to Silicon Chip
  4. Feature: Looking At Laptops by Ross Tester
  5. Feature: Getting Into WiFi, Pt.2 by Ross Tester
  6. Project: The Mesmeriser: A LED Clock With A Difference by Scott Melling
  7. Project: The Coolmaster Fridge/Freezer Temperature Controller by Jim Rowe
  8. Salvage It: A voltmeter for almost nothing by Julian Edgar
  9. Project: Alternative Power Regulator by Ross Tester
  10. Project: PICAXE Colour Recognition System by Clive Seager
  11. Feature: PICAXE In Schools, Pt.2 by Clive Seager
  12. Project: AVR200 Single Board Computer, Pt.1 by Ed Schoell
  13. Vintage Radio: Signal Generators: what they are and how to fix them by Rodney Champness
  14. Book Store
  15. Advertising Index
  16. Outer Back Cover

This is only a preview of the June 2005 issue of Silicon Chip.

You can view 39 of the 112 pages in the full issue, including the advertisments.

For full access, purchase the issue for $10.00 or subscribe for access to the latest issues.

Articles in this series:
  • Getting into Wi-Fi (May 2005)
  • Getting into Wi-Fi (May 2005)
  • Getting Into WiFi, Pt.2 (June 2005)
  • Getting Into WiFi, Pt.2 (June 2005)
  • Getting Into WiFi, Pt.3 (July 2005)
  • Getting Into WiFi, Pt.3 (July 2005)
Items relevant to "The Coolmaster Fridge/Freezer Temperature Controller":
  • Coolmaster PCB pattern (PDF download) [10108051] (Free)
  • Coolmaster front panel artwork (PDF download) (Free)
Items relevant to "PICAXE Colour Recognition System":
  • PICAXE-08M BASIC source code for the PICAXE Colour Recognition System (Software, Free)
Items relevant to "PICAXE In Schools, Pt.2":
  • PICAXE-08M BASIC source code for "PICAXE in Schools", part 2 (Software, Free)
Articles in this series:
  • What’s this? Free PC Boards for Schools? (May 2005)
  • What’s this? Free PC Boards for Schools? (May 2005)
  • PICAXE In Schools, Pt.2 (June 2005)
  • PICAXE In Schools, Pt.2 (June 2005)
  • PICAXE In Schools, Pt.3 (July 2005)
  • PICAXE In Schools, Pt.3 (July 2005)
  • PICAXE In Schools, Pt.4 (September 2005)
  • PICAXE In Schools, Pt.4 (September 2005)
  • PICAXE In Schools; Pt.5 (November 2005)
  • PICAXE In Schools; Pt.5 (November 2005)
Articles in this series:
  • AVR200 Single Board Computer, Pt.1 (June 2005)
  • AVR200 Single Board Computer, Pt.1 (June 2005)
  • AVR200 Single Board Computer, Pt.2 (July 2005)
  • AVR200 Single Board Computer, Pt.2 (July 2005)

Purchase a printed copy of this issue for $10.00.

GETTING INTO Part 2: setting up an ad-hoc wireless network by Ross Tester With WiFi hardware prices way down and Windows XP virtually doing it all for you, there’s no excuse not to set up a wireless network at home or in the office. The simplest network of all is the ad-hoc network. I n our introduction to practical WiFi last month we looked at the differences between the various wireless networking standards. Fortunately, setting up the two most popular, 802.11b and 802.11g, is pretty much identical. All you have to do is decide which type of wireless network you require. However, there is more to 802.11g than simply faster speed. They also (usually!) offer higher performance than 802.11b (see separate panel, “It’s more than just speed”). To briefly recap, there are two types of basic wireless networking: ad-hoc and infrastructure. For either type, for each computer to be connected to the wireless network you’ll need a Wireless Network Adaptor (they’re also known by a variety of other names, such as a Wireless NIC, or network interface card; Wireless Dongle, Wireless Card and so on). Many computers these days, especially newer laptops, come with the adaptor built in. But even many motherboards today offer integrated 802.11g facilities. If all you want to do is share files between computers, perhaps print a document on one computer via a printer attached to another, that’s all the hardware you will need. It’s called an ad-hoc network. It’s also sometimes called a peer-to-peer or computer-to-computer network. If you want to use your wireless network for more advanced tasks – to connect to the internet or to another network, for example – an infrastructure network may be required. And for that, you need another piece of hardware called an access point (AP). (Again as we said last month, access points can be entirely software – see separate panel, “SoftAPs”). And just to clarify one thing: just now (and last month) 14  Silicon Chip we said that if you want to connect to the internet, you may need an infrastructure network. We also said last month that Windows XP takes much of the hard work out of setting up any form of network (including wireless). Well, Windows XP goes even further than simplifying connection. It also allows you, via the “Sharing a Connection” option, to connect to the internet using an ad-hoc network. The steps are explained elsewhere but it is quite simple. Client, server, host, peer-to-peer . . . Before we get too much further, there are a couple of terms which you will find again and again so we should explain them. We just mentioned a couple of them – peer to peer (which simply means that the routing for the data is taken care of by the computers themselves, not by other hardware). The other terms you’ll often come across are “client” and “host”. Usually, a client is simply the user’s computer which accesses remote services on another, perhaps more powerful, computer. That computer is often referred to as the “host” but can also be known as a “server”. The name comes from the days when PCs were not as powerful as they are today. Organisations usually had one larger, faster, more powerful computer which handled most of the data manipulation – it was known as a server – and the computers which were networked to it relied on it for some, or most, or all, of their operation. In fact, often they weren’t really computers at all; they were dumb terminals which relied totally on the server to do all their “thinking” for them. There were also “print servers” whose sole (or main) job was to drive the printers siliconchip.com.au of the day. The term stuck when these new-fangled personal computers came on the scene! Think of the “host” as the main computer in your network. If you have an internet connection, it will be the computer which has that connection. Think of the “clients” as all the other computers. Why are we mentioning this here? Just to save confusion later . . . Setting up an ad-hoc wireless network The first thing to do when setting up any network – wired or wireless – is to draw a diagram of it. Here’s a tip: use a drawing program on your PC to do it – that way you will have it in the future if you need to refer to it. Yes, you do have a drawing program – “Paint” is more than adequate for the task. Of course, higher level programs will do even better. Give your network a name – a bland name which won’t arouse much suspicion if it is cracked is best – but write it down so that you remember it when it comes to adding the other computers to the network. This name can be something familiar, such as “johns network” – but it’s not wise to use your address (you may end up with more than bandwidth burglars!). As shown in the diagram published last month, an ad-hoc network has each of the computers directly talking to each other. There is no “intermediary” access point as there is in an infrastructure network . The first computer is assumed to be the “host” computer, with all others the “clients”. You need to set up the host computer first. XP or install disk? There are two ways to set up the ad hoc network. One, the way explained here, is to let Windows XP do it for you. It’s quite simple and Windows tries pretty hard to stop you making a mistake. The second way is to use the installation software provided with your wireless adaptor. Some wireless adaptors are pretty specific about NOT using Windows to set it up, probably because the installation program also loads its own drivers and perhaps proprietary software to give more features than Windows. One of the wireless adaptors we obtained from Dick Smith Electronics (NZ) came with a warning to use the installation disk, not Windows. Being the ornery types we are, we tried it both ways on different computers. Guess which method of the two didn’t work? (In fact, the Windows method caused us all sorts of grief which took some time to work through). It’s up to you: if the card documentation specifically warns you about using Windows, we’d probably go with that documentation. If it is non-committal or doesn’t even mention it, we’d go with Windows. 802.11b vs 802.11g – Stan shows it may be more than just speed! Last month, we stated that 802.11“g” offers significant speed advantages over the older 802.11“b” standard – a raw throughput of 54Mbps versus 11Mbps – as well as some advantages in the way it handles the packets of data. But there is even more to it than that. Following further experimentation with USB “b” and “g” adaptors, it is apparent that at least the “g” devices I’ve tried also offer superior weak signal reception. Compare the Netstumbler* graphs below. A Genius GW-7200U “g” (~AU$50) showed about 10dB better signal levels, from an obscured acess point (AP) 100m away, when trialled beside a classic DSE Zydas “b”. When placed at the focal point of a 300mm cookware parabola (see “WiFry”, SILICON CHIP, September 2004) and directed over NZ’s Wellington harbour, the USB Genius “g” later found many previously undetected APs (at approximately -80dBi) some 10km line-of-sight (LOS) away as well. However, the limiting factor now looks to be one’s weak outgoing signal (the Genius is only 16dBm or 40mW), meaning powerful remote access points may be heard but NOT connected to. Argh! Just because you can detect them (via Netstumbler etc) doesn’t mean they can hear YOU, since their reach is greater than yours. Either a costly (and possibly illegal) transmitter booster would now be needed, or improved focusing for your weak outgoing signal via a higher gain antenna. * Netstumbler www.netstumbler.com is invaluable for adaptor testing, AP detection, site coverate auditing and even antenna tweaking, while the Pocket PC “WiFiFoFum” (WFFF) www. aspecto-software.com/WiFiFoFum/ also allows more convenient compact PDA-based monitoring. Both are free downloads. The Windows XP route Turn the computer off and install the wireless adaptor, what ever its incarnation (USB dongle, PC card, etc for a laptop or desktop, internal wireless card for a desktop, etc). Turn the computer on and Windows XP will automatically detect the card and install its drivers. In some cases, Windows might not be able to find the drivers but unless you’ve acquired the card from a dubious source, it will come siliconchip.com.au Using Netstumbler to compare the “Genius” GW7200U WiFi adaptor (“g”) with the Zydas (“b”), with and without the “WiFry” parabolic scoop reflector. They’re looking at the same access point, about 100m away, through trees and buildings. Although the scoop gives around the same gain (~15dB) with each USB adaptor, the (newer) “g” dongle is showing far superior weak-signal performance (and therefore range?). June 2005  15 Fig.1: this computer has accessed a variety of wireless networks in the past – hence the list. Notice the little red “X” through the icon. That means it can’t find them at the moment. Fig.3: now we’re adding the new wireless network – it’s called “Ford Prefect”. At the moment, we’ve disabled encryption to make sure the network gets up and running without hassles. with drivers (usually on a CD). The computer will then look for wireless networks in range and if it finds any, automatically display a list of them in a box called “Wireless Network Connection Properties”. If, by chance, it does display them, don’t connect to any of them – you want it to connect to YOUR wireless network, not someone else’s! We’ll assume that there are no wireless networks in your neighbourhood, so it won’t find any. The “Preferred networks” field should be blank. If your computer previously connected to a nearby wireless network (eg, somewhere else!), make sure you disconnect it (use the disconnect tab). Previously found networks will almost certainly be listed but if they aren’t in range, there should be a small red cross through their symbol, as shown above. Now click on the “Advanced” tab (top of window). Select “computer to computer (ad hoc) networks only, and if the “automatically connect to non-preferred networks” box is ticked, untick it (again, to make sure you connect to your ad hoc network). Now click on the “Wireless Networks” tab again. See the “add” box down below. Click it and type in your network name (the one you wrote down before) in the box marked Network name (SSID). SSID stands for Service Set Identifier – and now that you know that, forget it. Just think of Fig.2: we want this to be an ad hoc (ie, computer-tocomputer) network. Here’s where we select this option. Fig.4: and then we can see that not only is the “Ford Prefect” network available, “320-nile” is also there. But it’s protected. 16  Silicon Chip siliconchip.com.au Fig.5: one of the easiest ways to check that the network is working is to check that packets are received as well as sent. That means another computer can talk to yours. SSID as meaning network name! Just for the moment (and only for the moment!) we’re not going to turn WEP on just yet. Despite our dire warnings last month, it does add one more thing to go wrong when setting up the network. So until we have everything working, leave it off. Your host computer installation is now complete. The SSID should now be displayed in the “Preferred networks” field. But there will be a red “X” displayed, telling you that there are no other computers (yet!) in the wireless network within range. Setting up the client computer Basically, it’s just a matter of repeating the above steps for each computer you want to add to your ad hoc network. The main difference is that you don’t need to put in the SSID because when the two computers are in wireless range, the SSID should automatically come up in the “available networks” window. Select configure, turn off WEP and you should find that the computers can talk to each other. It really is that simple! Turn WEP (or preferably WPA) on . . . Now that it’s all working, it’s time to go back and turn WEP (Wired Equivalent Privacy) on. As we said last month, WEP stops the casual snooper from getting into your system and either using your bandwidth or perhaps doing something nasty. WPA (WiFi Protected Access) is much more robust and, if your hardware will allow it, WPA is much preferred. If using WEP, starting with the host computer, click on the Wireless Network Properties tab and click on “Data encryption (WEP enabled)”. siliconchip.com.au Most modern wireless adaptors support 128-bit encryption – the more bits, the harder it is to break. Older adaptors may only support 64-bit – Windows XP will automatically detect this in most cases and not let you enter 128-bit. Your network key ideally should consist of random letters and numbers (some setups do allow plain English which is then used to generate a key). Don’t be tempted to use birthdays or addresses – you want something that cannot be guessed. And remember to write it down somewhere – on your network plan, for example? Repeat the setup for all computers on the network Remember that if you get a key wrong, the computer will not be able to talk to the others. As mentioned, WPA is definitely preferred – use it if you can. It’s a lot more difficult to hack (vital if using the net for business and/or finance) and has plain word generation of the encryption key. A salutory warning Remember last month I mentioned that I was sharing internet access with my next-door neightbour? A couple of weeks ago, my computer started grabbing a completely unprotected wireless network, giving me full broadband access. At first I thought my neighbour’s AP had somehow reset itself without WEP – but no, it all checked out properly. A few days later, when talking to my neighbour on the other side I asked if he had recently installed a WiFi network. He looked at me as if I had two heads, both speaking Swahili – so I took that as a “no”. But his son, who was listening in, sheepishly said “Umm, yeah, I have . . .” June 2005  17 Fig.6: here’s where you turn on your Windows firewall (essential!) and allow other computers internet access via the Internet Connection Sharing check box. SoftAPs – Winmodems all over again? Need to link several WiFi users with a barebones budget? You may not even need an AP (access point)! We mentioned last month that access points can be “constructed” entirely in software. Suitable programs can convince some WiFi cards to act as a software based “soft AP”, promising instant multi-user laptop based WLANs that suit on-the-road meetings, events etc. Although such programs, especially HostAP and AgileAP, are popular under Linux , Windows versions are still evolving, with PCtel’s US$20 “softAP”(www.pctel.com) perhaps best known. As well as an always-on PC, you’ll still need a wireless card but the approach saves carrying yet another piece of equipment when on the road. Many new Asian-sourced “g” WiFi cards increasingly offer such a “soft AP” option as well as the normal adaptor function. Although this idea has appeal for experimenters and light duty residential users, it rather harks back to hybrid-softwarebased Win98 56K “WinModems” of the late 1990s – the cause of much hair-pulling and teeth-gnashing in dial-up modem days. It also has considerable scope for mischief, since an otherwise innocent-looking laptop may tempt nearby WiFi users to log on (perhaps even automatically) and divulge sensitive password details. Given the rapid fall in hardware-based AP costs, “soft APs” may have limited appeal, although the feature may well come inbuilt with future motherboards and operating systems. (From Stan Swan) 18  Silicon Chip Fig.7: finally, when you’re happy that everything is working as it should, don’t forget to turn data encryption back on again, on all computers on the network. Neighbour then said “I guess we have then!” I think both were a bit shocked when I told them I had full ’net access via their WiFi setup! “Sharing the Connection” under Windows XP This assumes that you have successfully set up the ad-hoc network. 1. Open Network Connections on the host computer. (Click Start, Control Panel, Switch to classic view, and then click Network Connections. 2. Click the connection to be shared and under Network Tasks, click Change settings of this connection. 3. On the Advanced tab, select the “Allow other network users to connect through this computer’s Internet connection” check box. 4. If you are not using a third party firewall and have not already set up the Internet Connection Firewall (ICF), be sure to check the box enabling this feature. 5. Finally, enable the setting to let other users control or enable this connection if you wish that to be possible. Unfortunately, space has beaten us – we had hoped to cover AP infrastructure networks as well this month – but that will have to be another time! SC NEXT PART: We’re going to go for long-distance WiFi, using some high-gain antennas and tricky gear from Freenet-Antennas. Our aim is pretty modest – just a kilometre or so – but there are trees in the way! siliconchip.com.au