M-Bus Electricity Sub-Meters for the Outbuildings

I’ve been finding the electricity sub-meters in the House very useful, showing the electrical consumption of the ‘significant’ electrical loads as a proportion of the total recorded by the main electricity meter, so I’ll be adding some in the Outbuildings too.

For the House, I initially used cheap meters with only an S0 ‘pulse’ output and recorded the readings manually every month. Later, I found some affordable (second-hand) M-Bus adaptors for the ‘pulse’ meters (various models from the Relay Padpuls range) and added those, enabling the meters to be included in the once-per-minute reading cycle for the Water meters and the Heat meters.

The ‘significant’ loads that in my view warrant a dedicated sub-meter are:

  • Heat Pumps
    • In conjunction with a Heat Meter for heat pumps with a Water output, enabling the real-world efficiency to be calculated
    • With an Air-to-Air heat pump, as will be installed in the Outbuildings, it’s not practical to measure the heat output – but it’s still worth recording the electricity input
    • If there are secondary circulation pumps or control units which have a separate electrical supply from the main Heat Pump unit, these should ideally have their own sub-meter
  • Mechanical Ventilation (with or without Heat Recovery) Systems
    • While their consumption is not especially high, the fact that these typically run 24×7 means their total usage can add up – and since they’re still quite unusual in UK homes it’s good to track their actual energy consumption
    • Some MVHR units vary their fan power to provide a consistent airflow, in which case a gradual increase in energy consumption can be an indication that the filters need replacing – although normally the filters should be replaced before this increase becomes noticeable
  • Electric Vehicle Charge Points
    • Sometimes these incorporate their own electricity metering, which can be accessed via a Smartphone App or other interface, but it’s convenient to have them metered in the same way as the other electrical loads
    • Each charge point should have its own meter, should there be more than one
  • Other ‘large’ or ‘interesting’ loads
    • Immersion heaters
    • Rainwater harvesting pumps

There’s a wide choice of electricity meters with an S0 ‘pulse’ output (EN 62053-31) and a rather smaller choice of meters with a Modbus output. For meters with a native M-Bus (Meter-Bus) output the choice is smaller still – but for a building that needs to have some M-Bus metering anyway it’s much more straightforward to add further M-Bus meters than to cater for alternative metering protocols as well.

I’ve settled on using MID-certified M-Bus meters from UK company Rayleigh Instruments, having added one of their meters to the House a few months ago and after receiving positive feedback from another self-builder who uses one for their air-to-water Heat Pump:

  • The 2-module-wide RI-D35-100-MB which is a directly-connected meter for loads up to 100A
    • This reports Manufacturer = “RAY” which is one of two manufacturer codes allocated to “Rayleigh Instruments, United Kingdom”
    • This returns a lot of data via M-Bus which spills over into a second M-Bus telegram, requiring the M-Bus software to be able to handle a multi-telegram response
  • The 1-module-wide RI-D175-MB which is a directly-connected meter for loads up to 45A
    • Despite being branded as a Rayleigh Instruments unit, this reports Manufacturer = “PAD” which is a manufacturer code allocated “PadMess, Germany”
    • Note that this meter appears not to respond to a Secondary M-Bus address, so Primary addressing must be used
    • There’s a variant of this available with a Current Transformer (CT) input instead of being directly-connected, which caters for currents up to 100A
    • There’s more information about this specific meter in a Technical Article page here.

These are available for about £25 each; surprisingly the larger meter is less than 10% more expensive than the smaller one, so actually I only use the smaller one for loads up to about 16A (where the smaller terminals are helpful for connecting smaller-section cables) and use the larger one for loads like the EV charge points, where the load won’t even exceed 32A.

The Rayleigh meters are shipped with their Primary M-Bus address set to ‘0’ (RI-D35-100-MB) or ‘1’ (RI-D175-MB) so if the intention is to extract readings using the Primary rather than the Secondary M-Bus addresses, these need to be changed from the default. This can be accomplished using one of the utilities shipped as part of the libmbus codebase:

