Skip to main content

A CLI to control NDI-capable PTZ cameras via a joystick.

Project description

ndi-ptz

This is a CLI to control an NDI-enabled PTZ camera with a joystick.

Installation

uv tool install ndi-ptz

# or
pip install ndi-ptz

You also need to install the NDI Runtime, unless you have the NDI Tools or the NDI SDK installed

For further options, like choco or brew, consult the DistroAV wiki.

Quick-Start

$ ndi-ptz list-sources
Looking for NDI sources in the next 5 seconds
TAIL_AIR_006666 (OBSBOT)

$ ndi-ptz list-joysticks
Looking for joysticks in the next 5 seconds
Nintendo Switch Pro Controller (0)

$ ndi-ptz control --source-name "TAIL_AIR_006666 (OBSBOT)" --joystick-instance 0

Supported Joysticks

Currently only the following joysticks are supported:

Nintendo Controller

Only the Nintendo Switch Pro Controller is supported and tested.

  • You must hold L and R constantly to control the PTZ.
  • Use the left stick to control pan (left/right) and tilt (up/down).
  • Use the right stick to control the zoom (up/down).
  • Press the right stick to return the camera to the home position.
  • Hold the A button to trigger the autofocus.

Xbox Controller

Only the Xbox Series X Controller was tested. On Mac, it only works when connected via Bluetooth.

  • You must hold L and R constantly to control the PTZ.
  • Use the left stick to control pan (left/right) and tilt (up/down).
  • Use the right stick to control the zoom (up/down).
  • Press the right stick to return the camera to the home position.
  • Hold the B button to trigger the autofocus.

PlayStation Controller

PlayStation controllers are not tested.

  • You must hold L and R constantly to control the PTZ.
  • Use the left stick to control pan (left/right) and tilt (up/down).
  • Use the right stick to control the zoom (up/down).
  • Press the right stick to return the camera to the home position.
  • Hold the O button to trigger the autofocus.

Development

This project is managed with UV.

Build & Publish

# edit the project version in pyproject.toml
uv sync
git commit -m "Prepare 0.1.5" .
git tag '0.1.5'
rm -rf dist
uv build
uv publish
git push --tags
git push

Legal

This code is provided under the terms and permissions granted by the MIT license.

NDI® is a registered trademark of Vizrt NDI AB.

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

ndi_ptz-0.1.6.tar.gz (17.4 kB view details)

Uploaded Source

Built Distribution

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

ndi_ptz-0.1.6-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file ndi_ptz-0.1.6.tar.gz.

File metadata

  • Download URL: ndi_ptz-0.1.6.tar.gz
  • Upload date:
  • Size: 17.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for ndi_ptz-0.1.6.tar.gz
Algorithm Hash digest
SHA256 65fc4431895faca3da4e339f44b50287373e14bfc67b45800a771f46800043f6
MD5 840171a79597699d6838108be5064d8a
BLAKE2b-256 10a3ab6b97e86713b29f266070aedd49d1458f4e7fb81f4e037a9870633ea758

See more details on using hashes here.

File details

Details for the file ndi_ptz-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: ndi_ptz-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 7.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for ndi_ptz-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 cdca9207584578c3784d7a5c5593a7713e071c3b673930993d1abcc409dc60f4
MD5 54d451e6bf483cfd83e254f954aad823
BLAKE2b-256 1237b227ee7c46576002ffd92776788c01c4f277db766924976bda122e94386a

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