awkpullgprmc: BEGIN { FS="," } { FS="," if ($1=="$GPRMC") { print $0 } endif }
awk_justgprmc: BEGIN { FS="," } { FS= "," ARGC = 2 if ($1=="$GPRMC") { gpstime = $2 hr = substr($2,1,2) min = substr($2,3,2) sec = substr($2,5,2) latdeg = substr($4,1,2) latmin = substr($4,3,6) londeg = substr($6,2,2) lonmin = substr($6,4,6) declat = latdeg + (latmin/60) declon = (londeg + (lonmin/60)) * -1 date = $10 day = substr($10,1,2) month = substr($10,3,2) year = substr($10,5,2) printf("%8.6f, %8.6f, %s:%s:%s, %s\n",declon, declat, hr, min, sec, date) } }
awknav: { shipdate = $1 gpstime = $2 latdeg = substr($5,1,2) latdecmin = $6 declat = latdeg + (latdecmin/60) londeg = substr($7,1,3) londecmin = $8 declon = -1 * (londeg + (londecmin/60)) depmeters = $10 printf("%s, %s, %9.6f, %9.6f, %s\n",shipdate, gpstime, declat, declon, depmeters) }
awk_sddpt: { depthval = $1 printf("$SDDPT,%s,0.0*65\n",depthval) }