-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Ros timestamp shows incorrect values #5067
Comments
I have analyzed the frames using the C++ API to look at the raw data. The timestamps from rs2::frameset::get_timestamp also show the exact same problem. Additionally, I checked with another realsense camera, and this gives the same problem. Hence, I think the problem is somewhere in the firmware or the API, in combination with Linux |
Looked into the metadata of the file, and I found that both the BACKEND_TIMESTAMP and the TIME_OF_ARRIVAL_TIMESTAMP do give the correct values, but |
Found out that the problem can be remedied by disabling all global timestamps. More specifically, i repaced
which disables the global time for all camera-based, which then default to the (correct) hardware clock. The new value correspond to the original IMU timestamps I don't consider this problem solved, but at least it is a workaround. |
Tested this on another laptop, and realized that the hardware clock of the color camera should not give you the current UNIX epoch... This is probably something in the library synchronizing the camera to the system time? Also, this apparently only occurs on my specific installation. |
I think this is similar to the issue that was reported in: |
Issue Description
As I was trying to calibrate the D435i IMU using the RGB camera, i found that the tool encountered an error concerning the timestamps. After a few days I found that the timestamps in the message headers of the RGB topic are corrupted.
I record a rosbag file using realsense-viewer, enabling the RGB camera on monochrome and including IMU data. If i then inspect the color channel using
rostopic echo /device_0/sensor_1/Color_0/image/data --noarr
I find that the 'secs' field fluctuates around 3 142 000 000.This incidentally doesn't happen (once in 20 tries), and doesn't seem to relate to any circumstance in particular.
After some digging, i found that the header starts correctly, as seen here:
but quickly approaches double the value
It seems to shuffle with 1000 seconds at a time
I initially used an installation by the package manager, but recently installed the library from sources trying to mitigate this problem.
I also used
roslaunch realsense2_camera rs_camera.launch unite_imu_method:=none
to obtain the data, but the resulting topics have the same issue (it does not relate to realsense-viewer nor the bag file reader/writer)The output when recorded with realsense2_camera is in topic.txt
The text was updated successfully, but these errors were encountered: