Home Assistant Community

Energy sensors

#1

Hi there!

My electric company is offering me to install Mirubox (https://mirubee.com/) at home to have some telemetry on the electricity consumption.

Mirubox si something not supported (yet) in HASS but I was wondering what are the solutions in use by the people here.

what are you guys using? Sense?

#2

For whole house energy consumption monitoring, I have two PZEM-016 sensors, one clamped on each leg my split phase power feed coming into my breaker panel. These devices are modbus, which is supported natively by Home Assistant. I purchased one of the PZEMs with an included RS458->USB converter to poll the modbus nodes within home assistant.

I can give more details if anyone is interested, but it’s a pretty uncomplicated installation.

#3

Please do, looking at doing the same thing. Have 2 200A services into the house as well as a 100A from a generator.

#4

So, I have two PZEM-016s, I have the one CT from each clamped into the main incoming feed in my breaker box.
I have the CT wires extended so I can place the PZEM outside my breaker box. I then have them both plugged into an outlet in the vicinity.

I have a modbus loop going from one, to the other, then to a RS485->USB converted plugged into my HA server (as a daisy chain).

From there, the modbus component is used to pull in the sensor data from each register.

The modbus RTU component seems to have some timing issues at the moment, so it creates a pretty noisy log, but it never seems to actually create any issues in the data that gets read in.

This is the data I’m getting in HA, and I’m also logging/graphing it with InfluxDB & Grafana.

If you have any specific questions about any of it, let me know.

#5

Hi there;

Any update on this project? I saw you mention you are now using a RS485 to TCP/IP modbus gateway?

Can you comment on that part as my electrical panels are in a utility room that does have a ethernet switch; but not a physical host.

So I was hoping to daisy chain 6 of the PZEM-16 off the modbus to monitor 2 200A dual phase panels; as well as a generator panel.

Then take that modbus into the gateway; and ethernet from that to the HA modbus component.

As much detail as you can give me would be great :wink:

#6

I’ll assume this was directed at me, but if not just ignore it lol

No real updates, It’s been working great for months so I haven’t touched it much lol.

I saw you mention you are now using a RS485 to TCP/IP modbus gateway?

Yes, I’m now using a USR-W610 bridge to take the RS485 signal to Modbus TCP/IP over wifi. The USR-W610 can do a lot actually, with RS232 or RS485, WiFi or ethernet, etc, but I’m keeping it simple in my setup.

an you comment on that part as my electrical panels are in a utility room that does have a ethernet switch; but not a physical host.
So I was hoping to daisy chain 6 of the PZEM-16 off the modbus to monitor […]

If you have wifi there, you could use the W610 to take in the serial signal and let HA consume it over the network. Daisy chaining modbus isnt a problem. The PZEM-16s all come from the factory with the same node address, so I would recommend using a USB<->serial adapter (RS485) to connect it to your laptop and change the node address on each one to be unique. It’s not too difficult and the PZEM manual actually does a decent job explaining the register map.

Ha, I’m not sure how much detail there is!
I have 2 PZEM-016s, which I configured separately to have unique node addresses. Each with a split core CT over one of the incoming phases. The modbus connection of one is daisy chained to the second, which is chained to the USR-W610’s RS485 port. The W610 is connected to my WiFi network. Home Assistant is configured to read the W610’s IP address as a modbus TCP/IP node. This is the configuration inside HA for the modbus network:

# USR-W610 WIFI BRIDGE
modbus:
  type: tcp
  host: !secret modbus_tcpip_bridge_ip
  port: 8899
  timeout: 2

I can’t remember why the port isn’t the standard modbus TCP/IP port (502), maybe I changed it in the W610 configuration. I’m not home now to check.

And this is the configuration for the sensors (to long to post in the comment).

#7

Thanks; this is what I needed to get off the fence and press order on Amazon :wink:

1 Like
#8

Hi. I also have some PZEM-016 and am using an Elfin RS485 to WiFi serial server. I am reading the values into HA with no issue. However I would like to send a reset command to zero the kWh counter each month. I can do it using MBPoll by sending hex string “01 42 80 11” where 01 is the device address and 42 is the hex command to reset energy (as per the PZEM manual). The 80 11 is the CRC check.
Do you (or anyone else out there) have any idea how I can write this command.
Thanks.