Top |
org.freedesktop.ModemManager1.Modem.Locationorg.freedesktop.ModemManager1.Modem.Location — The ModemManager Location interface. |
Setup (IN u sources, IN b signal_location); GetLocation (OUT a{uv} Location); SetSuplServer (IN s supl); InjectAssistanceData (IN ay data); SetGpsRefreshRate (IN u rate);
Capabilities readable u SupportedAssistanceData readable u Enabled readable u SignalsLocation readable b Location readable a{uv} SuplServer readable s AssistanceDataServers readable as GpsRefreshRate readable u
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.
This interface will only be available once the modem is ready to be registered in the cellular network. 3GPP devices will require a valid unlocked SIM card before any of the features in the interface can be used (including GNSS module management).
Setup (IN u sources, IN b signal_location);
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.
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
signal_location
argument can be set to FALSE
to disable location
updates via D-Bus signals and require applications to call
authenticated APIs (like
GetLocation()
) to get
location information.
The optional MM_MODEM_LOCATION_SOURCE_AGPS_MSA and MM_MODEM_LOCATION_SOURCE_AGPS_MSB allow to request MSA/MSB A-GPS operation, and they must be given along with either MM_MODEM_LOCATION_SOURCE_GPS_RAW or MM_MODEM_LOCATION_SOURCE_GPS_NMEA.
Both MM_MODEM_LOCATION_SOURCE_AGPS_MSA and MM_MODEM_LOCATION_SOURCE_AGPS_MSB cannot be given at the same time, and if none given, standalone GPS is assumed.
|
Bitmask of MMModemLocationSource flags, specifying which sources should get enabled or disabled. MM_MODEM_LOCATION_SOURCE_NONE will disable all location gathering. |
|
Flag to control whether the device emits signals with the new location information. This argument is ignored when disabling location information gathering. |
GetLocation (OUT a{uv} Location);
Return current location information, if any. If the modem supports
multiple location types it may return more than one. See the
"Location" property
for more information on the dictionary returned at location
.
This method may require the client to authenticate itself.
|
SetSuplServer (IN s supl);
Configure the SUPL server for A-GPS.
|
SUPL server configuration, given either as IP:PORT or as FQDN:PORT. |
InjectAssistanceData (IN ay data);
Inject assistance data to the GNSS module. The data files should be downloaded using external means from the URLs specified in the AssistanceDataServers property.
The user does not need to specify the assistance data type being given.
There is no maximum data
size limit specified, default DBus system bus limits apply.
|
assistance data to be injected to the GNSS module. |
SetGpsRefreshRate (IN u rate);
Set the refresh rate of the GPS information in the API. If not explicitly set, a default of 30s will be used.
The refresh rate can be set to 0 to disable it, so that every update reported by the modem is published in the interface.
|
Rate, in seconds. |
Capabilities readable u
Bitmask of MMModemLocationSource values, specifying the supported location sources.
SupportedAssistanceData readable u
Bitmask of MMModemLocationAssistanceDataType values, specifying the supported types of assistance data.
Enabled readable u
Bitmask specifying which of the supported MMModemLocationSource location sources is currently enabled in the device.
SignalsLocation readable b
TRUE
if location updates will be emitted via D-Bus signals, FALSE
if
location updates will not be emitted.
See the Setup() method for more information.
Location readable a{uv}
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.
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.
This dictionary is composed of a MMModemLocationSource key, with an associated data which contains type-specific location information:
Devices supporting this
capability return a string in the format
The entire string may only be composed of the ASCII digits
If any of these four items ( |
|||||||||||
Devices supporting this
capability return a D-Bus dictionary (signature The allowed key/value pairs and their formats are:
|
|||||||||||
Devices supporting this capability return
a string containing one or more NMEA sentences (D-Bus signature
For example, if the device sends a
If the device sends a new
If the device then sends a
The manager may discard any cached sentences older than 30 seconds. 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. |
|||||||||||
Devices supporting this
capability return a D-Bus dictionary (signature The allowed key/value pairs and their formats are:
|
SuplServer readable s
SUPL server configuration for A-GPS, given either as IP:PORT or FQDN:PORT.
AssistanceDataServers readable as
URLs from where the user can download assistance data files to inject with InjectAssistanceData().