sinette
Minimalistic Python library for Sinette DMX levels. No checking, just getting levels.
Status
- Subscribe and get DMX levels
Installation
- With uv:
uv add sinette
- With pip
pip install sinette
Usage
import time
import sinette
sinette_universe = 1
sinette_scope = "local"
sinette_receiver = sinette.SinetteReceiver(scope=sinette_scope)
@sinette_receiver.listen_on("universe", universe=sinette_universe)
def on_sinette_dmx(packet):
print(
f"[{packet.scope}] universe {packet.universe}: {packet.dmxData[:16]}",
flush=True,
)
def main() -> None:
sinette_receiver.join_multicast(sinette_universe)
sinette_receiver.start()
print(
f"Listening for Sinette universe {sinette_universe} in scope {sinette_scope!r}. Press Ctrl-C to stop."
)
try:
while True:
time.sleep(1)
except KeyboardInterrupt:
pass
finally:
sinette_receiver.stop()
if __name__ == "__main__":
main()
Development
PRs appreciated. You can use uv to get the project setup by running:
uv sync
Format
- To format, use ruff
uv format
Pre-commit hooks
- You can use the pre-commit hooks
uv run pre-commit install
Testing
- To test, use pytest
uv run pytest
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sinette-0.1.0-py3-none-any.whl.
File metadata
- Download URL: sinette-0.1.0-py3-none-any.whl
- Upload date:
- Size: 6.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":null,"id":"forky","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4d043c79279ad8e8653bf743474968a372f315b754e00680bdd58dcbb1436fb6
|
|
| MD5 |
c91878a1d63e53bd5f7fbf1922ae1451
|
|
| BLAKE2b-256 |
73637a901533dee60576392c305f44f7c2b196675ee88ffaf429a9c31dca6e76
|