1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359
|
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
]>
<refentry id="gdbus-org.freedesktop.ModemManager1.Modem.Location">
<refmeta> <refentrytitle role="top_of_page" id="gdbus-interface-org-freedesktop-ModemManager1-Modem-Location.top_of_page">org.freedesktop.ModemManager1.Modem.Location</refentrytitle>
<indexterm zone="gdbus-interface-org-freedesktop-ModemManager1-Modem-Location.top_of_page"><primary sortas="Modem.Location">org.freedesktop.ModemManager1.Modem.Location</primary></indexterm>
</refmeta> <refnamediv> <refname>org.freedesktop.ModemManager1.Modem.Location</refname> <refpurpose>The ModemManager Location interface.</refpurpose> </refnamediv> <refsynopsisdiv role="synopsis">
<title role="synopsis.title">Methods</title>
<synopsis>
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.Setup">Setup</link> (IN u sources,
IN b signal_location);
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.GetLocation">GetLocation</link> (OUT a{uv} Location);
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.SetSuplServer">SetSuplServer</link> (IN s supl);
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.SetGpsRefreshRate">SetGpsRefreshRate</link> (IN u rate);
</synopsis>
</refsynopsisdiv>
<refsect1 role="properties">
<title role="properties.title">Properties</title>
<synopsis>
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Capabilities">Capabilities</link> readable u
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Enabled">Enabled</link> readable u
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.SignalsLocation">SignalsLocation</link> readable b
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Location">Location</link> readable a{uv}
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.SuplServer">SuplServer</link> readable s
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.GpsRefreshRate">GpsRefreshRate</link> readable u
</synopsis>
</refsect1>
<refsect1 role="desc" id="gdbus-interface-org-freedesktop-ModemManager1-Modem-Location">
<title role="desc.title">Description</title>
<para> The Location interface allows devices to provide location information to
client applications. Not all devices can provide this information, or even
if they do, they may not be able to provide it while a data session is
active.
</para>
</refsect1>
<refsect1 role="details" id="gdbus-methods-org.freedesktop.ModemManager1.Modem.Location">
<title role="details.title">Method Details</title>
<refsect2 role="method" id="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.Setup">
<title>The Setup() method</title>
<indexterm zone="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.Setup"><primary sortas="Modem.Location.Setup">org.freedesktop.ModemManager1.Modem.Location.Setup()</primary></indexterm>
<programlisting>
Setup (IN u sources,
IN b signal_location);
</programlisting>
<para> Configure the location sources to use when gathering location
information. Also enable or disable location information gathering.
This method may require the client to authenticate itself.
</para><para> When signals are emitted, any client application (including malicious
ones!) can listen for location updates unless D-Bus permissions restrict
these signals from certain users. If further security is desired, the
<parameter>signal_location</parameter> argument can be set to <constant>FALSE</constant> to disable location
updates via D-Bus signals and require applications to call
authenticated APIs (like
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.GetLocation">GetLocation()</link>
) to get
location information.
</para><para> The optional
<link linkend="MM-MODEM-LOCATION-SOURCE-AGPS:CAPS">MM_MODEM_LOCATION_SOURCE_AGPS</link>
allows to request A-GPS operation, and it must be given along with either
<link linkend="MM-MODEM-LOCATION-SOURCE-GPS-RAW:CAPS">MM_MODEM_LOCATION_SOURCE_GPS_RAW</link>
or
<link linkend="MM-MODEM-LOCATION-SOURCE-GPS-NMEA:CAPS">MM_MODEM_LOCATION_SOURCE_GPS_NMEA</link>.
</para>
<variablelist role="params">
<varlistentry>
<term><literal>IN u <parameter>sources</parameter></literal>:</term>
<listitem><para>Bitmask of <link linkend="MMModemLocationSource">MMModemLocationSource</link> flags, specifying which sources should get enabled or disabled. <link linkend="MM-MODEM-LOCATION-SOURCE-NONE:CAPS">MM_MODEM_LOCATION_SOURCE_NONE</link> will disable all location gathering.</para></listitem>
</varlistentry>
<varlistentry>
<term><literal>IN b <parameter>signal_location</parameter></literal>:</term>
<listitem><para>Flag to control whether the device emits signals with the new location information. This argument is ignored when disabling location information gathering.</para></listitem>
</varlistentry>
</variablelist>
</refsect2>
<refsect2 role="method" id="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.GetLocation">
<title>The GetLocation() method</title>
<indexterm zone="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.GetLocation"><primary sortas="Modem.Location.GetLocation">org.freedesktop.ModemManager1.Modem.Location.GetLocation()</primary></indexterm>
<programlisting>
GetLocation (OUT a{uv} Location);
</programlisting>
<para> Return current location information, if any. If the modem supports
multiple location types it may return more than one. See the
<link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Location">"Location"</link> property
for more information on the dictionary returned at <parameter>location</parameter>.
</para><para> This method may require the client to authenticate itself.
</para>
<variablelist role="params">
<varlistentry>
<term><literal>OUT a{uv} <parameter>Location</parameter></literal>:</term>
<listitem><para></para></listitem>
</varlistentry>
</variablelist>
</refsect2>
<refsect2 role="method" id="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.SetSuplServer">
<title>The SetSuplServer() method</title>
<indexterm zone="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.SetSuplServer"><primary sortas="Modem.Location.SetSuplServer">org.freedesktop.ModemManager1.Modem.Location.SetSuplServer()</primary></indexterm>
<programlisting>
SetSuplServer (IN s supl);
</programlisting>
<para> Configure the SUPL server for A-GPS.
</para>
<variablelist role="params">
<varlistentry>
<term><literal>IN s <parameter>supl</parameter></literal>:</term>
<listitem><para>SUPL server configuration, given either as IP:PORT or with a full URL.</para></listitem>
</varlistentry>
</variablelist>
</refsect2>
<refsect2 role="method" id="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.SetGpsRefreshRate">
<title>The SetGpsRefreshRate() method</title>
<indexterm zone="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.SetGpsRefreshRate"><primary sortas="Modem.Location.SetGpsRefreshRate">org.freedesktop.ModemManager1.Modem.Location.SetGpsRefreshRate()</primary></indexterm>
<programlisting>
SetGpsRefreshRate (IN u rate);
</programlisting>
<para> Set the refresh rate of the GPS information in the API. If not explicitly
set, a default of 30s will be used.
</para><para> The refresh rate can be set to 0 to disable it, so that every update reported by
the modem is published in the interface.
</para>
<variablelist role="params">
<varlistentry>
<term><literal>IN u <parameter>rate</parameter></literal>:</term>
<listitem><para>Rate, in seconds.</para></listitem>
</varlistentry>
</variablelist>
</refsect2>
</refsect1>
<refsect1 role="details" id="gdbus-properties-org.freedesktop.ModemManager1.Modem.Location">
<title role="details.title">Property Details</title>
<refsect2 role="property" id="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Capabilities">
<title>The "Capabilities" property</title>
<indexterm zone="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Capabilities"><primary sortas="Modem.Location:Capabilities">org.freedesktop.ModemManager1.Modem.Location:Capabilities</primary></indexterm>
<programlisting>
Capabilities readable u
</programlisting>
<para> Bitmask of <link linkend="MMModemLocationSource">MMModemLocationSource</link>
values, specifying the supported location sources.
</para>
</refsect2>
<refsect2 role="property" id="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Enabled">
<title>The "Enabled" property</title>
<indexterm zone="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Enabled"><primary sortas="Modem.Location:Enabled">org.freedesktop.ModemManager1.Modem.Location:Enabled</primary></indexterm>
<programlisting>
Enabled readable u
</programlisting>
<para> Bitmask specifying which of the supported
<link linkend="MMModemLocationSource">MMModemLocationSource</link>
location sources is currently enabled in the device.
</para>
</refsect2>
<refsect2 role="property" id="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.SignalsLocation">
<title>The "SignalsLocation" property</title>
<indexterm zone="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.SignalsLocation"><primary sortas="Modem.Location:SignalsLocation">org.freedesktop.ModemManager1.Modem.Location:SignalsLocation</primary></indexterm>
<programlisting>
SignalsLocation readable b
</programlisting>
<para> <constant>TRUE</constant> if location updates will be emitted via D-Bus signals, <constant>FALSE</constant> if
location updates will not be emitted.
</para><para> See the
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.Setup">Setup()</link>
method for more information.
</para>
</refsect2>
<refsect2 role="property" id="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Location">
<title>The "Location" property</title>
<indexterm zone="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Location"><primary sortas="Modem.Location:Location">org.freedesktop.ModemManager1.Modem.Location:Location</primary></indexterm>
<programlisting>
Location readable a{uv}
</programlisting>
<para> Dictionary of available location information when location information
gathering is enabled. If the modem supports multiple location types it
may return more than one here.
</para><para> Note that if the device was told not to emit updated location
information when location information gathering was initially enabled,
this property may not return any location information for security reasons.
</para><para> This dictionary is composed of a
<link linkend="MMModemLocationSource">MMModemLocationSource</link>
key, with an associated data which contains type-specific location
information:
</para><para> <variablelist>
<varlistentry><term><link linkend="MM-MODEM-LOCATION-SOURCE-3GPP-LAC-CI:CAPS">MM_MODEM_LOCATION_SOURCE_3GPP_LAC_CI</link></term>
<listitem>
<para>
Devices supporting this
capability return a string in the format <literal>"MCC,MNC,LAC,CI"</literal> (without the
quotes of course) where the following applies:
</para>
<variablelist>
<varlistentry><term><literal>MCC</literal></term>
<listitem>
This is the three-digit ITU E.212 Mobile Country Code of the
network provider to which the mobile is currently registered.
e.g. <literal>"310"</literal>.
</listitem>
</varlistentry>
<varlistentry><term><literal>MNC</literal></term>
<listitem>
This is the two- or three-digit GSM Mobile Network Code of the
network provider to which the mobile is currently registered.
e.g. <literal>"26"</literal> or <literal>"260"</literal>.
</listitem>
</varlistentry>
<varlistentry><term><literal>LAC</literal></term>
<listitem>
This is the two-byte Location Area Code of the base station with
which the mobile is registered, in upper-case hexadecimal format
without leading zeros, as specified in 3GPP TS 27.007 section
10.1.19. e.g. <literal>"84CD"</literal>.
</listitem>
</varlistentry>
<varlistentry><term><literal>CI</literal></term>
<listitem>
This is the two- or four-byte Cell Identifier with which the mobile
is registered, in upper-case hexadecimal format without leading
zeros, as specified in 3GPP TS 27.007.
e.g. <literal>"2BAF"</literal> or <literal>"D30156"</literal>.
</listitem>
</varlistentry>
</variablelist>
<para>
The entire string may only be composed of the ASCII digits <literal>[0-9]</literal>,
the alphabetical characters <literal>[A-F]</literal>, and the comma (<literal>,</literal>) character.
No other characters are allowed. For example: <literal>"310,260,8BE3,2BAF"</literal> or
<literal>"250,40,CE00,1CEAD8F0"</literal>.
</para>
<para>
If any of these four items (<literal>MCC</literal>, <literal>MNC</literal>,
<literal>LAC</literal>, <literal>CI</literal>) is unknown or the
mobile is not registered with a network, then the
<link linkend="MM-MODEM-LOCATION-SOURCE-3GPP-LAC-CI:CAPS">MM_MODEM_LOCATION_SOURCE_3GPP_LAC_CI</link>
location
information item should not be provided as a returned value from the
<link linkend="gdbus-method-org-freedesktop-ModemManager1-Modem-Location.GetLocation">GetLocation()</link>
method or in the <link linkend="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.Location">"Location"</link> property.
</para>
</listitem>
</varlistentry>
<varlistentry><term><link linkend="MM-MODEM-LOCATION-SOURCE-GPS-RAW:CAPS">MM_MODEM_LOCATION_SOURCE_GPS_RAW</link></term>
<listitem>
<para>
Devices supporting this
capability return a D-Bus dictionary (signature <literal>"a{sv}"</literal>) mapping well-known
keys to values with defined formats.
</para>
<para>
The allowed key/value pairs and their formats are:
</para>
<variablelist>
<varlistentry><term><literal>"utc-time"</literal></term>
<listitem>
(Required) UTC time in ISO 8601 format, given as a string value (signature <literal>"s"</literal>). e.g. <literal>203015</literal>.
</listitem>
</varlistentry>
<varlistentry><term><literal>"latitude"</literal></term>
<listitem>
(Required) Latitude in Decimal Degrees (positive numbers mean N quadrasphere, negative mean S quadrasphere), given as a double value (signature <literal>"d"</literal>). e.g. <literal>38.889722</literal>, meaning 38d 53' 22" N.
</listitem>
</varlistentry>
<varlistentry><term><literal>"longitude"</literal></term>
<listitem>
(Required) Longitude in Decimal Degrees (positive numbers mean E quadrasphere, negative mean W quadrasphere), given as a double value (signature <literal>"d"</literal>). e.g. <literal>-77.008889</literal>, meaning 77d 0' 32" W.
</listitem>
</varlistentry>
<varlistentry><term><literal>"altitude"</literal></term>
<listitem>
(Optional) Altitude above sea level in meters, given as a double value (signature <literal>"d"</literal>). e.g. <literal>33.5</literal>.
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry><term><link linkend="MM-MODEM-LOCATION-SOURCE-GPS-NMEA:CAPS">MM_MODEM_LOCATION_SOURCE_GPS_NMEA</link></term>
<listitem>
<para>
Devices supporting this capability return
a string containing one or more NMEA sentences (D-Bus signature <literal>'s'</literal>).
The manager will cache the most recent NMEA sentence of each type for
a period of time not less than 30 seconds. When reporting multiple
NMEA sentences, sentences shall be separated by an ASCII Carriage
Return and Line Feed (<literal><CR><LF></literal>) sequence.
</para>
<para>
For example, if the device sends a <literal>$GPRMC</literal> sentence immediately
followed by a <literal>$GPGGA</literal> sentence, the reported location string would be
(where of course the <literal><CR><LF></literal> is replaced with the actual
ASCII <literal>CR</literal> (0x0D) and <literal>LF</literal> (0x0A) control characters):
<para><literal>
$GPRMC,134523.92,V,,,,,,,030136,,,N*73<CR><LF>$GPGGA,,,,,,0,00,0.5,,M,0.0001999,M,0.0000099,0000*45
</literal></para>
If the device sends a new <literal>$GPRMC</literal> three seconds later, the new <literal>$GPRMC</literal>
replaces the previously received <literal>$GPRMC</literal> sentence, and the updated
string would be:
<para><literal>
$GPRMC,134526.92,V,,,,,,,030136,,,N*76<CR><LF>$GPGGA,,,,,,0,00,0.5,,M,0.0001999,M,0.0000099,0000*45
</literal></para>
If the device then sends a <literal>$GPGSA</literal> sentence about 5 seconds later, the
<literal>$GPGSA</literal> sentence is added to the string (since no <literal>$GPGSA</literal> sentence was
obviously received in this session), the updated string would be:
<para><literal>
$GPRMC,134526.92,V,,,,,,,030136,,,N*76<CR><LF>$GPGGA,,,,,,0,00,0.5,,M,0.0001999,M,0.0000099,0000*45<CR><LF>$GPGSA,A,1,,,,,,,,,,,,,1.1,0.5,1.0*34
</literal></para>
The manager may discard any cached sentences older than 30 seconds.
</para>
<para>
This allows clients to read the latest positioning data as soon as
possible after they start, even if the device is not providing
frequent location data updates.
</para>
</listitem>
</varlistentry>
<varlistentry><term><link linkend="MM-MODEM-LOCATION-SOURCE-CDMA-BS:CAPS">MM_MODEM_LOCATION_SOURCE_CDMA_BS</link></term>
<listitem>
<para>
Devices supporting this
capability return a D-Bus dictionary (signature <literal>"a{sv}"</literal>) mapping well-known
keys to values with defined formats.
</para>
<para>
The allowed key/value pairs and their formats are:
</para>
<variablelist>
<varlistentry><term><literal>"latitude"</literal></term>
<listitem>
(Required) Latitude in Decimal Degrees (positive numbers mean N quadrasphere, negative mean S quadrasphere), given as a double value (signature <literal>"d"</literal>). e.g. <literal>38.889722</literal>, meaning 38d 53' 22" N.
</listitem>
</varlistentry>
<varlistentry><term><literal>"longitude"</literal></term>
<listitem>
(Required) Longitude in Decimal Degrees (positive numbers mean E quadrasphere, negative mean W quadrasphere), given as a double value (signature <literal>"d"</literal>). e.g. <literal>-77.008889</literal>, meaning 77d 0' 32" W.
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect2>
<refsect2 role="property" id="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.SuplServer">
<title>The "SuplServer" property</title>
<indexterm zone="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.SuplServer"><primary sortas="Modem.Location:SuplServer">org.freedesktop.ModemManager1.Modem.Location:SuplServer</primary></indexterm>
<programlisting>
SuplServer readable s
</programlisting>
<para> SUPL server configuration for A-GPS, given either as IP:PORT or with a full URL.
</para>
</refsect2>
<refsect2 role="property" id="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.GpsRefreshRate">
<title>The "GpsRefreshRate" property</title>
<indexterm zone="gdbus-property-org-freedesktop-ModemManager1-Modem-Location.GpsRefreshRate"><primary sortas="Modem.Location:GpsRefreshRate">org.freedesktop.ModemManager1.Modem.Location:GpsRefreshRate</primary></indexterm>
<programlisting>
GpsRefreshRate readable u
</programlisting>
<para> Rate of refresh of the GPS information in the interface.
</para>
</refsect2>
</refsect1>
</refentry>
|