I wanted to ask for help in researching appropriate Microcontrollers to create a Wireless Artnet/sACN Node for DMX communications with film and stage lighting Fixtures. The ultimate goal for the system is to have a mesh network of Nodes that are capable of putting out realtime DMX frames at 44fps. the main reason for a mesh system is to allow a user to control lighting fixtures from an Ipad and allow them to move freely around the stage without worrying about loosing signal connection.

At the moment I've been experimenting with an ESP32 Devboard from Sparkfun and their DMX shield. I've used their example libraries (here) as well as another Arnet Library for the ESP32 (here). I'm still looking into other libraries but so far the ones I have tried all "stutter" (only send one frame of DMX every second or so), then crash after a while and I can't find the bug int the code. I run the ESP32 Module as a wireless access point and this appears to be a cause.

My main question is would it be best to use 2 Microcontrollers for the nodes say an ESP32 for the wifi mesh and Artnet aspects and then an ATmega or Cortex-M4F /ARM Cortex-M7 (teensy 3.0/teensy 4.0) or something else to output the DMX information to the fixutre? Or would it be best to stick with a single microcontroller? Also how does the Serial buffer size affect the ability to output the information of a 512 channel universe, would a 256byte buffer be too small? What other factors, hardware wise would limit its ability to perform constantly for long periods of time?

If it isn't obvious yet I'm fairly new to all of this and exploring out of interest so please be kind. ;)

  • \$\begingroup\$ It's essentially impossible to make a wireless system for streaming a time sequence of events which is both "prompt" and "reliable". You either have to accept the risk of having to hold over old data, or you build in a buffering delay sufficient to give a few retires before you need to act on the data. Regardless of that, figure out the strategy with respect to protocol and buffering before you chose hardware, not after. \$\endgroup\$ – Chris Stratton Nov 1 '19 at 4:08
  • \$\begingroup\$ Hey Chris, I definitely agree. The problem is I'm not 100% sure what I'm looking for. in regards to dmx most of the code puts a universe's 512 channels into an array, then using Serial.write(buffer, length) where buffer is the array to send the data over serial. Is the Serial buffer hardware fixed or can it be manipulated? I see conflicting information on this. thanks for the response. \$\endgroup\$ – Connor N Nov 1 '19 at 13:01

I think the ESP32 is powerful enough to do both WiFi and DMX. Splitting between two micros won't help you much as you'll still need some communicaion link between them.

This guy is doing it with an ESP8266, which is much less powerful: https://github.com/claudeheintz/LXDMXWiFi_Library

On the mesh network side, you probably want to look at this https://github.com/espressif/esp-mdf , rather than running as a WiFi access point.

Also how does the Serial buffer size affect the ability to output the information of a 512 channel universe, would a 256byte buffer be too small?

This is a difficult question to answer without knowing the data rate of DMX and the CPU loading required to do the mesh networking, but the answer is very likely to be "256B is ample".

|improve this answer|||||
  • 1
    \$\begingroup\$ A 256 byte is rather obviously too small to hold an entire frame, if that works or not depends on if the buffer can be re-filled quickly enough during transmission, which depends on the unknowable delay in getting valid data over the radio, or what other local buffer may be upstream of the serial buffer. \$\endgroup\$ – Chris Stratton Nov 1 '19 at 4:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.