Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. SmartPhone Benachrichtigung erkennen

    NEWS

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker@Smart Living Forum Solingen, 14.06. - Agenda added

    • ioBroker goes Matter ... Matter Adapter in Stable

    SmartPhone Benachrichtigung erkennen

    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      CruziX last edited by CruziX

      Hallo Zusammen.
      Inspiriert von einigen Kommentaren wollte ich für mich folgendes umsetzen:
      Wenn mein SmartPhone eine WhatsApp Nachricht, oder einen Telefonanruf bekommt und auf lautlos ist, soll sich meine Alexa melden.
      Das kann aber so wie ich es gemacht habe, für jede App Benachrichtigung gemacht werden.
      Das habe ich alles ohne wirkliche Vorkenntnisse von HTTP oder so gemacht.
      Die Tasker App habe ich auch schon länger nicht mehr verwendet.
      Ich will hiermit nur mal einen Ansatz zeigen, der sicherlich noch verbessert werden kann 🙂

      Was ich verwendet habe:

      • Android
      • Android App Tasker (Kostenpflichtig)
      • Iobroker Adapter Simple-Api
      • Android App AutoNotification (Kostenpflichtig)
        Alternative hierzu ist die Benachrichtigung mit Tasker abzufangen. Ist aber für jede App seperat notwendig und mehr Tasker Programmierung

      Umsetzung Tasker

      ** Tasker Variablen**
      Zu erst habe ich 2 Variablen angelegt (siehe Screenshot).

      • %IobrokerSimpleDatenpunkt = javascript.0.SmartPhone_Nachricht (Pfad vom Datenpunkt in iobroker)
      • %IobrokerSimpleIP = IP vom iobroker

      Tasker Tasks
      1 Task - Send Request:

      Send Request (15)
          A1: Variable Setzen [ Name:%anapp Zu:%par1 Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] If [ %par1 ist gesetzt ]
          A2: Variable Setzen [ Name:%antitlebig Zu:%par2 Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] If [ %par2 ist gesetzt ]
          <wenn WhatsApp dann text leeren>
          A3: Variable Setzen [ Name:%antextbig Zu:leer Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] If [ %anapp gl WhatsApp ]
          A4: [X] Benachrichtigung [ Titel:Test Text:%IobrokerSimpleIP/set/%IobrokerSimpleDatenpunkt?value=Appname:%anapp;Titel:%antitlebig;Text:%antextbig Icon:null Nummer:0 Dauerhaft:Aus Priorität:3 Repeat Alert:Aus LED Colour:Rot LED Rate:0 Sound Datei: Vibration Pattern: Category: ] 
          <Sendet einen Get Request mit dem Appnamen und Inhalt an iobroker>
          A5: HTTP Request [  Method:GET URL:%IobrokerSimpleIP/set/%IobrokerSimpleDatenpunkt?value=Appname:%anapp;Titel:%antitlebig;Text:%antextbig Headers: Query Parameters: Body: File To Send: File To Save With Output: Timeout (Sekunden):30 Trust Any Certificate:An ] 
          A6: Warte [ MS:0 Sekunden:8 Minuten:0 Std.:0 Tage:0 ]
      

      2019-10-27 13_24_29-Window.png

      Hier werden die Variablen die von AutoNotification erstellt werden überschrieben, wenn der Task von außen mit Parametern aufgerufen wird (das passiert im 2 Task mit Telefon).

      Im Fall, dass die Nachricht von WhatsApp kommt, überschreibe ich noch die Variable %antextbig mit dem Nachrichteninhalt, da ich den in iobroker nicht brauche und das nicht im Klartext übers Netzwerk gehen soll.

      Dann habe ich eine Benachrichtigung drin, die ist aber nur zu Testzwecken von mir.

      Als nächstes der HTTP Request zu Iobroker und eine Wartezeit von 8 Sekunden, damit nicht bei jeder Nachricht ein Request gesendet wird.

      Der HTTP Request:
      2019-10-27 13_35_02-Window.png

      Zum Abschluss dann noch im Task oben auf das Zahnrad und auf "Neuen Task abbrechen" einstellen.
      Das verhindert die Parallelausführung der Tasks.

      2019-10-27 13_36_33-Window.png


      2 Task - Send Request Telefon - Das ist nur für das Abfangen von Anrufen notwendig:

      Send Request Telefon (18)
          A1: Variable Setzen [ Name:%antitlebig Zu:%CNAME Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] 
          A2: Task Ausführen [ Name:Send Request Priorität:%priority+1 Parameter 1 (%par1):%anapp Parameter 2 (%par2):%antitlebig Rücksetzungswert Variable: Stop:Aus ]
      

      2019-10-27 13_25_22-Window.png

      Ich überschreibe hier die Variable %antitlebig von AutoNotification mit der Tasker Variable %CNAME.
      Im Fall meines MI 9 wurde mit %antitlebig nicht immer der richtige Anrufername sondern manchmal die Telefonnummer angezeigt. %CNAME von Tasker funktioniert da ohne Probleme.

      Dann rufe ich einfach den 1 Task mit den richtigen Parametern auf:

      2019-10-27 13_31_56-Window.png

      Zum Abschluss dann noch im Task oben auf das Zahnrad und auf "Neuen Task abbrechen" einstellen.
      Das verhindert die Parallelausführung der Tasks.

      2019-10-27 13_37_42-Window.png

      Tasker Profile
      Bei beiden Profilen das Event AutoNotification Intercept auswählen.

      Profil App Benachrichtigung:


      photo5888670965255221562.jpg

      photo5888670965255221561.jpg

      Profil: App Benachrichtigung (14)
          Restore: no
          Ereignis: AutoNotification Intercept [ Konfiguration:Event Behaviour: true
         Notification Type: Only Created Notifications
         Persistency Type: Both
         Notification Apps: WhatsApp,Pushbullet
         Get All Fields : true ]
          Status: Displaystatus [ Ist:Aus ]
         Eingang: Send Request (15)
          A1: Variable Setzen [ Name:%anapp Zu:%par1 Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] If [ %par1 ist gesetzt ]
          A2: Variable Setzen [ Name:%antitlebig Zu:%par2 Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] If [ %par2 ist gesetzt ]
          <wenn WhatsApp dann text leeren>
          A3: Variable Setzen [ Name:%antextbig Zu:leer Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] If [ %anapp gl WhatsApp ]
          A4: [X] Benachrichtigung [ Titel:Test Text:%IobrokerSimpleIP/set/%IobrokerSimpleDatenpunkt?value=Appname:%anapp;Titel:%antitlebig;Text:%antextbig Icon:null Nummer:0 Dauerhaft:Aus Priorität:3 Repeat Alert:Aus LED Colour:Rot LED Rate:0 Sound Datei: Vibration Pattern: Category: ] 
          <Sendet einen Get Request mit dem Appnamen und Inhalt an iobroker>
          A5: HTTP Request [  Method:GET URL:%IobrokerSimpleIP/set/%IobrokerSimpleDatenpunkt?value=Appname:%anapp;Titel:%antitlebig;Text:%antextbig Headers: Query Parameters: Body: File To Send: File To Save With Output: Timeout (Sekunden):30 Trust Any Certificate:An ] 
          A6: Warte [ MS:0 Sekunden:8 Minuten:0 Std.:0 Tage:0 ]
      

      Profil Telefonanruf:


      photo5888670965255221565.jpg

      photo5888670965255221566.jpg

      Profil: Anruf (17)
          Restore: no
          Ereignis: AutoNotification Intercept [ Konfiguration:Event Behaviour: true
         Notification Type: Only Created Notifications
         Persistency Type: Both
         Notification Apps: Telefon
         Get All Fields : true ]
          Status: Anruf [ Typ:Eingehend Nummer:* ]
          Status: Displaystatus [ Ist:Aus ]
         Eingang: Send Request Telefon (18)
          A1: Variable Setzen [ Name:%antitlebig Zu:%CNAME Recurse Variables:Aus Mathematisch:Aus Hinzufügen:Aus Max Rounding Digits:3 ] 
          A2: Task Ausführen [ Name:Send Request Priorität:%priority+1 Parameter 1 (%par1):%anapp Parameter 2 (%par2):%antitlebig Rücksetzungswert Variable: Stop:Aus ]
      

      Iobroker

      Meine Einstellung im Simple-Api Adapter (Port variiert natürlich, bei mir war der Standard bereits belegt).


      7a314227-6c01-4ca8-a75f-cc3e6c625252-image.png

      Hier wird nur ein Skript benötigt, welches ich in Blockly gemacht habe.


      2019-10-27 13_40_01-Window.png

      Code von "SplitAndParseMessage"

       var lParameter = i.split(";");
      if(lParameter.length > 0)
      {
          // Appname
          var lAppName = lParameter[0].split(":");
          if (lAppName.length = 2)
              AppName = lAppName[1];
          
          // AppTitel
          var lAppTitel = lParameter[1].split(":");
          if (lAppTitel.length = 2)
              AppTitel = lAppTitel[1];
              
          // Text
          var lAppText = lParameter[2].split(":");
          if (lAppText.length = 2)
              AppInhalt = lAppTitel[1];
      }
      

      2019-10-27 13_40_26-Window.png

      2019-10-27 13_40_48-Window.png

      Exportierter Blockly


      <xml xmlns="http://www.w3.org/1999/xhtml">
      <variables>
      <variable type="" id="rv[D5#M#xl-fl_IAJ/yX">AppName</variable>
      <variable type="" id="wMPT6J+/@b!eVfPpvy/6">i</variable>
      <variable type="" id="Ny_}+(lYYEia^3cxv$q2">AppTitel</variable>
      <variable type="" id="qD:FXL84rN8tO2~:WTd">AppInhalt</variable>
      <variable type="" id="PR/pQwdg6c+A.GJ/,BQ">listeAppNames</variable> <variable type="" id="~pQOs?dGT6XyDYTXUr0Y">bWichtig</variable> <variable type="" id="0*20}aVTZlug2TWsjH/8">sAusgabeText</variable> <variable type="undefined" id="AppBenachrichtigungFreigeben">AppBenachrichtigungFreigeben</variable> <variable type="undefined" id="AppBenachrichtigungFreigeben2">AppBenachrichtigungFreigeben2</variable> </variables> <block type="variables_set" id="gbAWZ!jR%G}o}RB2CK=M" x="38" y="-513"> <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field> <value name="VALUE"> <block type="text" id="uk,0gFkA;8#FP]WxFp./"> <field name="TEXT">""</field> </block> </value> <next> <block type="variables_set" id="*ZyChTG]{wcPU]_FepGS"> <field name="VAR" id="Ny_}+(lYYEia^3cxv$q2" variabletype="">AppTitel</field> <value name="VALUE"> <block type="text" id="Mv(Vd$G/(*ugP(9Wph.T"> <field name="TEXT">""</field> </block> </value> <next> <block type="variables_set" id="B5IkQ}Yo@*|h0D?,yI@."> <field name="VAR" id="qD:_FXL84rN8tO2~:WTd" variabletype="">AppInhalt</field> <value name="VALUE"> <block type="text" id="lb,?adkP1F:]in^wQJsV"> <field name="TEXT">""</field> </block> </value> <next> <block type="variables_set" id="0FjF/Se!AZvR?uzyrSK8"> <field name="VAR" id="PR/pQwdg6c+A.GJ/,BQ" variabletype="">listeAppNames</field>
      <value name="VALUE">
      <block type="lists_create_with" id="-(!t;D@,GVX4DsKV({1U">
      <mutation items="0"></mutation>
      </block>
      </value>
      <next>
      <block type="variables_set" id="@qQ]sWO
      |7(#X9?mG^:]">
      <field name="VAR" id="~pQOs?dGT6XyDYTXUr0Y" variabletype="">bWichtig</field>
      <value name="VALUE">
      <block type="logic_boolean" id="t5jb?LD{-Qo)FE*]Fp]3">
      <field name="BOOL">FALSE</field>
      </block>
      </value>
      <next>
      <block type="on" id="zVhzoqM}]/DMZ8F?V##">
      <field name="OID">javascript.0.SmartPhone_Nachricht</field>
      <field name="CONDITION">any</field>
      <field name="ACK_CONDITION"></field>
      <statement name="STATEMENT">
      <block type="debug" id="GPvafzPb%[KN#!:Tn_d"> <field name="Severity">log</field> <value name="TEXT"> <shadow type="text" id="jdC,A5Wd}}|zaH.Kmc,A"> <field name="TEXT">Start</field> </shadow> </value> <next> <block type="controls_if" id="wv=xf~Yv3+([IJAy-cVf"> <value name="IF0"> <block type="logic_negate" id="on)x9@($Xw4RPX{.MS(">
      <value name="BOOL">
      <block type="get_value_var" id="Gv=OQ?(aM,DI@Xk)GPL"> <field name="ATTR">val</field> <value name="OID"> <shadow type="text" id="k9fXKwBG}a:}9(b)TS,J"> <field name="TEXT">linkeddevices.0.Alexa Yannick.Nicht stören</field> </shadow> </value> </block> </value> </block> </value> <statement name="DO0"> <block type="procedures_callcustomnoreturn" id="~eO*O=Hekb.pK9IY=~"> <mutation name="SplitAndParseMessage"> <arg name="i"></arg> </mutation> <value name="ARG0"> <block type="get_value_var" id="}G7p.CRQWK|lKVgU!I4t"> <field name="ATTR">val</field> <value name="OID"> <shadow type="text" id="iB:N8$az;x0{=Mts;^b">
      <field name="TEXT">javascript.0.SmartPhone_Nachricht</field>
      </shadow>
      </value>
      </block>
      </value>
      <next>
      <block type="debug" id="^}UeLwIsGP_l,YUWaL=~">
      <field name="Severity">log</field>
      <value name="TEXT">
      <shadow type="text" id="K%aSlGV!(p1c(LiBEW}">
      <field name="TEXT">test</field>
      </shadow>
      <block type="variables_get" id="4G1-@g=WSct%FX;ykXU2">
      <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field>
      </block>
      </value>
      <next>
      <block type="debug" id="nvFKv=sMMHq5#$t#)">
      <field name="Severity">log</field>
      <value name="TEXT">
      <shadow type="text" id="K%aSlGV!(p1c(LiBEW}">
      <field name="TEXT">test</field>
      </shadow>
      <block type="variables_get" id="X@#jHW1^2r,Y~1x.Xfm">
      <field name="VAR" id="Ny
      }+(lYYEia^3cxv$q2" variabletype="">AppTitel</field>
      </block>
      </value>
      <next>
      <block type="debug" id="#X5kefy$Xh=o$?A1SwUZ">
      <field name="Severity">log</field>
      <value name="TEXT">
      <shadow type="text" id="PCJ72RMN,%%I!obo0-RG">
      <field name="TEXT">test</field>
      </shadow>
      <block type="variables_get" id="{5]#q/q#Qs.?Kj~!E/L"> <field name="VAR" id="qD:_FXL84rN8tO2~:WTd" variabletype="">AppInhalt</field> </block> </value> <next> <block type="controls_if" id="uX0+S6[E,#SF-4Pq(b+">
      <mutation else="1"></mutation>
      <value name="IF0">
      <block type="logic_compare" id="VqP,;Pk_yq4NR7:?%Us
      ">
      <field name="OP">EQ</field>
      <value name="A">
      <block type="text_changeCase" id="fCVtOivZOHEisT9%#)@]">
      <field name="CASE">LOWERCASE</field>
      <value name="TEXT">
      <shadow type="text" id="fT;pGYi/PgatNBdk
      g$C">
      <field name="TEXT">abc</field>
      </shadow>
      <block type="variables_get" id="F;yuLZ=sof:77TP;eoHI">
      <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field>
      </block>
      </value>
      </block>
      </value>
      <value name="B">
      <block type="text" id="TC4zh-bc3P$c.,${2/D"> <field name="TEXT">telefon</field> </block> </value> </block> </value> <statement name="DO0"> <block type="comment" id="YU(b]lV%X3D]=?e9)+KR"> <field name="COMMENT">Wenn ein eingehender Anruf erkannt wird</field> <next> <block type="variables_set" id="g~lPry4nmXNE4z.YW/[s"> <field name="VAR" id="~pQOs?dGT6XyDYTXUr0Y" variabletype="">bWichtig</field> <value name="VALUE"> <block type="logic_boolean" id="C)*@]E)ao:Y|WOZREL69"> <field name="BOOL">TRUE</field> </block> </value> </block> </next> </block> </statement> <statement name="ELSE"> <block type="comment" id="GXxZ{Shd{z3V6BC|L[Cc"> <field name="COMMENT">Für alle anderen aktivieren Benachrichtigungen</field> <next> <block type="variables_set" id="``,hv=s29DaKeR]#Z6!d"> <field name="VAR" id="~pQOs?dGT6XyDYTXUr0Y" variabletype="">bWichtig</field> <value name="VALUE"> <block type="logic_boolean" id="JsmyOm8lKo6[5Z^_U](,"> <field name="BOOL">FALSE</field> </block> </value> </block> </next> </block> </statement> <next> <block type="comment" id="r+3Z%[R|@s@d;SOa.#K9"> <field name="COMMENT">Bedingungen wann und was passieren soll</field> <next> <block type="debug" id="B?[:f{sL6YjpH0Em(~Zo"> <field name="Severity">log</field> <value name="TEXT"> <shadow type="text" id="CEe}*wb;(SS9OyN5}3A">
      <field name="TEXT">Nicht stören ist aus</field>
      </shadow>
      </value>
      <next>
      <block type="comment" id="6$}I~K)HuhM[/sY$?YJe">
      <field name="COMMENT">Nur wenn es noch nicht in der letzten Minute ausgegeben wurde</field>
      <next>
      <block type="controls_if" id="ud-BZyz/E-lt5{6_iW$P">
      <value name="IF0">
      <block type="logic_operation" id="_C@i.?(4b4)sql-9%+(F">
      <field name="OP">OR</field>
      <value name="A">
      <block type="lists_isEmpty" id="!jXxxqd
      vtkB+07/%RaO">
      <value name="VALUE">
      <block type="variables_get" id="Nz@MW{4Am(4;w./@-7/S">
      <field name="VAR" id="PR/pQwdg6c+A.GJ/,BQ" variabletype="">listeAppNames</field> </block> </value> </block> </value> <value name="B"> <block type="logic_compare" id="sp?2Z;zX.LOcTSMj;*,2"> <field name="OP">LT</field> <value name="A"> <block type="lists_indexOf" id="aJ04]q[a$k}BoB6z6^iG"> <field name="END">FIRST</field> <value name="VALUE"> <block type="variables_get" id="FRPxEBZQnfF-(wE7B#Qr"> <field name="VAR" id="PR/pQwdg6c+A.GJ/,BQ" variabletype="">listeAppNames</field>
      </block>
      </value>
      <value name="FIND">
      <block type="variables_get" id="vym}[rlkU)UUh4{2in([">
      <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field>
      </block>
      </value>
      </block>
      </value>
      <value name="B">
      <block type="math_number" id="K3#(9lExyf7[B;6AN-,q">
      <field name="NUM">1</field>
      </block>
      </value>
      </block>
      </value>
      </block>
      </value>
      <statement name="DO0">
      <block type="debug" id="c%$gqe/oz1m]qnYrnxu"> <field name="Severity">log</field> <value name="TEXT"> <shadow type="text" id="M{f)v6=GQ.S*({.?+@vI"> <field name="TEXT">Liste ist leer oder noch nicht drin</field> </shadow> </value> <next> <block type="procedures_callnoreturn" id="b]HsmCD/KDlrR2,Nm2Ip"> <mutation name="Prozess"></mutation> </block> </next> </block> </statement> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> </statement> </block> </next> </block> </statement> </block> </next> </block> </next> </block> </next> </block> </next> </block> </next> </block> <block type="procedures_defcustomnoreturn" id=")0=5;5d/bT^GYpsS-4" x="887" y="-163">
      <mutation statements="false">
      <arg name="i" varid="wMPT6J+/@b!eVfPpvy/6"></arg>
      </mutation>
      <field name="NAME">SplitAndParseMessage</field>
      <field name="SCRIPT">IHZhciBsUGFyYW1ldGVyID0gaS5zcGxpdCgiOyIpOw0KaWYobFBhcmFtZXRlci5sZW5ndGggPiAwKQ0Kew0KICAgIC8vIEFwcG5hbWUNCiAgICB2YXIgbEFwcE5hbWUgPSBsUGFyYW1ldGVyWzBdLnNwbGl0KCI6Iik7DQogICAgaWYgKGxBcHBOYW1lLmxlbmd0aCA9IDIpDQogICAgICAgIEFwcE5hbWUgPSBsQXBwTmFtZVsxXTsNCiAgICANCiAgICAvLyBBcHBUaXRlbA0KICAgIHZhciBsQXBwVGl0ZWwgPSBsUGFyYW1ldGVyWzFdLnNwbGl0KCI6Iik7DQogICAgaWYgKGxBcHBUaXRlbC5sZW5ndGggPSAyKQ0KICAgICAgICBBcHBUaXRlbCA9IGxBcHBUaXRlbFsxXTsNCiAgICAgICAgDQogICAgLy8gVGV4dA0KICAgIHZhciBsQXBwVGV4dCA9IGxQYXJhbWV0ZXJbMl0uc3BsaXQoIjoiKTsNCiAgICBpZiAobEFwcFRleHQubGVuZ3RoID0gMikNCiAgICAgICAgQXBwSW5oYWx0ID0gbEFwcFRpdGVsWzFdOw0KICAgICAgICANCn0=</field>
      <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
      </block>
      <block type="procedures_defnoreturn" id="XZ?B!jTcqJ?1vTUOZf" x="37" y="513"> <field name="NAME">Prozess</field> <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment> <statement name="STACK"> <block type="lists_setIndex" id="@lrIRFncHNRW3O8KkN=}"> <mutation at="false"></mutation> <field name="MODE">INSERT</field> <field name="WHERE">LAST</field> <value name="LIST"> <block type="variables_get" id="Kloy:jP(UBgqp)cqnRs">
      <field name="VAR" id="PR/pQwdg6c+A.GJ/,BQ" variabletype="">listeAppNames</field> </block> </value> <value name="TO"> <block type="variables_get" id="gGmiMg{@.s%$:~C_*xD~"> <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field> </block> </value> <next> <block type="controls_if" id="U[!*SvX,_.8qw0WpSoVU"> <mutation else="1"></mutation> <value name="IF0"> <block type="logic_compare" id="d_LGRZ3_G4ez@cQ[Czx,"> <field name="OP">EQ</field> <value name="A"> <block type="text_changeCase" id="|Zq/NZOHoUq/WGDTBu1">
      <field name="CASE">LOWERCASE</field>
      <value name="TEXT">
      <shadow type="text" id="fT;pGYi/PgatNBdk
      g$C">
      <field name="TEXT">abc</field>
      </shadow>
      <block type="variables_get" id=")An
      ;sD{5w8U}YGGN20m">
      <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field>
      </block>
      </value>
      </block>
      </value>
      <value name="B">
      <block type="text" id="J0iHgg#c$gf}CL%GJ]/)">
      <field name="TEXT">telefon</field>
      </block>
      </value>
      </block>
      </value>
      <statement name="DO0">
      <block type="comment" id="Z9|wFB}!cAGW5f?F,~?"> <field name="COMMENT">Wenn ein eingehender Anruf erkannt wird</field> <next> <block type="debug" id="@dc=c@=(4[0JoT.wu{(">
      <field name="Severity">log</field>
      <value name="TEXT">
      <shadow type="text" id="$R#@R]L^C7W}%pwY-%Cd">
      <field name="TEXT">Telefon erkannt</field>
      </shadow>
      </value>
      <next>
      <block type="variables_set" id="@etNu{e/5rEX}yV2J$,
      ">
      <field name="VAR" id="020}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field>
      <value name="VALUE">
      <block type="text_join" id="fIB@?xLa!5zYnO{y/ZZ"> <mutation items="2"></mutation> <value name="ADD0"> <block type="text" id="E?4F%*uPS1Zs*xdy:S]["> <field name="TEXT">Anruf von </field> </block> </value> <value name="ADD1"> <block type="variables_get" id="^+kgnPr{pjINAS_HK![">
      <field name="VAR" id="Ny_}+(lYYEia^3cxv$q2" variabletype="">AppTitel</field>
      </block>
      </value>
      </block>
      </value>
      </block>
      </next>
      </block>
      </next>
      </block>
      </statement>
      <statement name="ELSE">
      <block type="comment" id="{@;rf{-1kU4Gp@R}2xko">
      <field name="COMMENT">Für alle anderen aktivieren Benachrichtigungen</field>
      <next>
      <block type="variables_set" id="SxK6a_N?[v+J|zw=tGA"> <field name="VAR" id="0*20}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field> <value name="VALUE"> <block type="text_join" id="~1LQTFHecm%PAR@*2@_="> <mutation items="2"></mutation> <value name="ADD0"> <block type="variables_get" id="bG=ZGj*QFF*6iDlHZ.Ut"> <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field> </block> </value> <value name="ADD1"> <block type="text" id="gKFN0/^oqN[C~qUmDp3%"> <field name="TEXT"> Nachricht erhalten</field> </block> </value> </block> </value> </block> </next> </block> </statement> <next> <block type="controls_if" id="!dtWxvF$a(8ib:mY%!y@"> <value name="IF0"> <block type="logic_negate" id="aVS}_43YeRjmlsTJU4r5"> <value name="BOOL"> <block type="text_isEmpty" id="UUG2R@+{EN|n7#~V77cy"> <value name="VALUE"> <shadow type="text" id="k0=%pDiZ[B@^3=3$9]=E"> <field name="TEXT"></field> </shadow> <block type="variables_get" id="Zum8}K5~Dwp(hjnp{*%z"> <field name="VAR" id="0*20}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field> </block> </value> </block> </value> </block> </value> <statement name="DO0"> <block type="debug" id="+k],pBg[~Yt/$6*.2n3-"> <field name="Severity">log</field> <value name="TEXT"> <shadow type="text" id=",hCZ1b4VT8HgALl=djNb"> <field name="TEXT">test</field> </shadow> <block type="text_join" id="-lF6rOx[x6wDatqm!KvU"> <mutation items="2"></mutation> <value name="ADD0"> <block type="text" id="PfhYOh,2+D1ugnKo=s?E"> <field name="TEXT">Ausgabe Text: </field> </block> </value> <value name="ADD1"> <block type="variables_get" id="*stZFed9*yPvv4}B$Yny"> <field name="VAR" id="0*20}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field> </block> </value> </block> </value> <next> <block type="control_ex" id="4yzS4(I3fi65fpZ1UJ#2"> <field name="TYPE">false</field> <field name="CLEAR_RUNNING">FALSE</field> <value name="OID"> <shadow type="field_oid" id="EiQI23d_CHSjg9T%}ctq"> <field name="oid">Object ID</field> </shadow> <block type="text" id="KwzK{e8@ZAR{M3XgA8a">
      <field name="TEXT">linkeddevices.0.Alexa Yannick.Sprechen</field>
      </block>
      </value>
      <value name="VALUE">
      <shadow type="logic_boolean" id="/WRu3n~i3TN(#-JI|f-6">
      <field name="BOOL">TRUE</field>
      </shadow>
      <block type="variables_get" id="j@|XK=:OZqJ3Hrch2aRI">
      <field name="VAR" id="0
      20}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field>
      </block>
      </value>
      <value name="DELAY_MS">
      <shadow type="math_number" id="oTR7pp6(|xI^|C}-yeoW">
      <field name="NUM">0</field>
      </shadow>
      </value>
      <next>
      <block type="variables_set" id="l4hi$+hH#(Oz+-[mA(">
      <field name="VAR" id="020}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field>
      <value name="VALUE">
      <block type="text" id="qQ3w+b1#_%4f%r;Zgdza">
      <field name="TEXT">""</field>
      </block>
      </value>
      <next>
      <block type="controls_if" id="Oo2%@8eDlvaOC!7Tfka@">
      <mutation else="1"></mutation>
      <value name="IF0">
      <block type="variables_get" id="U3eZ^#BwI^QZ2+G/E9">
      <field name="VAR" id="~pQOs?dGT6XyDYTXUr0Y" variabletype="">bWichtig</field>
      </block>
      </value>
      <statement name="DO0">
      <block type="debug" id="2B+b0@6slmyMJ_ZLd$7h">
      <field name="Severity">log</field>
      <value name="TEXT">
      <shadow type="text" id="({^;:rX
      bQKCdBs3Jbc">
      <field name="TEXT">Wichtig, also nicht in der Liste speichern</field>
      </shadow>
      </value>
      <next>
      <block type="timeouts_settimeout" id="d8TvtbcVyxIDeKLze#n"> <field name="NAME">AppBenachrichtigungFreigeben2</field> <field name="DELAY">5</field> <field name="UNIT">sec</field> <statement name="STATEMENT"> <block type="procedures_callnoreturn" id=",h*yFnzT5S8M^Qbm4q,h"> <mutation name="EntferneAppNameAusListe"></mutation> </block> </statement> </block> </next> </block> </statement> <statement name="ELSE"> <block type="timeouts_settimeout" id="jGl$l#L.mKoJJNZ?^JWI"> <field name="NAME">AppBenachrichtigungFreigeben</field> <field name="DELAY">1</field> <field name="UNIT">min</field> <statement name="STATEMENT"> <block type="procedures_callnoreturn" id="zH~XoI.lHr?QmPa~([C">
      <mutation name="EntferneAppNameAusListe"></mutation>
      </block>
      </statement>
      </block>
      </statement>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </statement>
      <next>
      <block type="variables_set" id="tBmSKzx[U%s9iz5QTAxR">
      <field name="VAR" id="0
      20}aVTZlug2TWsjH/8" variabletype="">sAusgabeText</field>
      <value name="VALUE">
      <block type="text" id="wH^W4C0[iErqlPT3|wZ|">
      <field name="TEXT"></field>
      </block>
      </value>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </statement>
      </block>
      <block type="procedures_defnoreturn" id="qPhOK/NFg^plZ6ypiA[8" x="38" y="1488">
      <field name="NAME">EntferneAppNameAusListe</field>
      <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
      <statement name="STACK">
      <block type="comment" id="nwV~1KrR%pKuB9mb?uU"> <field name="COMMENT">AppNamen in der Liste suchen und durch leeren String ersetzen</field> <next> <block type="debug" id="5q0k}3+Rh{t*nny?./6N"> <field name="Severity">log</field> <value name="TEXT"> <shadow type="text" id="KA,G!*QR[a@=@%!JRPKk"> <field name="TEXT">test</field> </shadow> <block type="text_join" id="|9/qA343vJAr?qnAAc">
      <mutation items="3"></mutation>
      <value name="ADD0">
      <block type="text" id="zd=j(eSl+9VpEZQdyksu">
      <field name="TEXT">Entferne </field>
      </block>
      </value>
      <value name="ADD1">
      <block type="variables_get" id="#IarAH!!kn~Lvj{:qw$T">
      <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field>
      </block>
      </value>
      <value name="ADD2">
      <block type="text" id="I[BoP8b,hQORY5,T4x;-">
      <field name="TEXT"> aus der Liste</field>
      </block>
      </value>
      </block>
      </value>
      <next>
      <block type="lists_setIndex" id="l(3pN^0g2Q=Dc$lv#B.,">
      <mutation at="true"></mutation>
      <field name="MODE">SET</field>
      <field name="WHERE">FROM_START</field>
      <value name="LIST">
      <block type="variables_get" id="Mc3JP5TWSeFB$kWL4TB*">
      <field name="VAR" id="PR/pQwdg6c+A.GJ/,BQ" variabletype="">listeAppNames</field> </block> </value> <value name="AT"> <block type="lists_indexOf" id="fu;FdH~@9]A1B0XG0WmI"> <field name="END">FIRST</field> <value name="VALUE"> <block type="variables_get" id="iY}nrDC%*J!$ET)S9Wv="> <field name="VAR" id="PR/pQwdg6c+A.GJ/,BQ" variabletype="">listeAppNames</field>
      </block>
      </value>
      <value name="FIND">
      <block type="variables_get" id="/I~oszp`S?wYQ649gUT{">
      <field name="VAR" id="rv[D5#M#xl-fl_IAJ/yX" variabletype="">AppName</field>
      </block>
      </value>
      </block>
      </value>
      <value name="TO">
      <block type="text" id="Oo_2i)*?pq?3mgH|,e6
      ">
      <field name="TEXT">""</field>
      </block>
      </value>
      </block>
      </next>
      </block>
      </next>
      </block>
      </statement>
      </block>
      </xml>

      K 1 Reply Last reply Reply Quote 5
      • K
        kigu318 @CruziX last edited by

        @cruzix Hi Ich bin ebenfalls gerade auf die Idee gekommen so etwas zu realisieren (noch sehr theoretisch). Allerdings möchte ich das über Bluetooth machen, wie z.b. es mein MiBand macht. Bekomme ich eine Benachrichtigung, vibriert es.
        Hat jemand Erfahrung, wie man so etwas realisieren könnte?

        1 Reply Last reply Reply Quote 0
        • First post
          Last post

        Support us

        ioBroker
        Community Adapters
        Donate

        905
        Online

        31.9k
        Users

        80.2k
        Topics

        1.3m
        Posts

        blockly communication template
        2
        2
        1173
        Loading More Posts
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes
        Reply
        • Reply as topic
        Log in to reply
        Community
        Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
        The ioBroker Community 2014-2023
        logo