  1.  NAME

  gps - Extract GPS information from non-NMEA files

  2.  USAGE

  gps control_file

  3.  DESCRIPTION

  This utility extracts GPS position and time from non-NMEA navigation
  files. It was motivated for data collected in the Azores during the
  AGMASCO project in November 1997. During this cruise, differential GPS
  was not available, however the ship was equipped with an Azhtech
  receiver logging GPS fixes every 10 seconds. A similar receiver was
  located in Faial. These two GPS data sets were then compared and
  processed in order to create better quality fixes. Its purpose is to
  create position files for input to refabs and refabsbt.

  Currently, only the above mentioned fix file can be read. It contains
  the following columns:

  1. Time in decimal days

  2. Unused

  3. Unused

  4. Unused

  5. Latitude in decimal degrees

  6. Longitude in decimal degrees

  7. Unused

  Position fixes are interpolated to the ADCP ensembles times. A good
  fix is determined as follows: the time difference between two
  consecutive fixes is less that a certain threshold value (see
  parameter tolerance) and the ADCP ensemble time must be within these
  two fixes.

  4.  PARAMETERS

  The control file must define the following parameters:

     dbname: name
        Name of database (with path) containing profiles to be fixed.

     year_base: YYYY
        Base year for converting time into decimal days. This value must
        be compatible with the decimal days listed in the fix file.

     gps_list: file
        Name of file (with path) containing list of gps fix files.

     output: file
        Name of output file.

     tolerance= integer
        Maximal allowed time gap, in second, allowed between an ensemble
        and two fixes. Because fixes might not cover the whole cruise,
        this parameter gives the possibility to cancel position fixing
        within these holes.

  5.  OPTIONS

  The following options are implemented:

     OPTIONS:
        This key word can be used to improve the clarity of the control
        file and specify the beginning of options. It has no effect.

     only_good_fixes
        Use only good fixes to correct only ADCP positions. Positions
        without fixes are left as is.

     longitude_180
        Specify this for converting longitude values between -180 and
        +180 degree before using them.

     end
        This keyword is mandatory and terminates the list of selected
        options.

  6.  TIME RANGES

  Finally, the control file is terminated by a list of time ranges.  See
  time_rng(5) for the syntax of these.

  7.  OUTPUT FILES

  The generated output file contains the following columns:

  1. Ensemble time in decimal days

  2. Longitude fix in decimal degrees

  3. Latitude fix in decimal degrees

  4. Fix status: -1 for a bad fix and +1 for a good fix

  5. Time in second from previous fix to ADCP ensemble time

  6. Time in seconds from ADCP ensemble to current GPS fix

  The last columns are meant for diagnostic purpose and eventually
  adjustment of parameter tolerance.

  8.  AUTHOR

  Pierre Jaccard, Geophysical Institute, University of Bergen, 1999

