'\" t .\" Title: gpsdecode .\" Author: [see the "AUTHOR" section] .\" Generator: DocBook XSL Stylesheets vsnapshot .\" Date: 6 December 2020 .\" Manual: GPSD Documentation .\" Source: The GPSD Project .\" Language: English .\" .TH "GPSDECODE" "1" "6 December 2020" "The GPSD Project" "GPSD Documentation" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" gpsdecode \- decode GPS, RTCM or AIS streams into a readable format .SH "SYNOPSIS" .HP \w'\fBgpsdecode\fR\ 'u \fBgpsdecode\fR [\-?] [\-\-ais] [\-\-decode] [\-\-debug\ \fILVL\fR] [\-\-encode] [\-\-help] [\-\-json] [\-\-minlength] [\-\-nmea] [\-\-split24] [\-\-types\ \fItypelist\fR] [\-\-unscaled] [\-\-verbose] [\-\-version] [\-c] [\-d] [\-D\ \fILVL\fR] [\-e] [\-h] [\-j] [\-m] [\-n] [\-s] [\-t\ \fItypelist\fR] [\-u] [\-v] [\-V] .SH "DESCRIPTION" .PP This tool is a batch\-mode decoder for NMEA and various binary packet formats associated with GPS, AIS, and differential\-correction services\&. It produces a JSON dump on standard output from binary on standard input\&. The JSON is the same format documented in \fBgpsd\fR(8); this tool uses the same decoding logic as gpsd, but with a simpler interface intended for batch processing of data files\&. .PP All sensor\-input formats known to the GPSD project can be decoded by this tool\&. These include: NMEA, AIVDM (the NMEA\-derived sentence format used by AIS, the marine Automatic Identification System), RTCM2, and all supported GPS binary formats (notably including SiRF)\&. See \fBgpsd\fR(8) for applicable standards and known limitations of the decoding logic\&. .PP You can use this tool with \fBnc\fR(1) to examine AIS feeds from AIS pooling services, RTCM feeds from RTCM receivers or NTRIP broadcasters\&. .SH "OPTIONS" .PP \fB\-?\fR, \fB\-h\fR, \fB\-\-help\fR .RS 4 Output a usage mssage, then exit\&. .RE .PP \fB\-c\fR, \fB\-\-json\fR .RS 4 Sets the AIS dump format to separate fields with an ASCII pipe symbol\&. Fields are dumped in the order they occur in the AIS packet\&. Numerics are not scaled (\fB\-u\fR is forced)\&. Strings are unpacked from six\-bit to full ASCII .RE .PP \fB\-d\fR, \fB\-\-decode\fR .RS 4 Decode packets presented on standard input to standard output\&. This is the default behavior\&. .RE .PP \fB\-D LVL\fR, \fB\-\-debug LVL\fR .RS 4 Set the debug verbosity level to LVL\&. It is mainly of interest to for troubleshooting\&. .RE .PP \fB\-e\fR, \fB\-\-encode\fR .RS 4 Encode JSON on standard input to JSON on standard output\&. This option is only useful for regression\-testing of the JSON dumping and parsing code\&. .RE .PP \fB\-j\fR, \fB\-\-json\fR .RS 4 Sets the output dump format to JSON (the default behavior)\&. .RE .PP \fB\-m\fR, \fB\-\-minlength\fR .RS 4 Dump minimum lengths for each packet type in the input (ignoring comment packets)\&. This is probably of interest only to GSD developers\&. .RE .PP \fB\-n\fR, \fB\-\-nmea\fR .RS 4 Dump the generated pseudo\-NME0183\&. .RE .PP \fB\-s\fR, \fB\-\-split24\fR .RS 4 Report AIS Type 24 sentence halves separately rather than attempting to aggregate them\&. .RE .PP \fB\-t TYPES\fR, \fB\-\-types TYPES\fR .RS 4 A comma\-separated list of numeric types\&. Packets with a numeric AIS, RTCM2, or RTCM3 type are passed through and output only if they match a type in the list\&. Packets of other kinds (in particular GPS packets) are passed through unconditionally\&. .RE .PP \fB\-u\fR, \fB\-\-unsscaled\fR .RS 4 Suppress scaling of AIS data to float quantities and text expansion of numeric codes\&. A dump with this option is lossless\&. .RE .PP \fB\-v\fR, \fB\-\-verbose\fR .RS 4 Dump textual packets to output as they are received on input, immediately preceding corresponding output\&. .RE .PP \fB\-V\fR, \fB\-\-version\fR .RS 4 Print version number, then exit\&. .RE .SH "AIS DSV FORMAT" .PP With the \fB\-c, \-\-ais\fR option, dump lines are values of AIS payload fields, pipe\-separated, in the order that they occur in the payload\&. Spans of fields expressing a date are emitted as an ISO8601 timestamp (look for colons and the trailing Z indicating Zulu/UTC time), and the 19\-bit group of TDMA status fields found at the end of message types 1\-4 are are dumped as a single unsigned integer (in hex preceded by "0x")\&. Unused regional\-authority fields are also dumped (in hex preceded by "0x")\&. Variable\-length binary fields are dumped as an integer bit length, followed by a colon, followed by a hex dump\&. .SH "SEE ALSO" .PP \fBgpsd\fR(8), \fBgpsctl\fR(1), \fBgpsdctl\fR(8), \fBgps\fR(1), \fBlibgps\fR(3), \fBlibgpsmm\fR(3), \fBgpsprof\fR(1), \fBgpsfake\fR(1), .SH "AUTHOR" .PP Eric S\&. Raymond \&.