DDF DMXC2

From English DMXC-Wiki
Jump to navigation Jump to search
Books.png DDF DMXC2


Hint:
25.10.2013: UPrenner: create the article page
07.11.2013 UPrenner: work-in-progress
11.11.2013: UPrenner article ready, just update of pictures
If you are a native speaker, please Help us and review this


Arrow back.png Pack And Go Function
DDFCreator Arrow forw.png
Contents

 

Overview

Picture 1: Graphical view with DDF icon
Picture 1: Graphical view with DDF icon


Picture 2: Opened DDF window with control elements
Picture 2: Opened DDF window with control elements


DDF is the abbreviation of Device Definition File. The DDF are the device description (Fixtures) in DMXControl, they serve to inform DMXControl about the functions of the attached DMX device to this. In the DDF the number becomes this one how channels of the DMX device defined and as well these use possible control elements:

  • Position input control element e.g. at Movingheads and Scanners.
  • RGB or CMY color choice control element to the color mixture at e.g. LED headlight or color mixed units at Movingheads.
  • Dropdown control elements
  • Button control elements.

Become the DDF in the « graphical view » with an icon of the device shown (see figure 1), then also can here be accessed the icon, the DDF window by a click with the control elements (see figure 2). XML format which is translated by DMXControl into the internal device description is carried out the description the DMX equipment in one. The DDF are found the DMXControl main directory in the sub-folder DEVICEs. The accompanying icon pictures, which one in the & laquo; Graphic stage view & raquo; be, lie in another sub-folder named shown images.

You get prefabricated DDFs, which weren't enclosed at the installation, can you perhaps of the DMXControl home page in the device library[1]. DDF can be made in a simple way with a XML editor (e. g. PSPad[2]) or also with the DDFCreator. There are advantages and disadvantages with the DDFCreator as also the construction of a DDF with a XML editor. With a XML editor, paraphrasing an existing DDF can be managed considerably faster than with the DDFCreator, against this one is fundamentally faster with the DDFCreator at the construction of a new DDF surface with slidern, button etc.

At both one needs a corresponding knowledge to make an operating DDF no matter whether one now the DDFCreator preferred or the XML editor. Shall the following chapters be conveyed for you, this knowledge among other things the language reference serves as a reference book

Description

A very common language syntax which e.g. is also used in the other dialects at web pages or WAP in the Internet sides is XML (eXtensible Markup Language). But you don't have to be an expert to make a new device description too manually. The following simple notes suffice:

Please take care that your editor doesn't store any (invisible) control characters. There won't be any problems at the Windows editor or PSPad. If you want to use Word or similar software, you should save the file in the raw document format (*.txt).

  • The DMXControl dialect of XML requires for every opening tag always one (<tag>) closing (</tag>) tag. Only this one gets the last level completed just by implication day (e. g. <item caption= "white" value="0" />).
  • The final signs /> and </tag> are semantically equivalent, also <item caption="white" value="0" > </item> is valid in this case.
  • Every day can have attributes which you find professed in the table below. Every attribute value is started with an equals sign and the value must always be included in double apostrophes.
  • All day and attribute identifiers are noted down at DMXControl in a small letter.
  • The day has to be defined hierarchically. They also should make this recognizable about corresponding indents.
  • As a rule, not cares about the order of the attributes of a day. Where it for once depends on the order anyway, you describe below explicitly.
  • Comment are noted down in the form <!- This is a comment —>.
  • E.g. you can have a look at xml files (therefore also the DMX DEVICEs files) in open form with the Internet Explorer.


So it was already this - we have a look at a simple example.


Example: dimmed spotlight

Every device should get an apt icon to receive an adapted representation in stage representation. This icon will be find in the subdirectory Images (Root:\Programme\DMXControl\Devices\Images).


 Important Hint The icons afterwards still can be changed in DMXControl. (In the context menu of the graphical view).


The preceding line numbers of the following XML example file cannot be inserted; they serve only the description of the example:

