ryanvade / pynmea

Automatically exported from code.google.com/p/pynmea
Other
0 stars 0 forks source link

Multiple Talker Identifier #2

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Hi,
I'm working on a multi talker identifier project and I want to use your library.
Looking at your code I find all the implemented (and not implemented) nmea 
sentences classes related to the GPS talker identifier (GP).
I was wandering if there's a way to get your library work also on sentences 
coming from other equipment than the GPS (maybe avoiding to replace the first 
chars of each sentence with "GP"). 
I think the only way is to change a bit the library structure, deleting the 
"GP" from the current nmea sentences classes and changing the identification 
functions (like _get_type in NMEAStream) to work on the sentences name.
Parsing functions should work also with this changes.

Just a suggestion because I don't know how to contribute directly to this 
project.

Original issue reported on code.google.com by mauro.ma...@gmail.com on 18 Jan 2013 at 4:19

GoogleCodeExporter commented 8 years ago
The attached nmea.py file implements what I wrote and maps all the sentences 
contained in the IEC 61162-1 third edition specs.
On some sentences an overriding parsing class should be created to parse 
variable length messages.
The streamer.py has been changed only in the _get_type function.
Hope this helps.

Original comment by mauro.ma...@gmail.com on 21 Jan 2013 at 2:57

Attachments:

GoogleCodeExporter commented 8 years ago
Hi Mauro

Just a small thing, I just happened to be using it with a DTM sentence:

In the DTM class, the call to super() has DSR as argument (nmea.py:549).

class DTM(NMEASentence):
    def __init__(self):
        super(DSR, self).__init__(parse_map)
              ^^^

Benjamin

Original comment by benjamin...@gmail.com on 19 Feb 2013 at 2:33