Skip to content
  • Home
  • Aktuell
  • Tags
  • 0 Ungelesen 0
  • Kategorien
  • Unreplied
  • Beliebt
  • GitHub
  • Docu
  • Hilfe
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Standard: (Kein Skin)
  • Kein Skin
Einklappen
ioBroker Logo

Community Forum

donate donate
  1. ioBroker Community Home
  2. Deutsch
  3. Skripten / Logik
  4. Node-Red
  5. Payload String zerlegen

NEWS

  • Weihnachtsangebot 2025! 🎄
    BluefoxB
    Bluefox
    23
    1
    1.3k

  • UPDATE 31.10.: Amazon Alexa - ioBroker Skill läuft aus ?
    apollon77A
    apollon77
    48
    3
    9.3k

  • Monatsrückblick – September 2025
    BluefoxB
    Bluefox
    14
    1
    2.5k

Payload String zerlegen

Geplant Angeheftet Gesperrt Verschoben Node-Red
77 Beiträge 7 Kommentatoren 15.7k Aufrufe 7 Watching
  • Älteste zuerst
  • Neuste zuerst
  • Meiste Stimmen
Antworten
  • In einem neuen Thema antworten
Anmelden zum Antworten
Dieses Thema wurde gelöscht. Nur Nutzer mit entsprechenden Rechten können es sehen.
  • mickymM mickym

    @66er Du kannst auch jedes Switch Objekt nur auf die Objektebene herauslösen und dann die Eigenschaften eines Switches in einem 2. Schritt bearbeiten. Deiner Fantasie sind keine Grenzen gesetzt:

    f54354a0-c8fb-41f2-8e38-7508b181b48b-image.png

    [
       {
           "id": "f86a9994.9674a8",
           "type": "inject",
           "z": "169f5b00.a13415",
           "name": "",
           "props": [
               {
                   "p": "payload"
               }
           ],
           "repeat": "",
           "crontab": "",
           "once": false,
           "onceDelay": 0.1,
           "topic": "",
           "payload": "{\"ble\":{},\"cloud\":{\"connected\":false},\"eth\":{\"ip\":null},\"input:0\":{\"id\":0,\"state\":false},\"input:1\":{\"id\":1,\"state\":false},\"input:2\":{\"id\":2,\"state\":false},\"input:3\":{\"id\":3,\"state\":false},\"mqtt\":{\"connected\":true},\"switch:0\":{\"id\": 0, \"source\": \"UI\", \"output\": false, \"apower\": 0.000, \"voltage\": 237.237,\"aenergy\": {\"total\":0.021,\"by_minute\":[0.000,0.000,0.000],\"minute_ts\":1633241652},\"temperature\":{\"tC\":null, \"tF\":null}},\"switch:1\":{\"id\": 1, \"source\": \"init\", \"output\": false, \"apower\": 0.000, \"voltage\": 237.292,\"aenergy\": {\"total\":0.000,\"by_minute\":[0.000,0.000,0.000],\"minute_ts\":1633241652},\"temperature\":{\"tC\":null, \"tF\":null}},\"switch:2\":{\"id\": 2, \"source\": \"init\", \"output\": false, \"apower\": 0.000, \"voltage\": 238.268,\"aenergy\": {\"total\":0.000,\"by_minute\":[0.000,0.000,0.000],\"minute_ts\":1633241652},\"temperature\":{\"tC\":null, \"tF\":null}},\"switch:3\":{\"id\": 3, \"source\": \"init\", \"output\": false, \"apower\": 0.000, \"voltage\": 238.230,\"aenergy\": {\"total\":0.000,\"by_minute\":[0.000,0.000,0.000],\"minute_ts\":1633241651},\"temperature\":{\"tC\":null, \"tF\":null}},\"sys\":{\"mac\":\"95CCA87E43AC\",\"restart_required\":false,\"time\":\"08:14\",\"unixtime\":1633241653,\"uptime\":741,\"ram_size\":236340,\"ram_free\":147172,\"fs_size\":474641,\"fs_free\":317515,\"available_updates\":{\"beta\":{\"version\":\"0.9.0-beta1\"}}},\"wifi\":{\"sta_ip\":\"192.168.1.182\",\"status\":\"got ip\",\"ssid\":\"IoT\",\"rssi\":-58}}",
           "payloadType": "str",
           "x": 330,
           "y": 1320,
           "wires": [
               [
                   "6cd75bd9.78f334"
               ]
           ]
       },
       {
           "id": "6cd75bd9.78f334",
           "type": "json",
           "z": "169f5b00.a13415",
           "name": "",
           "property": "payload",
           "action": "",
           "pretty": false,
           "x": 500,
           "y": 1320,
           "wires": [
               [
                   "d59ab49f.83adb8",
                   "e409ee82.60264",
                   "7e3fb303.82128c",
                   "efc2f40c.3bb7f8",
                   "b65c559e.7ae848"
               ]
           ]
       },
       {
           "id": "efc2f40c.3bb7f8",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "switch3",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload[\"switch:3\"]",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 700,
           "y": 1480,
           "wires": [
               [
                   "666be515.af213c",
                   "9b305a05.dd89e8"
               ]
           ]
       },
       {
           "id": "7e3fb303.82128c",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "switch2",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload[\"switch:2\"]",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 700,
           "y": 1400,
           "wires": [
               [
                   "1306fb28.2e72e5",
                   "ffe7aeed.e875e"
               ]
           ]
       },
       {
           "id": "e409ee82.60264",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "switch1",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload[\"switch:1\"]",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 700,
           "y": 1320,
           "wires": [
               [
                   "1ab33829.4b2438",
                   "9a153f8f.51f3a"
               ]
           ]
       },
       {
           "id": "d59ab49f.83adb8",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "switch0",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload[\"switch:0\"]",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 700,
           "y": 1240,
           "wires": [
               [
                   "10fa2b5a.1d3fd5",
                   "d9d71e77.faca5"
               ]
           ]
       },
       {
           "id": "b65c559e.7ae848",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "true",
           "targetType": "full",
           "statusVal": "",
           "statusType": "auto",
           "x": 480,
           "y": 1400,
           "wires": []
       },
       {
           "id": "10fa2b5a.1d3fd5",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "output",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.output",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1220,
           "wires": [
               [
                   "21f577ba.3b76c8"
               ]
           ]
       },
       {
           "id": "d9d71e77.faca5",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "energy",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.aenergy.total",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1260,
           "wires": [
               [
                   "f8d0d07f.86fff"
               ]
           ]
       },
       {
           "id": "1ab33829.4b2438",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "output",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.output",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1300,
           "wires": [
               [
                   "d763e07f.5c467"
               ]
           ]
       },
       {
           "id": "9a153f8f.51f3a",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "energy",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.aenergy.total",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1340,
           "wires": [
               [
                   "ae57bd4a.003a3"
               ]
           ]
       },
       {
           "id": "1306fb28.2e72e5",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "output",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.output",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1380,
           "wires": [
               [
                   "63096a35.170df4"
               ]
           ]
       },
       {
           "id": "ffe7aeed.e875e",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "energy",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.aenergy.total",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1420,
           "wires": [
               [
                   "678ced56.3d2c44"
               ]
           ]
       },
       {
           "id": "666be515.af213c",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "output",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.output",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1460,
           "wires": [
               [
                   "85150103.9bf37"
               ]
           ]
       },
       {
           "id": "9b305a05.dd89e8",
           "type": "change",
           "z": "169f5b00.a13415",
           "name": "energy",
           "rules": [
               {
                   "t": "set",
                   "p": "payload",
                   "pt": "msg",
                   "to": "payload.aenergy.total",
                   "tot": "msg"
               }
           ],
           "action": "",
           "property": "",
           "from": "",
           "to": "",
           "reg": false,
           "x": 890,
           "y": 1500,
           "wires": [
               [
                   "5dfb6b7f.67f114"
               ]
           ]
       },
       {
           "id": "21f577ba.3b76c8",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 0 output",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1220,
           "wires": []
       },
       {
           "id": "f8d0d07f.86fff",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 0 energy",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1260,
           "wires": []
       },
       {
           "id": "d763e07f.5c467",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 1 output",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1300,
           "wires": []
       },
       {
           "id": "ae57bd4a.003a3",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 1 energy",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1340,
           "wires": []
       },
       {
           "id": "63096a35.170df4",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 2 output",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1380,
           "wires": []
       },
       {
           "id": "678ced56.3d2c44",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 2 energy",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1420,
           "wires": []
       },
       {
           "id": "85150103.9bf37",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 3 output",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1460,
           "wires": []
       },
       {
           "id": "5dfb6b7f.67f114",
           "type": "debug",
           "z": "169f5b00.a13415",
           "name": "switch 3 energy",
           "active": true,
           "tosidebar": true,
           "console": false,
           "tostatus": false,
           "complete": "payload",
           "targetType": "msg",
           "statusVal": "",
           "statusType": "auto",
           "x": 1080,
           "y": 1500,
           "wires": []
       }
    ]
    

    66er6 Offline
    66er6 Offline
    66er
    schrieb am zuletzt editiert von
    #13

    @mickym
    Sieht ja fast aus, wie mein Ergebnis. :+1:

    So bin ich zu Erfolg gekommen:
    Bildschirmfoto vom 2021-10-03 14-18-14.png

    LG
    Stefan

    mickymM 1 Antwort Letzte Antwort
    0
    • 66er6 66er

      @mickym
      Sieht ja fast aus, wie mein Ergebnis. :+1:

      So bin ich zu Erfolg gekommen:
      Bildschirmfoto vom 2021-10-03 14-18-14.png

      mickymM Offline
      mickymM Offline
      mickym
      Most Active
      schrieb am zuletzt editiert von mickym
      #14

      @66er Falls Du das nur in eigene DP wegschreiben willst, dann kannst Dir ja mal meinen Subflow anschauen:

      https://forum.iobroker.net/topic/43856/json-string-oder-java-object-in-iobroker-struktur

      Seit Admin 5 musst Du dann zwar noch etwas nacharbeiten, in dem Du mit einem Skript die fehlenden Objekte noch erzeugst. Aber falls Du ihn nutzen willst, bekommst Du so alles in DP zerlegt.

      IN meinen Augen ist das zwar nicht sinnvoll, aber ich sehe ja, dass Du mit Deinem Flow nichts anderes machst.

      Oder Du nimmst den mqtt-Adapter im iobroker - dann hast Du ebenfalls alles als einzelne Datenpunkte.

      Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

      66er6 1 Antwort Letzte Antwort
      0
      • mickymM mickym

        @66er Falls Du das nur in eigene DP wegschreiben willst, dann kannst Dir ja mal meinen Subflow anschauen:

        https://forum.iobroker.net/topic/43856/json-string-oder-java-object-in-iobroker-struktur

        Seit Admin 5 musst Du dann zwar noch etwas nacharbeiten, in dem Du mit einem Skript die fehlenden Objekte noch erzeugst. Aber falls Du ihn nutzen willst, bekommst Du so alles in DP zerlegt.

        IN meinen Augen ist das zwar nicht sinnvoll, aber ich sehe ja, dass Du mit Deinem Flow nichts anderes machst.

        Oder Du nimmst den mqtt-Adapter im iobroker - dann hast Du ebenfalls alles als einzelne Datenpunkte.

        66er6 Offline
        66er6 Offline
        66er
        schrieb am zuletzt editiert von 66er
        #15

        @mickym sagte in Payload String zerlegen:

        ...

        IN meinen Augen ist das zwar nicht sinnvoll, aber ich sehe ja, dass Du mit Deinem Flow nichts anderes machst.

        Schau mir den anderen Link natürlich noch an.

        Warum ist das nicht sinnvoll? (Ich lerne mich ja gerade erst ein und wenn ich hier was falsch mache, sollte ich verstehen warum.)

        Versuchsweise schreibe ich die Werte da rein und visualisiere sie dann.

        Leider geben die Geräte nur einen "Sammelstring" nach MQTT und keine einzelnen, direkt verwertbare Datenpunkte.

        LG
        Stefan

        mickymM 1 Antwort Letzte Antwort
        0
        • 66er6 66er

          @mickym sagte in Payload String zerlegen:

          ...

          IN meinen Augen ist das zwar nicht sinnvoll, aber ich sehe ja, dass Du mit Deinem Flow nichts anderes machst.

          Schau mir den anderen Link natürlich noch an.

          Warum ist das nicht sinnvoll? (Ich lerne mich ja gerade erst ein und wenn ich hier was falsch mache, sollte ich verstehen warum.)

          Versuchsweise schreibe ich die Werte da rein und visualisiere sie dann.

          Leider geben die Geräte nur einen "Sammelstring" nach MQTT und keine einzelnen, direkt verwertbare Datenpunkte.

          mickymM Offline
          mickymM Offline
          mickym
          Most Active
          schrieb am zuletzt editiert von
          #16

          @66er OK zum Visualisieren hängt davon ab, was Du halt nutzt. Für VIS ja.

          Wenn Du das Node-Red Dashborad nutzt, dann fütterst Du ja den switch mit der payload und der Switch behält ja den Status.
          Aber Du hast Recht für VIS ist es sinnvoll.

          Ansonsten ist zwar schön alles in eigene Datenpunkte zu schreiben, aber gibt Dir ja keinen Mehrwert, weil die Info letztlich in dem JSON String enthalten ist. Wie gesagt für VIS ist es sinnvoll.

          Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

          66er6 1 Antwort Letzte Antwort
          0
          • mickymM mickym

            @66er OK zum Visualisieren hängt davon ab, was Du halt nutzt. Für VIS ja.

            Wenn Du das Node-Red Dashborad nutzt, dann fütterst Du ja den switch mit der payload und der Switch behält ja den Status.
            Aber Du hast Recht für VIS ist es sinnvoll.

            Ansonsten ist zwar schön alles in eigene Datenpunkte zu schreiben, aber gibt Dir ja keinen Mehrwert, weil die Info letztlich in dem JSON String enthalten ist. Wie gesagt für VIS ist es sinnvoll.

            66er6 Offline
            66er6 Offline
            66er
            schrieb am zuletzt editiert von 66er
            #17

            @mickym

            Ja, ich nutze VIS.

            Hier noch ein Screenshot von MQTT:

            Bildschirmfoto vom 2021-10-03 16-27-21.png

            Im RPC-String unter events steht alles drin.

            LG
            Stefan

            mickymM 1 Antwort Letzte Antwort
            0
            • 66er6 66er

              @mickym

              Ja, ich nutze VIS.

              Hier noch ein Screenshot von MQTT:

              Bildschirmfoto vom 2021-10-03 16-27-21.png

              Im RPC-String unter events steht alles drin.

              mickymM Offline
              mickymM Offline
              mickym
              Most Active
              schrieb am zuletzt editiert von
              #18

              @66er Ja wie gesagt, wenn Du nur das wieder in DP speicherst, was Du visualisierst - passt das schon!!!

              Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

              66er6 1 Antwort Letzte Antwort
              0
              • mickymM mickym

                @66er Ja wie gesagt, wenn Du nur das wieder in DP speicherst, was Du visualisierst - passt das schon!!!

                66er6 Offline
                66er6 Offline
                66er
                schrieb am zuletzt editiert von
                #19

                @mickym

                Prima,

                und ja: alle anderen Datenpunkt bleiben im JSON ohne das ich die anpacke.

                Danke, wieder mein Wissen und Verständnis für MQTT erweitert.:+1:

                LG
                Stefan

                R 1 Antwort Letzte Antwort
                0
                • 66er6 66er

                  @mickym

                  Prima,

                  und ja: alle anderen Datenpunkt bleiben im JSON ohne das ich die anpacke.

                  Danke, wieder mein Wissen und Verständnis für MQTT erweitert.:+1:

                  R Offline
                  R Offline
                  rieders
                  schrieb am zuletzt editiert von rieders
                  #20

                  Hallo

                  Ich versuche gerade mein Stromzähler String zu zerlegen.
                  Eine Verbindung zum mqtt-Broker besteht, die Daten werden auch im Debug angezeigt.

                  Ich habe schon einiges Versuch, ich bekomme einfach nicht die Werte einzeln angezeigt.

                  Smartmeter_Garten/tele/SENSOR : msg.payload : string[643]
                  "{"Time":"2023-01-13T12:54:35","SDM630":{"1":178,"Voltage_P1":231.88,"Voltage_P2":231.5,"Voltage_P3":232.49,"Current_P1":0,"Current_P2":0.1,"Current_P3":0,"Power_P1":0,"Power_P2":22.35,"Power_P3":0,"Frequenz":50.01,"Total":534.694,"phase_angle":-9.73,"Import_nres":186.145,"Export_nres":348.549,"Export_P1":13.568,"Export_P2":334.981,"Export_P3":0,"Import_P1":19.409,"Import_P2":131.003,"Import_P3":35.733,"L1_total_kwh":32.977,"L2_total_kwh":465.984,"L3_total_kwh":35.733,"Blindleistung_L1":0,"Blindleistung_L2":-7.734,"Blindleistung_L3":0,"Scheinleistung_L1":0,"Scheinleistung_L2":22.627,"Scheinleistung_L3":0,"VAh_since_last_reset":565.815}}"

                  Screenshot 2023-01-13 130004.png

                  Ich hoffe jemand kann mir weiter helfen.


                  [
                  {
                  "id": "553525487db580b5",
                  "type": "mqtt in",
                  "z": "eb71b4cddc9da37a",
                  "name": "Smartmeter_Garten/tele/SENSOR",
                  "topic": "Smartmeter_Garten/tele/SENSOR",
                  "qos": "2",
                  "datatype": "auto-detect",
                  "broker": "e7e1e2255e66e588",
                  "nl": false,
                  "rap": true,
                  "rh": "2",
                  "inputs": 0,
                  "x": 180,
                  "y": 260,
                  "wires": [
                  [
                  "04a7ba72539a5cb1",
                  "df378652670347e0"
                  ]
                  ]
                  },
                  {
                  "id": "b0fcb45d6d8ab9f4",
                  "type": "ui_gauge",
                  "z": "eb71b4cddc9da37a",
                  "name": "Test",
                  "group": "67140eec2a9994a9",
                  "order": 0,
                  "width": 0,
                  "height": 0,
                  "gtype": "gage",
                  "title": "Voltage_P1",
                  "label": "",
                  "format": "{{Value}}",
                  "min": "1",
                  "max": "260",
                  "colors": [
                  "#b30000",
                  "#e6e600",
                  "#00b815"
                  ],
                  "seg1": "",
                  "seg2": "",
                  "x": 890,
                  "y": 260,
                  "wires": []
                  },
                  {
                  "id": "9faaac80e56b9d83",
                  "type": "ui_chart",
                  "z": "eb71b4cddc9da37a",
                  "name": "",
                  "group": "67140eec2a9994a9",
                  "order": 0,
                  "width": 0,
                  "height": 0,
                  "label": "chart",
                  "chartType": "line",
                  "legend": "false",
                  "xformat": "HH:mm:ss",
                  "interpolate": "linear",
                  "nodata": "",
                  "dot": false,
                  "ymin": "0",
                  "ymax": "260",
                  "removeOlder": 1,
                  "removeOlderPoints": "",
                  "removeOlderUnit": "3600",
                  "cutout": 0,
                  "useOneColor": false,
                  "useUTC": false,
                  "colors": [
                  "#1f77b4",
                  "#aec7e8",
                  "#ff7f0e",
                  "#2ca02c",
                  "#98df8a",
                  "#d62728",
                  "#ff9896",
                  "#9467bd",
                  "#c5b0d5"
                  ],
                  "outputs": 1,
                  "useDifferentColor": false,
                  "x": 890,
                  "y": 320,
                  "wires": [
                  []
                  ]
                  },
                  {
                  "id": "04a7ba72539a5cb1",
                  "type": "json",
                  "z": "eb71b4cddc9da37a",
                  "name": "V1",
                  "property": "payload",
                  "action": "",
                  "pretty": false,
                  "x": 450,
                  "y": 200,
                  "wires": [
                  [
                  "35354018b6c6c095",
                  "639599639f78788c"
                  ]
                  ]
                  },
                  {
                  "id": "6f72cb37f4aa2278",
                  "type": "debug",
                  "z": "eb71b4cddc9da37a",
                  "name": "debug 1",
                  "active": true,
                  "tosidebar": true,
                  "console": false,
                  "tostatus": false,
                  "complete": "payload",
                  "targetType": "msg",
                  "statusVal": "",
                  "statusType": "auto",
                  "x": 900,
                  "y": 200,
                  "wires": []
                  },
                  {
                  "id": "35354018b6c6c095",
                  "type": "debug",
                  "z": "eb71b4cddc9da37a",
                  "name": "debug 2",
                  "active": true,
                  "tosidebar": true,
                  "console": false,
                  "tostatus": false,
                  "complete": "payload",
                  "targetType": "msg",
                  "statusVal": "",
                  "statusType": "auto",
                  "x": 620,
                  "y": 120,
                  "wires": []
                  },
                  {
                  "id": "639599639f78788c",
                  "type": "change",
                  "z": "eb71b4cddc9da37a",
                  "name": "",
                  "rules": [
                  {
                  "t": "set",
                  "p": "payload",
                  "pt": "msg",
                  "to": "payload["SDM630"].Voltage_P1",
                  "tot": "msg"
                  }
                  ],
                  "action": "",
                  "property": "",
                  "from": "",
                  "to": "",
                  "reg": false,
                  "x": 670,
                  "y": 200,
                  "wires": [
                  [
                  "6f72cb37f4aa2278",
                  "b0fcb45d6d8ab9f4",
                  "9faaac80e56b9d83"
                  ]
                  ]
                  },
                  {
                  "id": "a5192d83b6ce2f1c",
                  "type": "mqtt out",
                  "z": "eb71b4cddc9da37a",
                  "name": "V1",
                  "topic": "Testzähler",
                  "qos": "",
                  "retain": "",
                  "respTopic": "",
                  "contentType": "",
                  "userProps": "",
                  "correl": "",
                  "expiry": "",
                  "broker": "d19896c9b4e98e28",
                  "x": 750,
                  "y": 340,
                  "wires": []
                  },
                  {
                  "id": "df378652670347e0",
                  "type": "function",
                  "z": "eb71b4cddc9da37a",
                  "name": "function 2",
                  "func": "\nreturn msg;payload["SDM630"].Voltage_P1",
                  "outputs": 1,
                  "noerr": 0,
                  "initialize": "",
                  "finalize": "",
                  "libs": [],
                  "x": 560,
                  "y": 340,
                  "wires": [
                  [
                  "a5192d83b6ce2f1c"
                  ]
                  ]
                  },
                  {
                  "id": "e7e1e2255e66e588",
                  "type": "mqtt-broker",
                  "name": "mqtt-broker",
                  "broker": "192.168.1.146",
                  "port": "1885",
                  "clientid": "",
                  "autoConnect": true,
                  "usetls": false,
                  "protocolVersion": "4",
                  "keepalive": "60",
                  "cleansession": true,
                  "birthTopic": "",
                  "birthQos": "0",
                  "birthPayload": "",
                  "birthMsg": {},
                  "closeTopic": "",
                  "closeQos": "0",
                  "closePayload": "",
                  "closeMsg": {},
                  "willTopic": "",
                  "willQos": "0",
                  "willPayload": "",
                  "willMsg": {},
                  "userProps": "",
                  "sessionExpiry": ""
                  },
                  {
                  "id": "67140eec2a9994a9",
                  "type": "ui_group",
                  "name": "Test",
                  "tab": "71f6d060a354b8d9",
                  "order": 1,
                  "disp": true,
                  "width": "6",
                  "collapse": false
                  },
                  {
                  "id": "d19896c9b4e98e28",
                  "type": "mqtt-broker",
                  "name": "Venus OS",
                  "broker": "192.168.1.37",
                  "port": "1883",
                  "clientid": "test-client",
                  "autoConnect": true,
                  "usetls": false,
                  "protocolVersion": "4",
                  "keepalive": "60",
                  "cleansession": true,
                  "birthTopic": "",
                  "birthQos": "0",
                  "birthPayload": "",
                  "birthMsg": {},
                  "closeTopic": "",
                  "closeQos": "0",
                  "closePayload": "",
                  "closeMsg": {},
                  "willTopic": "",
                  "willQos": "0",
                  "willPayload": "",
                  "willMsg": {},
                  "userProps": "",
                  "sessionExpiry": ""
                  },
                  {
                  "id": "71f6d060a354b8d9",
                  "type": "ui_tab",
                  "name": "Home",
                  "icon": "dashboard",
                  "disabled": false,
                  "hidden": false
                  }
                  ]

                  Grüße André

                  mickymM 1 2 Antworten Letzte Antwort
                  0
                  • R rieders

                    Hallo

                    Ich versuche gerade mein Stromzähler String zu zerlegen.
                    Eine Verbindung zum mqtt-Broker besteht, die Daten werden auch im Debug angezeigt.

                    Ich habe schon einiges Versuch, ich bekomme einfach nicht die Werte einzeln angezeigt.

                    Smartmeter_Garten/tele/SENSOR : msg.payload : string[643]
                    "{"Time":"2023-01-13T12:54:35","SDM630":{"1":178,"Voltage_P1":231.88,"Voltage_P2":231.5,"Voltage_P3":232.49,"Current_P1":0,"Current_P2":0.1,"Current_P3":0,"Power_P1":0,"Power_P2":22.35,"Power_P3":0,"Frequenz":50.01,"Total":534.694,"phase_angle":-9.73,"Import_nres":186.145,"Export_nres":348.549,"Export_P1":13.568,"Export_P2":334.981,"Export_P3":0,"Import_P1":19.409,"Import_P2":131.003,"Import_P3":35.733,"L1_total_kwh":32.977,"L2_total_kwh":465.984,"L3_total_kwh":35.733,"Blindleistung_L1":0,"Blindleistung_L2":-7.734,"Blindleistung_L3":0,"Scheinleistung_L1":0,"Scheinleistung_L2":22.627,"Scheinleistung_L3":0,"VAh_since_last_reset":565.815}}"

                    Screenshot 2023-01-13 130004.png

                    Ich hoffe jemand kann mir weiter helfen.


                    [
                    {
                    "id": "553525487db580b5",
                    "type": "mqtt in",
                    "z": "eb71b4cddc9da37a",
                    "name": "Smartmeter_Garten/tele/SENSOR",
                    "topic": "Smartmeter_Garten/tele/SENSOR",
                    "qos": "2",
                    "datatype": "auto-detect",
                    "broker": "e7e1e2255e66e588",
                    "nl": false,
                    "rap": true,
                    "rh": "2",
                    "inputs": 0,
                    "x": 180,
                    "y": 260,
                    "wires": [
                    [
                    "04a7ba72539a5cb1",
                    "df378652670347e0"
                    ]
                    ]
                    },
                    {
                    "id": "b0fcb45d6d8ab9f4",
                    "type": "ui_gauge",
                    "z": "eb71b4cddc9da37a",
                    "name": "Test",
                    "group": "67140eec2a9994a9",
                    "order": 0,
                    "width": 0,
                    "height": 0,
                    "gtype": "gage",
                    "title": "Voltage_P1",
                    "label": "",
                    "format": "{{Value}}",
                    "min": "1",
                    "max": "260",
                    "colors": [
                    "#b30000",
                    "#e6e600",
                    "#00b815"
                    ],
                    "seg1": "",
                    "seg2": "",
                    "x": 890,
                    "y": 260,
                    "wires": []
                    },
                    {
                    "id": "9faaac80e56b9d83",
                    "type": "ui_chart",
                    "z": "eb71b4cddc9da37a",
                    "name": "",
                    "group": "67140eec2a9994a9",
                    "order": 0,
                    "width": 0,
                    "height": 0,
                    "label": "chart",
                    "chartType": "line",
                    "legend": "false",
                    "xformat": "HH:mm:ss",
                    "interpolate": "linear",
                    "nodata": "",
                    "dot": false,
                    "ymin": "0",
                    "ymax": "260",
                    "removeOlder": 1,
                    "removeOlderPoints": "",
                    "removeOlderUnit": "3600",
                    "cutout": 0,
                    "useOneColor": false,
                    "useUTC": false,
                    "colors": [
                    "#1f77b4",
                    "#aec7e8",
                    "#ff7f0e",
                    "#2ca02c",
                    "#98df8a",
                    "#d62728",
                    "#ff9896",
                    "#9467bd",
                    "#c5b0d5"
                    ],
                    "outputs": 1,
                    "useDifferentColor": false,
                    "x": 890,
                    "y": 320,
                    "wires": [
                    []
                    ]
                    },
                    {
                    "id": "04a7ba72539a5cb1",
                    "type": "json",
                    "z": "eb71b4cddc9da37a",
                    "name": "V1",
                    "property": "payload",
                    "action": "",
                    "pretty": false,
                    "x": 450,
                    "y": 200,
                    "wires": [
                    [
                    "35354018b6c6c095",
                    "639599639f78788c"
                    ]
                    ]
                    },
                    {
                    "id": "6f72cb37f4aa2278",
                    "type": "debug",
                    "z": "eb71b4cddc9da37a",
                    "name": "debug 1",
                    "active": true,
                    "tosidebar": true,
                    "console": false,
                    "tostatus": false,
                    "complete": "payload",
                    "targetType": "msg",
                    "statusVal": "",
                    "statusType": "auto",
                    "x": 900,
                    "y": 200,
                    "wires": []
                    },
                    {
                    "id": "35354018b6c6c095",
                    "type": "debug",
                    "z": "eb71b4cddc9da37a",
                    "name": "debug 2",
                    "active": true,
                    "tosidebar": true,
                    "console": false,
                    "tostatus": false,
                    "complete": "payload",
                    "targetType": "msg",
                    "statusVal": "",
                    "statusType": "auto",
                    "x": 620,
                    "y": 120,
                    "wires": []
                    },
                    {
                    "id": "639599639f78788c",
                    "type": "change",
                    "z": "eb71b4cddc9da37a",
                    "name": "",
                    "rules": [
                    {
                    "t": "set",
                    "p": "payload",
                    "pt": "msg",
                    "to": "payload["SDM630"].Voltage_P1",
                    "tot": "msg"
                    }
                    ],
                    "action": "",
                    "property": "",
                    "from": "",
                    "to": "",
                    "reg": false,
                    "x": 670,
                    "y": 200,
                    "wires": [
                    [
                    "6f72cb37f4aa2278",
                    "b0fcb45d6d8ab9f4",
                    "9faaac80e56b9d83"
                    ]
                    ]
                    },
                    {
                    "id": "a5192d83b6ce2f1c",
                    "type": "mqtt out",
                    "z": "eb71b4cddc9da37a",
                    "name": "V1",
                    "topic": "Testzähler",
                    "qos": "",
                    "retain": "",
                    "respTopic": "",
                    "contentType": "",
                    "userProps": "",
                    "correl": "",
                    "expiry": "",
                    "broker": "d19896c9b4e98e28",
                    "x": 750,
                    "y": 340,
                    "wires": []
                    },
                    {
                    "id": "df378652670347e0",
                    "type": "function",
                    "z": "eb71b4cddc9da37a",
                    "name": "function 2",
                    "func": "\nreturn msg;payload["SDM630"].Voltage_P1",
                    "outputs": 1,
                    "noerr": 0,
                    "initialize": "",
                    "finalize": "",
                    "libs": [],
                    "x": 560,
                    "y": 340,
                    "wires": [
                    [
                    "a5192d83b6ce2f1c"
                    ]
                    ]
                    },
                    {
                    "id": "e7e1e2255e66e588",
                    "type": "mqtt-broker",
                    "name": "mqtt-broker",
                    "broker": "192.168.1.146",
                    "port": "1885",
                    "clientid": "",
                    "autoConnect": true,
                    "usetls": false,
                    "protocolVersion": "4",
                    "keepalive": "60",
                    "cleansession": true,
                    "birthTopic": "",
                    "birthQos": "0",
                    "birthPayload": "",
                    "birthMsg": {},
                    "closeTopic": "",
                    "closeQos": "0",
                    "closePayload": "",
                    "closeMsg": {},
                    "willTopic": "",
                    "willQos": "0",
                    "willPayload": "",
                    "willMsg": {},
                    "userProps": "",
                    "sessionExpiry": ""
                    },
                    {
                    "id": "67140eec2a9994a9",
                    "type": "ui_group",
                    "name": "Test",
                    "tab": "71f6d060a354b8d9",
                    "order": 1,
                    "disp": true,
                    "width": "6",
                    "collapse": false
                    },
                    {
                    "id": "d19896c9b4e98e28",
                    "type": "mqtt-broker",
                    "name": "Venus OS",
                    "broker": "192.168.1.37",
                    "port": "1883",
                    "clientid": "test-client",
                    "autoConnect": true,
                    "usetls": false,
                    "protocolVersion": "4",
                    "keepalive": "60",
                    "cleansession": true,
                    "birthTopic": "",
                    "birthQos": "0",
                    "birthPayload": "",
                    "birthMsg": {},
                    "closeTopic": "",
                    "closeQos": "0",
                    "closePayload": "",
                    "closeMsg": {},
                    "willTopic": "",
                    "willQos": "0",
                    "willPayload": "",
                    "willMsg": {},
                    "userProps": "",
                    "sessionExpiry": ""
                    },
                    {
                    "id": "71f6d060a354b8d9",
                    "type": "ui_tab",
                    "name": "Home",
                    "icon": "dashboard",
                    "disabled": false,
                    "hidden": false
                    }
                    ]

                    Grüße André

                    mickymM Offline
                    mickymM Offline
                    mickym
                    Most Active
                    schrieb am zuletzt editiert von mickym
                    #21

                    @rieders Am besten ist es aus dem Debugfenster einfach den Pfad kopieren. Sprich du schaust, was aus debug2 rauskommt und kopierst den Pfad, des Wertes den Du anzeigen willst.

                    copy path.gif

                    Wenn ich also Dein Objekt nehme (Dein Flow lässt sich nicht importieren, da Du keine CodeTags verwendest) und möchte den Total Wert in der Text Node anzeigen, gehe ich mit dem Cursor dahin und kopieren den Pfad:

                    cca960b2-944e-4f26-a76f-d729853f8e0f-image.png

                    Dann kommt folgendes raus:

                    payload.SDM630.Total
                    

                    Das kannst Du nun direkt in der text node verwenden oder die payload verändern um es dann in einer gauge anzuzeigen.

                    In der Text-Node:
                    16172d89-4af0-4c05-aa6c-a6859d47d6a5-image.png

                    Mit der Change-Node:
                    d79496f0-9682-4b6b-856d-ce10b22dd2d1-image.png

                    8b658eef-2178-44f5-a447-1d68ae48ca9e-image.png

                    Hier mal mein Flow richtig exportiert in CodeTags:
                    Code-Tags.gif

                    [
                       {
                           "id": "79cb540f2a41c739",
                           "type": "inject",
                           "z": "289f539dcc33814e",
                           "name": "",
                           "props": [
                               {
                                   "p": "payload"
                               }
                           ],
                           "repeat": "",
                           "crontab": "",
                           "once": false,
                           "onceDelay": 0.1,
                           "topic": "",
                           "payload": "{\"Time\":\"2023-01-13T12:54:35\",\"SDM630\":{\"1\":178,\"Voltage_P1\":231.88,\"Voltage_P2\":231.5,\"Voltage_P3\":232.49,\"Current_P1\":0,\"Current_P2\":0.1,\"Current_P3\":0,\"Power_P1\":0,\"Power_P2\":22.35,\"Power_P3\":0,\"Frequenz\":50.01,\"Total\":534.694,\"phase_angle\":-9.73,\"Import_nres\":186.145,\"Export_nres\":348.549,\"Export_P1\":13.568,\"Export_P2\":334.981,\"Export_P3\":0,\"Import_P1\":19.409,\"Import_P2\":131.003,\"Import_P3\":35.733,\"L1_total_kwh\":32.977,\"L2_total_kwh\":465.984,\"L3_total_kwh\":35.733,\"Blindleistung_L1\":0,\"Blindleistung_L2\":-7.734,\"Blindleistung_L3\":0,\"Scheinleistung_L1\":0,\"Scheinleistung_L2\":22.627,\"Scheinleistung_L3\":0,\"VAh_since_last_reset\":565.815}}",
                           "payloadType": "json",
                           "x": 230,
                           "y": 4260,
                           "wires": [
                               [
                                   "479307770498d089",
                                   "7e8331652d9d7389",
                                   "ae5bde5b22da03b0"
                               ]
                           ]
                       },
                       {
                           "id": "479307770498d089",
                           "type": "debug",
                           "z": "289f539dcc33814e",
                           "name": "Objekt",
                           "active": true,
                           "tosidebar": true,
                           "console": false,
                           "tostatus": false,
                           "complete": "payload",
                           "targetType": "msg",
                           "statusVal": "",
                           "statusType": "auto",
                           "x": 390,
                           "y": 4260,
                           "wires": []
                       },
                       {
                           "id": "c9e73544e1bfa520",
                           "type": "ui_gauge",
                           "z": "289f539dcc33814e",
                           "name": "",
                           "group": "57f13d6f733e5c9d",
                           "order": 2,
                           "width": 0,
                           "height": 0,
                           "gtype": "gage",
                           "title": "Total",
                           "label": "units",
                           "format": "{{value}}",
                           "min": 0,
                           "max": "1000",
                           "colors": [
                               "#00b500",
                               "#e6e600",
                               "#ca3838"
                           ],
                           "seg1": "",
                           "seg2": "",
                           "className": "",
                           "x": 630,
                           "y": 4340,
                           "wires": []
                       },
                       {
                           "id": "7e8331652d9d7389",
                           "type": "ui_text",
                           "z": "289f539dcc33814e",
                           "group": "57f13d6f733e5c9d",
                           "order": 3,
                           "width": 0,
                           "height": 0,
                           "name": "",
                           "label": "Total",
                           "format": "{{msg.payload.SDM630.Total}}",
                           "layout": "row-spread",
                           "className": "",
                           "x": 390,
                           "y": 4300,
                           "wires": []
                       },
                       {
                           "id": "ae5bde5b22da03b0",
                           "type": "change",
                           "z": "289f539dcc33814e",
                           "name": "",
                           "rules": [
                               {
                                   "t": "set",
                                   "p": "payload",
                                   "pt": "msg",
                                   "to": "payload.SDM630.Total",
                                   "tot": "msg"
                               }
                           ],
                           "action": "",
                           "property": "",
                           "from": "",
                           "to": "",
                           "reg": false,
                           "x": 430,
                           "y": 4340,
                           "wires": [
                               [
                                   "c9e73544e1bfa520",
                                   "680cd23566aafb30"
                               ]
                           ]
                       },
                       {
                           "id": "680cd23566aafb30",
                           "type": "debug",
                           "z": "289f539dcc33814e",
                           "name": "Total",
                           "active": true,
                           "tosidebar": true,
                           "console": false,
                           "tostatus": false,
                           "complete": "payload",
                           "targetType": "msg",
                           "statusVal": "",
                           "statusType": "auto",
                           "x": 630,
                           "y": 4380,
                           "wires": []
                       },
                       {
                           "id": "57f13d6f733e5c9d",
                           "type": "ui_group",
                           "name": "Test",
                           "tab": "20b3095113f94d70",
                           "order": 2,
                           "disp": true,
                           "width": "6",
                           "collapse": false,
                           "className": ""
                       },
                       {
                           "id": "20b3095113f94d70",
                           "type": "ui_tab",
                           "name": "Home",
                           "icon": "dashboard",
                           "order": 1,
                           "disabled": false,
                           "hidden": false
                       }
                    ]
                    

                    Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                    R 1 Antwort Letzte Antwort
                    1
                    • mickymM mickym

                      @rieders Am besten ist es aus dem Debugfenster einfach den Pfad kopieren. Sprich du schaust, was aus debug2 rauskommt und kopierst den Pfad, des Wertes den Du anzeigen willst.

                      copy path.gif

                      Wenn ich also Dein Objekt nehme (Dein Flow lässt sich nicht importieren, da Du keine CodeTags verwendest) und möchte den Total Wert in der Text Node anzeigen, gehe ich mit dem Cursor dahin und kopieren den Pfad:

                      cca960b2-944e-4f26-a76f-d729853f8e0f-image.png

                      Dann kommt folgendes raus:

                      payload.SDM630.Total
                      

                      Das kannst Du nun direkt in der text node verwenden oder die payload verändern um es dann in einer gauge anzuzeigen.

                      In der Text-Node:
                      16172d89-4af0-4c05-aa6c-a6859d47d6a5-image.png

                      Mit der Change-Node:
                      d79496f0-9682-4b6b-856d-ce10b22dd2d1-image.png

                      8b658eef-2178-44f5-a447-1d68ae48ca9e-image.png

                      Hier mal mein Flow richtig exportiert in CodeTags:
                      Code-Tags.gif

                      [
                         {
                             "id": "79cb540f2a41c739",
                             "type": "inject",
                             "z": "289f539dcc33814e",
                             "name": "",
                             "props": [
                                 {
                                     "p": "payload"
                                 }
                             ],
                             "repeat": "",
                             "crontab": "",
                             "once": false,
                             "onceDelay": 0.1,
                             "topic": "",
                             "payload": "{\"Time\":\"2023-01-13T12:54:35\",\"SDM630\":{\"1\":178,\"Voltage_P1\":231.88,\"Voltage_P2\":231.5,\"Voltage_P3\":232.49,\"Current_P1\":0,\"Current_P2\":0.1,\"Current_P3\":0,\"Power_P1\":0,\"Power_P2\":22.35,\"Power_P3\":0,\"Frequenz\":50.01,\"Total\":534.694,\"phase_angle\":-9.73,\"Import_nres\":186.145,\"Export_nres\":348.549,\"Export_P1\":13.568,\"Export_P2\":334.981,\"Export_P3\":0,\"Import_P1\":19.409,\"Import_P2\":131.003,\"Import_P3\":35.733,\"L1_total_kwh\":32.977,\"L2_total_kwh\":465.984,\"L3_total_kwh\":35.733,\"Blindleistung_L1\":0,\"Blindleistung_L2\":-7.734,\"Blindleistung_L3\":0,\"Scheinleistung_L1\":0,\"Scheinleistung_L2\":22.627,\"Scheinleistung_L3\":0,\"VAh_since_last_reset\":565.815}}",
                             "payloadType": "json",
                             "x": 230,
                             "y": 4260,
                             "wires": [
                                 [
                                     "479307770498d089",
                                     "7e8331652d9d7389",
                                     "ae5bde5b22da03b0"
                                 ]
                             ]
                         },
                         {
                             "id": "479307770498d089",
                             "type": "debug",
                             "z": "289f539dcc33814e",
                             "name": "Objekt",
                             "active": true,
                             "tosidebar": true,
                             "console": false,
                             "tostatus": false,
                             "complete": "payload",
                             "targetType": "msg",
                             "statusVal": "",
                             "statusType": "auto",
                             "x": 390,
                             "y": 4260,
                             "wires": []
                         },
                         {
                             "id": "c9e73544e1bfa520",
                             "type": "ui_gauge",
                             "z": "289f539dcc33814e",
                             "name": "",
                             "group": "57f13d6f733e5c9d",
                             "order": 2,
                             "width": 0,
                             "height": 0,
                             "gtype": "gage",
                             "title": "Total",
                             "label": "units",
                             "format": "{{value}}",
                             "min": 0,
                             "max": "1000",
                             "colors": [
                                 "#00b500",
                                 "#e6e600",
                                 "#ca3838"
                             ],
                             "seg1": "",
                             "seg2": "",
                             "className": "",
                             "x": 630,
                             "y": 4340,
                             "wires": []
                         },
                         {
                             "id": "7e8331652d9d7389",
                             "type": "ui_text",
                             "z": "289f539dcc33814e",
                             "group": "57f13d6f733e5c9d",
                             "order": 3,
                             "width": 0,
                             "height": 0,
                             "name": "",
                             "label": "Total",
                             "format": "{{msg.payload.SDM630.Total}}",
                             "layout": "row-spread",
                             "className": "",
                             "x": 390,
                             "y": 4300,
                             "wires": []
                         },
                         {
                             "id": "ae5bde5b22da03b0",
                             "type": "change",
                             "z": "289f539dcc33814e",
                             "name": "",
                             "rules": [
                                 {
                                     "t": "set",
                                     "p": "payload",
                                     "pt": "msg",
                                     "to": "payload.SDM630.Total",
                                     "tot": "msg"
                                 }
                             ],
                             "action": "",
                             "property": "",
                             "from": "",
                             "to": "",
                             "reg": false,
                             "x": 430,
                             "y": 4340,
                             "wires": [
                                 [
                                     "c9e73544e1bfa520",
                                     "680cd23566aafb30"
                                 ]
                             ]
                         },
                         {
                             "id": "680cd23566aafb30",
                             "type": "debug",
                             "z": "289f539dcc33814e",
                             "name": "Total",
                             "active": true,
                             "tosidebar": true,
                             "console": false,
                             "tostatus": false,
                             "complete": "payload",
                             "targetType": "msg",
                             "statusVal": "",
                             "statusType": "auto",
                             "x": 630,
                             "y": 4380,
                             "wires": []
                         },
                         {
                             "id": "57f13d6f733e5c9d",
                             "type": "ui_group",
                             "name": "Test",
                             "tab": "20b3095113f94d70",
                             "order": 2,
                             "disp": true,
                             "width": "6",
                             "collapse": false,
                             "className": ""
                         },
                         {
                             "id": "20b3095113f94d70",
                             "type": "ui_tab",
                             "name": "Home",
                             "icon": "dashboard",
                             "order": 1,
                             "disabled": false,
                             "hidden": false
                         }
                      ]
                      

                      R Offline
                      R Offline
                      rieders
                      schrieb am zuletzt editiert von rieders
                      #22

                      Vielen Dank für die Hilfe.

                      Das Auslesen funktioniert super.
                      Ich weiß nur nicht wie du aus dem debug2 den Pfad ausgelesen hast, bei mir sieht das ganz anders aus.

                      Screenshot 2023-01-13 182121.png

                      Jetzt kann ich die Daten an Venus OS übergeben und hoffentlich als virtualen Zähler sehen.

                      mickymM 1 Antwort Letzte Antwort
                      0
                      • R rieders

                        Vielen Dank für die Hilfe.

                        Das Auslesen funktioniert super.
                        Ich weiß nur nicht wie du aus dem debug2 den Pfad ausgelesen hast, bei mir sieht das ganz anders aus.

                        Screenshot 2023-01-13 182121.png

                        Jetzt kann ich die Daten an Venus OS übergeben und hoffentlich als virtualen Zähler sehen.

                        mickymM Offline
                        mickymM Offline
                        mickym
                        Most Active
                        schrieb am zuletzt editiert von mickym
                        #23

                        @rieders Hab ich gar nicht, da ich deinen Flow ja nicht importieren konnte (nicht in CodeTags), aber Du hast ja die Daten zum Glück bzw. das Objekt gepostet und so habe ich es einfach in die Inject Node geschrieben. Du kannst übrigens direkt in ein Objekt wandeln lassen, dann kannst du das direkt nach der mqtt-In Node machen, in dem Du Dir ein analysiertes Objekt ausgeben lässt.

                        0784168f-bbda-49ee-a717-c84130207778-image.png

                        Dann brauchst nach der mqtt-In auch nichts mehr konvertieren.

                        Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                        frankthegreatF 1 Antwort Letzte Antwort
                        0
                        • mickymM mickym

                          @rieders Hab ich gar nicht, da ich deinen Flow ja nicht importieren konnte (nicht in CodeTags), aber Du hast ja die Daten zum Glück bzw. das Objekt gepostet und so habe ich es einfach in die Inject Node geschrieben. Du kannst übrigens direkt in ein Objekt wandeln lassen, dann kannst du das direkt nach der mqtt-In Node machen, in dem Du Dir ein analysiertes Objekt ausgeben lässt.

                          0784168f-bbda-49ee-a717-c84130207778-image.png

                          Dann brauchst nach der mqtt-In auch nichts mehr konvertieren.

                          frankthegreatF Offline
                          frankthegreatF Offline
                          frankthegreat
                          schrieb am zuletzt editiert von
                          #24

                          @mickym
                          Sorry, das ich mich hier mit ranhänge. Mein Problem ist denk mal ähnlich.
                          Ich möchte relatives Dimmen von KNX auf Zigbee umsetzen.
                          Dazu müßte wohl auch der Payload zerlegt werden :thinking_face:

                          Hier die Ausgaben vom KNX.

                          Taster ist gedrückt und soll runterdimmen:

                          {"topic":"1/4/26","devicename":"","payload":{"decr_incr":0,"data":1},"payloadmeasureunit":"unknown","payloadsubtypevalue":"unknown","knx":{"event":"GroupValue_Write","dpt":"3.007","dptdesc":"Dimming control","source":"1.1.4","destination":"1/4/26","rawValue":[1]},"previouspayload":{"decr_incr":0,"data":0},"_msgid":"34735868e6770bd1"}
                          

                          Taster losgelassen, dimmen soll stoppen:

                          {"topic":"1/4/26","devicename":"","payload":{"decr_incr":0,"data":0},"payloadmeasureunit":"unknown","payloadsubtypevalue":"unknown","knx":{"event":"GroupValue_Write","dpt":"3.007","dptdesc":"Dimming control","source":"1.1.4","destination":"1/4/26","rawValue":[0]},"previouspayload":{"decr_incr":0,"data":1},"_msgid":"a4982ca3e5461702"}
                          

                          Taster ist gedrückt und soll hochdimmen:

                          {"topic":"1/4/26","devicename":"","payload":{"decr_incr":1,"data":1},"payloadmeasureunit":"unknown","payloadsubtypevalue":"unknown","knx":{"event":"GroupValue_Write","dpt":"3.007","dptdesc":"Dimming control","source":"1.1.4","destination":"1/4/26","rawValue":[9]},"previouspayload":{"decr_incr":0,"data":0},"_msgid":"12ada754ecbda05f"}
                          

                          Taster losgelassen, dimmen soll stoppen:

                          {"topic":"1/4/26","devicename":"","payload":{"decr_incr":0,"data":0},"payloadmeasureunit":"unknown","payloadsubtypevalue":"unknown","knx":{"event":"GroupValue_Write","dpt":"3.007","dptdesc":"Dimming control","source":"1.1.4","destination":"1/4/26","rawValue":[0]},"previouspayload":{"decr_incr":1,"data":1},"_msgid":"dabb632a5c74b60d"}
                          

                          Änderungen sehe ich hier jeweils bei :
                          {"decr_incr":x,"data":x}

                          Die Befehle für die Zigbee Leuchtmittel hab ich getestet, bei direktem schicken auf den DP funktionieren die schonmal.
                          z.B.
                          hochdimmen={"brightness_move": 40}
                          runterdimmen={"brightness_move": -40}
                          stoppen={"brightness_move": 0}

                          Hab schon etliche Stunden mit der "Change" Node rumprobiert, allerdings ohne Erfolg :disappointed:

                          Wie muß ich vorgehen, um die KNX Befehle auf Zigbee umzusetzen?

                          1 Antwort Letzte Antwort
                          0
                          • mickymM Offline
                            mickymM Offline
                            mickym
                            Most Active
                            schrieb am zuletzt editiert von mickym
                            #25

                            @frankthegreat Na ja - da ist noch etwas mehr Logik im Spiel und das muss man sich trotz aller Flows genau überlegen. Ich hab ja mal einen softdimmer ähnlich mit einem vis Widget erstellt.

                            das mit dem hoch und runter Dimmen - kann man grundsätzlich mit mehreren Arten machen wahrscheinlich gibts den brightness Datenpunkt im Zigbee auch als absolute Werte. Move geht auch und vereinfacht das Ganze wohl eher.

                            33b2febe-49b6-4bd0-ae21-f25077572712-image.png

                            Im Prinzip, wenn es sich so darstellt, dann wäre

                            data: 1 immer gedrückt = dimmen
                            data: 0 immer losgelassen = stoppen

                            decr_incr: 1 bei data 1 = hochdimmen
                            decr_incr: 0 bei data 1 = runterdimmen.

                            Da wir immer stoppen egal wie gerade gedimmt wurde, ist uns egal welchen Zustand das Teil vorher hatte. Auf dieser Basis probieren wird das mal - kleinen Moment. ;)

                            So müsste das jetzt mal quick & dirty funktionieren:

                            5c24f2bb-adcb-4f19-af60-07cff983bff9-image.png

                            Statt der Inject Node halt Deine KNX Nodes dran machen und hinten halt in den brightness_move Datenpunkt ausgeben.

                            [
                               {
                                   "id": "65b061e782f70ac9",
                                   "type": "inject",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim down",
                                   "props": [
                                       {
                                           "p": "payload"
                                       }
                                   ],
                                   "repeat": "",
                                   "crontab": "",
                                   "once": false,
                                   "onceDelay": 0.1,
                                   "topic": "",
                                   "payload": "{\"decr_incr\":0,\"data\":1}",
                                   "payloadType": "json",
                                   "x": 340,
                                   "y": 140,
                                   "wires": [
                                       [
                                           "240e3279819f0eae"
                                       ]
                                   ]
                               },
                               {
                                   "id": "2e68f247a519c9b3",
                                   "type": "inject",
                                   "z": "f71771fc316ba18f",
                                   "name": "stop",
                                   "props": [
                                       {
                                           "p": "payload"
                                       }
                                   ],
                                   "repeat": "",
                                   "crontab": "",
                                   "once": false,
                                   "onceDelay": 0.1,
                                   "topic": "",
                                   "payload": "{\"decr_incr\":0,\"data\":0}",
                                   "payloadType": "json",
                                   "x": 350,
                                   "y": 220,
                                   "wires": [
                                       [
                                           "240e3279819f0eae"
                                       ]
                                   ]
                               },
                               {
                                   "id": "7efd5166901d779b",
                                   "type": "inject",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim up",
                                   "props": [
                                       {
                                           "p": "payload"
                                       }
                                   ],
                                   "repeat": "",
                                   "crontab": "",
                                   "once": false,
                                   "onceDelay": 0.1,
                                   "topic": "",
                                   "payload": "{\"decr_incr\":1,\"data\":1}",
                                   "payloadType": "json",
                                   "x": 350,
                                   "y": 180,
                                   "wires": [
                                       [
                                           "240e3279819f0eae"
                                       ]
                                   ]
                               },
                               {
                                   "id": "240e3279819f0eae",
                                   "type": "switch",
                                   "z": "f71771fc316ba18f",
                                   "name": "",
                                   "property": "payload.data",
                                   "propertyType": "msg",
                                   "rules": [
                                       {
                                           "t": "eq",
                                           "v": "0",
                                           "vt": "num"
                                       },
                                       {
                                           "t": "eq",
                                           "v": "1",
                                           "vt": "num"
                                       }
                                   ],
                                   "checkall": "true",
                                   "repair": false,
                                   "outputs": 2,
                                   "x": 530,
                                   "y": 180,
                                   "wires": [
                                       [
                                           "2e23dae4976566fd"
                                       ],
                                       [
                                           "2e5b171c27e7e26a"
                                       ]
                                   ]
                               },
                               {
                                   "id": "2e23dae4976566fd",
                                   "type": "change",
                                   "z": "f71771fc316ba18f",
                                   "name": "stop dimming",
                                   "rules": [
                                       {
                                           "t": "set",
                                           "p": "payload",
                                           "pt": "msg",
                                           "to": "0",
                                           "tot": "num"
                                       }
                                   ],
                                   "action": "",
                                   "property": "",
                                   "from": "",
                                   "to": "",
                                   "reg": false,
                                   "x": 830,
                                   "y": 160,
                                   "wires": [
                                       [
                                           "26db997e0e9ac3b2"
                                       ]
                                   ]
                               },
                               {
                                   "id": "2e5b171c27e7e26a",
                                   "type": "switch",
                                   "z": "f71771fc316ba18f",
                                   "name": "",
                                   "property": "payload.decr_incr",
                                   "propertyType": "msg",
                                   "rules": [
                                       {
                                           "t": "eq",
                                           "v": "0",
                                           "vt": "num"
                                       },
                                       {
                                           "t": "eq",
                                           "v": "1",
                                           "vt": "num"
                                       }
                                   ],
                                   "checkall": "true",
                                   "repair": false,
                                   "outputs": 2,
                                   "x": 670,
                                   "y": 220,
                                   "wires": [
                                       [
                                           "75612c32dc30ca8a"
                                       ],
                                       [
                                           "28f8664528857291"
                                       ]
                                   ],
                                   "outputLabels": [
                                       "dim down",
                                       "dim up"
                                   ]
                               },
                               {
                                   "id": "75612c32dc30ca8a",
                                   "type": "change",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim down",
                                   "rules": [
                                       {
                                           "t": "set",
                                           "p": "payload",
                                           "pt": "msg",
                                           "to": "-40",
                                           "tot": "num"
                                       }
                                   ],
                                   "action": "",
                                   "property": "",
                                   "from": "",
                                   "to": "",
                                   "reg": false,
                                   "x": 840,
                                   "y": 200,
                                   "wires": [
                                       [
                                           "26db997e0e9ac3b2"
                                       ]
                                   ]
                               },
                               {
                                   "id": "28f8664528857291",
                                   "type": "change",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim up",
                                   "rules": [
                                       {
                                           "t": "set",
                                           "p": "payload",
                                           "pt": "msg",
                                           "to": "40",
                                           "tot": "num"
                                       }
                                   ],
                                   "action": "",
                                   "property": "",
                                   "from": "",
                                   "to": "",
                                   "reg": false,
                                   "x": 850,
                                   "y": 240,
                                   "wires": [
                                       [
                                           "26db997e0e9ac3b2"
                                       ]
                                   ]
                               },
                               {
                                   "id": "26db997e0e9ac3b2",
                                   "type": "debug",
                                   "z": "f71771fc316ba18f",
                                   "name": "brightness move",
                                   "active": true,
                                   "tosidebar": true,
                                   "console": false,
                                   "tostatus": false,
                                   "complete": "payload",
                                   "targetType": "msg",
                                   "statusVal": "",
                                   "statusType": "auto",
                                   "x": 1040,
                                   "y": 200,
                                   "wires": []
                               }
                            ]
                            

                            Das geht auch mit einer switch Node - nur dann muss man halt JSONATA verwenden und bei der ersten Übereinstimmung stoppen - dafür schaut der Flow übersichtlicher aus.

                            60202c94-439b-4837-818e-f1e2536f5fd8-image.png

                            [
                               {
                                   "id": "9c42920aa2d032db",
                                   "type": "switch",
                                   "z": "f71771fc316ba18f",
                                   "name": "",
                                   "property": "payload",
                                   "propertyType": "msg",
                                   "rules": [
                                       {
                                           "t": "jsonata_exp",
                                           "v": "payload.data = 0",
                                           "vt": "jsonata"
                                       },
                                       {
                                           "t": "jsonata_exp",
                                           "v": "payload.decr_incr = 0",
                                           "vt": "jsonata"
                                       },
                                       {
                                           "t": "jsonata_exp",
                                           "v": "payload.decr_incr = 1",
                                           "vt": "jsonata"
                                       }
                                   ],
                                   "checkall": "false",
                                   "repair": false,
                                   "outputs": 3,
                                   "x": 670,
                                   "y": 380,
                                   "wires": [
                                       [
                                           "9b040f37641b3023"
                                       ],
                                       [
                                           "af3bf63193955ef5"
                                       ],
                                       [
                                           "fa5c8b6c4663ba2f"
                                       ]
                                   ]
                               },
                               {
                                   "id": "b20aff26a7c2e42c",
                                   "type": "inject",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim down",
                                   "props": [
                                       {
                                           "p": "payload"
                                       }
                                   ],
                                   "repeat": "",
                                   "crontab": "",
                                   "once": false,
                                   "onceDelay": 0.1,
                                   "topic": "",
                                   "payload": "{\"decr_incr\":0,\"data\":1}",
                                   "payloadType": "json",
                                   "x": 480,
                                   "y": 340,
                                   "wires": [
                                       [
                                           "9c42920aa2d032db"
                                       ]
                                   ]
                               },
                               {
                                   "id": "00cc24ce0bd3bc46",
                                   "type": "inject",
                                   "z": "f71771fc316ba18f",
                                   "name": "stop",
                                   "props": [
                                       {
                                           "p": "payload"
                                       }
                                   ],
                                   "repeat": "",
                                   "crontab": "",
                                   "once": false,
                                   "onceDelay": 0.1,
                                   "topic": "",
                                   "payload": "{\"decr_incr\":0,\"data\":0}",
                                   "payloadType": "json",
                                   "x": 490,
                                   "y": 420,
                                   "wires": [
                                       [
                                           "9c42920aa2d032db"
                                       ]
                                   ]
                               },
                               {
                                   "id": "291666bfb387eb09",
                                   "type": "inject",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim up",
                                   "props": [
                                       {
                                           "p": "payload"
                                       }
                                   ],
                                   "repeat": "",
                                   "crontab": "",
                                   "once": false,
                                   "onceDelay": 0.1,
                                   "topic": "",
                                   "payload": "{\"decr_incr\":1,\"data\":1}",
                                   "payloadType": "json",
                                   "x": 490,
                                   "y": 380,
                                   "wires": [
                                       [
                                           "9c42920aa2d032db"
                                       ]
                                   ]
                               },
                               {
                                   "id": "9b040f37641b3023",
                                   "type": "change",
                                   "z": "f71771fc316ba18f",
                                   "name": "stop dimming",
                                   "rules": [
                                       {
                                           "t": "set",
                                           "p": "payload",
                                           "pt": "msg",
                                           "to": "0",
                                           "tot": "num"
                                       }
                                   ],
                                   "action": "",
                                   "property": "",
                                   "from": "",
                                   "to": "",
                                   "reg": false,
                                   "x": 830,
                                   "y": 340,
                                   "wires": [
                                       [
                                           "f3660815c7c7b3df"
                                       ]
                                   ]
                               },
                               {
                                   "id": "af3bf63193955ef5",
                                   "type": "change",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim down",
                                   "rules": [
                                       {
                                           "t": "set",
                                           "p": "payload",
                                           "pt": "msg",
                                           "to": "-40",
                                           "tot": "num"
                                       }
                                   ],
                                   "action": "",
                                   "property": "",
                                   "from": "",
                                   "to": "",
                                   "reg": false,
                                   "x": 840,
                                   "y": 380,
                                   "wires": [
                                       [
                                           "f3660815c7c7b3df"
                                       ]
                                   ]
                               },
                               {
                                   "id": "fa5c8b6c4663ba2f",
                                   "type": "change",
                                   "z": "f71771fc316ba18f",
                                   "name": "dim up",
                                   "rules": [
                                       {
                                           "t": "set",
                                           "p": "payload",
                                           "pt": "msg",
                                           "to": "40",
                                           "tot": "num"
                                       }
                                   ],
                                   "action": "",
                                   "property": "",
                                   "from": "",
                                   "to": "",
                                   "reg": false,
                                   "x": 850,
                                   "y": 420,
                                   "wires": [
                                       [
                                           "f3660815c7c7b3df"
                                       ]
                                   ]
                               },
                               {
                                   "id": "f3660815c7c7b3df",
                                   "type": "debug",
                                   "z": "f71771fc316ba18f",
                                   "name": "brightness move",
                                   "active": true,
                                   "tosidebar": true,
                                   "console": false,
                                   "tostatus": false,
                                   "complete": "payload",
                                   "targetType": "msg",
                                   "statusVal": "",
                                   "statusType": "auto",
                                   "x": 1040,
                                   "y": 380,
                                   "wires": []
                               }
                            ]
                            

                            Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                            frankthegreatF 1 Antwort Letzte Antwort
                            1
                            • mickymM mickym

                              @frankthegreat Na ja - da ist noch etwas mehr Logik im Spiel und das muss man sich trotz aller Flows genau überlegen. Ich hab ja mal einen softdimmer ähnlich mit einem vis Widget erstellt.

                              das mit dem hoch und runter Dimmen - kann man grundsätzlich mit mehreren Arten machen wahrscheinlich gibts den brightness Datenpunkt im Zigbee auch als absolute Werte. Move geht auch und vereinfacht das Ganze wohl eher.

                              33b2febe-49b6-4bd0-ae21-f25077572712-image.png

                              Im Prinzip, wenn es sich so darstellt, dann wäre

                              data: 1 immer gedrückt = dimmen
                              data: 0 immer losgelassen = stoppen

                              decr_incr: 1 bei data 1 = hochdimmen
                              decr_incr: 0 bei data 1 = runterdimmen.

                              Da wir immer stoppen egal wie gerade gedimmt wurde, ist uns egal welchen Zustand das Teil vorher hatte. Auf dieser Basis probieren wird das mal - kleinen Moment. ;)

                              So müsste das jetzt mal quick & dirty funktionieren:

                              5c24f2bb-adcb-4f19-af60-07cff983bff9-image.png

                              Statt der Inject Node halt Deine KNX Nodes dran machen und hinten halt in den brightness_move Datenpunkt ausgeben.

                              [
                                 {
                                     "id": "65b061e782f70ac9",
                                     "type": "inject",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim down",
                                     "props": [
                                         {
                                             "p": "payload"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "payload": "{\"decr_incr\":0,\"data\":1}",
                                     "payloadType": "json",
                                     "x": 340,
                                     "y": 140,
                                     "wires": [
                                         [
                                             "240e3279819f0eae"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "2e68f247a519c9b3",
                                     "type": "inject",
                                     "z": "f71771fc316ba18f",
                                     "name": "stop",
                                     "props": [
                                         {
                                             "p": "payload"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "payload": "{\"decr_incr\":0,\"data\":0}",
                                     "payloadType": "json",
                                     "x": 350,
                                     "y": 220,
                                     "wires": [
                                         [
                                             "240e3279819f0eae"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "7efd5166901d779b",
                                     "type": "inject",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim up",
                                     "props": [
                                         {
                                             "p": "payload"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "payload": "{\"decr_incr\":1,\"data\":1}",
                                     "payloadType": "json",
                                     "x": 350,
                                     "y": 180,
                                     "wires": [
                                         [
                                             "240e3279819f0eae"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "240e3279819f0eae",
                                     "type": "switch",
                                     "z": "f71771fc316ba18f",
                                     "name": "",
                                     "property": "payload.data",
                                     "propertyType": "msg",
                                     "rules": [
                                         {
                                             "t": "eq",
                                             "v": "0",
                                             "vt": "num"
                                         },
                                         {
                                             "t": "eq",
                                             "v": "1",
                                             "vt": "num"
                                         }
                                     ],
                                     "checkall": "true",
                                     "repair": false,
                                     "outputs": 2,
                                     "x": 530,
                                     "y": 180,
                                     "wires": [
                                         [
                                             "2e23dae4976566fd"
                                         ],
                                         [
                                             "2e5b171c27e7e26a"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "2e23dae4976566fd",
                                     "type": "change",
                                     "z": "f71771fc316ba18f",
                                     "name": "stop dimming",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "0",
                                             "tot": "num"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 830,
                                     "y": 160,
                                     "wires": [
                                         [
                                             "26db997e0e9ac3b2"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "2e5b171c27e7e26a",
                                     "type": "switch",
                                     "z": "f71771fc316ba18f",
                                     "name": "",
                                     "property": "payload.decr_incr",
                                     "propertyType": "msg",
                                     "rules": [
                                         {
                                             "t": "eq",
                                             "v": "0",
                                             "vt": "num"
                                         },
                                         {
                                             "t": "eq",
                                             "v": "1",
                                             "vt": "num"
                                         }
                                     ],
                                     "checkall": "true",
                                     "repair": false,
                                     "outputs": 2,
                                     "x": 670,
                                     "y": 220,
                                     "wires": [
                                         [
                                             "75612c32dc30ca8a"
                                         ],
                                         [
                                             "28f8664528857291"
                                         ]
                                     ],
                                     "outputLabels": [
                                         "dim down",
                                         "dim up"
                                     ]
                                 },
                                 {
                                     "id": "75612c32dc30ca8a",
                                     "type": "change",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim down",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "-40",
                                             "tot": "num"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 840,
                                     "y": 200,
                                     "wires": [
                                         [
                                             "26db997e0e9ac3b2"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "28f8664528857291",
                                     "type": "change",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim up",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "40",
                                             "tot": "num"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 850,
                                     "y": 240,
                                     "wires": [
                                         [
                                             "26db997e0e9ac3b2"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "26db997e0e9ac3b2",
                                     "type": "debug",
                                     "z": "f71771fc316ba18f",
                                     "name": "brightness move",
                                     "active": true,
                                     "tosidebar": true,
                                     "console": false,
                                     "tostatus": false,
                                     "complete": "payload",
                                     "targetType": "msg",
                                     "statusVal": "",
                                     "statusType": "auto",
                                     "x": 1040,
                                     "y": 200,
                                     "wires": []
                                 }
                              ]
                              

                              Das geht auch mit einer switch Node - nur dann muss man halt JSONATA verwenden und bei der ersten Übereinstimmung stoppen - dafür schaut der Flow übersichtlicher aus.

                              60202c94-439b-4837-818e-f1e2536f5fd8-image.png

                              [
                                 {
                                     "id": "9c42920aa2d032db",
                                     "type": "switch",
                                     "z": "f71771fc316ba18f",
                                     "name": "",
                                     "property": "payload",
                                     "propertyType": "msg",
                                     "rules": [
                                         {
                                             "t": "jsonata_exp",
                                             "v": "payload.data = 0",
                                             "vt": "jsonata"
                                         },
                                         {
                                             "t": "jsonata_exp",
                                             "v": "payload.decr_incr = 0",
                                             "vt": "jsonata"
                                         },
                                         {
                                             "t": "jsonata_exp",
                                             "v": "payload.decr_incr = 1",
                                             "vt": "jsonata"
                                         }
                                     ],
                                     "checkall": "false",
                                     "repair": false,
                                     "outputs": 3,
                                     "x": 670,
                                     "y": 380,
                                     "wires": [
                                         [
                                             "9b040f37641b3023"
                                         ],
                                         [
                                             "af3bf63193955ef5"
                                         ],
                                         [
                                             "fa5c8b6c4663ba2f"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "b20aff26a7c2e42c",
                                     "type": "inject",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim down",
                                     "props": [
                                         {
                                             "p": "payload"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "payload": "{\"decr_incr\":0,\"data\":1}",
                                     "payloadType": "json",
                                     "x": 480,
                                     "y": 340,
                                     "wires": [
                                         [
                                             "9c42920aa2d032db"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "00cc24ce0bd3bc46",
                                     "type": "inject",
                                     "z": "f71771fc316ba18f",
                                     "name": "stop",
                                     "props": [
                                         {
                                             "p": "payload"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "payload": "{\"decr_incr\":0,\"data\":0}",
                                     "payloadType": "json",
                                     "x": 490,
                                     "y": 420,
                                     "wires": [
                                         [
                                             "9c42920aa2d032db"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "291666bfb387eb09",
                                     "type": "inject",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim up",
                                     "props": [
                                         {
                                             "p": "payload"
                                         }
                                     ],
                                     "repeat": "",
                                     "crontab": "",
                                     "once": false,
                                     "onceDelay": 0.1,
                                     "topic": "",
                                     "payload": "{\"decr_incr\":1,\"data\":1}",
                                     "payloadType": "json",
                                     "x": 490,
                                     "y": 380,
                                     "wires": [
                                         [
                                             "9c42920aa2d032db"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "9b040f37641b3023",
                                     "type": "change",
                                     "z": "f71771fc316ba18f",
                                     "name": "stop dimming",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "0",
                                             "tot": "num"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 830,
                                     "y": 340,
                                     "wires": [
                                         [
                                             "f3660815c7c7b3df"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "af3bf63193955ef5",
                                     "type": "change",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim down",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "-40",
                                             "tot": "num"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 840,
                                     "y": 380,
                                     "wires": [
                                         [
                                             "f3660815c7c7b3df"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "fa5c8b6c4663ba2f",
                                     "type": "change",
                                     "z": "f71771fc316ba18f",
                                     "name": "dim up",
                                     "rules": [
                                         {
                                             "t": "set",
                                             "p": "payload",
                                             "pt": "msg",
                                             "to": "40",
                                             "tot": "num"
                                         }
                                     ],
                                     "action": "",
                                     "property": "",
                                     "from": "",
                                     "to": "",
                                     "reg": false,
                                     "x": 850,
                                     "y": 420,
                                     "wires": [
                                         [
                                             "f3660815c7c7b3df"
                                         ]
                                     ]
                                 },
                                 {
                                     "id": "f3660815c7c7b3df",
                                     "type": "debug",
                                     "z": "f71771fc316ba18f",
                                     "name": "brightness move",
                                     "active": true,
                                     "tosidebar": true,
                                     "console": false,
                                     "tostatus": false,
                                     "complete": "payload",
                                     "targetType": "msg",
                                     "statusVal": "",
                                     "statusType": "auto",
                                     "x": 1040,
                                     "y": 380,
                                     "wires": []
                                 }
                              ]
                              

                              frankthegreatF Offline
                              frankthegreatF Offline
                              frankthegreat
                              schrieb am zuletzt editiert von
                              #26

                              @mickym
                              Jepp...und läuft auf Anhieb :clap:

                              Supi, danke dir. Abend gerettet.

                              Ich hatte hauptsächlich versucht in diesen DP zu schreiben. Da hatt's aber mit der Umwandlung nicht geklappt.

                              ad15c50f-f263-4207-8323-632d962d7a97-grafik.png

                              Aber so geht's natürlich auch.

                              Nochmal DANKE :+1:

                              1 Antwort Letzte Antwort
                              1
                              • R rieders

                                Hallo

                                Ich versuche gerade mein Stromzähler String zu zerlegen.
                                Eine Verbindung zum mqtt-Broker besteht, die Daten werden auch im Debug angezeigt.

                                Ich habe schon einiges Versuch, ich bekomme einfach nicht die Werte einzeln angezeigt.

                                Smartmeter_Garten/tele/SENSOR : msg.payload : string[643]
                                "{"Time":"2023-01-13T12:54:35","SDM630":{"1":178,"Voltage_P1":231.88,"Voltage_P2":231.5,"Voltage_P3":232.49,"Current_P1":0,"Current_P2":0.1,"Current_P3":0,"Power_P1":0,"Power_P2":22.35,"Power_P3":0,"Frequenz":50.01,"Total":534.694,"phase_angle":-9.73,"Import_nres":186.145,"Export_nres":348.549,"Export_P1":13.568,"Export_P2":334.981,"Export_P3":0,"Import_P1":19.409,"Import_P2":131.003,"Import_P3":35.733,"L1_total_kwh":32.977,"L2_total_kwh":465.984,"L3_total_kwh":35.733,"Blindleistung_L1":0,"Blindleistung_L2":-7.734,"Blindleistung_L3":0,"Scheinleistung_L1":0,"Scheinleistung_L2":22.627,"Scheinleistung_L3":0,"VAh_since_last_reset":565.815}}"

                                Screenshot 2023-01-13 130004.png

                                Ich hoffe jemand kann mir weiter helfen.


                                [
                                {
                                "id": "553525487db580b5",
                                "type": "mqtt in",
                                "z": "eb71b4cddc9da37a",
                                "name": "Smartmeter_Garten/tele/SENSOR",
                                "topic": "Smartmeter_Garten/tele/SENSOR",
                                "qos": "2",
                                "datatype": "auto-detect",
                                "broker": "e7e1e2255e66e588",
                                "nl": false,
                                "rap": true,
                                "rh": "2",
                                "inputs": 0,
                                "x": 180,
                                "y": 260,
                                "wires": [
                                [
                                "04a7ba72539a5cb1",
                                "df378652670347e0"
                                ]
                                ]
                                },
                                {
                                "id": "b0fcb45d6d8ab9f4",
                                "type": "ui_gauge",
                                "z": "eb71b4cddc9da37a",
                                "name": "Test",
                                "group": "67140eec2a9994a9",
                                "order": 0,
                                "width": 0,
                                "height": 0,
                                "gtype": "gage",
                                "title": "Voltage_P1",
                                "label": "",
                                "format": "{{Value}}",
                                "min": "1",
                                "max": "260",
                                "colors": [
                                "#b30000",
                                "#e6e600",
                                "#00b815"
                                ],
                                "seg1": "",
                                "seg2": "",
                                "x": 890,
                                "y": 260,
                                "wires": []
                                },
                                {
                                "id": "9faaac80e56b9d83",
                                "type": "ui_chart",
                                "z": "eb71b4cddc9da37a",
                                "name": "",
                                "group": "67140eec2a9994a9",
                                "order": 0,
                                "width": 0,
                                "height": 0,
                                "label": "chart",
                                "chartType": "line",
                                "legend": "false",
                                "xformat": "HH:mm:ss",
                                "interpolate": "linear",
                                "nodata": "",
                                "dot": false,
                                "ymin": "0",
                                "ymax": "260",
                                "removeOlder": 1,
                                "removeOlderPoints": "",
                                "removeOlderUnit": "3600",
                                "cutout": 0,
                                "useOneColor": false,
                                "useUTC": false,
                                "colors": [
                                "#1f77b4",
                                "#aec7e8",
                                "#ff7f0e",
                                "#2ca02c",
                                "#98df8a",
                                "#d62728",
                                "#ff9896",
                                "#9467bd",
                                "#c5b0d5"
                                ],
                                "outputs": 1,
                                "useDifferentColor": false,
                                "x": 890,
                                "y": 320,
                                "wires": [
                                []
                                ]
                                },
                                {
                                "id": "04a7ba72539a5cb1",
                                "type": "json",
                                "z": "eb71b4cddc9da37a",
                                "name": "V1",
                                "property": "payload",
                                "action": "",
                                "pretty": false,
                                "x": 450,
                                "y": 200,
                                "wires": [
                                [
                                "35354018b6c6c095",
                                "639599639f78788c"
                                ]
                                ]
                                },
                                {
                                "id": "6f72cb37f4aa2278",
                                "type": "debug",
                                "z": "eb71b4cddc9da37a",
                                "name": "debug 1",
                                "active": true,
                                "tosidebar": true,
                                "console": false,
                                "tostatus": false,
                                "complete": "payload",
                                "targetType": "msg",
                                "statusVal": "",
                                "statusType": "auto",
                                "x": 900,
                                "y": 200,
                                "wires": []
                                },
                                {
                                "id": "35354018b6c6c095",
                                "type": "debug",
                                "z": "eb71b4cddc9da37a",
                                "name": "debug 2",
                                "active": true,
                                "tosidebar": true,
                                "console": false,
                                "tostatus": false,
                                "complete": "payload",
                                "targetType": "msg",
                                "statusVal": "",
                                "statusType": "auto",
                                "x": 620,
                                "y": 120,
                                "wires": []
                                },
                                {
                                "id": "639599639f78788c",
                                "type": "change",
                                "z": "eb71b4cddc9da37a",
                                "name": "",
                                "rules": [
                                {
                                "t": "set",
                                "p": "payload",
                                "pt": "msg",
                                "to": "payload["SDM630"].Voltage_P1",
                                "tot": "msg"
                                }
                                ],
                                "action": "",
                                "property": "",
                                "from": "",
                                "to": "",
                                "reg": false,
                                "x": 670,
                                "y": 200,
                                "wires": [
                                [
                                "6f72cb37f4aa2278",
                                "b0fcb45d6d8ab9f4",
                                "9faaac80e56b9d83"
                                ]
                                ]
                                },
                                {
                                "id": "a5192d83b6ce2f1c",
                                "type": "mqtt out",
                                "z": "eb71b4cddc9da37a",
                                "name": "V1",
                                "topic": "Testzähler",
                                "qos": "",
                                "retain": "",
                                "respTopic": "",
                                "contentType": "",
                                "userProps": "",
                                "correl": "",
                                "expiry": "",
                                "broker": "d19896c9b4e98e28",
                                "x": 750,
                                "y": 340,
                                "wires": []
                                },
                                {
                                "id": "df378652670347e0",
                                "type": "function",
                                "z": "eb71b4cddc9da37a",
                                "name": "function 2",
                                "func": "\nreturn msg;payload["SDM630"].Voltage_P1",
                                "outputs": 1,
                                "noerr": 0,
                                "initialize": "",
                                "finalize": "",
                                "libs": [],
                                "x": 560,
                                "y": 340,
                                "wires": [
                                [
                                "a5192d83b6ce2f1c"
                                ]
                                ]
                                },
                                {
                                "id": "e7e1e2255e66e588",
                                "type": "mqtt-broker",
                                "name": "mqtt-broker",
                                "broker": "192.168.1.146",
                                "port": "1885",
                                "clientid": "",
                                "autoConnect": true,
                                "usetls": false,
                                "protocolVersion": "4",
                                "keepalive": "60",
                                "cleansession": true,
                                "birthTopic": "",
                                "birthQos": "0",
                                "birthPayload": "",
                                "birthMsg": {},
                                "closeTopic": "",
                                "closeQos": "0",
                                "closePayload": "",
                                "closeMsg": {},
                                "willTopic": "",
                                "willQos": "0",
                                "willPayload": "",
                                "willMsg": {},
                                "userProps": "",
                                "sessionExpiry": ""
                                },
                                {
                                "id": "67140eec2a9994a9",
                                "type": "ui_group",
                                "name": "Test",
                                "tab": "71f6d060a354b8d9",
                                "order": 1,
                                "disp": true,
                                "width": "6",
                                "collapse": false
                                },
                                {
                                "id": "d19896c9b4e98e28",
                                "type": "mqtt-broker",
                                "name": "Venus OS",
                                "broker": "192.168.1.37",
                                "port": "1883",
                                "clientid": "test-client",
                                "autoConnect": true,
                                "usetls": false,
                                "protocolVersion": "4",
                                "keepalive": "60",
                                "cleansession": true,
                                "birthTopic": "",
                                "birthQos": "0",
                                "birthPayload": "",
                                "birthMsg": {},
                                "closeTopic": "",
                                "closeQos": "0",
                                "closePayload": "",
                                "closeMsg": {},
                                "willTopic": "",
                                "willQos": "0",
                                "willPayload": "",
                                "willMsg": {},
                                "userProps": "",
                                "sessionExpiry": ""
                                },
                                {
                                "id": "71f6d060a354b8d9",
                                "type": "ui_tab",
                                "name": "Home",
                                "icon": "dashboard",
                                "disabled": false,
                                "hidden": false
                                }
                                ]

                                Grüße André

                                1 Offline
                                1 Offline
                                1984chris
                                schrieb am zuletzt editiert von
                                #27

                                @rieders @rieders Hallo Ich habe das gleiche Problem wie du

                                ![0_1684256284880_ausgabe.jpg](Uploading 100%)

                                konntest du das wie in Debug2 darstellen?
                                DANKE im Voraus

                                LG Christoph

                                1 1 Antwort Letzte Antwort
                                0
                                • 1 1984chris

                                  @rieders @rieders Hallo Ich habe das gleiche Problem wie du

                                  ![0_1684256284880_ausgabe.jpg](Uploading 100%)

                                  konntest du das wie in Debug2 darstellen?
                                  DANKE im Voraus

                                  LG Christoph

                                  1 Offline
                                  1 Offline
                                  1984chris
                                  schrieb am zuletzt editiert von
                                  #28

                                  @1984chris ausgabe.jpg

                                  1 mickymM 2 Antworten Letzte Antwort
                                  0
                                  • 1 1984chris

                                    @1984chris ausgabe.jpg

                                    1 Offline
                                    1 Offline
                                    1984chris
                                    schrieb am zuletzt editiert von
                                    #29

                                    @1984chris ich will die einzelnen Werte L1,L2,L3 Ströme A_L1,A_l2 usw an die influxDB übertragen

                                    mickymM 1 Antwort Letzte Antwort
                                    0
                                    • 1 1984chris

                                      @1984chris ausgabe.jpg

                                      mickymM Offline
                                      mickymM Offline
                                      mickym
                                      Most Active
                                      schrieb am zuletzt editiert von
                                      #30

                                      @1984chris Wenn ich Dir helfen soll, dann solltest Du den Wert in die Zwischenablage kopieren und hier in Codetags einbetten.

                                      Dann woher hast Du das - kommt das aus einer iobroker IN Node oder aus einer mqtt Node?

                                      Willst Du alle Werte in einzelne Datenpunkte zerlegen oder nur einzelne Werte extrahieren und weiter verarbeiten?
                                      Einzelne Werte kopierst Du in die Zwischenablage in dem Du mit der Maul im Debug Fenster neben den Wert fährst.

                                      copy path.gif

                                      Wenn Du es in der Zwischenablage hast, dann kopierst Du es bitte in Code-Tags wie hier dargestellt:

                                      Code-Tags.gif

                                      Und wie gesagt - wer es nett, wenn Du ein paar Zeilen dazu schreiben möchtest, was Du möchtest

                                      Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                                      1 Antwort Letzte Antwort
                                      0
                                      • 1 1984chris

                                        @1984chris ich will die einzelnen Werte L1,L2,L3 Ströme A_L1,A_l2 usw an die influxDB übertragen

                                        mickymM Offline
                                        mickymM Offline
                                        mickym
                                        Most Active
                                        schrieb am zuletzt editiert von mickym
                                        #31

                                        @1984chris sagte in Payload String zerlegen:

                                        @1984chris ich will die einzelnen Werte L1,L2,L3 Ströme A_L1,A_l2 usw an die influxDB übertragen

                                        Dann wäre es wohl sinnvoll einzelne Werte zu erstellen, dann empfehle ich Dir meinen Flow - der den ganzen JSON in einzelne Datenpunkte schreibt:

                                        https://forum.iobroker.net/topic/43856/json-oder-javascript-objekt-in-iobroker-datenpunkte-zerlegen

                                        Dann brauchst Du nur diesen Flow zu importieren.

                                        Im 1. Post ist eigentlich alles beschrieben und welche Einstellungen Du machen willst. Falls Du noch Fragen hast, dann gerne. Also hängt davon ab, ob Du nur ein paar Werte haben willst oder alle Werte einzeln haben möchtest.

                                        Jeder Flow bzw. jedes Script, das ich hier poste implementiert jeder auf eigene Gefahr. Flows und Scripts können Fehler aufweisen und weder der Seitenbetreiber noch ich persönlich können hierfür haftbar gemacht werden. Das gleiche gilt für Empfehlungen aller Art.

                                        1 1 Antwort Letzte Antwort
                                        0
                                        • mickymM mickym

                                          @1984chris sagte in Payload String zerlegen:

                                          @1984chris ich will die einzelnen Werte L1,L2,L3 Ströme A_L1,A_l2 usw an die influxDB übertragen

                                          Dann wäre es wohl sinnvoll einzelne Werte zu erstellen, dann empfehle ich Dir meinen Flow - der den ganzen JSON in einzelne Datenpunkte schreibt:

                                          https://forum.iobroker.net/topic/43856/json-oder-javascript-objekt-in-iobroker-datenpunkte-zerlegen

                                          Dann brauchst Du nur diesen Flow zu importieren.

                                          Im 1. Post ist eigentlich alles beschrieben und welche Einstellungen Du machen willst. Falls Du noch Fragen hast, dann gerne. Also hängt davon ab, ob Du nur ein paar Werte haben willst oder alle Werte einzeln haben möchtest.

                                          1 Offline
                                          1 Offline
                                          1984chris
                                          schrieb am zuletzt editiert von
                                          #32

                                          @mickym ```

                                          {"Time":"2023-05-16T19:45:29","Tagstrom":{"V_L1":233,"V_L3":236,"V_L3":236,"A_L1":0.63,"A_L2":2.33,"A_L3":0.32,"W_IN":590,"W_OUT":0,"kWh_total_IN":19147.756,"kWh_total_OUT":776.383},"WäPu":{"V_L1":232,"V_L3":236,"V_L3":235,"A_L1":0.48,"A_L2":0.00,"A_L3":0.02,"W_IN":112,"W_OUT":0,"kWh_total_IN":21698.535,"kWh_total_OUT":0.000}}
                                          

                                          die Daten kommen von einenm Nodred in mqtt ich bekomme das auf der Debugseite nicht so angezeigt wie du im Beispiel. Will die einzelnen Werte dan in eine influxDB und weiter mit GRAFANA....

                                          mickymM 2 Antworten Letzte Antwort
                                          0
                                          Antworten
                                          • In einem neuen Thema antworten
                                          Anmelden zum Antworten
                                          • Älteste zuerst
                                          • Neuste zuerst
                                          • Meiste Stimmen


                                          Support us

                                          ioBroker
                                          Community Adapters
                                          Donate

                                          412

                                          Online

                                          32.5k

                                          Benutzer

                                          81.7k

                                          Themen

                                          1.3m

                                          Beiträge
                                          Community
                                          Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen | Einwilligungseinstellungen
                                          ioBroker Community 2014-2025
                                          logo
                                          • Anmelden

                                          • Du hast noch kein Konto? Registrieren

                                          • Anmelden oder registrieren, um zu suchen
                                          • Erster Beitrag
                                            Letzter Beitrag
                                          0
                                          • Home
                                          • Aktuell
                                          • Tags
                                          • Ungelesen 0
                                          • Kategorien
                                          • Unreplied
                                          • Beliebt
                                          • GitHub
                                          • Docu
                                          • Hilfe