Skip to content

Commit

Permalink
update gnssntripclient to allow v1.0 response to v2.0 request or vv
Browse files Browse the repository at this point in the history
  • Loading branch information
semuadmin committed Nov 4, 2024
1 parent fd964c3 commit a03418c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
1 change: 1 addition & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

ENHANCEMENTS:

1. gnssntripclient will now tolerate an NTRIP 1.0 response to an NTRIP 2.0 request if the caster only supports NTRIP 1.0, or vice versa.
1. gnssstreamer now supports both NTRIP 1.0 and NTRIP 2.0 clients via the `-rtkntripversion` flag (previously it assumed NTRIP 2.0).

### RELEASE 1.1.6
Expand Down
10 changes: 4 additions & 6 deletions src/pygnssutils/gnssntripclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -893,8 +893,8 @@ def is_gnssdata(self) -> bool:
:rtype: bool
"""

return (self._ntrip_version == NTRIP2 and self.content_type == "gnss/data") or (
self._ntrip_version == NTRIP1 and self.status["protocol"].lower() == "icy"
return (
self.content_type == "gnss/data" or self.status["protocol"].upper() == "ICY"
)

@property
Expand All @@ -907,10 +907,8 @@ def is_sourcetable(self) -> bool:
"""

return (
self._ntrip_version == NTRIP2 and self.content_type == "gnss/sourcetable"
) or (
self._ntrip_version == NTRIP1
and self.status["protocol"].lower() == "sourcetable"
self.content_type == "gnss/sourcetable"
or self.status["protocol"].upper() == "SOURCETABLE"
)

@property
Expand Down

0 comments on commit a03418c

Please sign in to comment.