Coder Social home page Coder Social logo

gpsdclient's People

Contributors

dependabot[bot] avatar kolterdyx avatar tfeldmann avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gpsdclient's Issues

CLI output glitch

Maybe due to the newly added datetime timezone info.

Connected to gpsd v3.17
Devices: /dev/ttyO4

Mode | Time                 | Lat          | Lon          | Track  | Speed  | Alt       | Climb
-----+----------------------+--------------+--------------+--------+--------+-----------+----------
3    | 2022-11-22 10:29:51+00:00 | 51.778967817 | 6.40282045   | 326.31 | 0.0    | 75.874    | 0.0
3    | 2022-11-22 10:29:52+00:00 | 51.778967817 | 6.40282045   | 326.31 | 0.0    | 75.874    | 0.0

gpsdclient chokes on some gpsd output

OBSERVED
json.loads() can fail on some (valid) output from GPSD

REPRODUCE
Add a NTRIP source to gpsd and it will emit all kind of (valid) data that is not handled correctly by gpsdclient.

CAUSE
GPSD can emit trailing commas in the json data. This will cause the standard python json parser to choke.
See also: https://stackoverflow.com/questions/56592689/python-remove-comma-of-last-object-in-a-string-for-valid-json

PROPOSED FIX
Use json5 or yaml functions to parse the data.

Trying w/ gpsdclient

Hello,

I am getting an timeout error when running your source.

Connected to gpsd v3.22
Devices: /dev/ttyS2
timed out

Do you know what may be causing this issue currently?

Seth

RE: Errors and Running Your Application

Hello,

I had an error of no connection at first. I restarted the gpsd.service and everything works just as stated. Thank you for making this lib. available.

It is working well so far. I got some help from a person on writing to files in your gpsdclient lib. It helps to keep files of specifics.

oh!

Are there any resources you know of currently for porting to .kml files for Google Earth views? I was going to power my device, take a couple miles out of my day to move around w/ the device, and then hopefully put them manually into a .kml file for viewing in Google Earth.

I think the .kml files need to have a specific way of being managed:

<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2">
<Document>
<Style id="yellowPoly">
<LineStyle>
<color>7f00ffff</color>
<width>4</width>
</LineStyle>
<PolyStyle>
<color>7f00ff00</color>
</PolyStyle>
</Style>
<Placemark><styleUrl>#yellowPoly</styleUrl>
<LineString>
<extrude>1</extrude>
<tesselate>1</tesselate>
<altitudeMode>absolute</altitudeMode>
<coordinates>
 
# Here are where the coordinates go in "LAT, LON" and etc.
 
</coordinates>
</LineString></Placemark>
 
</Document></kml>

I guess I could pipe the results of my .txt file to a .kml file at a particular section in the file.

Seth

P.S. Anyway, if you are good with Python3 and your lib, please let me know if you have an online resource for this particular method of promoting .txt to .kml to Google Earth. Sorry if this is off topic. It can be closed if it is too far off. Thank you.

ConnectionRefusedError: [Errno 61] Connection refused

Hello,
I'm trying to run the following script:

from gpsdclient import GPSDClient

client = GPSDClient(host="127.0.0.1")
for result in client.json_stream():
print(result)

But it gives me always the error

714             if source_address:
715                 sock.bind(source_address)
716             sock.connect(sa)
717             # Break explicitly a reference cycle
718             err = None

ConnectionRefusedError: [Errno 61] Connection refused

I try to change the host to '0.0.0.0' but still not working and I do not know how to solve it ???!!!
Any hints for that!!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.