xgps.xml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <!--
  3. This file is Copyright 2004 by the GPSD project
  4. SPDX-License-Identifier: BSD-2-clause
  5. -->
  6. <!DOCTYPE refentry PUBLIC
  7. "-//OASIS//DTD DocBook XML V4.1.2//EN"
  8. "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
  9. <refentry id='xgps.1'>
  10. <refentryinfo><date>30 Sep 2020</date></refentryinfo>
  11. <refmeta>
  12. <refentrytitle>xgps</refentrytitle>
  13. <manvolnum>1</manvolnum>
  14. <refmiscinfo class="source">The GPSD Project</refmiscinfo>
  15. <refmiscinfo class="manual">GPSD Documentation</refmiscinfo>
  16. </refmeta>
  17. <refnamediv id='name'>
  18. <refname>xgps</refname>
  19. <refname>xgpsspeed</refname>
  20. <refpurpose>sample clients for gpsd</refpurpose>
  21. </refnamediv>
  22. <refsynopsisdiv id='synopsis'>
  23. <cmdsynopsis>
  24. <command>xgps</command>
  25. <arg choice='opt'>--help </arg>
  26. <arg choice='opt'>--debug <replaceable>DEBUG-LEVEL</replaceable></arg>
  27. <arg choice='opt'>--device <replaceable>DEVICE</replaceable></arg>
  28. <arg choice='opt'>--host <replaceable>HOST</replaceable></arg>
  29. <arg choice='opt'>--port <replaceable>PORT</replaceable></arg>
  30. <arg choice='opt'>--rotate <replaceable>DEGREES</replaceable></arg>
  31. <arg choice='opt'>-? </arg>
  32. <arg choice='opt'>-D <replaceable>DEBUG-LEVEL</replaceable></arg>
  33. <arg choice='opt'>-h </arg>
  34. <arg choice='opt'>-l <group><arg>d</arg><arg>m</arg><arg>s</arg></group></arg>
  35. <arg choice='opt'>-r <replaceable>DEGREES</replaceable></arg>
  36. <arg choice='opt'>-u <group><arg>i</arg><arg>n</arg><arg>m</arg></group></arg>
  37. <arg choice='opt'>-V </arg>
  38. <group>
  39. <replaceable>server</replaceable>
  40. <group>
  41. <replaceable>:port</replaceable>
  42. <group><replaceable>:device</replaceable></group>
  43. </group>
  44. </group>
  45. </cmdsynopsis>
  46. <cmdsynopsis>
  47. <command>xgpsspeed</command>
  48. <arg choice='opt'>--debug <replaceable>DEBUG-LEVEL</replaceable></arg>
  49. <arg choice='opt'>--device <replaceable>DEVICE</replaceable></arg>
  50. <arg choice='opt'>--help </arg>
  51. <arg choice='opt'>--host <replaceable>HOST</replaceable></arg>
  52. <arg choice='opt'>--landspeed </arg>
  53. <arg choice='opt'>--maxspeed <replaceable>MAXSPEED</replaceable></arg>
  54. <arg choice='opt'>--nautical </arg>
  55. <arg choice='opt'>--port <replaceable>PORT</replaceable></arg>
  56. <arg choice='opt'>--rotate <replaceable>DEGREES</replaceable></arg>
  57. <arg choice='opt'>--speedunits
  58. <group choice='req'>
  59. <arg>mph</arg><arg>kmh</arg><arg>knots</arg>
  60. </group>
  61. </arg>
  62. <arg choice='opt'>-D <replaceable>DEBUG-LEVEL</replaceable></arg>
  63. <arg choice='opt'>-? </arg>
  64. <arg choice='opt'>-h </arg>
  65. <arg choice='opt'>-r <replaceable>DEGREES</replaceable></arg>
  66. <arg choice='opt'>-V </arg>
  67. <group>
  68. <replaceable>server</replaceable>
  69. <group>
  70. <replaceable>:port</replaceable>
  71. <group><replaceable>:device</replaceable></group>
  72. </group>
  73. </group>
  74. </cmdsynopsis>
  75. </refsynopsisdiv>
  76. <refsect1 id='description'><title>DESCRIPTION</title>
  77. <para>These are two sample clients shipped with
  78. <application>gpsd</application>. They have some common options:</para>
  79. <para>The <option>-h</option> option causes each client to emit a summary of its
  80. options and then exit.</para>
  81. <para>The <option>-V</option> option causes each client to dump the package
  82. version and exit.</para>
  83. <para> The <option>-l</option> option, when present, sets the format
  84. of latitude and longitude reports. The value 'd' produces decimal
  85. degrees and is the default. The value 'm' produces degrees and
  86. decimal minutes. The value 's' produces degrees, minutes, and decimal
  87. seconds.</para>
  88. <para><application>xgps</application>,
  89. <application>cgps</application>, and <application>lcdgps</application>
  90. look at variables in the environment to figure out what units they
  91. should default to using for display &mdash; imperial, nautical, or
  92. metric. Here are the variables and values they check:</para>
  93. <screen>
  94. GPSD_UNITS one of:
  95. i = miles/feet
  96. imperial = miles/feet
  97. n = knots/feet
  98. nautical = knots/feet
  99. m = km/meters
  100. metric = km/meters
  101. LC_MEASUREMENT
  102. en_US = miles/feet
  103. C = miles/feet
  104. POSIX = miles/feet
  105. [other] = km/meters
  106. LANG
  107. en_US = miles/feet
  108. C = miles/feet
  109. POSIX = miles/feet
  110. [other] = km/meters
  111. </screen>
  112. <para>These preferences may be overridden by the <option>-u</option>
  113. option.</para>
  114. <para>The <option>-u</option> option can be used to set
  115. the system units for display; follow the keyword with 'i' for
  116. 'imperial' for American units (International Feet in altitude and error
  117. estimates, miles per hour in speeds), 'n' for 'nautical' (feet in altitude
  118. and error estimates, knots in speed) or 'm' for 'metric' (meters in
  119. altitude and error estimates, kilometers per hour in speeds).</para>
  120. <para>Note: The USA Survey Foot is not supported.</para>
  121. <para> The <option>-D</option> option, when present, sets a debug
  122. level; it is primarily for use by GPSD developers. It enables
  123. various progress messages to standard error.</para>
  124. <para>By default, clients collect data from all compatible devices on
  125. localhost, using the default GPSD port 2947. An optional argument to any
  126. client may specify a server to get data from. A colon-separated suffix
  127. is taken as a port number. If there is a second colon-separated
  128. suffix, that is taken as a specific device name to be
  129. watched. However, if the server specification contains square
  130. brackets, the part inside them is taken as an IPv6 address and
  131. port/device suffixes are only parsed after the trailing bracket.
  132. Possible cases look like this:</para>
  133. <para>The options for xgps can be placed in the XGPSOPTS environment variable.
  134. XGPSOPTS is processed before the CLI options.</para>
  135. <variablelist>
  136. <varlistentry>
  137. <term>localhost:/dev/ttyS1</term>
  138. <listitem><para>Look at the default port of localhost, trying both
  139. IPv4 and IPv6 and watching output from serial device 1.</para></listitem>
  140. </varlistentry>
  141. <varlistentry>
  142. <term>example.com:2317</term>
  143. <listitem><para>Look at port 2317 on example.com, trying both
  144. IPv4 and IPv6.</para></listitem>
  145. </varlistentry>
  146. <varlistentry>
  147. <term>71.162.241.5:2317:/dev/ttyS3</term>
  148. <listitem><para>Look at port 2317 at the specified IPv4
  149. address, collecting data from attached serial device 3.</para></listitem>
  150. </varlistentry>
  151. <varlistentry>
  152. <term>[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:2317:/dev/ttyS5</term>
  153. <listitem><para>Look at port 2317 at the specified IPv6
  154. address, collecting data from attached serial device 5.</para></listitem>
  155. </varlistentry>
  156. </variablelist>
  157. <refsect2><title>xgps</title>
  158. <para><application>xgps</application> is a simple sample client for
  159. <application>gpsd</application> with an X interface. It displays
  160. current GPS position/time/velocity information and (for GPSes that
  161. support the feature) the locations of accessible satellites.</para>
  162. <para>In the sky view, satellites are color-coded to indicate quality
  163. of signal; consult the data display to the left for exact figures in
  164. dB. Diamond-shaped icons indicate GLONASS satellites, squares are used
  165. for SBAS (e.g. WAAS, EGNOS), circles indicate GPS, and down-, up-,
  166. right-, and left-pointing triangles, respectively, indicate Galileo,
  167. BeiDou, QZSS, and other systems' satellites (e.g. IMES, IRNSS, as well
  168. as unknown systems). Filled icons were used in the current fix,
  169. outline icons were not. Hovering over a symbol with the mouse pointer
  170. will temporarily display a small popup window with the satellite
  171. details from the Satellite List pane.</para>
  172. <para>The -r option accepts an argument in degrees, to rotate the
  173. skyview counterclockwise.</para>
  174. </refsect2>
  175. <refsect2><title>xgpsspeed</title>
  176. <para><application>xgpsspeed</application> is a speedometer that uses
  177. position information from the GPS. It accepts an -h option and
  178. optional argument as for <application>gps</application>, or a -V
  179. option to dump the package version and exit.</para>
  180. <para>The default display mode is a speed and track presentation
  181. modeled after a marine navigation display; for backward compatibility
  182. the --nautical option forces this mode. The --landspeed option produces
  183. a simple speedometer.</para>
  184. <para>The --speedunits option can be used to set the speed units for
  185. display; follow the keyword with knots for nautical miles per hour,
  186. kmh for kilometers per hour, or mph for miles per hour. The default
  187. is miles per hour.</para>
  188. <para>In the nautical mode only, --maxspeed sets the maximum on the
  189. speedometer.</para>
  190. </refsect2>
  191. </refsect1>
  192. <refsect1 id='environment'><title>ENVIRONMENT</title>
  193. <para>The environment variable <envar>GPSD_UNITS</envar> is checked
  194. if no unit system is specified on the command line or in
  195. <envar>XPGSOPTS</envar> it may be set to 'i'. 'imperial', 'm', 'metric', or
  196. 'n', 'nautical'.</para>
  197. <para><envar>LC_MEASUREMENT</envar> and then <envar>LANG</envar> are
  198. checked if no unit system has been specified on the command line, in
  199. <envar>XPGSOPTS</envar> or in <envar>GPSD_UNITS</envar>. If the value
  200. is 'C', 'POSIX', or begins with
  201. 'en_US' the unit system is set to imperial. The default
  202. if no system has been selected defaults to metric.</para>
  203. <para>The <option>XGPSOPTS></option> environment variable may be set to
  204. pass commonly used command line options to <command>xgps</command>
  205. and <command>xgpsspeed</command>. This is often used to set the
  206. <option>-u</option> option for locale specific units.
  207. <option>XGPSOPTS</option> is processed before the CLI options.</para>
  208. </refsect1>
  209. <refsect1 id='see_also'><title>SEE ALSO</title>
  210. <para>
  211. <citerefentry><refentrytitle>gpsd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
  212. <citerefentry><refentrytitle>libgps</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
  213. <citerefentry><refentrytitle>libgpsmm</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
  214. <citerefentry><refentrytitle>gpsfake</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
  215. <citerefentry><refentrytitle>gpsctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
  216. <citerefentry><refentrytitle>gpscat</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
  217. <citerefentry><refentrytitle>gpsprof</refentrytitle><manvolnum>1</manvolnum></citerefentry>.
  218. <citerefentry><refentrytitle>gpspipe</refentrytitle><manvolnum>1</manvolnum></citerefentry>.
  219. <citerefentry><refentrytitle>gpsmon</refentrytitle><manvolnum>1</manvolnum></citerefentry>.
  220. <citerefentry><refentrytitle>gpxlogger</refentrytitle><manvolnum>1</manvolnum></citerefentry>.
  221. </para>
  222. </refsect1>
  223. <refsect1 id='maintainer'><title>AUTHORS</title>
  224. <para>
  225. Remco Treffcorn, Derrick Brashear, Russ Nelson &amp; Eric S. Raymond,
  226. Jeff Francis (cgps), Chen Wei <email>weichen302@aol.com</email> (gegps &amp; xgpsspeed),
  227. Robin Wittler <email>real@the-real.org</email> (xgpsspeed).
  228. </para>
  229. <para>This manual page by Eric S. Raymond <email>esr@thyrsus.com</email></para>
  230. </refsect1>
  231. </refentry>