Das sendet mein Stromzähler
Code: Alles auswählen
20:01:35 MQT: Keller/stromzahl/tele/STATE = {"Time":"2020-09-02T20:01:35","Uptime":"0T00:40:04","UptimeSec":2404,"Heap":23,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":19,"MqttCount":1,"Wifi":{"AP":1,"SSId":"FRITZ!Box Fon WLAN 7390","BSSId":"FC:EC:DA:A7:37:8C","Channel":11,"RSSI":50,"Signal":-75,"LinkCount":1,"Downtime":"0T00:00:03"}}
20:01:35 MQT: Keller/stromzahl/tele/SENSOR = {"Time":"2020-09-02T20:01:35","":{" Meter_number":"1EBZ0100558022","Total_in":1084.1563,"Power_curr":601,"LeistungL1":342.93,"LeistungL2":98.69,"LeistungL3":159.67}"Verbrauch Tag":1084.156 KWh,"Verbrauch Vortag":0.000 KWh}
Things
Code: Alles auswählen
Thing topic Stromzaehler "Stromzähler"(mqtt:broker:mosquitto) @ "MQTT" {
Channels:
Type string : wifi-rssi "Stromzähler RSSI"
[stateTopic="Keller/stromzahl/tele/STATE",transformationPattern="JSONPATH:$.Wifi.RSSI"]
Type string : devicestate"Stromzähler State"
[stateTopic="Keller/stromzahl/tele/LWT"]
Type string : devicestatet"Stromzähler Verbrauch Tag"
[stateTopic="Keller/stromzahl/tele/SENSOR",transformationPattern="JSONPATH:$..Verbrauch Tag"]
Type string : devicestatevt"Stromzähler Verbrauch VorTag"
[stateTopic="Keller/stromzahl/tele/SENSOR",transformationPattern="JSONPATH:$..Verbrauch Vortag"]
Type string : devicestateg"Stromzähler Anzeige"
[stateTopic="Keller/stromzahl/tele/SENSOR",transformationPattern="JSONPATH:$..Total_in"]
}
Code: Alles auswählen
String Stromzaeler_WifiRssi "Wemosklingel RSSI [%d %%] " <network> {channel="mqtt:topic:mosquitto:Stromzaehler:wifi-rssi"}
String Stromzaeler_DeviceState "Verbrauch Tag" <qualityofservice> {channel="mqtt:topic:mosquitto:Stromzaehler:devicestatet"}
String Stromzaeler_DeviceState1 "Verbrauch Vortag" <qualityofservice> {channel="mqtt:topic:mosquitto:Stromzaehler:devicestatevt"}
String Stromzaeler_DeviceStateA "Anzeige" <qualityofservice> {channel="mqtt:topic:mosquitto:Stromzaehler:devicestateg"}