Contatto
ModDMX
To send a well defined value to a well defined DMX chan-
nel at the pushing of a button connected to an input module
of
Contatto
bus, supposed to have assigned the address
127 to ModDMX module, the simplest way is to insert in the
program of MCP XT an equation similar to the following:
AO127:1
= P(
0x0164
)
I1.1
& P(
0x0100
)
I1.2
& \
P(
0x0200
)
I1.3
& P(
0x02FF
)
I1.4
& \
P(
0x0300
)I1.5 & P(
0x03FF
)I1.6
where
I1.1..I1.6
are the inputs connected to pushbut-
tons and
AO127:1
is the channel 1 of ModDMX module
(supposing 127 as address).
The values loaded by the Preset (P) function at the activa-
tion of an input, in the 16-bit hexadecimal format, will be in-
terpreted as follows: the high byte shows the DMX channel
on which the value specified by the low byte ha to be
loaded. Therefore, at the activation of the input
I1.1
the
value 0x0164 will be sent to the module, corresponding to
load the value 100 (decimal equivalent of 0x64) on the
DMX channel 1. In the same way, at the activation of input
I1.4
, the value 255 (0xFF) will be loaded on the DMX
channel 2 DMX, and so on. The values allowed for DMX
channels, as said before, must be in the range 0 to 255,
and the meaning depends on the type of connected DMX
device.
If a 3-channels RGB device is connected, this taking the
first 3 DMX channels, different values loaded on these
channels could allow, for instance, to reproduce 256
3
=
16.777.216 colors.
In this same example, to generate a succession of random
colors, the following simple script and equation can be
used, and this shows the potentiality of MCP XT controller
and of ModDMX module.
V1
simply generates a “clock” to
recall the script every 1 second.
script
1
trigger
=
V1
R0
= RANDOM(0)
R0
=
R0
&
0X00FF
R0
=
R0
|
0x0100
AO127:1
=
R0
R0
= RANDOM(0)
R0
=
R0
&
0X00FF
R0
=
R0
|
0x0200
AO127:1
=
R0
R0
= RANDOM(0)
R0
=
R0
&
0X00FF
R0
=
R0
|
0x0300
AO127:1
=
R0
endscript
V1
=
TIMER
(!
V1
,5,5)
Up, Down and Single Command functions
These control functions, with one-touch feature, are those
typical of the conventional dimmer modules of the
Domino
family and they will be described here in the following.
Up/Down
pushbuttons: pushing and holding Up (Down)
button, the brightness increases (decreases) until the max
(min) value is reached. When the brightness has reached
the desired level, release the button to hold it.
Single Command:
holding down the button, the brightness
increases until the max value is reached and, after 1
second about, the brightness decreases to the min value,
then it increases again and so on. Release the button at
the desired level to hold it.
When the lamp is ON, a short pulse (one-touch) on any
control button will cause the complete switching OFF.
When the lamp is OFF, a short pulse on any control push-
button will cause the switching ON at the last brightness
level.
In the following example, at the pushing of one of the 3 but-
tons, the single command code (0x83) will be sent to the
channel specified by the low byte (01, 02 or 03). When re-
leasing the button, the stop code (0x80, 0x00 can be also
used) will be sent
to the same channel
, allowing the mod-
ule to understand that the button has been released.
AO127
= P(
0x8301
)
I1.1
& P(
0x8001
)
!I1.1
& \
P(
0x8302
)
I1.2
& P(
0x8002
)
!I1.2
& \
P(
0x8303
)I1.3 & P(
0x8003
)!I1.3
To use the Up and Down functions instead of the single
command, simply use the related codes (0x81 and 0x82 re-
spectively).
Ramp or fade time
For ramp, or fade time, it is intended the time required to
change a channel value from 0 to 255. The allowed fade
times are in the range 0 to 255; it is possible to set the de-
sired fade time according to the following relationship:
Fade Time = Value x 255 x0,01 [seconds]
The fade time is always the same for all the 64 DMX chan-
nels; to set it, use the command 140.
The Fade Time is given in seconds. The following table
shows the relationship between some values that can be
written at the output a1 and the related fade time.
Set value
Fade time [sec]
0
0
1
2,55
2
5,10
3
7,65
....
....
255
650,25 (10' and 50” about)
Note 1:
it is not possible to set a different fade time for each chan-
nel; in other words, the fade time is a global parameter.
Note 2:
the regulation through Up, Down and Single Command
uses a fixed ramp time, so it cannot be modified.
DUEMMEGI
s.r.l. - Via Longhena, 4 - 20139 MILANO
Tel. 02/57300377 - Fax 02/55213686 –
www.duemmegi.it
Rel.: 2.2 December 2013
Page 3 of 7
HOME AND BUILDING AUTOMATION