NAME
gpsfs, gpsevermore – GPS time and position service |
SYNOPSIS
aux/gpsfs [ –d device ] [ –b baud ] [ –s srvname ] [ –m mntpt ]
aux/gpsevermore [ –d device ] [ –b baud ] [ –n baud ] [ –l location
] |
DESCRIPTION
Aux/gpsfs reads an NMEA–compatible serial GPS (Global Positioning
System) device and provides time and position through a file system,
by default mounted on /mnt and implementing /mnt/gps. It implements four files in the gps directory: position, time, satellites, and raw.
The read–only position file contains one line of information in
9 tab–separated fields:
The read–only time file contains one line of information in 4 tab–separated
fields:
The read–only satellites file contains information about the current
satellite constellation. It consists of one line of general information,
followed by zero or more lines, one for each satellite in use.
The first line contains two fields:
Subsequent lines have four fields: The contents of these files are refreshed once per second when reading from an actual GPS, and once per 100 ms (giving a speed up of a factor 10) when playing back from file. The read–only raw file can be read to obtain a copy of the raw NMEA GPS output. Gpsfs keeps an internal buffer of 8KB, so the reader must keep up with the output (typically 500 or so bytes per second). The –d flag establishes the device the GPS samples are read from. If the device file is not a serial interface, gpsfs assumes playback from file and modifies quality parameters as such. The –b flag specifies the baud rate of the serial line. The standard baud rate for NMEA GPS is 4800 baud, but many device allow changing to higher speeds. The –s flag specifies the name under which the gpsfs service is posted in /srv.
The –m flag specifies a mount mount other than /mnt. Evermore The –d flag specifies the serial device to the GPS. The –b flag specifies the baud rate of the serial line. The standard baud rate for NMEA GPS is 4800 baud, but many device allow changing to higher speeds. The –n flag specifies the speed to set the GPS to. When the command finishes, the GPS should be read (and configured) at the new speed.
The –l flag is sued to specify the location to initialize the GPS
to. The format is dd:mm:ssX or dd:mm.mmmX or dd.dddX, where dd
stands for degrees (one or more digits), mm for minutes and ss
for seconds of arc. X is one of W, E, N or S. Longitudes come
with W or E, latitudes with N or S. The –l flag is
followed by two such fields, one for longitude, one for latitude.
They may be given in a single argument (separated by white space),
or in two arguments, in either order. Initialization time is taken
from time(2). |
SEE ALSO
timesync(8), time(2) |
FILES
/mnt/gps/position position, time, speed and heading /mnt/gps/satellites satellites in view /mnt/gps/time GPS time (millisecond accuracy) /dev/eia0 default GPS device |
SOURCE
/sys/src/cmd/aux/gps |