1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <device image="light.gif" initsequence=“set 0 128“ >
3   <channels>
4     <function channel="0" minvalue="0" maxvalue="255" name="Intensity" fade="yes" />
5   </channels>
6   <form width="177" height="85">
7     <deviceimage top="0" left="0" />
8     <devicename top="0" left="40" />
9     <deviceadress top="16" left="40" />
10    <slider channel="0" startvalue="0" endvalue="255" top="40" left="0" height="41" width="176" default="0" />
11  </form>
12 </device>


Row   1 the Parser will informed about the used XML version.
Row   2 the global description of the new type of device defines inclusive reference to the icon to be put and one ( initialization of the device the optional initsequence was demonstrated here, is but at a headlight only conditionally appropriately. The dimmer channel is (50%) ) put on DMX value 128 at the initialization here.
Row   3 the DMX channels of the device are defined between line 3 and 5.
Row   4 the channel description of the first channel is. This is always the channel numbers at zero important begin, i. e. the first channel is channel="0". In addition, other parameters as well as the channel name are still put here.
Row   6 the lines 6-9 describe the form, that is this one, to graphic coordinates in the context menu for the device picture, names and start address in the unity „Pixel“.
Row 10 here the operating devices follow a slider with his graphic coordinates and the assignment to the channel in question with her qualities, in this example now. Operating devices like radio badges also could, drop down or badges are declared for other types of device here.


Picture 3: Dimmer-DDF
Picture 3: Dimmer-DDF


Three button become Pinup button, Move button, Close button will be generatedly per default generatedly on the top right side (see figure 3).

Create a DDF

Before you make a new DDF, please have a look on our webside in the device library whether a suitable or similar already give it to definitions for your device. To make a new DDF, you modify an existing DDF of a similar device best. This goes text been based change considerably faster than with the DDF Creator just with this. If you have completed your work, you simply put the xml file in the subdirectory in the DMXControl list „DEVICEs“himself has in your DMX installation as of and store the corresponding gif picture (in the format 32 x32 pixels, the transparency fashion proves itself) in the subdirectory „images“in this „DEVICE“List-. The device should be visible at the next start of DMXControl so.


Syntax overview

Every description contains four main parts (see figure 4):

  • Description of global qualities device (in the example dimmed spotlight line 1-2)
  • Description of the individual DMX channels channels (in the example dimmed spotlight line 3-5)
  • Description of the graphic context menu form (in the example dimmed spotlight line 6-11)
  • Prozedure code (not contained, optionally in the example)


Picture 4: Basic structure of a DDF
Picture 4: Basic structure of a DDF


All form elements must on the will provide DDF form with graphic coordinates to the positioning. The elements „Label“ and „Line“ are passive and serve only the design of the surface. The remaining active elements of the form (also control element mentioned, e.g. on/off) can be used for the active control of the DMX device.


Graphical elements

The figure 5 shows a survey of all supported graphic elements. An assignment to the required syntax elements is carried out in the explanation texts.


Picture 5: Graphic elements
Picture 5: Graphic elements


The following figure 6 illustrates the meaning of the graphic coordinates of the control elements:


Picture 6: Graphic coordinates of the control elements
Picture 6: Graphic coordinates of the control elements


Functional elements

The active control elements interact in 3 possible concepts with DMXControl or the device in which exactly one concept is selected at the definition of a concrete control element:


Konzept Beschreibung Beispiel
1 Channel/Value concept The control element is assigned via the channel attribute to a concrete channel. Concrete values or ranges of values which are put at the activity of the control element are defined in the control element. - option list
  caption="Star sky" value="165"

- Value range of the slider
  startvalue="0" endvalue="255"
2 Sequences An instruction consequence which is executed when operating is defined in the control element as a string. clicksequence=
“set 1 75; set 2 100“
3 Action/Procedures A separately defined procedure contains more complex program instructions. The procedure is operate assigned via the action attribute and at everybody the control element executed. action="SetGobo"


This which Channel attribute and the action attribute can want to use alternatively in the control elements particularly means.


 Important Hint For many applications the first two concepts are sufficient.


