Skip to main content

No project description provided

Project description

realsense-cli

A modern command-line interface for Intel RealSense cameras, built on pyrealsense2.

PyPI version Python License


Features

  • List connected devices and their supported streaming profiles
  • Configure sensor controls (exposure, gain, laser power, etc.)
  • Stream selected profiles and monitor live FPS per stream
  • Inspect ROS bag files without a full ROS installation
  • Multi-device support via --serial

Installation

uv (recommended):

uv tool install realsense-cli   # install permanently
uvx realsense-cli               # run without installing

pipx:

pipx install realsense-cli

pip:

pip install realsense-cli

Development

Clone and set up:

git clone https://github.com/yegarti/realsense-cli.git
cd realsense-cli
uv sync

Run the CLI from source:

uv run rs --help

Run tests:

uv run pytest                  # mock tests only (no camera required)
uv run pytest -m hardware      # hardware integration tests (camera required)

Quick Start

rs --help          # top-level help
rs list            # show connected devices
rs stream play     # start all streams with default settings

Use -s / --serial to target a specific device when multiple are connected:

rs -s 801312071342 stream play depth

Commands

rs list — connected devices

> rs list

                                     Devices
          Name              Serial       Firmware    USB Connection      Sensors
 ───────────────────────────────────────────────────────────────────────────────
  Intel RealSense D435   801312071342   5.13.0.51        2.1          Stereo Module
                                                                       RGB Camera
  Intel RealSense D415   732612060537   5.15.0.2         3.2          Stereo Module
                                                                       RGB Camera

rs config — sensor controls

List all writable controls for a sensor:

rs config list depth
rs config list color

Read control values:

rs config get depth exposure laser_power
  Name          Value
 ──────────────────────
  exposure      8500.0
  laser_power   150.0

Write control values:

rs config set depth exposure=15000 laser_power=120

Read all controls at once:

rs config get depth --all

rs stream — streaming

List supported profiles for a sensor (or all sensors):

rs stream list
rs stream list depth
                     Streams
  Stream       Resolution   FPS          Format
 ───────────────────────────────────────────────
  Depth        640x480      6/15/30      Z16
  Infrared 1   640x480      6/15/30      Y8
  Infrared 2   640x480      6/15/30      Y8
  Color        640x480      6/15/30      RGB8
  ...

Start streaming — profile syntax: STREAM[-WxH[-FPS[-FORMAT]]]

rs stream play                             # all streams, default settings
rs stream play depth                       # depth only
rs stream play depth color                 # depth + color
rs stream play depth-640x480-30-z16        # fully specified profile
rs stream play depth-640x480-30 color-0x0-15

Live view (Ctrl-C to stop):

  ╭─────── Depth (0) 640x480 15fps z16 ───────╮
  │ Frame #69       FPS: 15.01                │
  ╰───────────────────────────────────────────╯
  ╭───── Infrared 1 (1) 640x480 15fps y8 ─────╮
  │ Frame #66       FPS: 15.01                │
  ╰───────────────────────────────────────────╯
  ╭────── Color (0) 640x480 15fps rgb8 ───────╮
  │ Frame #68       FPS: 15.01                │
  ╰───────────────────────────────────────────╯

Hide metadata with --no-md. Switch to the low-level sensor API with --sensor.


rs bag — ROS bag inspection

rs bag info recording.bag

Displays bag duration and per-topic message counts without requiring a full ROS installation.


rs reset — hardware reset

rs reset

Options

Option Description
-s, --serial Select device by serial number
-v Verbose output (INFO); -vv for DEBUG
-h, --help Show help for any command

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

realsense_cli-0.3.0.tar.gz (13.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

realsense_cli-0.3.0-py3-none-any.whl (18.8 kB view details)

Uploaded Python 3

File details

Details for the file realsense_cli-0.3.0.tar.gz.

File metadata

  • Download URL: realsense_cli-0.3.0.tar.gz
  • Upload date:
  • Size: 13.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for realsense_cli-0.3.0.tar.gz
Algorithm Hash digest
SHA256 828a9a5cbfc34a1cd86cbbe184b6f74882179633b20d57defe130a32d37a3539
MD5 90144e529c8ed487a3ef001ba1fdf36f
BLAKE2b-256 0ba385f21950f6fe1c428f2e822b6f783cabf1f75981bf3ae8ae2e44068dbaed

See more details on using hashes here.

File details

Details for the file realsense_cli-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: realsense_cli-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 18.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for realsense_cli-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f1c168c096f90c5e86bd75e09f0d3a723f061d229825e2ece528e085269d00c2
MD5 88397b69d2f94448dc2d117996b4941a
BLAKE2b-256 56ab6ca8057a5b0aedbd9121402be9ece04f246f24b46acf4bb48e427b02f6d2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page