Channels To Digital Outputs

Open Source software contributions and discussions that supplement or extend the Palette / Light Palette software
User avatar
BrianEvans
Posts: 700
Joined: Fri Oct 12, 2007 1:11 pm
Location: Orlando, Florida

Channels To Digital Outputs

Post by BrianEvans » Thu Oct 02, 2008 3:51 pm

This code allows digital outputs to be driven by standard channels.
In the attached show file the macro is on the "IO_Link"
variable page, which has a macro that constantly triggers it.

Code: Select all

--* * * Channels To Digital Outputs Conversion  V1.0* * *
--* * *  Written By: Brian F. Evans - HCI * * *

IO_Channel=101          --Starting Fixture
 IO_Output=1            --Starting Digital Output Variable
   IO_Page="Digital_IO" --Name Of Variable Page Containg Digital Outputs
  IO_Total=24           --Total Number Of Digital Outputs

--* * * DO NOT MODIFY BELOW THIS LINE * * *
IO_Level={}

--* * * Load Channel Levels Into a Table * * *
for x=IO_Channel,IO_Channel+IO_Total-1 do
    --Must Convert String To Number
    IO_Level[x]=math.ceil(HC.AttributeGetValue(x,'Intensity'))
end

--* * * Change Status Of Digital Outputs* * *
if IO_Channel>IO_Output then
    IO_Difference=IO_Channel-IO_Output
    for x=IO_Channel,IO_Channel+IO_Total-1 do
        IO_Current=x-IO_Difference
        if IO_Level[x]>49 then
            HC.VariableSet(IO_Page,IO_Current,1)
        else
            HC.VariableSet(IO_Page,IO_Current,0)
        end
    end
end

if IO_Channel<IO_Output then
    IO_Difference=IO_Output-IO_Channel
    for x=IO_Channel,IO_Channel+IO_Total-1 do
        IO_Current=IO_Difference+x
        if IO_Level[x]>49 then
            HC.VariableSet(IO_Page,IO_Current,1)
        else
            HC.VariableSet(IO_Page,IO_Current,0)
        end
    end
end

if IO_Channel==IO_Output then
    for x=IO_Channel,IO_Channel+IO_Total-1 do
        IO_Current=x
        if IO_Level[x]>49 then
            HC.VariableSet(IO_Page,IO_Current,1)
        else
            HC.VariableSet(IO_Page,IO_Current,0)
        end
    end
end
Attachments
IO Demo.spf
(35.34 KiB) Downloaded 68 times
Last edited by BrianEvans on Fri Oct 03, 2008 12:09 pm, edited 2 times in total.
Brian Evans - System Specialist - Horizon Control Inc.

User avatar
gooze
Posts: 1760
Joined: Tue Dec 18, 2007 12:42 pm
Location: Amsterdam, The Netherlands
Contact:

Re: Channels To Digital Outputs

Post by gooze » Thu Oct 02, 2008 4:00 pm

What is a digital output? DMX? Shownet? Double width 10K fixtures? DL2's?
Floriaan Ganzevoort - Lighting designer
THEATERMACHINE design. production. operations.

User avatar
BrianEvans
Posts: 700
Joined: Fri Oct 12, 2007 1:11 pm
Location: Orlando, Florida

Re: Channels To Digital Outputs

Post by BrianEvans » Thu Oct 02, 2008 4:03 pm

In this example, a Digital Output is controlling an optical relay such as the Opto22 system.
Brian Evans - System Specialist - Horizon Control Inc.

User avatar
RobertBell
Posts: 2421
Joined: Fri Oct 12, 2007 1:11 pm
Primary Venue / Use: Other
Where I Am: Horizon Control Inc
Location: On the dark side just north of Toronto
Contact:

Re: Channels To Digital Outputs

Post by RobertBell » Fri Oct 03, 2008 11:20 am

The Variable Pages can be 'patched' to external devices like MIDI, Contact Closures using Vision Net interfaces or Opto 22 professional I/O.

http://www.opto22.com/

http://www.strandlighting.com/index.php ... y=Controls

See also:
http://www.horizoncontrol.com/mqhelp/mq ... iables.htm
Robert Bell - Product Manager - Horizon Control Inc.

User avatar
TaineGilliam
Posts: 1183
Joined: Tue Oct 23, 2007 5:15 pm
Location: Cleveland, OH
Contact:

Re: Channels To Digital Outputs

Post by TaineGilliam » Fri Oct 03, 2008 3:01 pm

Robert,

Can we get a summary of Variable Patch options? The list of what I think I know is:

B - VN or ILS (room number or station ID depending on station mode)
M - MIDI
P - pathport netslot
S - shownet netslot
A - artnet netslot
Look Page Name
Cue Page Name

I'm sure I'm missing something. And the ILS/VN thing is confusing.

Taine

User avatar
RobertBell
Posts: 2421
Joined: Fri Oct 12, 2007 1:11 pm
Primary Venue / Use: Other
Where I Am: Horizon Control Inc
Location: On the dark side just north of Toronto
Contact:

Re: Channels To Digital Outputs

Post by RobertBell » Fri Oct 03, 2008 3:46 pm

add to that O22-192.168.0.199 where O is a capital O (not zero) and the IP address is that of the Opto22 Ethernet Brain. This s/w is still in beta, but being used on a gig right now.

B1 is VN button station 1. No space, captical B.

You can have mutiple things patched (like three button stations) like B1,B2,B3 (no space)

or

B1,M2,O22-192.168.0.199,'Main'

Buttons station 1, Midi Channel 2, Opto 22 device and Cue List Main

Nifty.
Robert Bell - Product Manager - Horizon Control Inc.

MattKlasmeier
Posts: 491
Joined: Tue Oct 23, 2007 1:41 pm
Location: Cincinnati, OH
Contact:

Re: Channels To Digital Outputs

Post by MattKlasmeier » Fri Oct 03, 2008 4:22 pm

What Opto 22 devises are going being supported?

GaryDouglas
Posts: 689
Joined: Thu Oct 11, 2007 9:33 pm
Location: Calgary, Canada

Re: Channels To Digital Outputs

Post by GaryDouglas » Fri Oct 03, 2008 4:27 pm

Due to DMX input restructuring the P, S and A items are not available in 10.4.

You can now patch DMX in to a look and get the look's level for processing.

The rest is correct.
Gary Douglas - Lead Software Developer - Pathway Connectivity - A Division of Acuity Brands Lighting Canada.

GaryDouglas
Posts: 689
Joined: Thu Oct 11, 2007 9:33 pm
Location: Calgary, Canada

Re: Channels To Digital Outputs

Post by GaryDouglas » Fri Oct 03, 2008 4:28 pm

The Any opto 22 device that supports the OptoMMP protocol.

We only support the Digital I/O spec right now -- the analog stuff could be added if it's required for a job.
Gary Douglas - Lead Software Developer - Pathway Connectivity - A Division of Acuity Brands Lighting Canada.

User avatar
TaineGilliam
Posts: 1183
Joined: Tue Oct 23, 2007 5:15 pm
Location: Cleveland, OH
Contact:

Re: Channels To Digital Outputs

Post by TaineGilliam » Fri Oct 03, 2008 5:53 pm

I understand the B12 for ILS station id 12. There is also a bit in the manual concerning VN console buttons and sliders which seem to use similar syntax for a different result - B3 would be console buttons in Room 3?

Sorry to here about the departure of P, A, S. But I suspect the end result is more powerful yet simpler. Am I to understand that for the current (10.4.0+) versions the specified XDMX slot "master" the look or channel. Or in the case of input to output just a reroute.

Taine

Post Reply