GithubHelp home page GithubHelp logo

jetsonhacks / installrealsensesdk Goto Github PK

View Code? Open in Web Editor NEW
148.0 6.0 36.0 27 KB

Install the Intel RealSense SDK on the NVIDIA Jetson Development Kits

License: MIT License

Shell 100.00%
jetson-tx1 jetson-tx2 jetson-agx-xavier jetson-nano intel-realsense jetson-xavier-nx nvidia librealsense

installrealsensesdk's Introduction

installLibrealsense

Build and install scripts for Intel's librealsense for the NVIDIA Jetson Developer Kits

Original article on JetsonHacks: https://wp.me/p7ZgI9-34j

The Intel® RealSense™ SDK is here: https://github.com/IntelRealSense/librealsense The SDK library name is librealsense. This is for version 2 of the library, which supports the D400 series depth cameras, T265 tracking camera, L515 lidar, and the SR300 depth camera.

It is now possible on the NVIDIA Jetsons to do a simple install from a RealSense Debian repository (i.e. apt-get install). Previous versions of this repository require building librealsense from source, and (possibly) rebuilding the Linux kernel.

The current recommendation from Intel is to use UVC for video input on the Jetson family. The UVC API in librealsense has been rewritten to better support this use case.

installLibrealsense.sh

This script will install librealsense from the Intel Librealsense Debian Repository.

$ ./installLibrealsense.sh

Note: You do not have to patch modules and kernels.

buildLibrealsense.sh

This script will build librealsense from source and install it on the system. Note: It is recommended to install from Debian repository as described above. However, if you need to compile from source, you will find this script useful.

$ ./buildLibrealsense.sh [ -v | --version <version> ] [ -j | -jobs <number of jobs> ] [ -n | --no_cuda ]

Where:

  • <version> = Librealsense version. E.g. v2.49.0
  • <number of jobs> = # of jobs to run concurrently when building. Defaults to 1 if the Jetson has <= 4GB memory
  • <no_cuda> = Compile without CUDA support (by default, CUDA is on)

The librealsense Github repository has good documentation for supporting more advanced modes for the RealSense sensors. Please see: installation_jetson.md The documentation covers different communication interfaces and how to explore different features, some of which may require recompiling kernel modules.

Note: The build uses libuvc. You will not have to rebuild the kernel or modules in order to use this build.

Notes

If you use realsense-ros, make sure that you match the librealsense versions with the realsense-ros version requirement.

Releases

September, 2021

  • Release v1.1
  • Change release naming for this repository
  • Updated keyserver URL
    • Thank you Tomasz @tomek-I and Tommy @Tommyisr !
  • Enhanced buildLibrealsense script
  • Lookup latest version of librealsense from Github repository
    • Allow override via CLI argument ( -v | -version )
  • Allow user to specify number of build jobs ( -j | -jobs )
    • If Jetson has > 4GB use number of cores - 1 ; otherwise 1
  • Different parsing of comand line arguments using getopt
  • Tested on Jetson Nano, Jetson Xavier NX, L4T 32.6.1, JetPack 4.6
  • installLibrealsense.sh installed v2.49.0
  • Thank you Abdul @jazarie2 Matt @droter and @wegunterjrFIrefly for pull requests!

January, 2020

  • Release vL4T32.3.1
  • Jetson Nano, Jetson TX1, Jetson TX2, Jetson AGX Xavier
  • L4T 32.3.1, JetPack 4.3, Kernel 4.9
  • librealsense version v2.31.0

November, 2019

  • Initial release
  • Release vL4T32.2.1
  • Jetson Nano, Jetson TX1, Jetson TX2, Jetson AGX Xavier
  • L4T 32.2.1, JetPack 4.2.2, Kernel 4.9
  • librealsense version v2.30.0

installrealsensesdk's People

Contributors

jetsonhacks avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

installrealsensesdk's Issues

SR305 realsense-view depth value error

Describe the issue
realsense 2.31.0
when running realsense-viewer I get the error depth.
擷取

What version of L4T/JetPack
L4T/JetPack version: 4.2

Which Intel RealSense camera(s)
RealSense camera(s): SR305

To Reproduce
Steps to reproduce the behavior:
running realsense-viewer

[BUG] D415 did not work on latest Jetson Xavier NX

Describe the issue
D415 did not work on latest Jetson Xavier NX, detailed description

What version of L4T/JetPack
L4T/JetPack version: JetPack 4.4 DP, released on 14 May 2020

Which Intel RealSense camera(s)
RealSense camera(s): D415

Expected behavior
RealSense Viewer can not work

Additional context
I noticed that installation on jetson from debian is the same as here.
if building from source will fix the problem? and may I use the latest librealsense code of master branch to build? or try to use the repo first buildLibrealsense2Xavier

[BUG]d435i works, but not completely on NX devkit

