Sensors/GPS

From PaparazziUAV
Revision as of 20:24, 3 October 2008 by Jeremy (talk | contribs)
Jump to navigation Jump to search


Overview

U-blox color warm 60.gif

Paparazzi autopilots are designed around the popular u-blox brand of receivers.

  • Features:
    • Small size
    • Excellent performance
    • 4Hz position update rate

The Tiny features an onboard LEA series GPS receiver and patch antenna, while Classix and AVR-based boards require an external receiver+antenna such as the Paparazzi GPS or SAM-LS. Please note that the receivers must be configured (prior to use with the autopilot) as indicated below. Both modules have proven reliable and robust.

u-blox LEA GPS Receiver
u-blox SAM-LS GPS receiver (w/built-in Smart Antenna)

Note: The proprietary UBX protocol is used as it offers more information and efficiency than the universal NMEA protocol. The protocol is parsed in sw/airborne/gps_ubx.c. Other GPS brands would require a similar parsing file to be written for NMEA or other proprietary protocols.

GPS Receivers

u-Blox LEA Series Receivers

u-blox LEA

The [TWOG_v1|TWOG], Classix and AVR-based boards require an external GPS module and antenna. The Tiny features an integrated receiver and antenna. Either type is designed for u-blox 4 and 5 series GPS receivers and the proprietary UBX binary protocol. An external battery or capacitor is typically used to enable the GPS to retain data while powered off for significantly faster signal re-aquisition. Any of the LEA-4 and LEA-5 series receivers can be used including the less expensive LEA-4A, 4S, 5A and 5S models as the special boot configuration code required for these models is already written.

  • 4Hz Position update rate
  • Supports active or passive antennas
  • Supports DGPS, WAAS, EGNOS, and MSAS
  • Low position noise figure
LEA-4P installed on the Tiny


Paparazzi Stand-alone GPS Receivers

Paparazzi GPS13
LEA-5H Full Board Pinout

There are currently two (LEA-based) stand-alone, GPS receiver + antenna, prototype boards in development; the first one is based on the Sangshin 13mm patch antenna.
The second is based on the Sarantel helix antenna. Drawings for both are available from the CVS Version 1 (V1) BOM is here.. Please post any pics you might have and check this for accuracy
V1 BOM.xls
Eagle Parts List Output.txt

If this needs fixing don't be shy, fix away.


NAVILOCK NL-507TTL

The NAVILOCK NL-507TTL u-blox TTL Modul 60416 is available for 28€ at www.amazon.de

SPK GS406

SPK GS406 with LEA-5

Sparkfun sells a nice small module featuring the newer 5-series receiver and the highly rated Sarantel antenna for about $90. The design is based around the active version of the Sarantel instead of the more appropriate passive model and there's some potentially tricky soldering involved to get around the ribbon cable but the price is great for this hardware.


u-Blox C04-5H Reference Design

u-blox C04-5H

u-Blox sells a complete module with antenna for around $200 and will also provide complete schematics, BOM, and PCB files for free if you wish to make your own. Two versions are offered, one with an 18mm patch antenna and the other with the Sarantel P2 helical antenna. See http://www.u-blox.com/products/c04_5h.html for more info.

Connecting external receivers to Classix, 1.2.1, Lite, and RoboStix boards

The u-blox receivers require 3.3v power and all current models have 5V tolerant data lines. The best way to connect to the SAM-LS is to remove the bottom case and solder the 4 wires directly to the TIM-LL module (GND (pin 1) ,VCC (pin 2),TX (Pin 5),RX (pin 4)) check the TIM-LL datasheet for pinout diagrams. The Classix and Lite boards feature a 3.3V regulator to power the GPS.


Sourcing from u-blox

u-blox keeps tight control over the distribution of their products. They must be obtained DIRECTLY from their own reseller offices. These offices may not be available in your area, for example Canada does not have a reseller. Sample quantities can be obtained from uBlox but overnight or 2 day shipping is required which drives the cost up considerably. While it is a large hassle obtaining these devices, it is undoubtedly worth it.

