Using the uDMX commandline interface and PHP it is fairly easy to build a system to control your lights from a ordinary web browser. In this post I show you how to put a slider on a web page that controls the first channel of your DMX light dimmer. This is not a very useful application, but throw in some more Ajax and a database of your choice, et voilà: A web based lighting desk…
Ingredients
- web server (close to your light dimmers) running Apache and PHP with a free USB port
- libusb installed
- uDMX USB-DMX interface
- script.aculo.us and prototype (or any other ajax library of your choice)
1. Compile the command line interface
Compile the uDMX command line tool for your operating system
cd UDMX_SOURCE/commandline/
make
Move the command line tool to a directory thats accessible by PHP (for example into your web directory, something like /var/www/ on LINUX or /Library/WebServer/Documents/ on MacOSX) and make sure it is executable
mv uDMX /var/www/uDMX
sudo chmod a+x /var/www/uDMX
2. The php script
Next we’ll write a php script that takes some arguments and calls the udmx command line tool
file udmx.php:
3. The HTML file
include the scriptaculous and protpotype libraries in the header of your html and put this slider on your page:
Leave a Reply