Arduino + DMX

  • So I'm building a larger version of the stringin it toy I hardware hacked last year...
    you can see information on that project in this thread --> http://post.monome.org/comments.php?DiscussionID=6453&page=1

    So I decided to purchase a Chauvet ColorStrip to use as the lights in the larger installation to simplify the process.... and now I am running into some theoretical problems involving DMX... I want to sort this out before I get any PCB's fabbed (which I'm hoping to send out monday). Right now I am unsure if I can do what I am trying with an arduino... and may switch to the propeller... I am pasting below my post on the arduino forum which outlines my problem

    I'm working on an installation to make live 3D visuals. The installation will consist of 2 dc motors, a DMX LED lighting rig, and analogue controls for human interaction.

    I am currently hoping to use the arduino as the middle man... specifically using this shield to connect the DMX lighting rig to the arduino.

    Now I am a little bit unsure as to how the arduino handles DMX data, specifically when it comes to DMX protocol. Apparantly a DMX byte is 44us long, and with my lighting rig having 4 channels, so based on my math it would take 308 us to send the DMX data stream for my light's.

    Am I right to assume that while the DMX data stream is being sent that my arduino is incapable of processing any other data? What exactly does the RS485 chip do on the shield? Is it responsible for sending data streams, or does it just make the connection?

    My other concern is if the arduino is the device sending the data stream to the DMX rig, am I going to be able to control my DC motors using PWM and a transistor???

    Ok... lots of questions I know... so I'll reiterate very simply...

    1) Is the arduino going to be unable to perform any calculations while streaming data to DMX
    2) Can I use the arduino to stream DMX and control motors using PWM at the same time
    3) Can I poll user interaction while DMX stream is being sent
    4) Should I be looking into a multi-core micro-controller such as the propeller for this project?

  • Bueler?

    Well I heard from a friend of a friend who's sister.....

    Seriously though... I know very little about arduino, as in next to nothing. So this may not help that much. However, I do happen to know a heck a lot about DMX and the like because I interned with ETC for a while.

    This is my guess: DMX is mono-directional (right now), it has to completely send all data packets to the fixtures or console before it can switch directions and receive data back from where it was sent.

    So, if the arduino is only single-core (I think you mentioned that), then you'll only be able to handle the DMX fixture with the chip. You won't be able to send out more than one stream before the process is complete.

    So to have at question 2, my guess is that you might be able to if you don't take the full 512 packets that can be sent with DMX, which you won't with 4 channels.

    I really wish I knew more about arduino and other hardware controllers now, sorry. Perhaps after a quick read of the arduino documentation I'll be able to answer you better.

  • I'm going to work with this code

    http://code.google.com/p/tinkerit/wiki/DmxSimple...

    We'll see what happens... :D

    I get my pcb's and componants to make a dmx shield and my lights on wednesday... then I'll be experimenting :D

  • Theres always that too. I think I like experimenting even when it won't work out, there seems to be a lot more learning involved somehow.

  • Well I've got my arduino controlling DMX!

    Built one of the shields from the Arduino.cc documentation, and used the DMXsimple libraries posted above and was able to successfully control my lights via the serial terminal.

    I'll have some max patch's up and running soon. Will be looking to integrate TouchOSC, and monome control!

    Will post when I have some stuff to post.

  • Sweet working action! Got the touchOSC stuff working this afternoon

    http://www.youtube.com/watch?v=XX9AVYvVYFU

  • don't suppose you have any extra boards??

    Is your DMX board compatible with arduino duemilanove?? I'd love to get something set up for a house party next weekend.

    I'm also located in Calgary, AB.

    Just looking for some DMX gear to interface with on http://www.prosounddepot.com. Their deals seem pretty good and its free shipping to Canada...

  • Sweetnessss! I love the picture you posted, the XLR/DMX out looks like some kind of helicopter rocket canon. I think it's about time I go and buy an arduino and start finally getting my hack on.

    Couple questions though:
    1) Are you using the duemilanove board?
    2) Can you drop a list of components your using on the shield, I really want to mess with this quite a bit.

    I think it'd be pretty cool to go and code a max patch that can universally recieve midi data from other apps like polygome.

    Thanks man and good luck.

  • I do have an extra board but I doubt you want it as it would be $35 (what I paid for it) and I totally botched it by putting the socket in backwards.

    Good news... the place I got them printed from is in Calgary

    http://www.apcircuits.com/

    Boards will be much cheaper for you to get if you pick them up (I had overnight delivery). I believe the cost was around 30 bucks for the 2 boards... the rest was shipping.

    You can get the eagle files for the pcb's from this site http://iad.projects.zhdk.ch/physicalcomputing/hardware/arduino/dmx-shield-fur-arduino/

    I found the lights I was working with on the site you posted

    http://www.prosounddepot.com/Chauvet-COLORstrip-DMX-LED-Linear-Wash-Light-Prodview.html

    but I would advise against using these. I didn't do my research prior to the purchase (really rushed for an installation) and it turns out that the fixture is not exactly DMX compliant... as it can't receive information fast enough... which can cause the occasional random flicker... I'm trying to write some code to fix this, but it is a work around not a solution.

    Either way the DMXsimple library I posted above has worked very well for me, and the shield is excellent... if you have any questions or want any of my code give me a holla

  • Parts List from Mouser

    688-RDC1022A05
    10K ohm 22mm travel x 1

    571-1-390261-2
    8P ECONOMY TIN x 2

    294-100-RC
    100ohms x 1

    595-SN75176AP
    Bus Diff x 1

    568-NC3FAH-2
    3C FEMALE RECEPT x 1

    You are also going to need headers... I had some from sparkfun that I used...

    I used Breakaway female headers which you can find here
    http://www.sparkfun.com/commerce/product_info.php?products_id=115

    And also used Breakaway striaght Headers which you can find here
    http://www.sparkfun.com/commerce/product_info.php?products_id=116

    I used the male ones for the connection to the arduino, and the female one for the break out pins... allowing me to prototype easily.

  • Sweet sweet thanks for that. This looks like a great way to experiment with DMX at a low cost.

    I really think I might build one of these and use it to drive my permanent table front rather when I play live.

  • I finished the installation... check out the video and tell me what you think

    http://www.youtube.com/watch?v=X96E2jjCfC8

  • I had got a desire to begin my own firm, nevertheless I did not have enough amount of cash to do that. Thank God my close mate proposed to utilize the credit loans. So I received the commercial loan and realized my desire.

  • Hey man, thanks for throwing this idea out there a while ago. I ordered the parts and just need the circuit board. I'm having a problem though because the company you used can't open the .brd and .sch files that you posted a link to above.

    I don't own EAGLE or know how to save the files in the different format that they requested. They had this to say in an email:

    "In order to provide the most accurate pricing we ask
    that you submit the following data for your designs: an NC drill file in ASCII Excellon format; and
    the outer and inner copper layers, the solder mask layers, and the silk screen layers in either Gerber
    RS-274X format, or Gerber RS-274D format with an external aperture file."

    Could you either tell me how to convert the DMX1_2 files or drop a link to files you already made? I'd appreciate it very much. Thanks in advance.

  • I'll check when I get home to see if I still have the files... I downloaded eagle for free to make them, followed a tutorial I found googling... I'll let you know if I find them

  • Ok sweet thanks. I found the freeware version of EAGLE but can't figure out how to save them exactly as they requested. I'll take another smack at it and ask google. Thanks man.

  • Hey, so thanks to tehn and google I'm pretty sure I figured it out and got it right.

    If you do happen to still have you files can you still send them my way? I want to peep them to make sure I did everything right. By the way, didn't you say you had an error with one of them?

  • Hey just curious, did you have a hard time pulling the resistor through the holes? The ones you recommended and I ordered from Mouser seem too big. I'm putting a lot of force on them to get it flush.

    Gonna head up to Radio-shack and see if they have ones that are smaller because it seems like all my other packets from them are smaller than my ones from Mouser.

    Thanks.

  • freelance writer