Friday, November 22, 2013

GPS altitude application

A previous post have introduced some math about altitude measurement with GPS, within this post I will show a Venus GPS receiver at work. At the same time I will introduce a GPS logger application for Android cell phones, this DIY application was developed and intended as free solution for OpenStreetMap   mapping support.
I give a lot of credit to GC that developed and shared the Android logger system, him is also a main Airboom project contributor.
Figure 20.1 GPS logged path visualized into google earth
Have been chosen off the shelf components so assembly work is minimized.
The chosen receiver is a Venus638FLPx GPS, neatly packed by Sparkfun , the antenna is a 26db Gain unit suited to be magnetically fixed; the GPS and antenna connectors are matched, a four pin right angle header must be soldered to GPS unit serial interface.

The GPS receiver must be then connected to a PC by mean of a TTL serial to usb adaptor. You can see the general arrangement in the next figure.

Figure P20.2 GPS receiver and antenna ready to be connected to a PC

TTL serial usb adapter should be connected with four F/F wires to the GPS receiver, just follow the labels on both units. At a glance, wire the boards in the following way (GND; GND) ,(+3,3V;+3,3V), (TX,RX) and (RX,TX).

Preloaded firmware instructs the GPS receiver to continuosly send GPS strings to serial port , the communication is set to 9600 Baud 8N1. To read the ouput you need to run a serial/modem terminal software on your PC, for the purpose I used Minicom under Linux and Teraterm under Windows.

Once powered up you will get an infinite series of messages like those here below


Table P20.1 Venus GPS serial output
The first line provide latitude 4509.9767 N longitude 01000.471 E, 40.2 MSL altitude and geoid altitude correction 42.3 m.
Figure P20.3, Ready to operate antenna  on the car roof, magnetic link.
At the same time, and location, Android GPS logger provide an altitude of 82,3m.
Figure 20.4 Output of Android GPS logger, steady measurement

So GPS receiver provide 82,5 m=40,2m+42,3m of altitude and Android cellular phone 82,3m; hence data from the two different sources are in agreement.

Provided altitudes are referenced to WGS-84 geoid, to express this measurement as MSL is possible to use, for example, EGM96 model information . This model provide at current coordinates a geoid height of 39,613m, hence GPS receiver is reading 82,5-39,613=42.9 MSL and cell phone 82,3-39,613=42,7 MSL.

As per programming manual, Venus GPS receiver can be configurated using binary commands through a serial terminal, for a soft approach I advise to use GPSViewer for Windows. This free software reports real time GPS data and permit to setup some features, as communication port settings and GPS refresh rate ; our GPS receiver refresh rate can be setup up to 20Hz.

Android GPS logger can save a path in .kml format, the Google Earth default format.
Figure 20.5 Output of Android GPS logger, path record
Using as example a Venus GPS the basic procedures to manage a GPS stand alone receiver have been provided.

Also with the geoid altitude correction the altitude MSL is not the real altitude, GPS accuracy impact is high as per precedent article. To proof this the easiest way is to go to a location, or landmark, with a known altitude as your city airport or main square; probably your reading will be wrong of around ten meters.
Android GPS logger will be descrived in more detail into another dedicated post, the software is open hence also the source code will be provided.
Post a Comment