Using a GPS Receiver with NetStumbler and MiniStumbler

 < Day Day Up > 



In order to physically locate an access point (AP) or to map AP locations, you have to know where you are when the AP is detected. While this may seem to be simplistic, it is true. So how do you track where you are when an AP is detected? One option would be for you to take notes, writing down your exact location every time NetStumbler finds an Access Point. But, this could be rather difficult; getting a precise location might involve making measurements, along with detailed notes. For instance, “35 feet north of the ‘No Parking’ sign in front of 23 Main St.; five feet from the edge of the sidewalk.” Using such a technique might be tedious, and you would proceed fairly slowly.

However, there is a much easier way to do this, with a level of precision within approximately 25 feet. By simply attaching a Global Positioning System (GPS) satellite receiver to your computer, NetStumbler will automatically log your location every time it receives a Probe Response frame.

GPS units are radio receivers that measure a signal from several different Global Positioning satellites. By using triangulation, the receiver calculates its location on the surface of the Earth using those signals. The location is reported in terms of the Latitude, Longitude, Altitude, and other data. Most GPS units continuously update their location information. The unit then sends out this position data over a serial data link, typically about once a second. In turn, NetStumbler reads this serial link data. It then records the Longitude and Latitude from the GPS whenever a Probe Response frame is heard.

Because of this ease of use in recording the location of a detected AP, a GPS is the second accessory that most WarDrivers add to their “Stumbling Rig.”

start sidebar
Tools & Traps…
Troubleshooting GPS Problems

If NetStumbler does not seem to be communicating with your GPS receiver, it is sometimes difficult to determine if the fault lays with the NetStumbler settings, the GPS unit itself, or something else such as the cables and connectors.

To check if the GPS is sending data, use a terminal emulator program. A common terminal emulator is HyperTerminal, which comes with Windows. Start by changing the Communications settings in the Device Manager to the GPS serial settings. For most brands of GPS receiver, the default communications settings are 4800 baud, 8 Data Bits, 1 Stop Bit, and No Parity. Don’t forget to choose the communications port that is connected to the GPS.

Make sure that the GPS has a clear view of the sky to get proper signals. If the GPS receiver is working properly, and the communications settings are correct, then you should see NMEA sentences in the terminal emulator. NMEA sentences should look similar to the following, although the data will differ slightly according to your location.

end sidebar

$GPGSV,3,1,10,17,78,216,38,23,63,311,42,26,56,051,41,15,52,303,43*7E $GPGSV,3,2,10,18,46,295,49,09,36,152,,29,36,053,,03,09,317,*7C $GPGSV,3,3,10,10,08,097,,06,04,203,,,,,,,,,*7C $GPGLL,4422.2935,N,07313.8332,W,005702.969,A*21 $GPGGA,005702.97,4422.2935,N,07313.8332,W,1,05,2.7,00075,M,,,,*3E $GPRMC,005702.97,A,4422.2935,N,07313.8332,W,00.0,000.0,150303,15.,W*67 $GPGSA,A,2,17,23,26,18,15,,,,,,,,2.7,2.7,*13

If you see information similar to this, then the GPS is working properly, and you may need to adjust the NetStumbler settings. If you see characters that make no sense, then one or more communications settings are incorrect. Double-check the settings on both the GPS and the PC.

No characters showing at all in the terminal window indicates a probable cable issue. In this case, you may need to purchase a Null Modem, which will swap the connections of several common lines used in serial connections. Null Modems for serial cables can be obtained at most Radio Shack stores for under $10.

For advanced GPS diagnostics, you might want to look at the VisualGPS freeware program at www.visualgps.net/. For iPAQ users, there is VisualGPSce for the ARM processor.

Features of GPS receivers vary, but generally they fall into two categories: those that have an integral display and those that have no display. Those that are without a display are generally referred to as “mouse” or “puck” styles since they tend to resemble either a computer mouse or a hockey puck. Mouse or puck GPS receivers without a display are generally less expensive, but they need to be connected to a computer (or some other device) to work properly. Those with displays can function in a standalone mode. If you plan on using your GPS solely for WarDriving, a mouse or puck style may be fine. However, if you plan on using the GPS for other activities such as hiking, then you should buy one with a display. Figure 3.16 shows three common GPS units. The two on either end have a built-in Liquid Crystal Display (LCD), while the center one is a “puck” without a display.

Typical GPS Problems

