[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to get raw data from gpsd?
From: |
Gary E. Miller |
Subject: |
Re: How to get raw data from gpsd? |
Date: |
Fri, 29 Mar 2024 13:12:32 -0700 |
Yo 张延涛!
On Fri, 29 Mar 2024 19:20:05 +0800
张延涛 <zh6tao@gmail.com> wrote:
> Thanks for your reply. The GNSS receiver I am using is the ALLYSTAR
> HD8040.
Interesting. The first time I have heard of it. I can find little
documentation on the protocol. I found some information on much
older chips. Do you have any documenttion on the binary protocol?
> I have collected the gpsd running logs, which can be found in the
> attached file gpsd.log. At the same time, I have also collected the
> logs from the GNSS receiver, which can be found in the attached file
> serial.log.
Thanks. Looks like the ALLYSTAR binary is a sloppy copy of the UBX
protocol. An incompatible one.
> I have tried the superraw mode, but I could not receive any textual
> data other than NMEA. My experimental method was to manually send
> textual data to ttyS3, but `gpspipe -R` did not print out the textual
> data I sent to ttyS3.
"Superraw" is not completely raw.
> Then, I carefully read the gpsd source code and found that the data
> transmission process is roughly as follows:
>
> GNSS receiver --> ttyS3 --> GPSD calls read() function -->
> lexer.inbuffer --> lexer.outbuffer --> upper-layer applications
Yes, gpsd does not pass on data that it can not at least identify is
a valid sentence. It does not need to understand each message, but
the header and checksum must validate. Since gpsd knows nothing of
ALLYSTAR, it will not pass on the sentences, even in superraw mode.
This is usually a good think as a lot of junk can come into a serial
port, but not in your case.
> Therefore, I would like to know if there is an API that can directly
> access the data in `lexer.inbuffer`?
Nope, sorry. But I am working on code in gpsd git head that understands
the basic ALLYSTAR message structure. When that works, superraw mode
will work for you. If you can send me documentation on the binary
messages, I can get gpsd to decode them.
In summary:
Can you get me documentation on the binary protocol?
Can you build gpsd from git head and test?
Do you have sample parts you can send me?
RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
gem@rellim.com Tel:+1 541 382 8588
Veritas liberabit vos. -- Quid est veritas?
"If you can't measure it, you can't improve it." - Lord Kelvin
pgpF6EjcuXMQb.pgp
Description: OpenPGP digital signature