Skip to main content

Network client for Advanced Illumination DCS light controllers

Project description

pydcscontrol PyPI - Version

Python client library for communicating with Advanced Illumination DCS light controllers over the Ethernet interface.

This package implements the controller's SCPI-like command protocol over TCP (default port 777).

Even though the DCS controller is super simple, it is nice to be able to pull in a package to one-liner the most common operations.

These common operation wrappers also do a validation of the current configurations for a sanity check.

Usage

Command line (Using uv)

Using the easy-set CLI script to set the current of one or more DCS channels to 100 mA:

uvx --from pydcscontrol easy-set 100 --channels 1 2

Using the turn-off CLI script to turn off one or more DCS channels:

uvx --from pydcscontrol turn-off

Both commands default to channels 1 and 2 when --channels is omitted.

Python script

Install the package:

uv add pydcscontrol
# or
pip install pydcscontrol

Using continuous mode to set the current of one or more DCS channels to 100 mA:

from pydcscontrol import DCSController

if DCSController().easy_set(channels=[1, 2], current=100):
    print("DCS channels configured successfully")
else:
    print("DCS channels configuration failed")

Quickly turn DCS output off:

from pydcscontrol import DCSController

if DCSController().turn_off(channels=[1, 2]):
    print("DCS channels turned off successfully")
else:
    print("Failed to turn off DCS channels")

Development

uv sync
uv run ruff check
uv run ruff format .
uv run pytest
uv build
git tag -a vX.Y.Z -m vX.Y.Z
git push --tags

If a deployment fails

git tag -d vX.Y.Z
git push origin :refs/tags/vX.Y.Z
git tag -a vX.Y.Z -m vX.Y.Z
git push --tags

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

pydcscontrol-0.2.0.tar.gz (18.0 kB view details)

Uploaded Source

Built Distribution

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

pydcscontrol-0.2.0-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

Details for the file pydcscontrol-0.2.0.tar.gz.

File metadata

  • Download URL: pydcscontrol-0.2.0.tar.gz
  • Upload date:
  • Size: 18.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for pydcscontrol-0.2.0.tar.gz
Algorithm Hash digest
SHA256 db03085eb666e698b6b2b0cc839f3c06429073072478f3a73f3026d640cd181d
MD5 20e0f7254e2abc86e883c73ce586e15a
BLAKE2b-256 54a837426eac48210bacf595d6b7b4c6b4b8af0a05e77908205e8e392b766408

See more details on using hashes here.

File details

Details for the file pydcscontrol-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: pydcscontrol-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 7.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for pydcscontrol-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ac7f8fdce57c19307f29abb53e7d96915a24e3eb4f5edca0f8f5f5d18952a205
MD5 82ade8b4af95e1e8b47938f89c424d61
BLAKE2b-256 0fa0996b7f5a60842ebd444a5ec030b1e0929144d37be47604ce76a78f423b68

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