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

fix(robosense): use correct field to check time sync status #106

Merged
merged 2 commits into from
Dec 14, 2023

Conversation

mebasoglu
Copy link
Collaborator

@mebasoglu mebasoglu commented Dec 13, 2023

PR Type

  • Bug Fix

Related Links

Description

Currently, to get the time synchronization status, wrong field is used. If the sensor doesn't have time synchronization, driver doesn't start.

The current checked field is time_sync_mode states the mode that was set on web interface such as GPS or PTP.

This PR fixes this issue by checking sync_status field which is the correct way to see time synchronization status.

Review Procedure

You can use pcap files to test: #77 (comment)

Remarks

Pre-Review Checklist for the PR Author

PR Author should check the checkboxes below when creating the PR.

  • Assign PR to reviewer

Checklist for the PR Reviewer

Reviewers should check the checkboxes below before approval.

  • Commits are properly organized and messages are according to the guideline
  • (Optional) Unit tests have been written for new behavior
  • PR title describes the changes

Post-Review Checklist for the PR Author

PR Author should check the checkboxes below before merging.

  • All open points are addressed and tracked via issues or tickets

CI Checks

  • Build and test for PR: Required to pass before the merge.

@mebasoglu mebasoglu added the bug Something isn't working label Dec 13, 2023
@mebasoglu mebasoglu requested a review from mojomex December 13, 2023 09:39
@mebasoglu mebasoglu self-assigned this Dec 13, 2023
@codecov-commenter
Copy link

codecov-commenter commented Dec 13, 2023

Codecov Report

Attention: 9 lines in your changes are missing coverage. Please review.

Comparison is base (810849e) 6.43% compared to head (a3da6b8) 11.30%.

Files Patch % Lines
...s/nebula_decoders_robosense/decoders/bpearl_v3.hpp 0.00% 3 Missing ⚠️
...s/nebula_decoders_robosense/decoders/bpearl_v4.hpp 0.00% 3 Missing ⚠️
...ders/nebula_decoders_robosense/decoders/helios.hpp 0.00% 3 Missing ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff            @@
##            main     #106      +/-   ##
=========================================
+ Coverage   6.43%   11.30%   +4.87%     
=========================================
  Files        136       60      -76     
  Lines      10895     5537    -5358     
  Branches     854      799      -55     
=========================================
- Hits         701      626      -75     
+ Misses      9618     4357    -5261     
+ Partials     576      554      -22     
Flag Coverage Δ
differential 11.30% <0.00%> (?)
total ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@mojomex mojomex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR, good catch!
Everything looks good and I confirmed it is working as expected using the PCAPs for unsynced and GPS sync, as well as our Bpearl v4 for gPTP, PTP-E2E-L2, PTP-E2E-L2 and PTP-P2P.

Spell check is complaining about the word manc, so could you add it to .cspell.json to make CI pass?

@mebasoglu mebasoglu requested a review from mojomex December 14, 2023 14:39
Copy link
Collaborator

@mojomex mojomex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@mojomex mojomex merged commit 73a1e1b into tier4:main Dec 14, 2023
6 checks passed
@mebasoglu mebasoglu deleted the fix-time-sync-flag branch December 15, 2023 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants