Skip to content

Blockly

6.6k Topics 79.8k Posts

Hilfe für Skripterstellung mit Blockly

NEWS

  • Lichtsteuerung bei Ankunft

    20
    0 Votes
    20 Posts
    1k Views
    dslraserD
    @joachim-knape sagte in Lichtsteuerung bei Ankunft: @dslraser wie baue ich denn da jetzt astrozeiten ein.. kopfkratz oder so... [image: 1602791647288-bildschirmfoto-2020-10-15-um-21.53.32.png] Blockly Export <xml xmlns="https://developers.google.com/blockly/xml"> <block type="on_ext" id="wo+n7k.axGoXczYz%s|Z" x="112" y="62"> <mutation xmlns="http://www.w3.org/1999/xhtml" items="2"></mutation> <field name="CONDITION">gt</field> <field name="ACK_CONDITION"></field> <value name="OID0"> <shadow type="field_oid" id="E[#qZzqWB;9[?2AZ9!1w"> <field name="oid">default</field> </shadow> </value> <value name="OID1"> <shadow type="field_oid" id="x[=WA763_i[|sd`-0ygv"> <field name="oid">default</field> </shadow> </value> <statement name="STATEMENT"> <block type="controls_if" id="@|9?zj1#jBDY!)p%uF=w"> <value name="IF0"> <block type="time_compare_ex" id="gG|43tDqnH+tSoDQgU=Q"> <mutation xmlns="http://www.w3.org/1999/xhtml" end_time="true" actual_time="true"></mutation> <field name="USE_ACTUAL_TIME">TRUE</field> <field name="OPTION">between</field> <value name="START_TIME"> <shadow type="text" id="_!8!$R;N(l)N]3?6jM,H"> <field name="TEXT">12:00</field> </shadow> <block type="time_astro" id="JpJ;,er2-Jxz%gM5QEZ{"> <field name="TYPE">sunset</field> <field name="OFFSET">0</field> </block> </value> <value name="END_TIME"> <shadow type="text" id="3@~d:{r][Dv4cj@V#e%!"> <field name="TEXT">18:00</field> </shadow> <block type="time_astro" id="*$:M-i:%z6w?4ru??r[@"> <field name="TYPE">sunrise</field> <field name="OFFSET">0</field> </block> </value> </block> </value> <statement name="DO0"> <block type="controls_if" id="Is/ndd^-}wEDGo`eD;b#"> <value name="IF0"> <block type="logic_operation" id="iWRE};StGgIGY.UEdFlB" inline="false"> <field name="OP">OR</field> <value name="A"> <block type="logic_compare" id="~2,u[a.|I8z=}},ARRZ,"> <field name="OP">EQ</field> <value name="A"> <block type="get_value" id="Sy=X[;.hN}v5XmdM#l4z"> <field name="ATTR">val</field> <field name="OID">ID auswählen</field> </block> </value> <value name="B"> <block type="logic_boolean" id="7uM.~%=3Q=$Ds^@?2Luu"> <field name="BOOL">TRUE</field> </block> </value> </block> </value> <value name="B"> <block type="logic_compare" id="k)Q2AA#jx,@;f%U9R%d`"> <field name="OP">EQ</field> <value name="A"> <block type="get_value" id="=uK_.,g|~]uff@?mKAaF"> <field name="ATTR">val</field> <field name="OID">ID auswählen</field> </block> </value> <value name="B"> <block type="logic_boolean" id="O%6p^BLiVpi93D+r!E^Y"> <field name="BOOL">TRUE</field> </block> </value> </block> </value> </block> </value> <statement name="DO0"> <block type="control" id="#4rpLhqe!8R,ze1DZk7I"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">Object ID</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="logic_boolean" id="i%xTm9};5+jpn(1)IyY9"> <field name="BOOL">TRUE</field> </block> </value> <next> <block type="control" id="AEbfr1;^Fk(oKFL?qz,F"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="true"></mutation> <field name="OID">Object ID</field> <field name="WITH_DELAY">TRUE</field> <field name="DELAY_MS">5</field> <field name="UNIT">min</field> <field name="CLEAR_RUNNING">TRUE</field> <value name="VALUE"> <block type="logic_boolean" id="`(4aD2x}6%~o2*oS(!PZ"> <field name="BOOL">FALSE</field> </block> </value> </block> </next> </block> </statement> </block> </statement> </block> </statement> </block> </xml> EDIT: Oder so, weil Astro hat glaube ich irgendein Problem mit dem Tageswechsel (irgendwas war da, weiß ich aber leider nicht mehr genau...) [image: 1602791837841-bildschirmfoto-2020-10-15-um-21.56.04.png] Blockly Export <xml xmlns="https://developers.google.com/blockly/xml"> <block type="on_ext" id="wo+n7k.axGoXczYz%s|Z" x="112" y="62"> <mutation xmlns="http://www.w3.org/1999/xhtml" items="2"></mutation> <field name="CONDITION">gt</field> <field name="ACK_CONDITION"></field> <value name="OID0"> <shadow type="field_oid" id="E[#qZzqWB;9[?2AZ9!1w"> <field name="oid">default</field> </shadow> </value> <value name="OID1"> <shadow type="field_oid" id="x[=WA763_i[|sd`-0ygv"> <field name="oid">default</field> </shadow> </value> <statement name="STATEMENT"> <block type="controls_if" id="@|9?zj1#jBDY!)p%uF=w"> <value name="IF0"> <block type="time_compare_ex" id="gG|43tDqnH+tSoDQgU=Q"> <mutation xmlns="http://www.w3.org/1999/xhtml" end_time="true" actual_time="true"></mutation> <field name="USE_ACTUAL_TIME">TRUE</field> <field name="OPTION">not between</field> <value name="START_TIME"> <shadow type="text" id="_!8!$R;N(l)N]3?6jM,H"> <field name="TEXT">12:00</field> </shadow> <block type="time_astro" id="JpJ;,er2-Jxz%gM5QEZ{"> <field name="TYPE">sunrise</field> <field name="OFFSET">0</field> </block> </value> <value name="END_TIME"> <shadow type="text" id="3@~d:{r][Dv4cj@V#e%!"> <field name="TEXT">18:00</field> </shadow> <block type="time_astro" id="*$:M-i:%z6w?4ru??r[@"> <field name="TYPE">sunset</field> <field name="OFFSET">0</field> </block> </value> </block> </value> <statement name="DO0"> <block type="controls_if" id="Is/ndd^-}wEDGo`eD;b#"> <value name="IF0"> <block type="logic_operation" id="iWRE};StGgIGY.UEdFlB" inline="false"> <field name="OP">OR</field> <value name="A"> <block type="logic_compare" id="~2,u[a.|I8z=}},ARRZ,"> <field name="OP">EQ</field> <value name="A"> <block type="get_value" id="Sy=X[;.hN}v5XmdM#l4z"> <field name="ATTR">val</field> <field name="OID">ID auswählen</field> </block> </value> <value name="B"> <block type="logic_boolean" id="7uM.~%=3Q=$Ds^@?2Luu"> <field name="BOOL">TRUE</field> </block> </value> </block> </value> <value name="B"> <block type="logic_compare" id="k)Q2AA#jx,@;f%U9R%d`"> <field name="OP">EQ</field> <value name="A"> <block type="get_value" id="=uK_.,g|~]uff@?mKAaF"> <field name="ATTR">val</field> <field name="OID">ID auswählen</field> </block> </value> <value name="B"> <block type="logic_boolean" id="O%6p^BLiVpi93D+r!E^Y"> <field name="BOOL">TRUE</field> </block> </value> </block> </value> </block> </value> <statement name="DO0"> <block type="control" id="#4rpLhqe!8R,ze1DZk7I"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">Object ID</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="logic_boolean" id="i%xTm9};5+jpn(1)IyY9"> <field name="BOOL">TRUE</field> </block> </value> <next> <block type="control" id="AEbfr1;^Fk(oKFL?qz,F"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="true"></mutation> <field name="OID">Object ID</field> <field name="WITH_DELAY">TRUE</field> <field name="DELAY_MS">5</field> <field name="UNIT">min</field> <field name="CLEAR_RUNNING">TRUE</field> <value name="VALUE"> <block type="logic_boolean" id="`(4aD2x}6%~o2*oS(!PZ"> <field name="BOOL">FALSE</field> </block> </value> </block> </next> </block> </statement> </block> </statement> </block> </statement> </block> </xml>
  • Zeitrechnen

    blockly
    12
    1
    0 Votes
    12 Posts
    755 Views
    A
    @paul53 Hy Paul Ich habe einen Wassertank von 1000 lt. Mittels Wemos D1 ermittle ich die Distanz der Wasseroberfläche zum Sensor SR04 und ermittle so den aktuellen Füllstand. das funktioniert soweit ohne Probleme. jetzt möchte ich wieder die Anzahl Tage ermitteln zwischen voll und leer, damit ich abschätzen kann wie lange der Tank reicht. Jetzt kann ich ja die Zeitberechnung nicht mittels Trigger "Ist kleiner als letztes" starten, da mir ja der Sensor dauernd andere Werte liefert. Wie ist das umzusetzen? [image: 1602789572473-wassertank-anz-tage.jpg] Danke dir......
  • Hilfe zu Fussbodenheizung

    2
    1
    0 Votes
    2 Posts
    142 Views
    Z
    @zyrrill thx problem gelöst funkt schon
  • Blockly Scripte fehlerhafte Daten, Lösung?

    3
    2
    0 Votes
    3 Posts
    160 Views
    B
    @Homoran hi, danke daß ist mir jetzt auch gerade aufgefallen und ich glaube ich habe bereits selber die Lösung gefunden, hoffe ich zumindest. [image: 1602774455124-netzbezug-blockly-script-neu.jpg] Ich beobachte es mal, aber es schaut um einiges besser aus, als die Vorgängerversionen Gruß
  • [Gelöst] Publish raw command

    2
    0 Votes
    2 Posts
    348 Views
    V
    [image: 1602757864367-3da1d49b-bbd0-459b-90cf-a46cf01d0f32-grafik.png] Anstatt devId schreibt man einfach id.
  • Rollosteuerung mit shelly 2.5, neuen Datenpunkt integrieren

    blockly
    1
    1
    0 Votes
    1 Posts
    276 Views
    No one has replied
  • Eine Lampe mit 2 Scripten ansprechen

    3
    2
    0 Votes
    3 Posts
    341 Views
    Phil IppP
    @MCU danke für deine Antwort! Im ersten Script ist es nur Yeelight. Wenn DeckenYeelight an/aus, schalte Yeelight Birne an/aus. Wenn DeckenYeelight gedimmt wird, dimme Yeelight Birne. Im zweiten Script ist es deconz und yeelight. Wenn deconz Birne an. Schalte yeelight Birne an. Wenn deconz Birne an. Schalte deconzbirne2 an. Was meinst Du mit Bildern von den Datenpunkten? Screenshot von den ioBroker Objekten?
  • Blockly Zeitsteuerung funktioniert nicht/nur bedingt

    7
    6
    0 Votes
    7 Posts
    2k Views
    paul53P
    @csuser sagte: Wie kann ich denn die Uhrzeit aktualisieren/ Die Systemzeitzone richtig einstellen.
  • Anfänger braucht Hilfe bei der Zeitsteuerung

    17
    1
    0 Votes
    17 Posts
    307 Views
    Meister MopperM
    @Marfei Soll es denn nicht automatisch ausgeschaltet werden?
  • Telegram sendet mehrfach

    119
    1
    0 Votes
    119 Posts
    5k Views
    Meister MopperM
    @Semmy Der 3er muss meines Wissens von der SD-Karte gebootet werden. Der Rest läuft über die SSD. Es gibt viele Anleitungen im www.
  • (gelöst) Anfänger braucht mal bitte Hilfe bei einem Blockly

    6
    2
    0 Votes
    6 Posts
    543 Views
    J
    @Octopus180 Bis auf den Fehler ist das aber schon recht gut für den Anfang ;-)
  • Intervall ON/OFF Frostschutz

    3
    1
    0 Votes
    3 Posts
    474 Views
    S
    Danke für deinen Tipp Ich musste zwar noch ein paar Dinge anpassen. Aber soweit scheint es zu funktionieren... [image: 1602618015716-screenshot-2020-10-12-220744.jpg]
  • 0 Votes
    3 Posts
    543 Views
    S
    @paul53 Manchmal ist die Lösung so nah, es funktioniert Danke, da wäre ich jetzt nicht drüber gestolpert
  • Musik auf Abfrage

    17
    0 Votes
    17 Posts
    487 Views
    L
    Vielen Dank für die vielen Ansätze. Werde das Projekt demnächst mal in Angriff nehmen.
  • Twitch API mit Blockly

    6
    0 Votes
    6 Posts
    835 Views
    J
    Geht vermutlich deutlich eleganter, aber es funktioniert. [image: 1602491951346-353c432f-a467-47f9-a36e-c9cae23200fc-image.png]
  • Bewegungsmelder Licht an bei Bewegung, danach wieder..

    blockly scenes
    8
    1
    0 Votes
    8 Posts
    1k Views
    paul53P
    @snookerap sagte: hast du hier eventuell auch ein Beispiel Wie man die Variable erstellt ? [image: 1602484839961-blockly_temp.jpg]
  • Variablenwert nach n Tagen ändern

    3
    0 Votes
    3 Posts
    188 Views
    mcBirneM
    @paul53 Danke!
  • Problem mit setzten des State mit einer Zahl

    9
    3
    0 Votes
    9 Posts
    290 Views
    Q
    @Homoran Der Datenpunkt ist: [image: 1602431782202-unbenannt.png]
  • Bei Bewegung und Licht schalten

    3
    0 Votes
    3 Posts
    220 Views
    paul53P
    @Sarah sagte: Versucht hab ich mit folgendem: Der BWM muss triggern. Export <xml xmlns="https://developers.google.com/blockly/xml"> <variables> <variable type="timeout" id="timeout">timeout</variable> </variables> <block type="comment" id="OSO=R5pTa5dd57(pCHBQ" x="-238" y="-387"> <field name="COMMENT">BWM</field> <next> <block type="on_ext" id="J^V:?i(?I[76Y)f51U|I"> <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation> <field name="CONDITION">ne</field> <field name="ACK_CONDITION"></field> <value name="OID0"> <shadow type="field_oid" id="]$w0#p=ciU2rOBf2G]?a"> <field name="oid">default</field> </shadow> </value> <statement name="STATEMENT"> <block type="controls_if" id="%d|($)|c;/b1CQs_?eXp"> <mutation else="1"></mutation> <value name="IF0"> <block type="on_source" id="?-T@4I@+ZNcSeEc5$$x:"> <field name="ATTR">state.val</field> </block> </value> <statement name="DO0"> <block type="timeouts_cleartimeout" id="G1m!h!r*477zG[FxYi4W"> <field name="NAME">timeout</field> <next> <block type="controls_if" id="1?0XbxLFe^.|ZA@WMWP7"> <value name="IF0"> <block type="logic_compare" id="^_!,8bEk@r]*RH~#w`qr"> <field name="OP">LT</field> <value name="A"> <block type="get_value" id="6,b;Ld,lC2ZZ~)WoP/2."> <field name="ATTR">val</field> <field name="OID">deconz.0.Sensors.27.lux</field> </block> </value> <value name="B"> <block type="math_number" id="[KidI)n#+QBW_brL5p*f"> <field name="NUM">200</field> </block> </value> </block> </value> <statement name="DO0"> <block type="control" id="*#Uh!TMj4SYlJw:^6|//"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">deconz.0.Lights.11.on</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="logic_boolean" id="a]k.d=zbPyw49|1T@bN9"> <field name="BOOL">TRUE</field> </block> </value> </block> </statement> </block> </next> </block> </statement> <statement name="ELSE"> <block type="timeouts_settimeout" id="i_.N-{0pYsV./^Gbd)9#"> <field name="NAME">timeout</field> <field name="DELAY">5</field> <field name="UNIT">min</field> <statement name="STATEMENT"> <block type="control" id="`?FeP*D:dM,8m}XBd|7U"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">deconz.0.Lights.11.on</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="logic_boolean" id="qZ$IXjQ2NFg-xH!Dv[O+"> <field name="BOOL">FALSE</field> </block> </value> </block> </statement> </block> </statement> </block> </statement> </block> </next> </block> </xml>
  • [gelöst] Mit Blockly Trigger aus Liste erstellen?

    3
    1
    0 Votes
    3 Posts
    964 Views
    akwakA
    @Asgothian Super, Danke. Das hilft mir weiter. Bei Trigger habe ich natürlich nicht gesucht da ich ja einen Wert auslesen wollte :-(. Das das aktuell auslösende Objekt natürlich mit Triggern zu tun hat ist allerdings, nach etwas nachdenken, naheliegend. Alfred

402

Online

32.8k

Users

82.7k

Topics

1.3m

Posts