Inhalt des Readings auswerten

Begonnen von spel, 28 November 2018, 19:32:11

Vorheriges Thema - Nächstes Thema

spel

Hallo,

ich bekomme es mal wieder nicht hin:

Printing {"progress": 51, "_timestamp": 1543429775, "location": "local", "path": "test.gcode"}

Ich möchte das Reading "Printing" auf die Werte 0-100% (progress) hin auswerten. Bekomme es nicht hin.

Also wenn progress vom Printing 95 = dann möchte ich ein notify machen...

Danke

CoolTux

Zeig mal bitte ein list vom Device welches das Reading enthält.

Du kannst mittels ReadingsVal den Inhalt des Readings auslesen, musst diesen aber definitiv noch bearbieten. Eventuell hilft hier ein Userreading weiter.
Du musst nicht wissen wie es geht! Du musst nur wissen wo es steht, wie es geht.
Support me to buy new test hardware for development: https://www.paypal.com/paypalme/MOldenburg
My FHEM Git: https://git.cooltux.net/FHEM/
Das TuxNet Wiki:
https://www.cooltux.net

spel

Internals:
   IODev      myMQTT
   NAME       3DDrucker
   NR         708
   STATE      ???
   TYPE       MQTT_DEVICE
   READINGS:
     2018-11-27 22:14:48   Disconnected    {"_event": "Disconnected", "_timestamp": 1543353288}
     2018-11-28 19:51:42   Druckbett       {"_timestamp": 1543431102, "actual": 44.52, "target": 0.0}
     2018-11-07 20:32:16   Error           {"_timestamp": 1541619136, "reason": "autodetect_port", "_event": "Error", "error": "Failed to autodetect serial port, please set it manually."}
     2018-11-28 19:51:42   Hotend          {"_timestamp": 1543431102, "actual": 198.31, "target": 0.0}
     2018-11-27 12:14:58   MQTT            disconnected
     2018-11-28 19:51:28   Printing        {"progress": 100, "_timestamp": 1543431088, "location": "local", "path": "test.gcode"}

CoolTux

Da gibt es glaube ein Modul oder eine Funktion welche dir daraus einzelne Readings macht. Müssen wir beide mal hier die Suche bemühen.
Du musst nicht wissen wie es geht! Du musst nur wissen wo es steht, wie es geht.
Support me to buy new test hardware for development: https://www.paypal.com/paypalme/MOldenburg
My FHEM Git: https://git.cooltux.net/FHEM/
Das TuxNet Wiki:
https://www.cooltux.net

CoolTux

Du musst nicht wissen wie es geht! Du musst nur wissen wo es steht, wie es geht.
Support me to buy new test hardware for development: https://www.paypal.com/paypalme/MOldenburg
My FHEM Git: https://git.cooltux.net/FHEM/
Das TuxNet Wiki:
https://www.cooltux.net

spel