Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistency of PHASE SHIFT Option in rtkconv/convbin #567

Open
liusheng2020 opened this issue Jan 21, 2025 · 2 comments
Open

Inconsistency of PHASE SHIFT Option in rtkconv/convbin #567

liusheng2020 opened this issue Jan 21, 2025 · 2 comments

Comments

@liusheng2020
Copy link

The GUI application rtkconv includes a PHASE SHIFT option, while the CUI application convbin seems to lack this option (at least I couldn't find it in the consapp\convbin\convbin.c file or by running convbin -?). This causes discrepancies in the conversion results.

Image

For example, when GPS L2X PHASE SHIFT = -0.25000, all GPS L2X PHASE observation value elements in the conversion results exhibit a -0.25 difference.

Image

Image

Is this a bug, or do I need to add a specific option to make the conversion results of convbin consistent with those of rtkconv?

@ourairquality
Copy link

My reading of the RINEX spec is that the observations should have aligned phases, aligned to their reference signals, and that the header phase shifts are for recovering the original unaligned signals. This option hard codes some phase shifts, those in the RINEX spec table A23, which appear to be for recovering the unaligned phases. It's does seem odd that the observations change based on the header phase shifts. Would have expected the internal rtklib observations to be the aligned phases rather than attempting to recover the unaligned, and that the observations are always the aligned phases so should not change based on the header phase shifts?

If the phases from the ublox f9 raw data are already phase aligned (even if after some decoding adjustments) then it would appear that the RINEX header phase shift should be zero, that this conversion option should not be used. If these are not phase aligned, and if the internal observation phases were intended to be the original unaligned phases, then they would need to be output in the RINEX header and the values adjust to be aligned.

But still, perhaps the application of the phase shift is not correct. Are the internal observation phases intended to be phase aligned, or not??

@rtklibexplorer
Copy link
Owner

Regarding the difference between the GUI and the CUI, it does look like the CUI is missing support for this feature.

If you want to fix this yourself before the next release and you are able to modify and build the code, I think it simply needs this code:

    else if (!strcmp(argv[i],"-phshift")) {
        opt->phshift=1;
    }

added right after this code in convbin.c:

    else if (!strcmp(argv[i],"-halfc")) {
        opt->halfcyc=1;
    }

Then it can be enabled by adding "-phshift" as an option to the command line.

I haven't tried this but believe it should work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants