Crates.io | enttecopendmx |
lib.rs | enttecopendmx |
version | 0.1.1 |
source | src |
created_at | 2021-09-17 14:46:04.152952 |
updated_at | 2021-09-18 08:54:22.365929 |
description | Rust bindings for the Enttec Open DMX USB and its FTDI D2XX Chip. |
homepage | |
repository | https://github.com/Beuscher/enttecopendmx-rs |
max_upload_size | |
id | 452808 |
size | 12,711 |
DISCLAIMER: still in testing
Rust bindings for the Enttec Open DMX USB and its FTDI D2XX Chip.
The code is roughly based on the programming examples provided by Enttec, from which I extracted the settings for the FTDI Chip. For communication with the chip the excellent crate libftd2xx as a safe wrapper of the FTDI 2DXX driver c-bindings from the libftd2xx-ffi crate.
First install the FTDI 2DXX driver
Then, simply add this crate as a dependency in your Cargo.toml
.
[dependencies]
enttecopendmx = "0.1.0"
This basic example sets the output of channel 1 to the maximum value of 255.
use enttecopendmx;
let mut interface = enttecopendmx::EnttecOpenDMX::new();
interface.open();
interface.set_channel(1 as usize, 255 as u8);
interface.render();
or simply run cargo run --example rgb-chase
in the root directory of the (github) repository.
The changelog can be found in the Changelog.md file.
If you encounter any problems just open an issue, but a response may take some time.
Result<T,E>
return values for all methodsEnttecOpenDMX::new()
method, which allows to specify the interface eg. by serial numberThis crate is still in an early version, so if you have suggestions for improvements regarding this crate feel free to open a pull request.