There are several potential “stumbling” blocks you may come across when using your GPS receiver with NetStumbler. First and foremost is the requirement to use a GPS unit that will transmit its data over some manner of communications link. Most GPS receivers will output location data in the National Marine Electronics Association (NMEA) 0183 data protocol, using a serial cable. Technically, the NMEA 0183 output is EIA-422A data, but for all practical purposes it is the same as RS-232 serial data. This means a GPS that sends NMEA 0183 data will talk to the serial communications (COM) ports used on most computers. Some newer GPS units use Bluetooth low-power radio communications to transmit the NMEA data.

click to expand
Figure 3.16: Typical GPS Receiver Models

Before you attempt to use the GPS receiver with NetStumbler or MiniStumbler, you must go through an initialization procedure. The procedure needs to be done before the GPS will send out the correct location data. Be sure to read the instructions for your GPS, and go through the setup.

The serial ports on both the computer running NetStumbler and the GPS receiver must be set to use the same settings that NetStumbler uses. As we saw in the section covering the GPS tab of the NetStumbler Options dialog box, the default GPS communications settings for NetStumbler are 4800 baud, 8 Data Bits, No Parity Bit, and 1 Stop Bit. This is because these are the default settings for many NMEA devices. Again, the port and communication settings may be changed as needed via the GPS tab on the View | Options dialog box. NetStumbler will look for NMEA data on whichever serial port is set under the GPS settings. It will also adjust the speed and other data setting on the chosen serial port to the settings found under this tab.

The Map Datum from the GPS should be set to World Geodetic System of 1984 or WGS84. This is the default setting for most GPS receivers, but occasionally the data output is set to the North American Datum of 1927 (NAD27). While the two data sets are very similar, there can be a difference in location of over 100 meters (320 feet) in different sections of the United States. Using the NAD27 setting therefore may result in inaccurate location information. This error will become very apparent if any mapping is done using the NetStumbler data.

A second problem is that some GPS brands and models need to lock on to the satellite signals and establish their location before they send any serial data. More than one person has started checking cables and connections, and analyzing RS-232 data protocols, only to realize that the receiver had just not seen enough satellite signals to establish a location, and had not sent anything out of the serial port.

Conversely, many GPS units will send out data, but it may not be very accurate if the receiver has not locked onto the satellite signals. One chipset, the Sony CXD2931R, used in some popular GPS units is known to initialize itself to Tokyo if it cannot see any satellite signals. That’s fine if you happen to be in Tokyo when you start your WarDrive, but will probably not be very accurate otherwise.

The lesson here is to make sure your GPS receiver has a satellite lock before you head out on your first WarDrive. GPS satellite signals are relatively weak since the satellites are in high orbit, and the GPS receiver may need several minutes to figure out where it is on the Earth’s surface. If you are inside a building, moving outdoors will help speed up this process, as the receiver will have better “Line of Sight” to the satellites, and therefore have better signal reception. Also, anything that blocks the GPS receiver’s clear view of the sky, from heavy tree cover to a city’s “concrete canyons,” can hinder the capability of the receiver to determine location. While WarDriving, try to keep the GPS where it can see the sky. In most vehicles, this will be an area on the dashboard under the windshield, or near another window. For the sake of safety, make sure the GPS receiver (or any other device) does not obstruct the driver’s field of view.

A third issue is that RS-232 serial data has its own pitfalls. Almost all serial connections on the GPS receivers are proprietary, so most users will need to purchase a cable from the GPS manufacturer. The plugs and sockets for the PC end of the cable are usually DB9 subconnectors on most laptops, but sometimes those are also proprietary. Encountering a plug (or socket) on both the laptop and the GPS requiring the purchase and use of gender-changer plugs or sockets in order to just get the equipment to connect to each other is quite common. Another common difficulty with the RS-232 standard is finding that a null modem is required to switch the location of the data lines within the connectors. A gender changer and a null modem are shown in Figure 3.17.

click to expand
Figure 3.17: A “Gender Changer” Plug and a Null Modem Needed to Connect Various GPS Cables

The final common problem with using a GPS is that many laptops produced in the last few years lack RS-232 serial ports. Instead, the serial ports have been replaced with the faster and more flexible Universal Serial Bus (USB) ports. However, the current version of NetStumbler does not support USB data for the GPS data. This will require the use of a serial-to-USB converter, and assigning a virtual serial communication (COM) port to the USB input.



 < Day Day Up > 



WarDriving(c) Drive, Detect, Defend(c) A Guide to Wireless Security
Special Edition Using Macromedia Studio 8
ISBN: N/A
EAN: 2147483647
Year: 2006
Pages: 125

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net