Jump to content

DMX512 Controller


philetaylor

Recommended Posts

  • Replies 77
  • Created
  • Last Reply

Top Posters In This Topic

Wouldn't that particular application rather call for the use of a joystick? Could be done with just two analog inputs...

I know I was just musing, I will probably end up using a joystick.... I did wonder whether a laptop style touchpad would be usable? I have never really looked at them, we have loads of dead laptops at work so I might investigate further....

Link to comment
Share on other sites

Wow, that's good quick work youv'e done.

I second that your casing can easily be the most expensive part of a design.

Do you have any plans to implement the second data pair of the DMX spec? I think RDM uses this, but I don't currently own or work with any gear that needs this, just wondering. I assume so far that you are just using the standard IIC midi module with 5 pin XLRs instead of 5 pin DIN's?

Your really tempting me to start playing around with this, but I must resist..... Must finish other projects.......must resist.......Aaaaarghhhh.....must resist....

Link to comment
Share on other sites

I know I said that it was a medium term project but I got a bit with the bug and decided to make a start (and I haven't stopped since!!)

I wasn't planning to implement comms on the the second pair as most manufacturers seem to have their own systems that are incompatible whereas RDM is a bit more intelligent.

The current RDM standard (ANSI/ESTA E1.20) is actually a bit more intelligent and I am planning on trying to implement it as soon as I get a fixture that supports it.

The way it works is that the controller usually streams DMX messages with a start code of 0x0. RDM uses a different start code (0x33 I think) which non RDM fixtures 'should' ignore and then stops sending DMX streams and waits a pre-defined time for the fixture to respond.

I have implemented the hardware required for this by using a spare output on the p16f88 to switch the SN75176 to input so I just need to write the code (once I know what is required!). I will post the schematic for my little interface soon.......

Phil

Link to comment
Share on other sites

Hi.

Here is a quick circuit that I have knocked-up.

It should probably have a 120 Ohm resistor between pins 2 & 3 of the XLR but I haven't bothered at the moment!

The benefit with the 75176 is that it has active high tx and active low rx so tx/rx can be toggled with a single data line.

I suppose I should include some sort of opto isolation eventually but I can't really be bothered at the moment!

Cheers

Phil

IIC-MIDI_IF.pdf

IIC-MIDI_IF.pdf

Link to comment
Share on other sites

Ahh yes, that's correct on RDM. I have been reading, slowly over the last 10 months, a very good book on show control, thought the title and name escape me at the moment. I went back to it last week and decided it has almost enough info to not need to purchase the official DMX spec... and tons of other stuff. I'll edit this post with the title and name when I A) remember it B) long enough to post it....

as for being bitten by the bug, that's why I am trying to finish my other projects first......even though this one would probably be used more often, it seems I am in the church (where I plan to use this device) much more than my own studio anymore.

Anyway thanks for sharing your work, I'll try to look it over soon, though I haven't looked at your code I downloaded last week yet..... I have been commisioned by a local church to install a sound system and owe them a proposal next week. Paying gigs always take precedence  ;)

Link to comment
Share on other sites

Having tried both, I'd suggest an incremental (trackpad/trackball) type control for pan and tilt, rather than a joystick.

If you have a moving mirror type unit, the joystick can work well, since the mirror's range of motion is typically less than 180 degrees in either axis. Movement of the joystick stick can then directly match the mirror (especially with some of the really quick mirror units...)

If you have a moving head unit, most of these have around 270 degrees for tilt, and 540 degrees for pan. This can be very confusing and difficult to control using a joystick, as the same physical lamp position can be found at several joystick positions.

Using an incremental control also works well when moving groups of fixtures together.

Link to comment
Share on other sites

Ahh yes, that's correct on RDM. I have been reading, slowly over the last 10 months, a very good book on show control, thought the title and name escape me at the moment. I went back to it last week and decided it has almost enough info to not need to purchase the official DMX spec... and tons of other stuff. I'll edit this post with the title and name when I A) remember it B) long enough to post it....

as for being bitten by the bug, that's why I am trying to finish my other projects first......even though this one would probably be used more often, it seems I am in the church (where I plan to use this device) much more than my own studio anymore.

Anyway thanks for sharing your work, I'll try to look it over soon, though I haven't looked at your code I downloaded last week yet..... I have been commisioned by a local church to install a sound system and owe them a proposal next week. Paying gigs always take precedence  ;)

It is annoying when proper work gets in the way of having fun isn't it  :)

With the code, I have made massive changes recently so I will probably just update the attachments on the other post.

