  1.  NAME

  load_sbe - Load CTD data from SBE files

  2.  USAGE

  load_sbe control_file

  3.  DESCRIPTION

  This utility loads CTD data from SBE files. These are ASCII output
  files from package SEASOFT for SeaBird CTD. Optionally, a database
  with the content of bottle data can also be loaded. The producer
  definition file ctd_hm.def (or similar) is required in order to create
  the CTD database, and ctdbothm.def for the database with bottle data.
  This utility is a modified copy load_ctd in the CODAS package.

  Unfortunately, automatic time and position stamping at acquisition
  time is very badly resolved by package SEASOFT. Sometime, it is even
  necessary to turn it off and enter data by hand. This implies that any
  kind of format can be encountered. In order to avoid problems, header
  files should be scanned for correct time and position format.  This
  can be done with scan_sbe(1). The following formats are implemented:

     time
        Time is read from field System UpLoad Time which must contain
        the following space separated elements:

        Mmm
           The first three character of the English month name. The
           first character must be in upper case letter, the two other
           one in lower case.

        dd The number of the day.

        YYYY
           The year in four digits.

        hh Hour.

        mm Minutes.

        ss Seconds.

     Latitude
        Latitude is read from field Latitude which is made up like dd mm
        ss H or H dd mm ss, where H is the hemisphere, i.e. N or S. The
        character separating these elements (a space in this case) is
        not important.

     Longitude
        Longitude format is similar to the one required for latitude,
        except of course the hemisphere character. It is read from the
        field Longitude.

     Station number
        The station number is read from field Station.

     Depth
        The bottom depth is read from field Depth.

  4.  PARAMETERS

  The control file must define the following parameters:

     DATABASE_NAME: name
        Name of CTD database to create.

     DEFINITION_FILE: file
        Name (with path) of producer definition file for creating the
        database.

     SHIP_NAME: name
        The name of the ship (max 11 characters).

     CRUISE: name
        Cruise identification (max 11 characters).

     START_PRESSURE: p_min
        Smallest value for pressure in dbar.

     MAX_PRESSURE: p_max
        Largest value for pressure in dbar.

     PRESSURE_INCREMENT: delta_p
        Pressure increment in dbar.

     HDR_FILES: file
        Name of file (with path) containing list of header files to
        parse successively. These are files with suffix hdr.

     ASC_FILES: file
        Name of file (with path) containing list of CTD data files to
        parse successively. These have the same base name as the header
        files, but have suffix asc.

  Parameters START_PRESSURE, MAX_PRESSURE and PRESSURE_INCREMENT define
  the grid for CTD data in the database. Only the values closest to
  these grid points are saved, i.e. no interpolation or extrapolation is
  carried out.

  5.  OPTIONS

  In addition to the parameters listed above, the following options are
  available:

     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.

     bottles:
        Specify this for loading data from the bottle files into a
        separate database. The following options must be defined:

        db_name: name
           Name (with path) of database for bottle data.

        def_file: file
           Name (with path) of producer definition file for CTD bottle
           database.

        btl_files: file
           File containing list of bottle files to process successively.
           These have the same base name as header files, however with
           suffix btl.

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

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

  6.  OUTPUT FILES

  The specified database files.

  7.  SEE ALSO

  load_ctd(1) and scan_sbe(1)

  8.  AUTHORS

  The author of the original file load_ctd.c is unknown

  Pierre Jaccard, Geophysical Institute, University of Bergen, 1999