$ mbus-serial-set-address -b 2400 /dev/ttyUSB0 old_primary_address new_primary_address

Computer Network Switch Selection for the Outbuildings

I’m using Ubiquiti UniFi network equipment in the House – notably for the PoE Network Switches and the Wireless Access Points. I find the UniFi gear provides a reasonable balance between Enterprise-grade functionality and Consumer-grade pricing.

The CCTV cameras are also from the UniFi product range – although those operate as part of the UniFi Protect sub-system and are largely independent of the underlying network equipment. I don’t currently use a UniFi network ‘Security Gateway’ since I prefer the flexibility of a more extensible router and firewall solution that I can add my own code to (I’ve recently moved to OPNsense) – though when the time comes to sell the house I might swap to one of the more user friendly UniFi gateways (and also replace the self-hosted UniFi Network Controller application, which currently runs in a Docker container on an Gen8 HP MicroServer).

It therefore makes sense to continue to use UniFi network equipment in the Outbuildings, managed via the existing UniFi Network Controller dashboard. The question is: which model from the extensive UniFi switch portfolio to choose?

The basic requirement is for at least 22 wired Ethernet ports, at least 13 of which need Power over Ethernet (for CCTV cameras, Wireless Access Points etc). That requirement maps nicely to a 24-port switch – although two 16-port switches would provide some redundancy and more expansion capacity.

  1. Second-hand US 24 250W PoE?
    • That’s just a scaled-down version of the US 48 500W PoE switches in the house – which are OK but they’re relatively deep, and heavy – and the cooling fans are quite noisy (and would be far from ideal in the more dusty / gritty environment of the Outbuildings)
    • These seem to go for around £175 on eBay – and might have been running 24×7 for many years so are likely to need new fans, if nothing else
  2. Two Gen2 USW-16-POE switches?
    • These are fanless units (good) and have a 42W PoE budget (more than adequate) – but they only have 8 PoE-capable ports, so only16 from a pair – which is barely enough
    • These also seem expensive compared to the 24-port variants – about £275 (inc VAT) each, brand new, so £550 for a pair
  3. One Gen2 USW-24-POE switch?
    • These are fanless and have 16 PoE-capable ports (a much better proportion)
    • They’re about £350 (inc VAT) each
    • The main limitation is they only have regular SFP uplink ports – i.e. 1Gb/s max
  4. One Gen2 USW-24-Pro-POE switch?
    • These have SFP+ uplink ports – i.e. 10Gb/s max – and all 24 ports are PoE+ (or PoE++) capable
    • They have a 400W PoE power budget (much more than required) and they provide Layer 3 capabilities (e.g. a DHCP Server and inter-VLAN Routing) which can also be provided by the Firewall (which is required anyway, for other reasons)
    • They’re over £600 (inc VAT) – which is a big premium to pay for features that aren’t currently necessary for this ‘domestic’ installation

On balance, the USW-24-POE seems the least-bad choice. While the 1Gb/s uplink is a limitation, the network link back to the house will be via two firewalls which also impose a 1Gb/s limit – until those are moved to more modern hardware. Second-hand (but relatively young) examples of the USW-24-POE occasionally appear on eBay – though typically for more than half the ‘new’ price.

If additional ports are required, a second (smaller?) switch can be added later – potentially in a ‘satellite’ location (avoiding the need to run all the structured cables back to the Plant Room).

One mitigation for the 1Gb/s uplink limitation would be to ‘aggregate’ both SFP ports for (a slightly better) 2Gb/s back to the adjacent firewall. Unfortunately, it seems that one of the three 1Gb/s ports on the PC Engines APU2 device that runs this firewall is currently refusing to run at more than 100Mb/s – due to some sort of hardware issue – so it’s stuck with one Gigabit connection to the House and one Gigabit connection to the Switch.