# ntploggps - log gpsd data for use by ntpviz

| from Alice’s Adventures in Wonderland, Lewis Carroll S is for snakeoil.

## 1. Manual Pages

### 1.1. Manual Pages

- `ntp.conf(5)` - ntpd Configuration File

- `ntp.keys(5)` - NTP symmetric key file format

- `ntpd(8)` - Network Time Protocol (NTP) daemon

- `ntpdig(1)` - Simple Network Time Protocol (SNTP) client

- `ntpfrob(8)` - frob the local clock hardware

- `ntpkeygen(8)` - generate public and private keys

- `ntpleapfetch(8)` fetch and manage leap-offset file

- `ntploggps(1)` - log gpsd data for use by ntpviz

- `ntplogtemp(1)` - log system temperature data for use by ntpviz

- `ntpmon(1)` - real-time NTP status monitor

- `ntpq(1)` - standard NTP query program

- `ntpsnmp(1)` - an AgentX Simple Network Management Protocol sub-agent [`experimental`]

- `ntpsweep(1)` - print information about given NTP servers

- `ntptime(8)` - read and set kernel time variables

- `ntptrace(1)` - trace a chain of NTP servers back to the primary source

- `ntpviz(1)` - make offset, jitter, and other plots from logfiles

- `ntpwait(8)` - wait until ntpd is in synchronized state

## 2. Table of Contents

- SYNOPSIS

- DESCRIPTION

- OPTIONS

- USAGE

- EXIT STATUS

- AUTHORS

## 3. SYNOPSIS

    ntploggps [-h] [-l LOGFILE] [-o] [-w WAIT] [-v] [-V]

    -h, --help            show this help message and exit
    -l LOGFILE, --logfile LOGFILE
                          append log data to LOGFILE instead of stdout
    -o, --once            log one line, then exit
    -w WAIT, --wait WAIT  wait WAIT seconds after each log line, default 5
    -v, --verbose         be verbose
    -V, --version         show program's version number and exit

## 4. DESCRIPTION

ntploggps connects to a local gpsd daemon and logs the number of satellites in use and the Time Dilution of Precision (TDOP). ntploggps can run as any user, no special privileges are required.

The default is to write the data to stdout about once every 5 seconds. The log file looks like:

    # Time       Device     TDOP     nSat
    1483668619.0 /dev/ttyS0 0.820000 7
    1483668624.0 /dev/ttyS0 0.820000 7
    1483668629.0 /dev/ttyS0 0.820000 7

`Time` is the POSIX time of when the log line is written.

`Device` is the GPS device the data came from.

`TDOP` is the Time Dilution of Precision as reported by the GPS. Some GPS always output a static TDOP.

`nSat` is the number of satellites in use.

## 5. OPTIONS

`-h, --help`

  Displays usage information and exits.

`-l LOGFILE, --logfile LOGFILE`

  Append log data to LOGFILE instead of stdout

`-o, --once`

  Log one line, then exit.

`-v, --verbose`

  Be verbose

`-w WAIT, --wait WAIT`

  Wait WAIT seconds after each log line. The default is 5 seconds. This is just the minimum wait time. gpsd may be reporting data at a much slower interval.

`-V, --version`

  show program’s version number and exit

## 6. USAGE

`ntploggps`

  This the simplest use of this program. It can be used to check the status of the local gpsd daemon.

`ntploggps -l /var/log/ntpstats/gpsd -w 60` &

  This will continuously log the gpsd data in the background to the file /var/log/ntpstats/gpsd. Only log every 60 seconds.

## 7. EXIT STATUS

One of the following exit values will be returned:

0 (EXIT_SUCCESS)

  Successful program execution.

1 (EXIT_FAILURE)

  The operation failed or the command syntax was not valid.

## 8. AUTHORS

Gary E. Miller

Home Page | Site Map | Contacts