mruettgers / SMLReader

ESP8266 based smart meter (SML) to MQTT gateway
GNU General Public License v3.0
289 stars 67 forks source link

JSON Value Support #53

Open GreyPenguin opened 1 year ago

GreyPenguin commented 1 year ago

Instead of writing the value for each sensor type, is it possible to produce one single json output? The MQTT traffic will be less by the factor of sensors and parsing will also easier MB-Monty ➜ ~ mosquitto_sub -h 10.4.32.103 -v -t smartmeter/mains/# smartmeter/mains/info Hello from 00C7551E, running SMLReader version 2.1.5. smartmeter/mains/sensor { "sensors": { "sensor": [ { "id": "1", "1-0:1.8.0": "3546245.9", "1-0:2.8.0": "13.2", "1-0:1.8.1": "0.0", "1-0:2.8.1": "13.2", "1-0:1.8.2": "3546245.9", "1-0:2.8.2": "0.0", "1-0:16.7.0": "451.2" }, { "id": "2", "1-0:1.8.0": "3546245.9", "1-0:2.8.0": "13.2", "1-0:1.8.1": "0.0", "1-0:2.8.1": "13.2", "1-0:1.8.2": "3546245.9", "1-0:2.8.2": "0.0", "1-0:16.7.0": "451.2" } ] } }