Setup
RKNN Setup
Hardware
- Computer : Orange Pi 5B
Software
- Ubuntu 22.04
- Python 3.10
- RKNN-ToolKit-Lite2 (python API)
Installaion
- Install python3 and pip3
sudo apt-get update
sudo apt-get install -y python3 python3-dev python3-pip gcc
- Install dependent libraries
sudo apt-get install -y python3-opencv
sudo apt-get install -y python3-numpy
- Install RKNN Toolkit Lite2
cd ./rknn-toolkit2/rknn_toolkit_lite2/packages
pip3 install rknn_toolkit_lite2-1.5.2-cp310-cp310-linux_aarch64.whl
Run Demo
cd ./rknn-toolkit2/rknn_toolkit_lite2/examples/inference_with_lite
python3 test.py
Realsense Setup
Hardware
- Computer : Orange Pi 5B
- Depth camera : Intel® RealSense™ Depth Camera D435i
- Connection : USB 3.0
Software
- Ubuntu 22.04
- Python 3.10
- Intel® RealSense™ SDK 2.0
Download Source code (zip) & Unzip
- Intel® RealSense™ SDK 2.0 (v2.53.1)
- released this Dec 6, 2022
- The lastest version may not be built correctly.
Prerequisites
sudo apt-get update && sudo apt-get -y upgrade
sudo apt-get install -y --no-install-recommends \
python3 \
python3-setuptools \
python3-pip \
python3-dev
sudo apt-get install -y git libssl-dev libusb-1.0-0-dev pkg-config libgtk-3-dev
sudo apt-get install -y libglfw3-dev libgl1-mesa-dev libglu1-mesa-dev
Building librealsense2 SDK
cd ./librealsense
~/librealsense$ ./scripts/setup_udev_rules.sh
~/librealsense$ mkdir build && cd build
~/librealsense/build$ cmake ../ -DBUILD_EXAMPLES=true -DFORCE_RSUSB_BACKEND=true -DBUILD_PYTHON_BINDINGS:bool=true
-DBUILD_EXAMPLES=true
- C++ sample code build option
-DFORCE_RSUSB_BACKEND=true
- realsense sdk에서 지원하는 커널 버전(5.13, 5.15)과 orange pi 지원 커널 버전(5.10)이 맞지 않아 해당 옵션 추가
-DBUILD_PYTHON_BINDINGS:bool=true
- Build Python bindings for the SDK
~/librealsense$ sudo make uninstall && make clean && make -j4 && sudo make install
~/librealsense$ export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python3.10/pyrealsense2
Run example
- The binary demos, tutorials and test files will be copied into
/usr/local/bin
- 파이썬 스크립트의 경우
import pyrealsense2.pyrealsense2 as rs
로 수정한 후 실행
참고자료
- How to install librealsense and pyrealsense2 on the Jetson NX
- Realsense 파이썬으로 사용하기
- Linux/Ubuntu - RealSense SDK 2.0 Build Guide
- Supported Linux image types and kernel versions
- Linux Ubuntu Installation
- NVIDIA Jetson installation
- Build Configuration