gpsd-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gpsd-dev] [PATCH] Fix on NMEA driver 2D mode


From: José Miguel Gonçalves
Subject: Re: [gpsd-dev] [PATCH] Fix on NMEA driver 2D mode
Date: Thu, 12 Apr 2012 17:27:30 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120329 Thunderbird/11.0.1

On 12-04-2012 16:59, Eric S. Raymond wrote:
José Miguel Gonçalves<address@hidden>:
The problem does not occur with the full set of NMEA messages.
Moreover, it does not happen if I add the GLL message to the set of
messages that the device sends.
Good.

A device that behaves like you describe is not really following the
standard. I understand that you want to support the biggest set of
receivers that you can, but I think that you should privilege the
ones that behave correctly.
Sadly, attempting that would be a disaster. The NMEA standard is
proprietary and complex; additionally, while I've never seen it, I
have good reason to believe that it is vague about edge cases and
exceptional conditions.  Thus, "behave correctly" is not necessarily
well-defined even if one can see NMEA 0813 - and I think mamy GPS
implementors never have seen it.  Instead they emulate the behaviors they've
seen in other devices, along with the mutations that arose during
previous folk transmission.

My company has a copy of the standard and I don't think it's vague, at least in the point we are discussing. But I agree with you that, because of its proprietary nature, many (if not the majority) of the implementations were made without reading the standard, with the implied problems of that.


Under these circumstances, you basically need to code to cope with maximum
perversity in what comes up the pipe.

What's your expected gain from reducing the sentence set?  You haven't
given me a good reason to support that yet at the cost of
reduced bulletproofing, but perhaps there is one.

I mainly work with low power and low processing embeded systems, so I normally need to spare every CPU resource that I can. Because of that I normally set my GPS receivers to output only the messages that I need to process.

I think that we can yet be on the safe side and solve this problem aroused with PolaRx2 if we change the test to;

((session->newdata.mode < MODE_NO_FIX) || (session->newdata.mode > MODE_2D))

Best regards,
José Gonçalves




reply via email to

[Prev in Thread] Current Thread [Next in Thread]