Talking with ublox sale for two years, Confirmed, that Order is possiable Directly from ublox, by knowing what project it was for & how was it to be use. After long reply waiting time, the answer was: - YES, but at least 2K-3K in volume, otherwise they're not interested. Like to share the order ? It is 500pcs/Roll.

Other potential source of u-blox GPS

There seems to be a few alternative source of u-blox GPS out there. They are considerably cheaper then the samples u-blox offers (at least in america). We didn't buy from these sources yet. Do not take this as a recommandation, we do not know the level of service they offer, etc.

If you do order from any of them, please update this page with your feedback.

Here's a few link worth exploring:


GPS configuration using U-Center

u-center configuration software

U-Center is a very comprehensive freeware program intended for the configuration and evaluation of u-blox receivers.

  • Note: You must install the UART tunnel to enable direct access to the built-in GPS on the Tiny.
  • Note: You can run u-center on Linux by installing "wine" (Installation of Wine) and setting up com1 as /dev/ttyUSB0 See Info on wine for "dosdevices" setup. Just download the u-setup.exe and run it with wine, follow prompts. This has been tested with Ubuntu7.10 and Ubuntu 8.04 so far.
  • Note: You will need a driver for your FTDI cable if you run u-center on Windows, which can be found here.

The u-blox and Tiny UARTs both operate at 3.3V TTL levels and are 5V TTL tolerant. You must use a level shifter such as the common MAX232 to connect these devices to a standard PC serial port. The easiest and most recommended method is to connect to a USB port instead of serial with the $20 FTDI USB-TTL converter cable available from Digikey, Mouser, or direct from FTDI. Other similar converters are available from pololu / sparkfun or Halfbase. A stand-alone GPS such as the SAM-LS will require clean 3.3V/50mA power and a common ground with the TTL converter.

  • U-blox occasionally releases firmware updates. Log on to the u-blox website using paparazzi for username & password to view or download the latest firmware images. There have 'never' been any updates released for the Antaris-4 series used in the Tiny.

Start U-center and choose your com port from the pull down list under the connect button near the top left corner of the window. Choose your baudrate from the pull down box to the right of the connect button or select the auto-baud button to the right of that. U-blox default is 9600 baud. This must be changed to 19200 or higher to accomodate the 4Hz update rate.
connect, baud, and autobaud buttons

Uploading the Configuration File

Download the appropriate configuration file below and use u-center to load in onto your receiver. Under the Tools menu, choose GPS configuration. Be sure the box 'Store configuration into BBR/Flash' is checked and hit the button File>>GPS. A few errors and retries are normal, but a significant number of errors may indicate a poor connection and the software will notify you if it is unable to send all the data successfully.

Manual Configuration

If you prefer to setup your receiver manually or have a model not listed above, here are instructions to configure your receiver in u-center. Open the message window (menu View->messages view) to start the configuration process by changing the following settings:

LEA-4P

1. Right Click on the NMEA Icon and choose disable child
2. Choose UBX->CFG->NAV2(Navigation 2) - set it to use Airborne 4G (tells the Kalman filter to expect significant changes in direction)
3. UBX->CFG->PRT - set USART1 to 38400bps (must match the value in your Airframe file)
4. Change the baudrate of U-Center to 38400bps if the connection is lost at this point
5. UBX->CFG->RXM(Receiver Manager) - change GPS Mode to 3 - Auto (Enabling faster bootup only if signal levels are very good)
6. UBX->CFG->RATE(Rates) - change the Measurement Period to 250ms (4 Hz position updates)
7. UBX->CFG->SBAS : Disable (SBAS appears to cause occasional severe altitude calcuation errors)
8. UBX->NAV (not UBX->CFG->NAV): double click on POSUTM, SOL, STATUS, SVINFO, VELNED. They should change from grey to black
9. UBX->CFG->CFG : save current config, click "send" in the lower left corner to permanently save these settings to the receiver 

LEA-5H

