<?xml version="1.0"?>
<device image="Colorflood.gif" initsequence="set 0 0; set 1 0; set 2 0; set 3 0; set 4 0; set 5 0">
	<information>
		<vendor>American DJ </vendor>
		<name>Mega Tripar Profile 6CH</name>
		<author>Detlev Weniger</author>
		<comment>6-Kanal-Modus</comment>
	</information>
	<channels>
		<function channel="0" minvalue="0" maxvalue="255" name="rot" fade="yes" type="r" action="GetColor_1" />
		<function channel="1" minvalue="0" maxvalue="255" name="grün" fade="yes" type="g" action="GetColor_1" />
		<function channel="2" minvalue="0" maxvalue="255" name="blau" fade="yes" type="b" action="GetColor_1" />
		<function channel="3" minvalue="0" maxvalue="255" name="ColorMode" fade="yes" type="dimmer" />
		<function channel="4" minvalue="0" maxvalue="255" name="Strobe" fade="no" type="dimmer" />
		<function channel="5" minvalue="0" maxvalue="255" name="Master" fade="yes" type="dimmer" />
	</channels>
	<form width="272" height="271">
		<deviceimage top="4" left="4" width="40" height="40" />
		<devicename top="10" left="60" width="200" height="20" />
		<deviceadress top="30" left="60" width="200" height="20" />
		<label top="56" left="4" caption="Farbe" />
		<line y1="60" x1="50" y2="60" x2="260" />
		<colorpicker channel1="0" channel2="1" channel3="2" mode="rgb" layout="2" top="76" left="4" width="150" height="100" />
		<label top="180" left="4" caption="Masterdimmer" />
		<slider top="204" left="4" height="25" width="116" startvalue="0" endvalue="255" tickfreq="30" smallchange="1" largechange="10" name="master" channel="5" />
		<command top="204" left="128" width="40" caption="0%" clicksequence="set 5 0;" />
		<command top="204" left="176" width="40" caption="50%" clicksequence="set 5 128;" />
		<command top="204" left="224" width="40" caption="100%" clicksequence="set 5 255;" />
		<label top="228" left="0" caption="Strobe-Dimmer" />
		<slider top="248" left="4" height="25" width="116" startvalue="0" endvalue="255" tickfreq="30" smallchange="1" largechange="10" name="Strobe" channel="4" />
		<command top="244" left="128" width="40" caption="Stop" clicksequence="set 4 0;" />
		<command top="244" left="176" width="40" caption="slow" clicksequence="set 4 120;" />
		<command top="244" left="224" width="40" caption="fast" clicksequence="set 4 255;" />
		<line y1="188" x1="80" y2="188" x2="262" />
		<!--      Modul als Dropdown     -->
		<!--                              -->
		<dropdown top="76" left="156" width="112" name="Color_1" action="SetColor_1">
			<item caption="schwarz" value="0" color="#000000" />
			<item caption="rot" value="20" color="#ff0000" />
			<item caption="grün" value="40" color="#00ff00" />
			<item caption="blau" value="60" color="#0000ff" />
			<item caption="orange" value="80" color="#ff8000" />
			<item caption="gelb" value="100" color="#ffff00" />
			<item caption="magenta" value="120" color="#ff0080" />
			<item caption="weiss" value="255" color="#ffffff" />
		</dropdown>
	</form>
	<!--      START der PROCEDUREN                             -->
	<!--      Proceduren IMMER HINTER dem FORM Bereich         -->
	<!--                                                       -->
	<!--  Das Dropdown hat den Namen Color_1 und startet die   -->
	<!--  Aktion SetColor_1 in Abhängigkeit vom Wert des       -->
	<!--  dropdowns wird ueber die IF Abfrage ausgewaehlt      -->
	<!--  wie die jeweiligen RGBs gesetzt werden muessen       -->
	<!--                              -->
	<code>
		<procedure name="INITCONTROLS">
		!call|GetColor_1$
</procedure>
		<procedure name="SetColor_1">
      !if|({Color_1}=0)| 
      !set_channel|0|0$
      !set_channel|1|0$
      !set_channel|2|0$
      !set_channel|3|0$
	  $
      !if|({Color_1}=20)| 
      !set_channel|0|255$
      !set_channel|1|0$
      !set_channel|2|0$
      !set_channel|3|0$
	  $
      !if|({Color_1}=40)| 
      !set_channel|0|0$
      !set_channel|1|255$
      !set_channel|2|0$
      !set_channel|3|0$
	  $
	  !if|({Color_1}=60)| 
      !set_channel|0|0$
      !set_channel|1|0$
      !set_channel|2|255$
      !set_channel|3|0$
      $
      !if|({Color_1}=80)| 
      !set_channel|0|255$
      !set_channel|1|90$
      !set_channel|2|0$
      !set_channel|3|0$
	  $
      !if|({Color_1}=100)| 
      !set_channel|0|255$
      !set_channel|1|170$
      !set_channel|2|0$
      !set_channel|3|0$
	  $
      !if|({Color_1}=120)| 
      !set_channel|0|245$
      !set_channel|1|0$
      !set_channel|2|170$
      !set_channel|3|0$
	  $
      !if|({Color_1}=255)|
      !set_channel|0|255$
      !set_channel|1|255$
      !set_channel|2|255$
      !set_channel|3|0$
	  $
  </procedure>
		<procedure name="GetColor_1">
      !if|(({channel_0}=0) and ({channel_1}=0) and ({channel_2}=0))|
      !set_control|Color_1|0$
      $
      !if|(({channel_0}=255) and ({channel_1}=0) and ({channel_2}=0))|
      !set_control|Color_1|20$
      $
      !if|(({channel_0}=0) and ({channel_1}=255) and ({channel_2}=0))|
      !set_control|Color_1|40$
      $
      !if|(({channel_0}=0) and ({channel_1}=0) and ({channel_2}=255))|
      !set_control|Color_1|60$
      $
      !if|(({channel_0}=255) and ({channel_1}=90) and ({channel_2}=0))|
      !set_control|Color_1|80$
      $
      !if|(({channel_0}=255) and ({channel_1}=170) and ({channel_2}=0))|
      !set_control|Color_1|100$
      $
      !if|(({channel_0}=245) and ({channel_1}=0) and ({channel_2}=170))|
      !set_control|Color_1|120$
      $
      !if|(({channel_0}=255) and ({channel_1}=255) and ({channel_2}=255))|
      !set_control|Color_1|255$
      $
</procedure>
	</code>
</device>