Skip to content

fix(ubx): real UTC time and no fake sample timestamp on NAV-RELPOSNED/DAHEADING - #240

Draft
dakejahl wants to merge 1 commit into
mainfrom
dakejahl/ubx-relpos-time
Draft

fix(ubx): real UTC time and no fake sample timestamp on NAV-RELPOSNED/DAHEADING#240
dakejahl wants to merge 1 commit into
mainfrom
dakejahl/ubx-relpos-time

Conversation

@dakejahl

Copy link
Copy Markdown
Contributor

Summary

NAV-RELPOSNED and NAV-DAHEADING get a real time_utc_usec and no longer stamp timestamp_sample with the parse time.

Problem

time_utc_usec carried the raw iTOW, GPS time of week rather than a UTC epoch, so a consumer aligning the relative position to a PPS pulse got a time off by weeks. timestamp_sample was set to the parse time, which reads as a driver-supplied measurement time and defeats the consumer's receiver delay compensation. The PX4 side of this is PX4/PX4-Autopilot#27102.

Solution

The UTC time is derived from the last NAV-PVT or NAV-TIMEUTC epoch with a valid time by the iTOW difference, wrapped at the week boundary. GPS and UTC differ by a whole number of seconds, so the sub-week offset is identical in both. timestamp_sample is left unset for the consumer to fill.

…/DAHEADING

time_utc_usec carried the raw iTOW, which is GPS time of week rather than
a UTC epoch, so a consumer aligning the relative position to a PPS pulse
got a time off by weeks. The UTC time is now derived from the last
NAV-PVT/TIMEUTC epoch with a valid time by the iTOW difference; GPS and
UTC differ by whole seconds, so the sub-week offset is identical in both.

timestamp_sample was stamped with the parse time, which reads as a
driver-supplied measurement time and defeated the consumer's receiver
delay compensation. It is now left unset.
@github-actions

Copy link
Copy Markdown

ABI/API Compatibility Report

Status: ⚠️ Breaking changes detected

Details

�[0;31m[ERROR]�[0m Missing dependencies: 
Install with: sudo apt-get install 

This comment is automatically updated on each push.

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

Successfully merging this pull request may close these issues.

1 participant