1. Right Click on the NMEA Text on top of the tree and choose disable child messages
2. Choose UBX->CFG->NAV5(Navigation 5) - set it to use Airborne 8 <4G. This tells the Kalman filter to expect significant changes in direction. 
   Note that this setting is only good for faster moving airplanes. For a fixed position hovering heli, 'pedestrian' setting is better
3. UBX->CFG->PRT - set USART1 to 38400bps (must match the value in your Airframe file)
4. Change the baudrate of U-Center to 38400bps if the connection is lost at this point
5. UBX->CFG->RATE(Rates) - change the Measurement Period to 250ms This gives a 4 Hz position update since 4 x 250ms is one second.
6. UBX->CFG->SBAS : Disable (SBAS appears to cause occasional severe altitude calcuation errors)
7. UBX->NAV (not UBX->CFG->NAV): double click on POSLLH, SOL, STATUS, SVINFO, VELNED. They should change from grey to black
(add the flag -DGPS_USE_LATLONG in your Airframe file) also make sure you set tiny_2_1_1.h if you have the latest boards Tiny/TinyWOG)
8. UBX->CFG->CFG : save current config, click "send" in the lower left corner to permanently save these settings to the receiver 
  • Cycle the power and verify that the new configuration was saved
  • To reset the receiver to the factory defaults go to UBX->CFG->CFG, select 'Revert to default configuration', and click Send at the bottom left corner. To permanently save these values choose 'Save current configuration' and click Send.
  • To backup the configuration to a file on your PC: under the tools menu, choose GPS configuration, then click GPS>>file. This file can be re-loaded in a similar manner to configure additional identical receivers. Be sure the box 'Store configuration into BBR/Flash' is checked when reloading a configuration file to make the changes permanent.
  • To update the firmware on a LEA-5H get u-center >= 5.03, revert the GPS receiver to the default configuration, get an appropriate image from u-blox (fitting your receivers serial number), find the flash identification flash.txt file in the u-center install directory and be prepared to wait a long time.
  1. NOTE: If you have a Tiny with LEA-5H module you must use u-center and manually setup the parameters as shown above (at least switch to 38400 baud manually before transferring the configuration file).
  2. NOTE: POSUTM is not available on LEA-5H. Instead, use POSLLH. Additionally, add the flag -DGPS_USE_LATLONG in the makefile section of the airframe xml file.

Reset to Default Settings

The GPS module can be reset to its original default settings by pulling BOOT_INT high(3.3V) during a power cycle (Antaris Manual, p. 122). It may be required after a wrong firmware upgrade or a bad configuration change.

DGPS (Differential GPS)

Differential GPS is any method of improving GPS accuracy by comparing the GPS-indicated position of a nearby location to the known value and transmitting any error to the mobile unit. DGPS was originally created as a means of bypassing the deliberately introduced inaccuracies in civilian GPS signals. The original method used low frequency ground radios to relay correction data to the mobile unit and is still used today at airports, shipping ports, and even individual farms. Satellite Based Augmentation System (SBAS) is a modern form of DGPS where the ground stations relay correction data to a GEO-Stationary satellite, which then relays it to the mobile unit on standard GPS frequencies eliminating the need for a separate radio reciever. SBAS is currently available in 3 regions, WAAS, EGNOS, and MSAS though only WAAS is officially operational. U-blox receivers support all common varieties of DGPS read the u-blox SBAS application note.

  • It is important to note that DGPS methods only improve the accuracy of the position calculation, not the precision. Since Paparazzi navigation is typically performed relative to the power-on location, any static error that could be corrected with DGPS is irrelevant.

WAAS issues

WAAS has been officially operational and "suitable for safety-of-life applications" since 2003. The default setting of all u-blox receivers ignores WAAS correction data and only uses the WAAS satellites for regular navigation like any other satellite. U-blox recommends further limiting this setting to exclude any stray EGNOS/MSAS satellites in North America, and completely disabling all SBAS functions for use outside North America. In 2006 one formerly reliable Paparazzi aircraft began having great GPS problems and displaying very erratic altitude calculations, disabling WAAS immediately resolved the issue and this phenomenon was recreated several times for verification. Turns out a new WAAS satellite was being added to the system and the others were being moved that week for better distribution. Our advice is to completely disable WAAS.

EGNOS issues

EGNOS is officially in "testing mode" and no claims of reliability are made. The u-blox FAQ states the following:

  • "Do you see issues with EGNOS?"
    "Yes. Although the data transmitted by the EGNOS satellites are usually good and valuable (e.g. during the solar storms in autumn 2003), they can sometimes be very unreliable, for example when system tests are performed. As an example, u-blox has noticed erroneous range information (up to three hundred kilometers) on various EGNOS satellite over the last few months [2006]."

Further Reading

The u-blox System Integration Manual covers a lot of GPS theory as well as product specific topics.

Antenna options for the Tiny and Paparazzi GPS units

The Tiny 1.1 features a 28mm square ground plane intended to be centered below the Sangshin 13mm patch antenna. Much better performance has been seen with the 18mm antennas and an augmented ground plane. The ground plane is a critical part of the antenna affecting not only the gain and polarization characteristics but also the center frequency of the system. Users are advised to expand the ground plane to approximately 36mm square, centered on the ceramic portion of the antenna (not the pin). This can be done with copper foil soldered to the vias of the existing ground plane.

SAM-LS 25mm / Emtac 20mm / Emtac 18mm / Sangshin 18mm / Sangshin 13mm / Sarantel P2


Sangshin 18mm Patch

Sangshin 18mm x 4mm 1580Mhz

The Sangshin KSA-ST1580MS18 antenna has proven to offer the best performance of the currently available options. These are available from any Sanshin distributor such as rfmw (here) and cost approximately $6.50/ea. in small quantities.


EMTAC 18mm Patch

Emtac 18mm x 4mm 1580Mhz

Offering identical performance to the Sangshin in a less attractive package is the Emtac 18mm antenna. The part number for the standard 1580MHz 18x18x4mm is ANA1580T18D40 and is not listed on their website. Other frequencies are available on a special order basis and the 1584Mhz has proven to outperform all other frequencies when used with a 36mm ground plane and no radome. The use of a radome (any material covering the antenna) or a larger ground plane should theoretically favor even higher frequencies.

Availability

  • TransplantGPS in MN, USA. The 1580Mhz models are usually available at a cost of $3.55ea but there may be a minimum order requirement of ~$50 USD.
  • PPZUAV ~$10.00 USD (no min. order requirement)


Sangshin 13mm Patch

Sangshin 13mm x 4mm 1580Mhz

Part of interest: KSA-ST1580MS13

The Tiny 0.99 (not 0.9) and 1.1 were designed around this antenna but users are advised to install 18mm units for better performance.

Size: 13 x 13 mm
Center Frequency: 1580 MHz
Bandwidth: 5 MHz
@Fo: -15 dB
GAIN (dBi): 0 dBi
Ground Plane: 50 x 50 mm

Available From

Systronic INC. - Alberta, Canada

Emtac 20mm Patch

Emtac 20mm x 4mm

The Tiny 0.9 was designed around this 1583Mhz antenna and performed extremely well. Emtac has replaced this with an 18mm model that they claim offers even better performance.

  • Obsolete


Sarantel GeoHelix-P2

Sarantel Geohelix P-2 1575Mhz

This antenna is popular among UAV designers due to it's natural rejection of other radio frequencies such as those originating from the modem or video system as well as it's improved rejection of signals reflected from the ground. U-blox recommends this antenna and features it in their reference design. Frequency and polarization are not dependent upon ground plane geometry so this antenna is sold only in the true GPS frequency of 1575Mhz. The geometry makes this antenna very inconvenient to mount, especially in an airplane. Some very non-scientific testing has been done with one of these antennas connected to a Tiny with a short length of 50 Ohm coax above a 120mm square of ungrounded aluminum foil and performance was adequate. The helical design should theoretically outperform a patch in the air, but not on the ground, so any organized comparison will be difficult. Possibly the most important aspect of this antenna is it's natural RFI filtering, which should be evaluated further.


Availability

  • Sarantel @ cost of approx $18 USD each (active versions available for ~$40)