Guten Morgen meine Lieben,
obgleich das Thema schon etwas älter ist, möchte ich noch einmal meine Anpassung für die Philips Hue Lampen einbringen.
e59a98ae-83c6-4610-82d7-87992be32c57-image.png
<xml xmlns="https://developers.google.com/blockly/xml"> <variables> <variable id="!;/[u^vQs,tRIaZhN%@,">Timesteps</variable> <variable id="K$?TZ05P_nNo#(2H~G#M">Farbe_Hue</variable> <variable id="+wmE3GSnSf(]x%lgQx*c">Farbe_Sat</variable> <variable type="interval" id="Intervall">Intervall</variable> </variables> <block type="schedule" id="!ttNhYm1F*[/qNb$9Wnb" x="187" y="63"> <field name="SCHEDULE">{"time":{"exactTime":true,"start":"05:45"},"period":{"days":1}}</field> <statement name="STATEMENT"> <block type="controls_if" id="/IPuT}!9AbE_qAkM^M6|"> <value name="IF0"> <block type="logic_compare" id="eymVL5uq#V^)dABSo2+4"> <field name="OP">EQ</field> <value name="A"> <block type="get_value" id="@=#`hn,wpAcU~[b1ysM^"> <field name="ATTR">val</field> <field name="OID">alexa2.0.Echo-Devices.XXXXXX.Alarm.XXXXXX.enabled</field> </block> </value> <value name="B"> <block type="logic_boolean" id="hE5EHAD,XE7tCuKtH8sJ"> <field name="BOOL">TRUE</field> </block> </value> </block> </value> <statement name="DO0"> <block type="variables_set" id="JCWeDStbtm50i-S#/[_3"> <field name="VAR" id="!;/[u^vQs,tRIaZhN%@,">Timesteps</field> <value name="VALUE"> <block type="math_number" id="a^t4?#!ms]ioV/BNjtX2"> <field name="NUM">0</field> </block> </value> <next> <block type="variables_set" id="1gSLmMgqA0w+7n#6K}Ft"> <field name="VAR" id="K$?TZ05P_nNo#(2H~G#M">Farbe_Hue</field> <value name="VALUE"> <block type="math_number" id="9XwM$F4E^?3|pP=(Mcj$"> <field name="NUM">1</field> </block> </value> <next> <block type="variables_set" id="QUvE$NAO7*n/{{*=BG_o"> <field name="VAR" id="+wmE3GSnSf(]x%lgQx*c">Farbe_Sat</field> <value name="VALUE"> <block type="math_number" id="(+k5x{OMb0?,=?4^IPcJ"> <field name="NUM">254</field> </block> </value> <next> <block type="timeouts_setinterval" id="}m-RdKOYjC]1r^uqr#c!"> <field name="NAME">Intervall</field> <field name="INTERVAL">60</field> <field name="UNIT">sec</field> <statement name="STATEMENT"> <block type="control" id="q*nkfofX%/{[7a#|@/WP"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">hue.0.Stimmungslicht_(Schlafzimmer).bri</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="variables_get" id="dtIxq=9U}`|Nyb:00x0d"> <field name="VAR" id="!;/[u^vQs,tRIaZhN%@,">Timesteps</field> </block> </value> <next> <block type="control" id="v^Pr_E.xKe_x_S^f9NQZ"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">hue.0.Stimmungslicht_(Schlafzimmer).hue</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="variables_get" id="G4Hne9,Nm-Ii#mVW0N;~"> <field name="VAR" id="K$?TZ05P_nNo#(2H~G#M">Farbe_Hue</field> </block> </value> <next> <block type="control" id=",Ye^pG44{yc@TlOYly}h"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">hue.0.Stimmungslicht_(Schlafzimmer).sat</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="variables_get" id="Nj_L#||xgxd+u9:L^,C@"> <field name="VAR" id="+wmE3GSnSf(]x%lgQx*c">Farbe_Sat</field> </block> </value> <next> <block type="variables_set" id="@=x.T*4S.$2)@O|A|!:4"> <field name="VAR" id="!;/[u^vQs,tRIaZhN%@,">Timesteps</field> <value name="VALUE"> <block type="math_arithmetic" id="7w7mw;F~Qq1^~%;c-hmp"> <field name="OP">ADD</field> <value name="A"> <shadow type="math_number" id="e=f=Q7y[Iclt4a$}4#mE"> <field name="NUM">1</field> </shadow> <block type="variables_get" id="o4[BraKJ5QLJUo1+RbEY"> <field name="VAR" id="!;/[u^vQs,tRIaZhN%@,">Timesteps</field> </block> </value> <value name="B"> <shadow type="math_number" id="A!X34WDk*a$]3keId}i,"> <field name="NUM">13</field> </shadow> </value> </block> </value> <next> <block type="variables_set" id="!-+qw6XlEgMT9/tk}BuI"> <field name="VAR" id="K$?TZ05P_nNo#(2H~G#M">Farbe_Hue</field> <value name="VALUE"> <block type="math_arithmetic" id="CzIO[xQKUwqPO))%E+L+"> <field name="OP">ADD</field> <value name="A"> <shadow type="math_number"> <field name="NUM">1</field> </shadow> <block type="variables_get" id="LsFB?;7HrHoI~Im!.4sH"> <field name="VAR" id="K$?TZ05P_nNo#(2H~G#M">Farbe_Hue</field> </block> </value> <value name="B"> <shadow type="math_number" id="=#2R$lCY`HwaN0=2r`1I"> <field name="NUM">4</field> </shadow> </value> </block> </value> <next> <block type="variables_set" id="Ooqg7W/@{tCW|y%lFiLM"> <field name="VAR" id="+wmE3GSnSf(]x%lgQx*c">Farbe_Sat</field> <value name="VALUE"> <block type="math_arithmetic" id="JxmFIXz0ePa7tCJhejg|"> <field name="OP">MINUS</field> <value name="A"> <shadow type="math_number"> <field name="NUM">1</field> </shadow> <block type="variables_get" id="0x{[!bXY|ave}Evn4f10"> <field name="VAR" id="+wmE3GSnSf(]x%lgQx*c">Farbe_Sat</field> </block> </value> <value name="B"> <shadow type="math_number" id="Jzwmyk^u`t:#A/~om+`o"> <field name="NUM">14</field> </shadow> </value> </block> </value> <next> <block type="controls_if" id="GUx[jne8MMD+Hx0/Vsfr"> <value name="IF0"> <block type="logic_operation" id="Z3T*P|%WJWRRz@H-cYD="> <field name="OP">OR</field> <value name="A"> <block type="logic_compare" id="%U8YW5.E(OIk:w1pUzL5"> <field name="OP">EQ</field> <value name="A"> <block type="variables_get" id="*y%L,xS0I6:LK:#cqpMG"> <field name="VAR" id="!;/[u^vQs,tRIaZhN%@,">Timesteps</field> </block> </value> <value name="B"> <block type="math_number" id="3T0waKEGP].2dB.]^s0~"> <field name="NUM">195</field> </block> </value> </block> </value> <value name="B"> <block type="logic_compare" id="#`42~yA+E4iKs$jps:=%"> <field name="OP">EQ</field> <value name="A"> <block type="get_value" id="=n=AZjdUKlGr+(|l(Y1A"> <field name="ATTR">val</field> <field name="OID">alexa2.0.Echo-Devices.XXXXX.Alarm.XXXXX.enabled</field> </block> </value> <value name="B"> <block type="logic_boolean" id="1%Uy.b2Q-ROL{3Y/kygu"> <field name="BOOL">FALSE</field> </block> </value> </block> </value> </block> </value> <statement name="DO0"> <block type="timeouts_clearinterval" id="zrxJAaEjJv;m|a|)IGvD"> <field name="NAME">Intervall</field> <next> <block type="control" id="3^~r{uZhNgqaBlKkH~G{"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="true"></mutation> <field name="OID">hue-extended.0.groups.stimmungslicht__schlafzimmer_-5.action.on</field> <field name="WITH_DELAY">TRUE</field> <field name="DELAY_MS">60</field> <field name="UNIT">sec</field> <field name="CLEAR_RUNNING">FALSE</field> <value name="VALUE"> <block type="logic_boolean" id=".)4%+#]?1JYZ3g$KU*[V"> <field name="BOOL">FALSE</field> </block> </value> </block> </next> </block> </statement> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> </statement> </block> </next> </block> </next> </block> </next> </block> </statement> </block> </statement> </block> </xml>Liebe Grüße