Everybody seems to have slightly different ideas on implementation when it comes to DMX so I would welcome any suggestions, especially wrt timing. RDM seems to expect to receive a packet within 58mS of sending the RDM request so these can easily interleave with the DMX packets and still achieve over 40 packets a second.

I got a big delivery last week so I have been concentrating on the hardware recently, I got a 40x4 display as well which may be too big but at least I can display plenty of information!

Cheers

Phil

Link to comment
Share on other sites

BTW, the opto is only required/possible on an input, not on an output (same as MIDI).

Yes I thought that but I notice on the magnulator project ( www.freedmx.org ) they have used a 6n137 between the PIC and the 75176. I suspect that it is overkill but as it is talking to devices that 'could' inject mains voltages onto the DMX bus they were just playing very safe. Especially as on their project the other end of the PIC is connected to a PC parallel port, I am not sure how much isolation the 75176 provides?

Phil

Link to comment
Share on other sites

  • 2 weeks later...

I have been making many changes to the code recently, I redesigned the IIC-DMX firmware again and I have cut the DMX channels down to 256. I was tearing my hair out with 352 channels as 16 registers just wasn't enough for temporary data etc.

I was concerned that the core was having to retry IIC sends a lot so I am now doing the IIC receive via an interrupt and buffering it. I am not now getting retries and it all seems much more stable.

As RDM definately interests me and I can't find a (cheap) RDM compatible dimmer/fixture, I have decided to build one! I am currently designing the pcb etc for a 4 channel dimmer so this is taking quite a bit of my time (I wish I could just stick to doing one thing !!!), hopefully I can then use it for RDM testing etc.

I am going to Poland for the weekend but I will post updated code soon!

Phil

Link to comment
Share on other sites

I have just updated the downloads on the wiki page http://www.midibox.org/dokuwiki/doku.php?id=midiboxdmx to the latest (still very beta) version.

This version seems much more stable and I am now using a simple CRC8 check for the terminator so the chance of invalid data being received should be almost zero..

Buffering the received IIC data and making it interrupt driven also seems to have fixed most of the retry/timeout issues. I have also tried to tidy the code up a bit although there are still some very messy bits!

Cheers

Phil

Link to comment
Share on other sites

Can/should I move this to 'User Projects' yet? I think so.

BTW, where did you get that sexy-ass LCD?!? What is it? Give us the goss! :D

The 'squares' make it look optrex, and the high contrast/wide viewing angle... but optrex don't do 4x40....

Hi Stryd, Yes a move to user projects works for me....

You are quite right (well wrong actually)  :D  it is an OPTREX C-51849! Got it from RS in the UK, about £35.

Cheers

Phil

Link to comment
Share on other sites

I now have a copy of the Wybron responder source for RDM and the spec pdf for RDM (ANSI E1.20) there are various changes that it looks like I should make with regard to timing etc and they also recommend that the controller contains a simple voltage divider which works as a bias circuit providing a 'mark' even when the controller is in the receive state (high impedance). I will look at this over the next few days.

I think that to fully support RDM may be a bit complicated to handle within the midibox controller itself but I may write a PC program which actually handles the RDM discovery etc as then I have no memory constraints, I was thinking that the actual RDM information could be transferred to/from the PC as Sysex  messages. As this is not mission-critical it wouldn't really matter if the PC was not connected during normal operation but it could be connected to handle discovery and any error conditions.

p.s. Thanks for moving the thread stryd.  :)

Link to comment
Share on other sites

I had some fun last night, I got a bankstick connected and created a simple chase function and it worked! As I still haven't quite got round to finishing a DIN module (I forgot to order enough resistors...) so I created a simple store routine for each state using midi notes. I actually have a simple lighting desk now, unfortunately it has cost me £100s so far and has less functionality than ones I can buy on ebay for £60 but it is a start and I now know a LOT more about DMX!

I did have some problems with the bankstick, initially I was calling MIOS_BANKSTICK_ReadPage from within the Timer function and I kept getting some weird results. I then changed it so the Timer sets a flag and called MIOS_BANKSTICK_ReadPage from within the Tick function and it seems to be much more stable. I suppose this is the best way to guarantee that the IIC bus is free? Is the the recommended way to do it?

I received a case today so I may look at trying to get everything mounted over the christmas period. I am still not sure how to cut the slots for the faders or the hole for the display though ???

I have also made some (administrative) advances with RDM support. Each RDM compliant device MUST have a unique 48bit ID and ESTA assign a Manufacturer ID for the first 16 bits. I have got the ID of 4D42h assigned to the midibox project (care of me) and I have checked with TK to make sure he is OK with me administering it. I am planning to create a website to allow people to request a block of addresses for their devices but this is a long way away  :)

Cheers

Phil

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...