Skip to content

Conversation

@at-wat
Copy link
Member

@at-wat at-wat commented Nov 21, 2025

  • Internally use 64bit microseconds timestamp
  • Use high precision timestamp extension of TM/MD/ME commands
    • Add ClockEstimator and ScanEstimator for high precision timestamp

@at-wat at-wat self-assigned this Nov 21, 2025
@at-wat at-wat marked this pull request as draft November 21, 2025 01:34
@at-wat at-wat requested a review from Copilot November 21, 2025 01:34
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements support for high precision timestamp extensions in the URG sensor system by transitioning from 24-bit millisecond timestamps to 64-bit microsecond timestamps. The key changes enable compatibility with newer sensor firmware versions (4.1.0+) that support extended SCIP2 commands with microsecond-resolution timestamps.

Key changes:

  • Introduced 64-bit microsecond timestamp resolution (WALL_TIMESTAMP_RESOLUTION) to replace millisecond resolution
  • Added ClockEstimatorRaw and ScanEstimatorRaw classes for high precision timestamp handling
  • Extended protocol support with "%" prefix commands for high precision modes

Reviewed Changes

Copilot reviewed 24 out of 24 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
include/urg_stamped/device_state_estimator.h Added new estimator classes and updated timestamp resolution constants
include/scip2/walltime.h Modified to accept microsecond timestamps while maintaining millisecond-based overflow detection
include/scip2/response/time_sync.h Extended timestamp parsing to support both 4-byte and 11-byte formats
include/scip2/response/stream.h Extended scan data timestamp parsing for both precision modes
include/scip2/response.h Added prefix-based response registration to handle "%" commands
src/device_state_estimator.cpp Updated timestamp resolution references
src/clock_estimator_raw.cpp New estimator implementation for high precision timestamps
src/scan_estimator_raw.cpp New scan estimator for raw timestamp handling
src/urg_stamped.cpp Integrated high precision mode detection and command prefix handling
src/urg_sim/urg_sim.cpp Added high precision timestamp simulation support
test/src/test_device_state_estimator.cpp Updated test values to microsecond scale
test/src/test_walltime.cpp Updated test values to microsecond scale

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@sqbot

This comment has been minimized.

@codecov
Copy link

codecov bot commented Nov 21, 2025

Codecov Report

❌ Patch coverage is 88.32117% with 32 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.79%. Comparing base (752e1bf) to head (8c753dc).

Files with missing lines Patch % Lines
src/urg_sim/urg_sim.cpp 74.07% 14 Missing ⚠️
include/scip2/response/stream.h 71.42% 6 Missing ⚠️
src/clock_estimator_raw.cpp 90.38% 5 Missing ⚠️
include/scip2/response/time_sync.h 86.95% 3 Missing ⚠️
src/urg_stamped.cpp 92.85% 2 Missing ⚠️
include/scip2/walltime.h 92.85% 1 Missing ⚠️
src/scan_estimator_utm.cpp 80.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #187      +/-   ##
==========================================
- Coverage   83.73%   81.79%   -1.94%     
==========================================
  Files          28       30       +2     
  Lines        1832     1989     +157     
==========================================
+ Hits         1534     1627      +93     
- Misses        298      362      +64     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sqbot

This comment was marked as outdated.

@sqbot

This comment has been minimized.

@at-wat at-wat marked this pull request as ready for review November 22, 2025 00:49
@sqbot

This comment has been minimized.

@sqbot

This comment has been minimized.

@sqbot

This comment has been minimized.

@sqbot

This comment has been minimized.

@sqbot
Copy link
Member

sqbot commented Dec 25, 2025

✅ Passed noetic 3.20

Log summary

Summary

noetic built:	1
noetic tried:	1
noetic deleted:	0
noetic total built:	1
noetic total relevant aports:	1
noetic total aports:	1

urg_stamped

ros-noetic-urg-stamped-0.4.1_git20251225062135-r0.apk
Build succeeded.

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.

2 participants