question

remco-de-g avatar image
remco-de-g asked

Energy meter with MQTT to Venus OS

I have a domoticz system which reads data from a grid meter. Would it be possible to send the data from domoticz with MQTT to Venus OS and create a 'virtual' energy meter.

If possible does someone has an example on how to do this?

Venus OSMQTT
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

4 Answers
matt1309 avatar image
matt1309 answered ·
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

gerard-van-seventer avatar image
gerard-van-seventer answered ·

This is doable, in fact I am going to do the same. I assume looking at your name you have (D)SMR.

The point is that Domoticz shows the "usage" separate from the "delivery". I'm having a DSMR5, so it spits out the whole telegram every second. Telling Domotics to dump this on the mqtt broker is quit some traffic. Not the greatest problem but you must realise this.

I'm thinking to call the Domoticz API and read the "usage" and "return" and present this as one value (usage-return) to the Victron system.

The logic could be done in the Python code on the Victron system. Not too difficult but it takes some time to do.


--Gerard

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

remco-de-g avatar image
remco-de-g answered ·

I also found this project Generic driver for MQTT devices using dbus-mqtt (dbus-mqtt-devices) - Victron Community (victronenergy.com)

I now have it working with node-red on venus os which connects to domoticz through mqtt.

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

gerard-van-seventer avatar image
gerard-van-seventer answered ·

Yeah, there are many such projects. At the moment I have a Shelly EM3 measuring L1 and another PV inverter on AC-in (Enphase) and a little piece of code to use it as an external meter and adding the Enphase PV to the VRM.

In hindsight I think adding Domoticz is not a good idea. It might be better to use a P1 interface to MQTT and from there report to the Victron dbus.

Too many options :-)

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

Related Resources