dmxusb icon indicating copy to clipboard operation
dmxusb copied to clipboard

Support for Received DMX Packet (Label=5)

Open Nexyll opened this issue 3 years ago • 1 comments

Hi,

I'm building a DMX remote with an arduino. I found that a good part of labels were supported by the library. So it would be interesting to add the support of a DMX input to the existing code instead of starting from scratch.

Do you already have an idea of how to implement this feature?

Nexyll avatar Aug 30 '20 19:08 Nexyll

Hi there! I have not yet implemented DMX input.

Input is a bit more complicated to deal with. The main difficulty is getting a fixed message rate, but this is difficult to do when other things are running on the Arduino, and different Arduino-compatibles are faster/slower more powerful/less powerful than others. Ideally this would be handled in a separate thread so that it is not hindered at all by the user-programmed main loop. This is theoretically possible on the Teensy, but then the library also needs to be made thread-safe, which would be a bit of work.

I should also note that implementing label 5 is only the first part. You would also need to implement labels 8 and 9. A simple driver or program may only rely on label 5, but label 9 (sending only changes) is much more efficient. However I have not tested that so I honestly do not know how widely used it is.

What I am working on right now are some performance improvements, but unfortunately I don't currently have access to the hardware needed to finish that.

You are welcome to work on adding that and I will help you as much as I can. I would definitely review and merge a pull that adds DMX input if you are able to get it to work reliably.

May I ask what specifically you are trying to do? Depending on what software and platforms you are trying to control there may be a much easier way to do this with other protocols and adapting methods. If you would rather it be wireless then it would definitely be easier with sACN and something like an esp8266.

DaAwesomeP avatar Sep 03 '20 21:09 DaAwesomeP