gps backend issues
keith preston
keithpre at gmail.com
Tue Jul 10 07:10:31 PDT 2007
On 7/10/07, Jussi Kukkonen <jhkukkon at cc.hut.fi> wrote:
>
> I've been playing with the gps backend for a while now, and have some
> comments / questions:
>
>
> First, I just couldn't get my gps (Nokia LD-3W) to work with the
> current gps backend: geoclue_position_current_position() calls gps_query
> to get coordinates, but my device requires 10-60 such calls before it
> gets a fix and starts answering with coordinates.
> I've understood this is normal for gps devices -- gps data should in
> general be read using a callback (and waiting until there's actual data).
> Plan:
> * I'll implementing geoclue_position_current_position_changed-signal
> using gps_set_callback internally (it uses POSIX threading, I
> assume that's ok?)
This is a good idea and should be the prefered method of getting a Signal.
* current_position should probably use the same gps callback
> internally, but dbus timeout may be a problem if geoclue waits for
> an actual position before returning... I wonder if asynchronous
> method calls have a timeout in dbus?
current_position shouldn't be asynchronous. If it does not have the
position it should return that it doesn't and then the application should
listen for the signal of position changed.
Second, I'm going to add some code to use libgpsbt and libgpsmgr when
> present (they take care of of e.g. starting and stopping gpsd as needed
> to preserve resources). At the moment this is maemo specific, but I
> assume other mobile linux systems will use them too (it has been
> discussed on the openmoko list at least), so I'd like to put the
> changes in geoclue proper.
> My solution was this, please suggest better ones if this is suboptimal:
> * use AC_CHECK_LIB in configure.ac to define HAVE_LIBGPSBT
> if the lib is there
> * use "#ifdef HAVE_LIBGPSBT" in gps backend code when I want to
> call the library
>
> Any comments?
This sounds fine as long as it is an optional dependency.
-jussi
>
>
>
> _______________________________________________
> GeoClue mailing list
> GeoClue at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/geoclue
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freedesktop.org/archives/geoclue/attachments/20070710/cb336252/attachment.htm
More information about the GeoClue
mailing list