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

Infrared sensor timestamps for D435 are not accessible #7039

Closed
t-fi opened this issue Aug 5, 2020 · 2 comments
Closed

Infrared sensor timestamps for D435 are not accessible #7039

t-fi opened this issue Aug 5, 2020 · 2 comments

Comments

@t-fi
Copy link

t-fi commented Aug 5, 2020

Dear librealsense Team,

sadly I accidentally deleted the issue template and cannot make it come back.

My setup is:
OS: Ubuntu
Wrapper: Python3
HW: D435

I observe the following behavior both on the pipy version and a fresh local build of master with -DENFORCE_METADATA=true:

import pyrealsense2.pyrealsense2 as rs

pipe = rs.pipeline()
config = rs.config()
config.enable_stream(rs.stream.infrared, 1, 1280, 800, rs.format.y16)
pipe.start(config)

frames = pipe.wait_for_frames()
ir_l = frames.get_infrared_frame(1)

print(ir_l.supports_frame_metadata(rs.frame_metadata_value.sensor_timestamp))
print(ir_l.get_frame_timestamp_domain())
print(ir_l.get_frame_metadata(rs.frame_metadata_value.sensor_timestamp))

Will yield

False
timestamp_domain.global_time
Traceback (most recent call last):
  File "/home/oba/src/blitzr3d/tmp.py", line 14, in <module>
    print(ir_l.get_frame_metadata(rs.frame_metadata_value.sensor_timestamp))
RuntimeError: metadata not available

So, is getting the sensor timestamp (aka mid exposure timestamp) possible? Is there a setting I can use to enable the functionality?

@MartyG-RealSense
Copy link
Collaborator

MartyG-RealSense commented Aug 5, 2020

Hi @t-fi You should not need to use the -DENFORCE_METADATA flag on Linux as it is a Windows command. To enable metadata, you should apply kernel patching when building from source on Linux. The information in the link below will hopefully be helpful to you.

#3717 (comment)

You can avoid the need to patch the kernel if you build from source using the libuvc / RSUSB backend install method, as it requires an internet connection but is not reliant on Linux versions, kernel versions or patching and includes metadata support.

#6368 (comment)

Bear in mind that there are disadvantages to the backend method as well as advantages, so it is not suitable for every project. In the link below, scroll down to the section headed What are the advantages and disadvantages of using libuvc vs patched kernel modules?

#5212 (comment)

@MartyG-RealSense
Copy link
Collaborator

Case closed due to no further comments received.

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

No branches or pull requests

2 participants