Luxbeam Introduction
- Documentation: https://qiti.github.io/Luxbeam/
- PyPI: https://pypi.org/project/Luxbeam/
Luxbeam is a python package that implements the protocol for programming Luxbeam DMD controller from VISITECH.
The Luxbeam class implements the control protocol of Luxbeam digital micro-mirror device (DMD) controller.
This is tested with Luxbeam 4600 controller and DLP9500UV DMD.
In addition to equipment control from the Luxbeam class, the LuxbeamSeqeuncer class implements the support for composing sequencer code used in Luxbeam controller.
This allows the user to compose the sequencer code using native python arithmetic operations and some of the flow controls.
Installation
Luxbeam can be installed from PyPI via:
pip install Luxbeam
One can also clone the repository to install it in the develop mode:
pip install -e .
Test
It is recommended to run the test cases to ensure LuxBeam is compatiable with your setup.
Run the tests in the test folder:
pytest test --ip="<IP address>"
Run the interactive tests:
pytest test --ip="<IP address>" --interactive -s
Example
import Luxbeam
from Luxbeam.sample import number_image
# This is the equivalent example of displaying non-scrolling images in the LB 4600 user guide.
# Connect to the Luxbeam
luxbeam = Luxbeam.Luxbeam("192.168.0.10", timeout=1) # modify the ip address if required.
# Prepare the image (display 123 on the DMD)
image = number_image(123, luxbeam.cols, luxbeam.rows)
# Set image type to 1 (binary). (One-time Operation)
luxbeam.set_image_type(1)
# Set inum size to 1080. (One-time Operation)
luxbeam.set_inum_size(luxbeam.rows)
# Disable the sequencer.
luxbeam.set_sequencer_state(Luxbeam.SEQ_CMD_RUN, Luxbeam.DISABLE)
# Set sequencer in reset-state
luxbeam.set_sequencer_state(Luxbeam.SEQ_CMD_RESET, Luxbeam.ENABLE)
# Load the image to inum = 0.
luxbeam.load_image(0, image)
# Compose the sequencer file.
seq = Luxbeam.LuxbeamSequencer()
for _ in seq.jump_loop_iter(): # A while-true loop
seq.load_global(0, 400) # Load data from Inum (0) to DMD
seq.trig(Luxbeam.TRIG_MODE_NEGATIVE_EDGE, Luxbeam.TRIG_SOURCE_INTERNAL, 0) # Neg. edge internal trigger
seq.reset_global(40) # Display contents on DMD
# View the generated sequence file
print(seq.dumps())
# Send sequence file.
luxbeam.load_sequence(seq.dumps())
# Take sequencer out of reset-state
luxbeam.set_sequencer_state(Luxbeam.SEQ_CMD_RESET, Luxbeam.DISABLE)
# Start the sequencer
luxbeam.set_sequencer_state(Luxbeam.SEQ_CMD_RUN, Luxbeam.ENABLE)
Metadata
Release files for Luxbeam 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| Luxbeam-0.1.2.tar.gz | 10.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| Luxbeam-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.1 kB
Release files / Luxbeam-0.1.2.tar.gz
| Download URL | Luxbeam-0.1.2.tar.gz |
|---|---|
| Size | 10.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ef8b69b907b5c2e6c0acc2b9226154433dfac4ac4beb1a37bf2eeb319efda5dd
|
|
BLAKE2b-256 checksum How to use checksums |
97f3b1d6fd66daa53027014cdb3f1266d39760c89788f768bc4d83f00626c805
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.18
|
Release files / Luxbeam-0.1.2-py3-none-any.whl
| Download URL | Luxbeam-0.1.2-py3-none-any.whl |
|---|---|
| Size | 10.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ce0cd578c09ae053865254f3e0273b05496b6fef7fb739486af7edea737a03fa
|
|
BLAKE2b-256 checksum How to use checksums |
98f02d6bb4da2c2a43aecf676e2c050a5c3e27f563847927071ec8181a4f5ca8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.18
|