Software/GeoClue

http://folks.o-hand.com/~jku/geoclue-docs/geoclue-small.jpg

GeoClue: The Geoinformation Service

Geoclue is a modular geoinformation service built on top of the D-Bus messaging system. The goal of the Geoclue project is to make creating location-aware applications as simple as possible.

Geoclue is Free Software, licensed under GNU LGPL. It is developed for Linux, but should be portable to any platform that uses D-Bus.

Geoclue defines a set of geoinformation APIs, but it also includes some providers that implement those APIs. Here is a list of services provided through Geoclue with the currently included implementations:

Position
gpsd, gypsy, hostip, plazes, gsmloc
Address
hostip, plazes, manual, localnet
Velocity
gpsd, gypsy
Geocode
geonames, yahoo
ReverseGeocode
geonames

Geoclue source code contains:

Discuss & contribute

Learn more

The documentation includes

The documentation source also contains documentation on provider API and writing providers, but these are not finished.

Below is a higher level description of Geoclue interfaces, providers and master provider.

Interfaces

Geoclue has three interfaces for querying "current situation": Position, Address and Velocity. They all include a method and a signal to acquire the information in question along with the time and accuracy of the measurement.

There are also interfaces Geocode (for getting a Position from an Address) and ReverseGeocode (for getting an Address from a Position).

Possible future interfaces include Map and Route.

Providers

All Geoclue providers are D-Bus services, and can be accessed either via "raw" D-Bus or the C API. A provider may implement more than one Geoclue interface if that makes sense internally. Providers do not have to run as daemons, as D-Bus will start them when needed (providers may also shut down when they're no longer used).

There are several reasons for this structure:

Providers must naturally implement the methods in the interfaces they support. However, not all providers support signals: E.g. web service based providers usually do not. A client accessing providers directly should be aware of this.

See also list of current provider and their features.

Master provider

Geoclue includes a master provider, which implements the same interfaces and is used in the same manner as any other provider. The difference is that internally master uses the best Geoclue provider (based on client requirements and provider availability, accuracy and resource requirements). The provider that is actually used may change over time as conditions change, but the client can just ignore this.

Using the Master provider is favourable for several reasons:

The master implementation is currently experimental.

Get the source

The code is licensed under the GNU LGPL and is available as a tar-ball and in a Git repository. You can also browse the source.

Latest release: Geoclue 0.11.1

Git repository:

For help with Git, see Usage notes here on freedesktop.org and documentation on Git homepage.

The included providers and the C bindings depend on GLib, GObject and Libxml.

Miscellany

History

Geoclue got started during GNOME Summit 2006 in Boston. At least Keith Preston and Tuomas Kuosmanen can be blamed.

There was a total rewrite after version 0.9. Use tag "0.9" (as in git checkout 0.9) if you need the old code. A copy of the Geoclue wiki page from that time is preserved here.

Application ideas

Possible data sources