Skip to main content

Blocking Python facade for driving Extron SIS devices over SSH

Project description

sismatic

An open-sourced library for working with the Simple Instruction Set used by many Extron devices. The name comes from SIS + automatic, because it handles the SIS machinery behind the scenes without human control.

Why?

There are several reasons why this library is worthwhile:

  1. Relies on a stable, unchanging protocol.
  2. Hides complexities of managing connections.
  3. Hides complexities of byte-level communication.

Python Consumer Example

The following is an example of how this library can be consumed in Python.

Examples

Configuration

[defaults]
port = 22023
connect_secs = 5
command_secs = 3

[[device]]
id = "atrium-101"
host = "10.0.0.7"
username = "admin"
password = "extron"

[[device]]
id = "annex-far"
host = "10.0.0.8"
username = "admin"
password = "extron"
connect_secs = 10   # override default connect timeout
command_secs = 8    # override default command timeout

Iterate over package public properties

>>> from sismatic import Sis
>>> [m for m in dir(Sis) if not m.startswith('_')]
['command', 'from_toml', 'ids', 'query', 'register']

List Recorders (no network)

from sismatic import Sis

sis = Sis.from_toml("devices.toml")
for device_id in sorted(sis.ids()):
  print(device_id)

Start a Recording

# control_recording.py
# Starts recording and stamps a title across a batch of devices.

from dataclasses import dataclass
from sismatic import Sis

@dataclass(frozen=True)
class RecordingJob:
    """(device_id × title) as a product type. A job is exactly a pairing of
    the two — never one without the other — so the type says that, instead
    of the two strings being threaded separately through every call site as
    two positional arguments that happen to always travel together."""
    device_id: str
    title: str


def run_job(sis: sismatic, job: RecordingJob) -> None:
    sis.register(job.device_id, "title", job.title)   # "title" — see Register::Title
    sis.command(job.device_id, "start")                # "start" — see Command::Start


def main() -> None:
    sis = Sis.from_toml("devices.toml")
    jobs = [
        RecordingJob(device_id="atrium-101", title="Week 4 — Lecture"),
        RecordingJob(device_id="annex-far", title="Week 4 — Overflow Room"),
    ]
    for job in jobs:
        run_job(sis, job)


if __name__ == "__main__":
    main()

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

sismatic-0.1.3.tar.gz (59.1 kB view details)

Uploaded Source

Built Distributions

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

sismatic-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl (1.6 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.28+ x86-64

sismatic-0.1.3-cp38-abi3-macosx_11_0_arm64.whl (1.9 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

sismatic-0.1.3-cp38-abi3-macosx_10_12_x86_64.whl (2.0 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file sismatic-0.1.3.tar.gz.

File metadata

  • Download URL: sismatic-0.1.3.tar.gz
  • Upload date:
  • Size: 59.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for sismatic-0.1.3.tar.gz
Algorithm Hash digest
SHA256 c5268fbffb5f311300eb62aeca7f4de3404d5e5bd5c44eb0fbe3cdf12a3a4a17
MD5 c96ad8c7d6b0e55e4fb7fe99cbdd78a6
BLAKE2b-256 95fe9ab4ef52b3bfa34b21eb2133ab2f654e1435ee07fa5b4d8038c1afb73783

See more details on using hashes here.

Provenance

The following attestation bundles were made for sismatic-0.1.3.tar.gz:

Publisher: pipeline.yml on metzenseifner/sismatic

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sismatic-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sismatic-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 65ad6bf9b6b47c06a59dd93b1e7509f130c50c17707aecbcd69fa028156e7a73
MD5 bc17195d30c49646f4e605b7af07620a
BLAKE2b-256 95c8a78b5d6bf8a3352f8a92597d56bb3f4401518f987535cd08f6aa19c7a045

See more details on using hashes here.

Provenance

The following attestation bundles were made for sismatic-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl:

Publisher: pipeline.yml on metzenseifner/sismatic

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sismatic-0.1.3-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for sismatic-0.1.3-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 186d6dfa42999d8448592f111a7fd7c115dcbb7dedff21a4fc861299e2eb0bae
MD5 e549242cf43e0c1fd0ff6e44bdf74707
BLAKE2b-256 a7f464d0317f341a6ebb6ac24a86ed888bbb5cf056a9b74e7ed65c22101f3590

See more details on using hashes here.

Provenance

The following attestation bundles were made for sismatic-0.1.3-cp38-abi3-macosx_11_0_arm64.whl:

Publisher: pipeline.yml on metzenseifner/sismatic

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sismatic-0.1.3-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for sismatic-0.1.3-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 27b7bbefff9fbfd12a0aa8b7c9139d585ddc47622a2e4c5e62299ffd5b04e994
MD5 239a8d8a2b9fe390ea5b3f841a4d44ec
BLAKE2b-256 8909c074d2c2cd0946763bec28b773ea06fb5cc8e7b8578d3d1ef7e74e29bc62

See more details on using hashes here.

Provenance

The following attestation bundles were made for sismatic-0.1.3-cp38-abi3-macosx_10_12_x86_64.whl:

Publisher: pipeline.yml on metzenseifner/sismatic

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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