Closed alphaville closed 4 months ago
@pdavid747 @Runway27 Note that if you write your own code you won't have to use gpsd
at all. Actually you shouldn't use it because it won't let you read the serial. Start by reading the documentation to understand what sort of data we get from the GPS and then build a simple DTO: a Python class whose attributes are the quantities the GNSS measures.
@pdavid747 @Runway27 @jamie-54 u-center is a software provided by u-blox and should allow us to configure the GNSS module and increase the update rate
⚠️ The GPS coordinates are in degrees-minutes-seconds; after the conversion to a decimal representation, it turns out that the coordinates are fairly accurate.
@pdavid747 use the following function to convert the GPGLL data to degrees:
def deg_min_sec_to_decimal(dms, dir="N"):
"""
Convert degrees-minutes-seconds from GPGLL to degrees (deciman)
:param dms: degrees-minutes-seconds (must be positive)
:param dir: direction (can be one of 'N', 'W', 'E', 'S')
"""
dms_abs = np.abs(dms)
degrees = np.floor(dms_abs/100)
minutes = np.floor(dms_abs - 100 * np.floor(dms_abs/100))
seconds = 10 * (dms_abs - np.floor(dms_abs))
deg_decimal_abs = degrees + minutes / 60 + seconds / 3600
dir_sign = -1 if (dir in ["S", "W"]) else 1
return dir_sign * deg_decimal_abs
I installed PyGPSClient on Mac:
It allows to set the measurement update rate and many more settings.
Scatter plot of estimated positions while static:
while being connected to 3-8 satellites (the antenna is placed on metallic plate, but indoors having a decent but not perfect view of the sky; it has an elevation of around 75 degrees). We seem to be getting an accuracy of about ±10m at best, but we might get better results outdoors.
Some more results...
Figure 1. Satellites
Figure 2. SNR
Figure 3. Scatter plot (best one)
Figure 4. Scatter plot
Parameter | Value |
---|---|
Satellites in view | 7 - 9 |
SIV | 7-9 |
SIP | 7 |
PDOP | 3-3.5 |
HDOP | 1.5-3 |
From my other window with 9-10 satellites (10-12 in view), pdop: 1.5-2, and higher SNR
Done
Describe the solution you'd like
I have uploaded the data we collected on 28/11/23 https://gist.github.com/alphaville/995a15ef74e8d5b3128c87667b5bfdaf. This is how the data looks like
Documentation
The data are structured according to the NMEA Standard Logs protocol. Examples:
First of all we need to decipher what all these mean and how the data are structured (read the docs).
Issues to address
500,000
. We can write a simple interface that reads the data from serial (usingpyserial
) and parses it~Accuracy~
~In terms of absolute accuracy, it seems to be quite bad...~ (Update: My bad! See my comment below)
~There seems to be negligible variance when the antenna is perfectly static.~ (Update: It depends... see below)
We should see how sensitive it is: we should move it by 1m and see what measurements we get. (TODO!)