diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2017-05-28 13:51:31 -0700 |
---|---|---|
committer | Fred Wright <fw@fwright.net> | 2017-07-18 14:32:22 -0700 |
commit | 795908afe3435d3095bb9ceb81c8b35fd1e22805 (patch) | |
tree | 9a9cde3323faacd08b0cac4db2a1da177912612f /gpsprof | |
parent | bda3f970bd713cf553dcca47beb22682a49c7081 (diff) | |
download | gpsd-795908afe3435d3095bb9ceb81c8b35fd1e22805.tar.gz |
gpsprof: accept valid samples only.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
Signed-off-by: Fred Wright <fw@fwright.net>
TESTED:
Verified that gpsprof still produces output. - fw
Diffstat (limited to 'gpsprof')
-rwxr-xr-x | gpsprof | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -190,9 +190,11 @@ class spaceplot(plotter): def sample(self): # Watch out for the NaN value from gps.py. - self.fixes.append((self.session.fix.latitude, - self.session.fix.longitude, - self.session.fix.altitude)) + if (self.session.valid & + (gps.ONLINE_SET | gps.PACKET_SET | gps.LATLON_SET)): + self.fixes.append((self.session.fix.latitude, + self.session.fix.longitude, + self.session.fix.altitude)) return True def header(self): |