Closed BertoldVdb closed 5 years ago
Are these types of messages usually interleaved with $
prefixed messages?
edit: if not, I think this would work better as a standalone sub-package.
Usually, yes. There are devices that output for example GPS data and received AIS messages. Then they come interleaved. Class A AIS units will also include some $AI messages for configuration and status reporting.
$ and ! are the only start characters allowed by the current standard, but in principle a later version could add more. (albeit unlikely, as older multiplexers would not pass the messages through)
A standalone decoder may also work. The application code can call both parse functions after another if it expects interleaved traffic.
EDIT: This is the manual of a device that outputs interleaved $ and ! sentences: https://www.navico-commercial.com/Root/SimradProSeries_docs/MX535A_TechMan_EN_3508-102-70860_B_w.pdf See Figure 2.6 on page 31 for an example. This is another one: https://www.sv-zanshin.com/r/manuals/raymarineais500installationinstructions.pdf (see table on page 44)
Thanks for the additional info, I'll take a closer look on Tuesday.
Sorry, I was a bit busy with another project. I will make the changes tomorrow.
@BertoldVdb no rush.
Changes committed.
@adrianmo look over this when you get a chance.
Ah. I didn't see that the supported messages were listed in the README. I will change it.
Is there a specific way the messages in the readme should be ordered? I just added it to the end now.
Is there a specific way the messages in the readme should be ordered? I just added it to the end now.
No, we have been adding them in order of implementation. Maybe we could order them alphabetically, but we will do it on a different PR.
@icholy you have the last word :)
@BertoldVdb thanks for the contribution :)
Thank you very much. I can now replace my own NMEA parser with this one :)
Hello,
This pull request implements support for VDM/VDO encapsulated message parsing. It requires a change to sentence.go as these messages use '!' instead of '$' as start byte.
VDM and VDO are the same message, depending on the circumstances or configuration the sender will produce one or the other, but they are handled identically. Currently I made one decoder that handles both messages, is this the way to go?
Sincerely, Bertold