Coastal & Marine Geology InfoBank

Home FACS Activities Atlas Geology School Related Sites More

USGS InfoBank program -- gprmc2daps

Skip navigational links
Loading
InfoBank Programs: by Name   by Topic  
Expanded Description
Topic Description
Name
gprmc2daps
Synopsis
/infobank/programs/refmt/gprmc2daps/gprmc2daps.for
Description
  Program to reformat GPRMC GPS records to standard DAPS format.

       
OUTPUT
  YonavTime, Latitude, Longitude, GPSTime, DeltaTime

    
AUTHOR
  Clint Steele      10/7/2002


    
Reads
          read (90, '(q,a)', end = 99)
     *        Length, ALine(1:Length)
          read (ALine(1:2), '(i2)') YonavHour
          read (ALine(4:5), '(i2)') YonavMinute
          read (ALine(7:8), '(i2)') YonavSecond
          read (ALine(10:12), '(i3)') YonavTenths
          read (ALine(Comma(1)+1:Comma(1)+2), '(i2)') GPSHour
          read (ALine(Comma(1)+3:Comma(1)+4), '(i2)') GPSMinute
          read (ALine(Comma(1)+5:Comma(1)+6), '(i2)') GPSSecond
          read (ALine(Comma(1)+8:Comma(1)+9), '(i2)') GPSTenths
          read (ALine(Comma(3)+1:Comma(3)+2), '(i2)') LatDeg
          read (ALine(Comma(3)+3:Comma(3)+10), '(f8.5)') LatMin
          read (ALine(Comma(5)+1:Comma(5)+3), '(i3)') LongDeg
          read (ALine(Comma(5)+4:Comma(5)+11), '(f8.5)') LongMin
          read (ALine(Comma(9)+1:Comma(9)+2), '(i2)') Day
          read (ALine(Comma(9)+3:Comma(9)+4), '(i2)') Month
          read (ALine(Comma(9)+5:Comma(9)+6), '(i2)') Year
Writes
            write (91, '(i4.4,i3.3,3i2.2,i1.1,
     *        t16,f9.5,t26,f10.5,1x,
     *        i4.4,i3.3,3i2.2,i1.1,
     *        1x,a1,i4.4,i3.3,3i2.2,i1.1)')
     *        Year, JDay+YonavDay,
     *        YonavHour, YonavMinute, YonavSecond, YonavTenths,
     *        Latitude, Longitude,
     *        Year,JDay+GPSDay,
     *        GPSHour, GPSMinute, GPSSecond, GPSTenths,'+',
     *        0,DTime,DHour,Dminute,DSecond,DTenths
            write (91, '(i4.4,i3.3,3i2.2,i1.1,
     *        t16,f9.5,t26,f10.5,1x,
     *        i4.4,i3.3,3i2.2,i1.1,
     *        1x,a,i4.4,i3.3,3i2.2,i1.1)')
     *        Year, JDay+YonavDay,
     *        YonavHour, YonavMinute, YonavSecond, YonavTenths,
     *        Latitude, Longitude,
     *        Year,JDay+GPSDay,
     *        GPSHour, GPSMinute, GPSSecond, GPSTenths,'-',
     *        0,DTime,DHour,DMinute,DSecond,DTenths
Opens
Calls
      call openem (1,-1)
          call getcentury (Year, Century)
          call julianday ("JULIAN", JDay, Year, Month, Day)
          call converttime ('COMPRESS', 
     *        JDay+YonavDay, YonavHour, YonavMinute, YonavSecond,
     *        YonavTenths, YonavTime, ErrorFlag)
          call converttime ('COMPRESS',
     *        JDay+GPSDay, GPSHour, GPSMinute, GPSSecond,
     *        GPSTenths, GPSTime, ErrorFlag)
          call converttime ('EXPAND',
     *        DTime, Dhour, DMinute, DSecond, DTenths,
     *        TimeDiff, ErrorFlag)
           call converttime ('EXPAND',
     *        DTime, Dhour, DMinute, DSecond, DTenths,
     *        -TimeDiff, ErrorFlag)

Skip footer navigational links

Coastal and Marine Science Centers:  Pacific   St. Petersburg   Woods Hole  
InfoBank   Coastal and Marine Geology Program   Geologic Information   Ask-A-Geologist   USGS Disclaimer  


Accessibility FOIA Privacy Policies and Notices

Take Pride in America logo USA.gov logo U.S. Department of the Interior | U.S. Geological Survey
URL: http://walrus.wr.usgs.gov/infobank/programs/refmt/gprmc2daps/gprmc2daps.doc.html
Page Contact Information: InfoBank staff
Page Last Modified: Mon Sep 16 03:38:32 PDT 2013  (chd)