Like the complexity and cardinality of the 3 concepts grows, the running time requirements also increase. The simplest variant on the solution of a task should therefore always be chosen. Also at the channel description an action attribute can be used. This means that the procedure is called at every change of the channel value. In figure 7 an example is shown how different control elements can interact with the channels. „So like the complexity and channel_n“address and can over the 3 mentioned above concepts be put. The current value, obliged to it for a control element are, are addressed more than one name freely eligible for office (reference) assigned to the control element here „control_n“bezeichnet. Im following example is for three control elements „Actionses“and additional „Reference names“assigned. And therefore should, as a rule these Actionses be able to do one or put several Channel values „set name“being described. Furthermore there is one „action“ assigned to the channel_3. This is intended to read and to inform about to the control elements the current channel values „assigned to the channel_3. Scheduled, this one are Get name this for this“get since she must read current channel values.


Picture 7: Interaction of control elements
Picture 7: Interaction of control elements



 Important Hint The markings of the buttons don't have a meaning here.


Syntax

This chapter describes the syntax of the device and form configuration files of DMXControl.


Generic attributs

 Important Hint Attributes often recurring are described to it globally once for the shortening with the same meaning after the following tables here.


Reference Attribute Hierachie and properties Notice Example
GP1 value Assigned DMX value byte 0, 128, 255
GP2 caption Descriptive enumeration value.
Explanatory name for an attitude.
string Dimmer,
Strobe,
usw.
GP3 top Relative x-coordinate of the
element of the left upper corner
integer top=“150“
GP4 left Relative x-coordinate of the
element of the left upper corner.
integer left=“100“
GP5 width Width of the element integer width=“80“
GP6 height Height of the element integer height=“30“


 Important Hint All coordinate details (top, left, width, height) are indicated in pixel.


Device description

