Replies: 2 comments 5 replies
-
Hi @WH2425 Some additional context would be helpful here... If your intention here is to parse a live NTRIP data stream, there may be a simpler approach...
if you require more advanced NTRIP Client functionality, including support for encrypted (TLS) and encoded (chunked, gzip, etc.) NTRIP data streams and automatic connection retries, have a look at the gnssntripclient.GNSSNTRIPClient class in pygnssutils, which implements a more advanced version of If, on the other hand, you're parsing an offline NTRIP data log, then you could simply concatenate the individual with open("ntripdata.bin", 'wb') as ntripfile:
for data in ntrip.record_data_yield():
ntripfile.write(data)
with open("ntripdata.bin", 'rb') as stream:
rtr = RTCMReader(stream)
for raw_data, parsed_data in rtr:
if parsed_data is not None:
print(parsed_data) |
Beta Was this translation helpful? Give feedback.
-
Hi @semuadmin
When I exit the rtcm parser, I check if the TCP connection is not interrupted. Sometimes the TCP connection is not interrupted. In addition, I found that the exit of the rtcm parser is not necessarily caused by a timeout in getting data from TCP.
stream = ntrip.client
rtr = RTCMReader(stream) I am looking forward to your answer, thank you very much |
Beta Was this translation helpful? Give feedback.
-
Hello, I hope to obtain the last incomplete data when the stream terminates .Because I can only use io.BytesIO(data) to simulate the stream for real-time decoding.I would like to be able to return unused bytes and None at the end of the stream.
Beta Was this translation helpful? Give feedback.
All reactions