You could use MQTT Auto Discovery and create config objects for the shelly MQTT outputs
For example:
homeassistant/sensor/shellyem-1-0/power/config
Code: Select all
{
"dev": {
"ids": [
"485519DABF59"
]
},
"name": "shellyem-1 Power 0 R",
"stat_t": "~emeter/0/power",
"avty_t": "~online",
"pl_avail": "true",
"pl_not_avail": "false",
"enabled_by_default": true,
"uniq_id": "485519DABF59_0_power",
"qos": 0,
"~": "shellies/shellyem-1/",
"dev_cla": "power",
"stat_cla": "measurement",
"unit_of_meas": "W",
"val_tpl": "{{value|float|round(1)}}"
}
homeassistant/sensor/shellyem-1-0/total/config
Code: Select all
{
"dev": {
"ids": [
"485519DABF592"
]
},
"name": "shellyem-1 Total 0",
"stat_t": "~emeter/0/total",
"avty_t": "~online",
"pl_avail": "true",
"pl_not_avail": "false",
"enabled_by_default": true,
"uniq_id": "485519DABF592_0_total",
"qos": 0,
"~": "shellies/shellyem-1/",
"dev_cla": "energy",
"la_te": true,
"stat_cla": "total_increasing",
"unit_of_meas": "Wh",
"val_tpl": "{{value|round(2)}}"
}
Make sure all id's are unique and you group the power/usage like above
Example for the voltage
homeassistant/sensor/shellyem-1-0/voltage/config
Code: Select all
{
"dev": {
"ids": [
"485519DABF59"
]
},
"name": "shellyem-1 Voltage 0",
"stat_t": "~emeter/0/voltage",
"enabled_by_default": true,
"uniq_id": "485519DABF59_0_voltage",
"qos": 0,
"~": "shellies/shellyem-1/",
"dev_cla": "voltage",
"stat_cla": "measurement",
"unit_of_meas": "V",
"val_tpl": "{{value|float|round(1)}}",
"avty_t": "~online",
"pl_avail": "true",
"pl_not_avail": "false"
}
I am using a application called MQTT Explorer.
Make sure the config objects you publish with the 'retain' topic set, so the will always be there
Once they are in Domoticz you should get monthly year graphs/reports
Once you have all 3 phases in Domoticz, you could create a script that generates a P1 Meter from these values