Tag Attribute Hierachie and properties Notice Example
<device> Level 1
image Icon filename. string,
Filename.gif
Moon.gif
initsequence Sets initial values for the individual DMX channels of the device Optional use e.g. for scanner/moving head's start position set 0 15;
set 7 128;
<information> Level 2
Supplementary comment.
<name> Level 3
Arbitrary text.
Custom Scanner
<vendor> Level 3
Arbitrary text
(manufacturer).
optional Showtec
<deviceidentifier> Level 3
Arbitrary text
(manufacturer identifier.
optional TG-3
<author> Level 3
Arbitrary text
(originator).
optional
<comment> Level 3
Arbitrary text
(comment).
optional
<help> Level 2
Help text (ASCII).
optional

Channel description

Tag Attribute Hierachie and properties Notice Example
<channels> Level 2
For every DMX channel is one
<function>”-part to define
<function> Level 3
Subtag from “<channels>
channel Internal DMX channel number
channel no. must always of 0
climbing without interruption be
defined for the individual channels
integer
minvalue Minimal DMX value integer
maxvalue Maximal DMX value integer
name Descripting name
for the channel.
string Intensity
fade Channel fading string yes,no
type Channel typ
Important for the internal
data handling
string dimmer, r,g,b,
pan, panfine,
tilt, tiltfine,
color, gobo
action Call of a procedure at
change of the channel value
string
optional
<virtual> Level 3
Subtag from “<channels>
<channel> Level 4
Subtag from “<virtual>
channel Internal DMX channel number
The three rgb channels assigned to the virtual dimmer
integer


 Important Hint The channel type (type) also should allocate channel for everybody

become provided that this channel to the type matches. E.g. it doesn't make sense to describe every channel as a dimmer.


dimmer reserved for channels these regulate the intensity
r,g,b reserve for channels of RGB LED equipment, r for the red channel, g for the green channel, b for the blue channel. On the one hand, r, g, b are for the type it HAL needs in DMXControl. This also means, this in the graphical view the colors of the spotlights be shown.
One can one racks use this in the program configuration under « graphical view » and then at « symbol » « representation of the colors instead of graphic ».
On the other hand, the type also for the one into the 2.12 new one LED's run light generator required becomes.
a,w reserve for channels of (RGB)A as and (RGB)W LED devices, a for the amber channel, W for the white channel. The type a and w aren't supported by DMXControl yet the device, however, is appropriately since amber or white channel make a bigger and bigger contribution to the market and therefore perhaps are supported by DMXControl soon, too with additional.
pan, panfine reserve for the Pan channels of scanners, moving heads or similar equipment. How pan is and panfine assigned to the channel for the rough control the channel for the fine control at 16 bits of device.
tilt, tiltfine as in the case of pan and panfine but for the tilt axis.
color, gobo The appropriate Farb and Goborad channels can be assigned to (importantly to color & gobo lists)
c, m, y reserviert für Kanäle von CMY-Geräten, c für den Cyan Kanal, m für den magenta Kanal und y für den gelben Kanal.
Die types c, m, y werden noch nicht von DMXControl unterstützt sind aber sinnvoll.

reserved for CMY devices, c for the cyan channel, m for the magenta channel, y for the yellow channel. The type c, m, y aren't supported by DMXControl make sense, however, yet.

other all other channels don't need a type description


 Important Hint The ones for RGB devices reserved type's are important the HAL (Hardware Abstraction Layer) since version 2. 11 in which then be able to the adjusted colors of the spotlight, be represented in the graphical view too. Also for version 2.12, here they also are needed for the RGB running light generator.


Menue description

Tag Attribute Hierachie and properties Notice Example
<form> Level 2
Subtag from “<device>
width
height
See generic attribute
GP5; GP6
integer
<deviceimage> 'Level 3
Subtag from “<form>“;
Absolute position of
the shown picture
top
left
width
height
See generic attribute
GP3 bis GP6
integer
<devicename> 'Level 3
Subtag from “<form>“;
Absolute position of
the shown name
top
left
width
height
See generic attribute
GP3 bis GP6
integer
<deviceaddress> 'Level 3
Subtag von “<form>“;
Absolute position of
the shown base address
top
left
width
height
See generic attribute
GP3 bis GP6
integer

Control elements

Position control
Tag Attribute Hierachie and properties Notice Example
DMXC2 Manual DDF position field cartesian.png  DMXC2 Manual DDF position field polar.png
<position> Level 3
Subtag from “<form>“;
Creates a positioning
field for positioning from
scanners or moving heads.
By a click on the button down on the right in the DDF you can switch between a cartesian and polar positioning.
top
left
width
height
See generic attribute
GP3 bis GP6
integer


 Important Hint The position pointer can be placed by initsequenz


Slider
Tag Attribute Hierachie and properties Notice Example
DMXC2 manual DDF slider.png
<slider> Level 3
Subtag from “<form>“;
Creates a slider
top
left
width
height
See generic attribute
GP3 bis GP6
integer
channel assigned channel
alternative for action
integer
optional
startvalue Value range of the
Slider (lower value)
integer startvalue="0"
endvalue Value range of the
Slider (uper value)
integer endvalue="255"
tickfreq Scaling, distance of the
scale subdivision
integer tickfreq="32"
smallchange Change rate e.g. at the
up down keys
integer
(VB-properties)
smallchange="20"
largechange Change rate e.g. at the
mouse click (not draged)
integer
(VB-properties)
largechange="50"
name Referenz name for procedure
code (variable name)
string
optional
StrobeSpeed
action Call of a procedure at
change at the Slider
alternative channel
string
optional
SetSpeed
Dropdown
Tag Attribute Hierachie and properties Notice Example
DMXC2 manual DDF dropdown.png
<dropdown> Level 3
Subtag from“<form>“;
Creates a dropdown menu.
top
left
width
See generic attribute
GP3 bis GP5
integer
channel Assigned channel
alternative for action
integer
optional
name Referenz name for procedure
code (variable name)
string
optional
Gobo
action Call of a procedure at
change of a dropdown
entries, alternative for channel
string
optional
SetGobo
<item> Level 4
Subtag from “<dropdown>
caption Explanatory name string Clear
value DMX value for caption integer value="0"
minvalue
maxvalue
Value range for caption for
the diplayed of the dropdown entry.
integer minvalue="10"
maxvalue="26"
color Show a square with the assigned color before caption. hex color="#ff0000"
Color Red
<colorlist> Level 4
Subtag from “<dropdown>
All entries of the in color list assigned to the device insert.
optional a substitute/
addition for
Item
<gobolist> Level 4
Subtag from“<dropdown>
All entries of the in gobo list assigned to the device insert.
optional a substitute/
addition for
Item
Options
Tag Attribute Hierachie and properties Notice Example
DMXC2 manual DDF options.png
<options> Level 3
Subtag from “<form>“;
Creates a radio button field
top
left
See generic attribute
GP3 & GP4
integer
channel Assigned channel alternative foraction integer
optional
action Call of a procedure at
change of a radio buttons,
alternative for channel
optional SetGoboSpeed
name Referenz name for procedure
code (variable name)
string
optional
GoboSpeed
<option> Level 4
Subtag from “<options>
caption See generic attribute
GP2
string off
value DMX value for caption integer 0
top
left
See generic attribute
GP3 & GP4, relativ position
for positioning from “<options>
integer left="0"
top="0"
On/Off-Button
Tag Attribute Hierachie and properties Notice Example
DMXC2 Manual DDF onoff.png
<onoff> Level 3
Subtag from “<form>“;
Creates a button as switch
top
left
width
height
See generic attribute
GP3 bis GP6
integer
channel Assigned channel alternative for action integer
optional
action Call of a procedure at
pushing the buttons
alternative for channel
string
optional
SetLampOnOff
name Referenz name for procedure code (variable name) string
optional
LampOnOff
caption Explanatory name string On/Off
color Hex RGB color value of the button hex color="#00ff00"
color green
onvalue DMX value for button ON integer onvalue="150"
offvalue DMX value for button OFF integer offvalue="0"
onsequence Execute a Sequence, by switching to ON string "set 0 230;
set 1 25"
offsequence Execute a Sequence, by switching to OFF string "set 0 0;
set 1 0"
Command-Button
Tag Attribute Hierachie and properties Notice Example
DMXC2 manual DDF command.png
<command> Level 3
Subtag for “<form>“;
Creates a button as push button.
top
left
width
height
See generic attribute
GP3 bis GP6
integer
action Call of a procedure at pushing the button. string
optional
SetReset
name Referenz name for procedure code (variable name) string
optional
Reset
caption Explanatory name string Reset
color Hex RGB color value of the button string color="#0000ff"
color blue
clicksequence Activity to be started at the button click is specified in the attribute string "save 0;
set 0 230;
hold 5500;
restore 0"
downsequence Activity to be started at push down the button is specified in the attribute string "save 0;
set 0 230;
hold 5500;
restore 0"
upsequence Activity to be started at relase the button is specified in the attribute string "save 0;
set 0 230;
hold 5500;
restore 0"
Colorpicker
Tag Attribute Hierachie and properties Notice Example
DMXC2 manual DDF colorpicker.png
<colorpicker> Level 3
Subtag from “<form>“;
Creates a colorpicker.
top
left
width
height
See generic attribute
GP3 bis GP6
integer
channel1 Assignment to 1. channel
red oder cyan,
alternative for action
integer
optional
channel2 Assignment to 2. channel
green or magenta,
alternative for action
integer
optional
channel3 Assignment to 3. channel
blue oder yellow,
alternative for action
integer
optional
name Referenz name for procedure code (variable name) string
optional
ColRGB
action Call of a procedure at
changing a color,
alternative for channel1-3
string
optional
SetColRGB
mode Choice of the two modes
RGB or CMY
string mode=“cmy“
layout Choice of two
different layouts from the
Colorpickers
integer layout="1"

Beispiel:

<colorpicker mode="rgb" channel1="0" channel2="1" channel3="2" layout="2" top="40"
left="0" height="75" width="177"/>


 Important Hint Please keep the mouse button pushed down if you want to change the setting in the color bar over the drop down menu. A direct input of the numeric value is also possible.

Become the color values in procedures about name:colorchannel provided with references ({ColRGB:1}; {ColRGB:2}; {ColRGB:3})


Passive design elements

Tag Attribute Hierachie and properties Notice Example
DMXC2 Manual DDF line.png
<line> Level 3
Subtag from “<form>“;
Design element;
Creates a line.
x1; y1 Start coordinate of the line integer
x2; y2 End coordinate of the line integer
DMXC2 Manual DDF label.png
<label> Level 3
Subtag from “<form>“;
Design element;
additional description of
an operating device.
top
left
width
height
See generic attribute
GP3 bis GP6
integer
caption Text to be shown string CMY Mischung

Example:

Bild 8: DDF Giotto Spot 400


 Advanced information You find this DDF in the device libary (at the moment not online) on the DMXControl Website.


Help

In fig. 9 shows an example of a help menu, help menus are optional. It is recommended to announce the DMX occupancy of the device here. The help description is carried out in the ASCII format. Please increase the clarity by formatting with tabulator signs or underlinings. The help can one by click on the question mark button (next to the Pin badge) and be turned off.

miniatur|center|600px|Bild 9: Hilfemenü eines DDF's

Sequences

Operation Meaning Example
save >channel< Storing the current channel value of the DMX channel intermediately >channel< "save 0; set 0 230; hold 5500; restore 0"
set >channel< >value< Set the channel >channel< to value
>value<
"save 0; set 0 230; hold 5500; restore 0"
hold >time< Timer (wait >time< in ms) "save 0; set 0 230; hold 5500; restore 0"
restore >channel< Move the value of the DMX channel stored intermediately >channel< back again. "save 0; set 0 230; hold 5500; restore 0"

Procedurs (advanced programming options)

The device and form configuration of DMXControl also permits the programming of algorithmic changes of the DMX signals which are executed automatically with the operation of control elements like onoff button, dropdown menu or slider.

So you can set conditions and formulae the values which are assigned to the control elements about logical. E.g. the procedures serve to be able to treat multiple occupations of a channel (e.g. gobo rotation lies on the same channel as the gobo selection) so that the value can be calculated differently depending on rotational speed.

These procedures also permit you the programming of dependences of the channels or operating devices of a device, any colors e.g. you connect certain colors with gobos in a firm or algorithmic assignment or you organize certain speeds.

Also can at devices with two color wheels, the colors then select more than one drop down or predefined colors have drop down at RGB or CMY devices assigned to one for themselves so.


General principles

The procedures become this one as an action attribute <function> tags (channels) or the control elements e.g. <onoff>, <slider> or <dropdown> assigned. With operation of corresponding control elements the code of the procedure is interpreted and executed automatically. The action attribute is against this into assigned, a channel the <function> tag she is executed so at every change of the belonging channel value. Using the procedures „References“on the values of the control elements which are declared by the Name attribute within the form definition of the control elements e.g.


<dropdown top="16" left="207" width="113" name="color_color" action="SetColor">


This means: The procedure SetColor is executed with operation of the drop down menu and the value of the drop down menu is submitted to the called procedure SetColor as a variable color_color.

Furthermore implicit references as a default assignment to the channels exist. E.g. that way is channel_2 with the channel (function) with channel=2 binded, also the action GetColor assigned.


<function channel="2" minvalue="0" maxvalue="255" name="Color" fade="no" 
action="GetColor" colorchannel="yes"/>


Till now, variables in the real meaning as freely verifiable loft values aren't defined.

Basic syntax elements and conventions

While the references are marked by her name ("color_color"), the current value is addressed by curly brackets of the assigned control element ("{color_color}").

To simplify the interpretation of the procedure code by a Parser, some conventions you unfortunately must observe although they seem not very user friendly are agreed on in the present program release. For comparison purposes and the following tables on this one always provide a generic language variant to right sides on the easier to learn.

The following signs serve as sync separators:

Operation Meaning
! start with an command
 | separate the individual components
 $ conclude an order

The following arithmetical operations are supported:

Operation Meaning
 + addition
 - subtraction
 * multiplication
 / division
 mod modulo-Operation
(issues the remainder of the
mod division in the form of result)

Every expression must be surrounded by a bracket to be calculated. The following examples illustrate the use of arithmetical operations:

DMXControl code Generic language variant
!set_channel|2|(227+{color_speed})$ channel_2 := 227 + color_speed
!set_channel|3|((({gobos_gobo}-1)*51)+25)$ channel_3 := (gobos_gobo-1)*51+25
!set_control|gobos_speed|((({channel_3}-1) mod 51)-26)$ gobos_speed := ((channel_3 -1) mod 51)-26

The used standard operators have the following semantics:

Operation Meaning
set_control | >cntr< | >val< the control element puts >val< on the value of the expression with the given name >cntr<
set_channel | >ch< | >val< >Val< submits the value to the indicated channel >ch<

The following relational operators can be used:

Operation Alternative notation Meaning
> > - &gt; - |gt| greater
< < - &lt; - |lt| smaller
= = - &eq; - |eq| eaqual

With the help of the comparing operations conditions can be formulated since DMXControl supports the if instruction.

DMXControl code Generic language variant
!if|{channel_3} < 1| if channel_3 < 1 then


 Important Hint The procedure “INITCONTROLS”do you execute when opening the form around which Controls put toward the values which are provided by the current DMX values. Into this, so only "Get" functions should be called! However, it is recommended Initcontrols doesn't have to be defined so that the Controls always show the current condition of the device.


XML syntax of the procedure code

Tag Attribute Hierarchy and properties Meaning Example
<code> Level 2
Subtag from "<device>"
includes all procedures
<procedure> Level 3
Subtag from "<code>"
includes the code of the procedures
name Name of the procedures string SetGobo

An example prozedure

This example shows a procedure that sets the values of the control elements "color_color" and "color_speed" a moving heads in relation to the current DMX-value of channel 2 (color changer). The Mac 250 + has 4 options for the color wheel:


  • Solid color (first If in the example below),
  • Turn clockwise (2. If in the example below),
  • Turn counter clockwise (3 if in the example below), as well as
  • random colors with different speeds (4. If in the example below).


Here, the declarations in the configuration file, the relevant variables are highlighted in bold:


<function channel="2" minvalue="0" maxvalue="255" name="Color" fade="no" 
action="GetColor"/>


“color_color” is the reference to the value of the dropdown menu for selecting a color.


<dropdown top="16" left="207" width="113" name="color_color" action="SetColor">


“color_speed” is the reference to the value of the slider to the speed:


<slider top="16" left="320" height="25" width="65" startvalue="0" endvalue="18" 
tickfreq="9" smallchange="1" largechange="5" name="color_speed" action="SetColor"/>


The procedure split the DMX_Werte of the channel 2 in 4 intervals and performs different assignments. The current value is checked so and the controls are adjusted accordingly.


DMXControl code Generic language variant
<procedure name='GetColor'>
Procedure GetColor( )

!if|{channel_2} &lt; 208| 
  !set_control|color_color|
  {channel_2}$ 
  !set_control|color_speed|0$ 
| 
!if|({channel_2} &gt; 207) and  
({channel_2} &lt; 227)| 
  !set_control|color_color|-1$ 
  !set_control|color_speed|
  (226-{channel_2})$ 
$ 
!if|({channel_2} &gt; 226) and  
({channel_2} &lt; 246)| 
  !set_control|color_color|-2$ 
  !set_control|color_speed|
  ({channel_2}-227)$ 
$ 
!if|({channel_2} &gt; 245) and  
({channel_2} &lt; 256)| 
  !set_control|color_color|-3$ 
  !set_control|color_speed|
  ((255-{channel_2}) * 2)$
$ 
$
begin 
if channel_2 < 208 then
  color_color := channel_2; 

  color_speed := 0; 
(else)  
if (channel_2 > 207)  and  
(channel_2 < 227) then
  color_color := -1; 
  color_speed := 226-channel_2; 

(else)  
if (channel_2 > 226) and  
(channel_2 < 246) then
  color_color := -2; 
  color_speed :=channel_2-227 

(else) 
if (channel_2 > 245) and  
   (channel_2 < 256) then
  color_color := -3; 
  color_speed := (255-channel_2) * 2; 

;
</procedure>
end

Tip(s)

'Minvalue' and 'maxvalue' the control attributes are new in DMXControl 2.12 drop. By setting these attributes also the right double down entry is displayed if the current DMX value of value is different, but still in the range min/max value is.

Links and references

Links

 

Arrow back.png Pack And Go Function
DDFCreator Arrow forw.png
Contents