Python client for gpsd
Project description
README
This package is based on a fork of gps3 (https://github.com/wadda/gps3) which hasn't been updated in a while.
It includes some bug fixes for GST class handling.
Only agps versions exist in this package.
To use:
from agps3threaded import AGPS3mechanism
Then engage the thread triumvirate,
agps_thread = AGPS3mechanism() # This instantiate the mechanism, as I believe it's called. agps_thread.stream_data() # Stream the data from host, port, devicepath. agps_thread.run_thread() # Iterate stream as a thread with throttle control for empty look ups.
Four lines of code that lets you connect, communicate and control most of what you expect a gpsd to do.
while True: # All data is available via instantiated thread data_stream attributes. Confur
# lines #140-ff of the client /usr/local/lib/python3.5/dist-packages/gps3/agps.py
print('----------------')
print( agps_thread.data_stream.time)
print('Lat:{} '.format(agps_thread.data_stream.lat))
print('Lon:{} '.format(agps_thread.data_stream.lon))
print('Speed:{} '.format(agps_thread.data_stream.speed))
print('Course:{}'.format(agps_thread.data_stream.track))
print('----------------')
sleep(60) # Sleep, or do other things for as long as you like.
Without arguments between the parentheses, the threaded client defaults to host='127.0.01'
, port=2947
, gpsd_protocol='json'
, and usnap=0.2
, for a respectable default of 2/10th of a second micro nap after each empty socket lookup.
The rest of the project is in DESCRIPTION.rst
, or documented in the files themselves.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file agps3-0.36.1.tar.gz
.
File metadata
- Download URL: agps3-0.36.1.tar.gz
- Upload date:
- Size: 17.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9915807927ed79c11fa6d0d13aec91326f632951c78c324166b147143d7f134e |
|
MD5 | 3e2c3135f585d4d7f7d58440fa614681 |
|
BLAKE2b-256 | f58bc06c2bc7c6bfe21a85f2a9d5ef517fe7a70eaff5eb60be8f33dbea85ad2f |
File details
Details for the file agps3-0.36.1-py2.py3-none-any.whl
.
File metadata
- Download URL: agps3-0.36.1-py2.py3-none-any.whl
- Upload date:
- Size: 17.6 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e15ed2952f46c6d6163b5c10790f8f5b32e052f89239f501b1cc2b2bbcba66b |
|
MD5 | ab9d04adbf13617368042adf964d39d8 |
|
BLAKE2b-256 | fcd64afe6f173ee50f2872f13beab65c37212ce73f3d936c80581b08745b4a5e |