Describe the issue
Please describe the issue
I tried both building from sources [ in which case it wouldn't run rs-distance]
and apt installation [ in which case some of examples worked, but not reasense viewer]
What version of L4T/JetPack
L4T/JetPack version: 4.4

Which Intel RealSense camera(s)
RealSense camera(s):d435i

To Reproduce
Steps to reproduce the behavior:
For example, what command line did you run?
for source code build installation rs-distance won't work
for apt installation other examples won't run, but rs-distance works

Expected behavior
realsense-viewer is expected to work both in case with installation from apt repository and from sources; Moreover, other graphical examples would be anticipated to work also
Additional context
Have you had a chance to try D400x series on NX?

installrealsense.sh does not install pyrealsense2

Describe the issue

  1. I am able to use pyrealsense2 using the buildrealsense.sh, but with installrealsesne.sh (which uses apt-get) I cannot get pyrealsense2.

  2. I was also wondering if the installrealsense.sh method enables CUDA support for librealsense2 as we specify to build with CUDA in buildrealsense.sh.

What version of L4T/JetPack
L4T/JetPack version: 32.3.1

Which Intel RealSense camera(s)
RealSense camera(s): d430

Thank you

T265 and D435 not working together in jetson xavier

hey,

i am building librealsense from scratch using ./buildLibrealsense.sh script and then doing
$ source ~/.bashrc
so that pyrealsense could work in python3. And it is successfully imported.
Then i am running rs-enumerate-devices in the terminal which shows both the devices but when i run the following code:
import pyrealsense2 as rs
context = rs.context()
pipelines = []

for device in context.query_devices():
pipe = rs.pipeline(context)
config = rs.config()
config.enable_device(device.get_info(rs.camera_info.serial_number))
pipe.start(config)
pipelines.append(pipe)
print(device)

it is showing :
<pyrealsense2.device: Intel RealSense D435 (S/N: 834412071756)>
and gets stuck.

Please help me out. What am i doing wrong?
I have shifted from jetpack version 4.3 to 4.2.3 and then 4.2.2.
Help me out here.

building from sources doesn't work [BUG]

Describe the issue
After building from sources (I need python bindings that are not in the repo and CUDA) rgb stream doesn't work. Both realsense-viewer and python api returns an error that
RuntimeError: Frame didn't arrived within 5000.
Realsense-viewer also prints in the console
(synthetic-stream.cpp:47) Exception was thrown during user processing callback!

What version of L4T/JetPack
NVIDIA Jetson Xavier
L4T 32.3.1 [ JetPack 4.3 ]
Ubuntu 18.04.4 LTS
Kernel Version: 4.9.140-tegra
CUDA 10.2.89

Which Intel RealSense camera(s)
RealSense camera(s): D415 or D435

To Reproduce
Steps to reproduce the behavior:

  1. run buildRealsense.sh
  2. open realsense-viewer/try to get frames from python.

Additional context
Used cuda 10-2 instead of 10-0 in the script to compile. Also tried version 2.32.1.

Can't take the correct info from the topic "/camera/aligned_depth_to_color/image_raw" which is under rs_camera.launch

Required Info
Camera Model {SR300 / D400 }
Firmware Version
Operating System & Version TX2(Ubuntu 18.04) & PC(Ubuntu 16.04)
ROS Version TX2(melodic) & PC(Kinetic)
Kernel Version (Linux Only) 4.9
Platform NVIDIA Jetson TX2 (Jetpack4.2)
TX2 SDK Version { 2.31.0 & 2.22.0 }
PC SDK Version { 2.31.0 & 2.24.0 & 2.32.1 }
Language {C++ }
Segment Robot

Issue Description

Hi, I got a problem about performance of SR305, when I run the API on TX2, the depth info was perfect, but if I run the node I wrote, there were incorrect values that only print 127mm at the maximum, and when I echo the topic, there was no value at the high byte position. But there was no problem when I run the node on PC.

Btw, all the parameters on SDK between PC and TX2 are the same, and the connection about D435i on TX2 and PC everything is good.

And these are the reference I followed to install on TX2:
RealSense API: https://github.com/Tengyun-Mo/buildLibrealsense2TX2
ROS wrapper: https://github.com/jetsonhacks/installRealSenseROS

Is there any people experienced this ..? Please help me.

It's the aligned depth to color image on PC.
sr305_PC

And this is the incomplete frames on TX2.
SR305_TX2

But there is no problem when I run the API on TX2.
SRviewerTX2

[BUG]motion module fail when build from source

Problem solved after I updated the firmware to 05.12.03.00.

======================================================================

Describe the issue
Please describe the issue
When install from prebuild installLibrealsense.sh, everything is OK. BUT, When install from source buildLibrealsense.sh, the realsensen-viewer gives motion module fail warning. The reason why I build from source is there is no pybinding in installLibrealsense.sh.

What version of L4T/JetPack
L4T/JetPack version: JetPack4.3 with Xavier

Which Intel RealSense camera(s)
RealSense camera(s):435i

To Reproduce
Steps to reproduce the behavior:
realsensen-viewer

Expected behavior
A clear and concise description of what you expected to happen.
No warning information show on the screen.

Additional context
The warning is missing, after I updated the firmware to 05.12.03.00

Realsense T265 running in ROS errors

Hi,
i know this issue is more about the ROS(i have submitted same issue in realsense-ros also), but maybe someone knows this problem hier.
ROS: melodic
OP: ubuntu 18 in JETSON TX2
i can use realsense-viewer to access t265, but when i launch the t265 in ROS, i got the errors

[ERROR] [1575669433.435019328]: Failed to load nodelet [/camera/realsense2_camera] of type [realsense2_camera/RealSenseNodeFactory] even after refreshing the cache: Could not find library corresponding to plugin realsense2_camera/RealSenseNodeFactory. Make sure the plugin description XML file has the correct name of the library and that the library actually exists.
[ERROR] [1575669433.435131872]: The error before refreshing the cache was: Could not find library corresponding to plugin realsense2_camera/RealSenseNodeFactory. Make sure the plugin description XML file has the correct name of the library and that the library actually exists.
[FATAL] [1575669433.435440256]: Failed to load nodelet '/camera/realsense2_camera` of type `realsense2_camera/RealSenseNodeFactory` to manager `realsense2_camera_manager'
[camera/realsense2_camera-2] process has died [pid 25692, exit code 255, cmd /opt/ros/melodic/lib/nodelet/nodelet load realsense2_camera/RealSenseNodeFactory realsense2_camera_manager __name:=realsense2_camera __log:=/home/robocar/.ros/log/7a58a8f4-1863-11ea-ac4d-00044bc5026c/camera-realsense2_camera-2.log].
log file: /home/robocar/.ros/log/7a58a8f4-1863-11ea-ac4d-00044bc5026c/camera-realsense2_camera-2*.log

Realsense viewer can't find realsenseD455 camera

Realsense viewer can't find realsenseD455 camera

L4T/JetPack version: L4T 32.3.1

RealSense camera(s): D455

I run the ./installLibrealsense.sh and then ./buildLibrealsense.sh.
when it finished ,I turn on the Realsense Viewer and used the D455 camera , but realsense viewer can't found the D455.
But when I tried D435 , the realsense viewer work fine.
Is D455 not currently supported?

Cannot multicam on TX2

Describe the issue
I am encountering an issue when I try to do multicam on the NVIDIA Jetson TX2. I have 3 D435 cameras connected to a USB3 hub. When I try to get the cameras through code, it either gets stuck or crashes with a "Failed to set power state" error. It works perfectly fine on a laptop with the same hub. After investigation, it seems to be not related to hub nor the usb controller.

Any suggestion would be welcome!

What version of L4T/JetPack
Jetson TX2, Ubuntu 18.04 4.9.140-tegra, JetPack 3.3

Which Intel RealSense camera(s)
RealSense camera(s): D435 cameras, firmware 05.12.03.00, realsense 2.34.1

To Reproduce
There are different scenarios:

  • Connect 3 cameras and run the rs-multicam realsense example. It should crash with a "Failed to set power state" error.
  • Connect 3 cameras, open realsense-viewer and stream Depth+RGB at maximum resolution. Some stream won't work.
  • Run the following python code. It should get stuck after printing the devices and before stopping them (similar to the issue #2 ).
import pyrealsense 2 as rs

ctx = rs.context()
cfgs = [rs.config(), rs.config(), rs.config()]
for config in cfgs:
    config.enable_stream(rs.stream.depth, 1280, 720, rs.format.z16, 6)
    config.enable_stream(rs.stream.color, 1280, 720, rs.format.rgb8, 6)

pipes = []
for i in range(3):
    d = ctx.devices[i]
    print(d)
    config = cfgs[i]
    pipe = rs.pipeline()
    profile = pipe.start(config)
    pipes.append(pipe)

 for p in pipes:
    print(p)
    p.stop()

[FEATURE REQUEST] JetPack V5 support

JetPack v5 has been out for a while now and our team just upgraded the boards to the latest GA. However, we are struggling to install librealsense and pyrealsense2 as the latest JetPack version supported is v4.6. Another issue reporting the same problem faced by users - IntelRealSense/librealsense#10989

There is apparently a way to install librealsense on JetPack v5, however, it lacks proper documentation. The method is mentioned here IntelRealSense/librealsense#10416 (comment). The related comments also provide hints of how to go about the installation.

End Goal

Have a new section / page describing how to install librealsense on jetpack v5

No librealsense2-dkms after using ./installLibrealsense.sh

Describe the issue
I'm using Jetson Xavier + Ubuntu 18 + ROS Melodic.
First of all, I tried standard way - install librealsense from official github. It does not work because of kernel 4.9 - problem that I can't install librealsense2-dkms. As a result, I can't use rs_camera.launch for example. However, realsense_viewer works.

Next, I tried to install Librealsense by buildLibrealsense2Xavier, but my current version of Jetpack is L4T 32.3.1. Then, I see that I can use jetsonhacks / installRealSenseSDK. However, when I used skript $ ./installLibrealsense.sh, I still couldn't find the librealsense2-dkms.

Any ideas I am doing something wrong, or it will be easier just to install L4T 32.1.0 and then use buildLibrealsense2Xavier to patch kernel 4.9?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.