1GPSPROF(1) GPSPROF(1)
2
3
4
6 gpsprof - profile a GPS and gpsd, plotting latency information
7
9 gpsprof [-f plot_type] [-m threshold] [-n packetcount] [-s speed]
10 [-t title] [-h]
11
12
14 gpsprof measures the various latencies between a GPS and its client. It
15 emits to standard output a GNUPLOT program that draws an illustrative
16 graph. It can also be told to emit the raw profile data. The informa‐
17 tion it provides can be useful for establishing an upper bound on la‐
18 tency, and thus on position accuracy of a GPS in motion.
19
20
21 gpsprof uses instrumentation built into gpsd.
22
23
24 To display the graph, use gnuplot(1). Thus, for example, to display the
25 default spatial scatter plot, do this:
26
27
28 gpsprof | gnuplot -persist
29
30
31
32
34 The -f option sets the plot type. The X axis is samples (sentences with
35 timestamps). The Y axis is normally latency in seconds. Currently the
36 following plot types are defined:
37
38
39 space Generate a scattergram of fixes and plot a probable-error cir‐
40 cle. This data is only meaningful if the GPS is held stationary
41 while gpsprof is running. This is the default.
42
43
44
45
46 uninstrumented
47 Plot total latency without instrumentation. Useful mainly as a
48 check that the instrumentation is not producing significant dis‐
49 tortion. It only plots times for sentences that contain fixes;
50 staircase-like artifacts in the plot are created when elapsed
51 time from sentences without fixes is lumped in.
52
53
54 raw Plot raw data.
55
56
57 split Each sentence has its RS232 latency time colored differently.
58
59
60 cycle Report on the set of sentences or packets emitted by the GPS,
61 their send intervals, and the basic cycle time. (This report is
62 plain text rather than a gnuplot script.)
63
64
65 The instrumented time plot conveys the following information:
66
67
68 RS232 time
69 Minimum time required to send the sentence from the GPS to gpsd.
70 This is computed, not measured, and may be an underestimate.
71
72
73 Other line latency
74 The transmission latency between the GPS and gpsd not accounted
75 for by RS232 time. Total line latency (the sum of this bar and
76 RS232 time) is measured; it begins with the GPS sentence's time‐
77 stamp and ends with a timestamp that gpsd generates at sen‐
78 tence-reading time, before it is decoded.
79
80
81 Decode time
82 Elapsed time between sentence reception and the moment that gpsd
83 ships the resulting update to the profiling client.
84
85
86 TCP/IP latency
87 Elapsed time between the moment that gpsd ships the update to
88 the profiling client and the moment it is decoded and times‐
89 tamped.
90
91
92 Because of RS232 buffering effects, the profiler sometimes generates
93 reports of ridiculously high latencies right at the beginning of a ses‐
94 sion. The -m option lets you set a latency threshold, in multiples of
95 the cycle time, above which reports are discarded.
96
97
98 The -n option sets the number of packets to sample. The default is 100.
99
100
101 The -s option sets the baud rate. Note, this will only work if the
102 chipset accepts a speed-change command (SiRFstarII and SiRFstarIII sup‐
103 port this feature).
104
105
106 The -t option sets a text string to be included in the plot title.
107
108
109 The -h option makes gpsprof print a usage message and exit.
110
111
113 Probably overestimates TCP/IP latency somewhat, as that includes the
114 Python interpreter's decode time. A C client would be faster.
115
116
118 gpsd(8), gps(1), libgps(3), libgpsd(3), gpsfake(1), gpsctl(1), gp‐
119 scat(1), gnuplot(1).
120
121
123 Eric S. Raymond <esr@thyrsus.com>. There is a project page for gpsd
124 here: http://gpsd.berlios.de/.
125
126
127
128
129 GPSPROF(1)