DMX is generally an industry standard for controlling lighting technology and is used in stage and event technology. Areas of application for DMX range from simple control of lighting technology such as dimmers to ‘intelligent’ spotlights such as moving heads and effect devices.DMX stands for Digital Multiplexing. The most widely used DMX protocol is DMX512, as it is the oldest.
DMX uses RS485 as its physical layer. With an $ RS485 shield $ , you can control DMX devices with an Arduino.
DMX Spotlight
LED spotlights with DMX connections are available from specialist retailers starting at around £35. These spotlights are usually called ‘LED MINI PAR LIGHT’ or something similar. There are usually two 3-pin DMX connections (old DMX standard) on the back of the spotlight. Connections A (also known as the hot connection), B and shield are connected to our RS422/RS485 module with the connections of the same name on the screw terminal strip.
Wiring
The current DMX standard specifies five-pin XLR connectors. From an electrical point of view, however, these function in exactly the same way as the three-pin connectors, provided that the DMX device still supports the DMX512 standard. (The free contact pair pins 4 and 5 are only used in the DMX512-A standard.)
The connection to the RS485 shield is made according to the connection diagrams below.
Configuring the shields
For DMX512 communication, the DIP switches and jumpers on the shield must be configured correctly.
First, we set the DIP switches as follows:
Now the jumpers must be set correctly. Jumper JP1 is set to the 5V position. The jumpers JP2 - JP4 for communication are set as shown in the figure below:
Only one jumper is required for TX. The jumper for RX is not required.
Software
Many examples refer to the DMXSimple library. Unfortunately, this library does not support the Arduino UNO R4 and appears to no longer be maintained. However, this is not a problem, as Arduino itself offers its own DMX library that supports both the Arduino UNO R4 and the R3.
When compiling for the UNO R3, you will receive a warning. In my experience, however, the programme still works on the UNO R3. Since the UNO R3 only has one serial interface, you will have to do without debug output in this case.
Unfortunately, there is no standardisation of channel assignments for DMX512 devices, so each manufacturer assigns channels to their DMX devices slightly differently. I use an LED MINI PAR Light 86, which has the following DMX channels:
A look at the manufacturer's data sheet/operating instructions for the respective spotlight reveals which DMX channels are assigned to which functions.