Showing posts with label Bluetooth. Show all posts
Showing posts with label Bluetooth. Show all posts

Friday, October 24, 2014

Using USB and Bluetooth GPS with Laptops and Netbooks (PC) - Part 1


After the success of the post on Using USB GPS on Android,  eventually I am going discuss the obvious - using the USB GPS receiver with your laptop or netbook, which this kind of GPS receivers were made for in the first place. I say laptop, because you are not going to go around with a desktop in the outdoors, otherwise these would work just as fine with any PC.

I am going to describe the workflow assuming you have a Windows PC, readers with other OSs (Mac or Linux) have to find out equivalent functions and software on those platforms. Now, first thing first, making your GPS to work with your PC, and you would want to plug the GPS in one of the PC's USB ports at this point. For the absolute beginners, please don't expect a new disk drive to appear in your My Computer like what happens when you plug in a USB Flash drive or external Hard Disk. Notice that when you plug in your GPS for the first time, Windows will automatically detect a new hardware and try to install an appropriate device driver so that it can communicate with the new device the way it should. In this case the GPS would appear as a COM port, which would maintain the communication between PC and GPS. Instead of looking into My Computer you have to look for the new device in the Control Panel > Device Manager > Ports (COM & LPT).

If Windows was successful in finding the appropriate driver, you would see a new serial (COM) port listed here. However, if Windows was unsuccessful, you would still see an unrecognized device marked with that infamous yellow exclamation sign, which means you have to supply (install) a device driver for your GPS. The driver CD may already have come with your GPS or you may have to download it from the supplier/manufacturer's website. One of the most common hardware that comes built-in with this types of GPSs is a small chip called PL-2303, which functions as a bridge between USB on the PC side and Serial Port on the GPS side. The device driver, therefore, you are looking for is a Prolific PL-2303 driver (other OS users may also benefit from this information). If it is not a PL-2303 on your GPS, you have to find out which USB-to-Serial hardware is used in your GPS, and download a generic device driver for that hardware from anywhere on the Internet. Once you install the driver from CD or download (or upgrade driver from Device Manager) the exclamation sign would go away, which would mean your GPS is now ready to communicate with PC. Remember the COM port number shown in the Device Manager list (in my case it is COM port 7, as shown in Figure 1).

Figure 1.

After having completed this preparatory step, fortunately which you have to do only the first time, the real communication with GPS might begin now. And this part involves a small software, which will allow you to see what the GPS is doing once connected, and what kind of data it is sending to your computer. If you are using Windows XP you already have a small software called Hyper Terminal; for Windows 7 or 8 download any free terminal emulator software. In this example I am using a nice little once called TeraTerm (you are free to use the terminal program of your choice). Unzip the downloaded file, and run TeraTerm by double clicking the ttermpro.exe executable file. As shown in Figure 2, select "Serial" as your preferred communication method, and select the COM port number to which your GPS is connected, in my case COM7. After clicking OK you may get something like what appears in Figure 3.

Figure 2.

Figure 3.

Now, this is not what you'd probably expected. You instead may be seeing something different, like in Figure 5; if so, you don't have to follow the next step. In either case, your GPS is sending data to your computer, it's just the difference how the data is being received. If you are in Figure 3 situation, that would mean your software is trying to receive data at a speed different than what the GPS is set up to send it. So, from the "Setup" menu, click "Serial port....", and change the Baud rate (speed) to what your GPS's manual suggests (in my case 4800 instead of the TeraTerm default 9600), as shown in Figure 4. If you are correct, you get this data stream as shown in Figure 5.

Figure 4.

Figure 5.

Most likely this is still not what you were hoping for. What you get here are called NMEA sentences. Most GPS receivers  are configured to continuously send these NMEA sentences at predefined interval (usually 1-2 sec) to whatever display/data terminal it is connected to. So, you are getting perfectly usual staff. These NMEA sentences carry all the information you would ever want from a GPS. At this point, however, you would require another piece of software to interpret this bizarre looking data into nicely formatted information on the satellites visible on your sky, their PRN numbers, satellite that are being used by your receiver, your location, your speed and direction if you are moving, GPS accuracy of your location (fix), date & time and a variety of other useful staff. This group of software is generally known as NMEA parser.

In the second part of this tutorial I shall recommend some beautiful GPS software, and show how to use and get the most out of them.

You might be wondering, what about the Bluetooth GPS receivers that I promised in the title. Well, that's simple, when you pair a bluetooth GPS with your PC, you get a COM port over bluetooth. Use that port the same way.

Tuesday, June 5, 2012

Using an external Bluetooth GPS with Android Device

Some Android phones (and other smart-phones too) come with built-in GPS receiver (in addition to AGPS capability, that means it can acquire location from GPS satellites like a standard handheld GPS receiver), but many of them are not as fast and as sensitive as a dedicated GPS unit in acquiring satellite signals and getting a fix (location). They are generally very slow in getting the first location fix (mine takes 30-40 minutes to get a fix when I am standing still, and takes eternity when on move). This is frustrating and virtually makes the phone's GPS a useless piece of hardware. High battery drainage is another compelling reason for not using the phone's GPS. Some smart-phones doesn't have built-in GPS. This is where an external bluetooth GPS unit fits perfectly. These external GPS units with no display, a built-in rechargeable battery, a few LED indicators and a bluetooth radio are generally pretty small and lightweight. These have a much better GPS circuitry than most smartphones on the market do, while they cost between 50 and 100 USD.

Mine is a Freedom Keychain GPS 2000 bought from amazon.co.uk for about 40 GBP. Here is a picture of the unit-

This unit and other similar product come with a home and a car charger, needs a couple of hours for charging, and runs for a good 10 hours. Mine also goes to sleep when no bluetooth device is using the unit to conserve power elongating the effective run-time.

How to use with an Android smartphone/tablet:

1) Switch on the GPS unit and Enable Bluetooth on your Android device. You can 'discover' the Keychain GPS on the Android's available bluetooth devices, as shown in the following picture.



2) Pair and connect the GPS unit from Android device. Usually the pairing code is 0000 or 1234. Mine's is 0000.



3) Download one of several Android Apps from Google Play (former Android Market). My favorite is Bluetooth GPS, good alternatives can be Bluetooth GPS Provider and Bluetooth GPS Provider (yes, the same name, but two different apps). However, don't confuse with the app Bluetooth GPS Output, which is for making your phone an external bluetooth GPS to be used on other devices. These apps will actually provide a port to the external GPS, that means they make the satellite signals from the external GPS used on your phone in such a way that as if the signals are being received by your phone's built in GPS. This lets you use other map Apps such as Orux, Locus, Google Earth, Google Maps etc while the port App is running in the background.

4) Run the Bluetooth GPS. Here is how the App's main screen look like. NOTE that the app has four tabs: Main, Status, NMEA, and Map. If the Keychain GPS is paied over bluetooth, you should see the GPS appearing in the drop-down device list. Select the GPs and hit 'Connect'.

To be able to use the external GPS's data in other Apps, you must check "Enable Mock GPS Provider" before hitting 'Connect'.




5) If everything goes well, you should see time, location and other GPS information being updated on this screen. If you still don't have a location fix, because you are indoors or for other reasons, you can still check if the GPS is working properly on your Android device. Swipe to go to the NMEA tab, and hit 'View log' (it becomes 'Pause' after you hit it). You should see the GPS's NMEA data sentences appearing endlessly on this screen.



6) Now, don't quit or kill the Bluetooth GPS app, just send it to background while it is still running. Open your favorite map App, or any other location aware App to receive location information from the external Bluetooth GPS.