1

We are working with Unity 3D and we have a game fully developed, but the client wants fully operational game rooms, with lights, fans, fog machines ect (in the real world) that will be triggered from the Unity game that we have developed, I`ll start in saying that I have no idea how to do this, and I'm stressing! I understand that I need to use a DMX box for this, we have done a lot of research and the enttec USB DMX PRO seems like the right way to go, but I don't know how to use a DMX box at all.

I may be wrong, but it seems we need to send a file of code to it to giving it it's actions to preform? and we send it this code by placing the code file in a folder, but I'm not sure of that! if this is the case, then I could get unity to place files in a folder at the correct given moments in the game.

If someone who knows how to send code to a DMX box, it would be great if you could correct me on this, and if you could tell me the type of code so that I can get learning it that would be great.

And is the USB DMX PRO to right way to go?

JasonMArcher
  • 14,195
  • 22
  • 56
  • 52
Beauzach
  • 11
  • 1
  • 3

3 Answers3

0

I didn't know dmx box before reading your question and it indeed looks like it could fill your purpose, but only if you are going to use dmx compatible hardware only.

I had unity programs that were also used to control real world events in several instances -for instance in order to trigger a camera shutter- the thing is that unless you use a ready-to-use fully wrapped hardware set, there is not going to be a single unit that will be able to control all your real world devices.

In the case of your smoke unit for instance, chances are that there is only a GPIO pin for you to control it. You would in this case need to look into building a micro-controlling unit for each of the real world devices.

More specifically, the chain of command would be like that: 1. Unity wants to start the smoke, sends command to wrapper 2. Wrapper transmits command to Microcontroller 3. Microcontroller transmits appropriate signal to smoke unit (or real world button-pusher if the smoke unit doesn't even have a GPIO)

This process can take some time, especially if you are not familiar with microcontrollers, but it is definitely doable, the question remains if the client is okay with the development time and cost.

TNTanuki
  • 59
  • 7
0

DMX is the way to go, you can get all-sorts of kit that can be controlled by it (including smoke machines)

The protocol itself is easy, its just a stream of 8-bit 512 byte values repeated over and over again, the timing is crucial though so the stream needs to be generated in its own process or even processor (which is how the entec pro is doing it)

The interesting thing is how to talk to that process or processor and as a programmer, thats what should lead your decision, dmx interfaces will either let you talk raw to the interface or be oriented around triggering 'scenes' which are ready made sets of values

What you are being really asked to do is "show control" a popular protocol for that is "OSC" (open sound control) so the way I would tackle it is install the OSC library into unity, and use a dmx hardware/software combination that is compatible with that.

back_ache
  • 382
  • 1
  • 13
  • This is what we finally did, I should have listened to your advice sooner as i tried to send the commands directly from unity which turned out to be a waste of time, if it's possible or not I don't know... But I couldn't do it ;) In the end I used UniOSC and lightjams – Beauzach Nov 14 '14 at 08:39
  • Glad you got it working, Lightjams looks really great – back_ache Nov 18 '14 at 13:24
0

I don't know Unity framework, but maybe it will be easier to use Artnet protocol. It is over Ethernet so it should be easier to program. Or you can try using 3rd party software like LightJams - it is full featured DMX controller, with OSC support. There is OSC library for Unity, so you can set up cues on LightJams (ie. turn on lights to red, and switch on fog machine) and execute them by sending OSC commands from Unity to LightJams.

mefju
  • 539
  • 7
  • 26
  • 1
    unfortunately I can't set two answers as correct, but OSC (UniOSC asset) and LightJams is the way we went and it works! – Beauzach Nov 14 '14 at 08:40