Repository navigation
Fix BeiDou C39, C49 and C59 names in Sat::GetStr() - #231
Merged
Merged
Conversation
The BDS string table had "C30", "C40" and "C50" in the slots for C39, C49 and C59, so those satellites printed as the wrong PRN and Sat(sat.GetStr()) did not round-trip. Add a round-trip test over all valid satellites of every constellation.
Contributor
|
Hi Jayden |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug. The BeiDou name table in
fpsdk_common/src/gnss.cpphas three wrong entries. The slots for C39, C49 and C59 hold "C30", "C40" and "C50". So these satellites print the wrong name, for example in the UBX-RXM-SFRBX info string.Sat(sat.GetStr())also gives a different satellite for them.Fix. Put "C39", "C49" and "C59" in those three slots.
Test. I added the three satellites to
GnssTest.SatStr. I also addedGnssTest.SatStrRoundtrip, which checksSat(sat.GetStr()) == satfor every valid satellite of every constellation. The full library needs Linux. So I compiledgnss.cpp,logging.cpp,string.cppandgnss_test.cppfrom a33788a with gtest 1.15.2 on macOS. Before the fix, 10 of 12 tests pass.SatStrgets "C30" for C39, and the round trip fails with "C30 is not BDS 39". With the fix, 12 of 12 pass. clang-format 18.1.8 is clean. I did not runmake testin your Linux image.