gpsd-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gpsd-users] retrieve data from gpsd without waiting


From: Gary E. Miller
Subject: Re: [gpsd-users] retrieve data from gpsd without waiting
Date: Mon, 27 Aug 2018 11:28:21 -0700

Yo Felipe!

On Mon, 27 Aug 2018 16:56:48 +0200
Felipe Gutierrez <address@hidden> wrote:

> I am newbie using gpsd with C. I implemented my first client which
> uses gps_stream function. If I understood correctly, it is like a
> pub/sub function that you can read gps data using gps_read.

Yeah, pretty much.

> I want to
> retrieve the data as soon as it is available.

Not much you can do to affect that.

Every once in s ahwile the GPS will send data to gpsd. gpsd collects
that until it has a omplete thought, then forwards that rogh on to the
client.


> The only way I found is
> to decrease the time on the gps_waiting function.

Placebo effect.

> I wonder if there
> is a way to not use the gps_waiting function and retrieve as soon as
> possible.

The only way, if you can use partial data as it dribble in, would be
to parse the raw data from the GPS.

> Here below is my code.

Munged by being put in an email, but looks good at first glance.

If you need the data faster, you best bet it to get the serial
port speed as fast as possible, but not so fast as to corrupt the
data.

If that is not good enough you need to set the cycle rate on your GPS
to be faster, or buy a high rate GPS.

RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
        address@hidden  Tel:+1 541 382 8588

            Veritas liberabit vos. -- Quid est veritas?
    "If you can’t measure it, you can’t improve it." - Lord Kelvin

Attachment: pgp7PpLkeTXQk.pgp
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]