Shiny Lights

This is all about DMX-web

So there’s this thing called DMX.

It allows you to control these sorts of things:

An assortment of lighting fixtures
An assortment of lighting fixtures

In order to create this sort of thing:

Coldplay, apparently.
Coldplay, apparently.

Or, as is much more likely, this sort of thing:

There are surprisingly few pictures on Google Images of drunk people on dodgy dancefloors
There are surprisingly few pictures on Google Images of drunk people on dodgy dancefloors

DMX‘ is the name given to a lighting protocol that can be used to automate and co-ordinate the control of these kinds of lights, which is something you desperately want to know about because it turns out that one day

  • you’re putting on a play, or
  • you have a pub and want to bring in and daze a few punters, or
  • you want to cut down on your obsessive OCD light switching ritual you need to perform every time you leave the house.

If this sounds like you, then you’ll probably want some software that can speak DMX.

The link-level DMX protocol is fairly simple: each DMX cable is daisy chained from one light to the next, with each ‘fixture‘ on that chain taking up a finite number of ‘channels‘ in a 512-channel ‘universe‘. If you want more than 512 one-channel lights, or, say, 64 eight-channel lights, then you need to run multiple universes (sometimes called a multiverse).

I didn’t come up with these names.

Perhaps a diagram is in order:

The cloud-ready DMX-web architecture
The cloud-ready™ DMX-web architecture

So here we have a 5-channel LED spotlight (called a ‘par), a 3-channel box that shoots lasers out of its eyes, and an 8-channel moving head spotlight (called a ‘wash‘, for reasons explained in this wikipedia page).

The channels that each light occupies in the universe can’t overlap with any of the other lights, so each fixture is given an ‘offset‘ defining that fixture’s starting channel, usually by dialling it in on a panel on the back of the thing using mislabelled DIP switches or some kind of digital readout that have differing opinions on where channel 1 is.

The individual channels that a fixture responds to is different for each fixture type, but typically involve some combination of the following:

  • what colour it is
  • what brightness it is
  • where it’s pointing
  • how fast it’s moving
  • what kind of shape it’s casting on the wall (possibly using gobos , which in all likelihood are spinning at some defined rate)
  • how big the shape is
  • whether the shape is in focus or not
  • whether the light is rapidly pulsing on and off and how quickly it’s doing that (‘strobe’)
  • whether it’s intentionally emitting smoke
  • whether it’s currently in a manufacturer-defined light-show (called a ‘macro‘ in DMX terminology), which may or may not be synchronised with whatever the light is hearing in it’s built-in microphone.
    Disco lights have microphones, you’ll be please to hear, especially if you’re the sort of person who wears tin-foil millinery .
    Anyway, if a fixture is currently in ‘macro’ mode, then that usually means it will ignore any inputs on its other channels, except when it doesn’t.
  • and for light fixtures that have multiple outputs, some unintuitive combination of the above

There’s no consistent standard for this, so you might also have extra-special fixtures that do something else, like shoot fireworks or change the channel on a TV or something. If you get enough of these fixtures operating in one place, then you can keep people entertained whilst they’re forced to listen to (popular artist of the day), make your house be the envy of your neighbourhood during the Christmas season, or group them together to form a very bright 0.0001 mega-pixel display.

So let’s say you’ve got a DMX light, a bit of old mic cable , and the cheapest USB to DMX adapter on the planet .

What you want to do, say, is set the value at channel 20 to 255 and then to 0 again in a loop to make the thing flash . And there are many, many, many software products out there that help you to do that.

Why isn’t there even more software that allows me to do this ?

If you’re setting up a small lightshow, you might spend $x0,000 on Chauvet ShowXPress Pro Master Enterprise Professional Expert Edition Premium, Chamsys MagicQ PC (now with wings) or MADRIX, or, if you’re not drinking champaigne out of gold-encrusted goblets, you might consider some of the free packages that exist, such as FreeStyler, DMXcontrol, or Q Light Controller. Or you might choose dmx-web, because I wrote it and it’s ace.

It also runs in a web browser, which I think is something that might take off one day.

When you fire the thing up, you get a selection of buttons that look a bit like this down the left hand side:

The buttons on the left hand side of the DMX-web controller.
The buttons on the left hand side of the DMX-web controller.
The order typically goes (from left to right, top to bottom): Blackout / Shows / Fixtures / DMX / Logs / Config.
If you’re setting this up for the first time, you’d generally go from the last panel to the first.

Clicking or tapping one of those big, fat, roadie-sized buttons will change the display to show you information relevant to that view:

The DMX-web controller panels, in the same order as the image above.
The DMX-web controller panels, in the same order as the image above.

Each panel on the right is slightly purple in colour, which apparently is less blinding in low-light conditions. I wrote it about 5 years ago, so it probably looks a bit naff. It’s all HTML though, so presumably you could make the buttons look like whatever MS/Apple think buttons should look like this week.

At any rate, each panel provides a slightly different abstraction of the light show; the DMX panel allows you to view and modify the raw DMX values that are being sent down the wire, the fixtures panel allow you to tell individual or groups of lights to do things that a human might understand (e.g. make the stage go green), and the show panel allows you to trigger pre-arranged sequences of light and/or sound (e.g. cast a spotlight on stage left, play a dramatic sting, and put ‘ACT III SCENE IV – THE NEXT BIT’ on the overhead projector).

In the interests of pragmatism, there’s also a big red button that turns off everything, which is what you’ll be hitting when things start going haywire, a log panel which gives you some feedback on what’s currently going wrong, and a config panel to configure everything.

Actually configuring the thing is the fun part of course, which is probably too complex to go into in any great depth here. Suffice to say there are another three levels of abstraction in that, depending on whether you want to point and click at things or describe the light show in code, which obviously takes less time, if you’re willing to learn a scripting language and the associated API, which I can pretty much guarantee that you aren’t.

If you are vaguely interested in taking a look at this thing though, why not check out the still not completed website at www.dmx-web.com and put your details in there.

2021-01-09 Update: So after 5 years and failing to make any improvements on this at all, thought it’d be easier just to dump the thing up on github (with a list of caveats) and let someone else have a go at finishing it.

Here you go:

dmx-web
git@github.com:randomnoun/dmx-web.git


    Yes, gobos. Not just a character from Fraggle Rock.
    Which, incidentally, would look fantastic under the disco ball.
    Obviously you’ll be using gold-plated XLR digital DMX cables with platinum connectors, because that will make things flash better, man. Or you’ll use a bit of microphone cable.
    Buy them in packs of ten, and then leave them around so that people steal them
    Because the build process has failed, or no-one’s getting on the rollercoaster, your stock price has raised or lowered by 5%, or you’ve just set initiated your self-destruct sequence.


One Comment

Add a Comment

Your email address will not be published. Required fields are marked *