EcoMBR1 - ModBus relay
Read smart meters and switch loads
The EcoMBR1 reads a smart meter (electricity meter) via its ModBus RTU interface (RS485) and sends the values via WiFi to ecosensors.cloud. In addition it has a relay that can be switched manually or automatically based on the grid power.
Technically it is based on ESPhome (see the general guide). Hardware and software are open, so the sensor can also be built yourself.
What you get
- Grid L1/L2/L3: voltage, current and power
- Total power at the grid connection and grid frequency
- Total import and total export
- Relay: switch manually or automatically with adjustable on and off switching points (in watts)
All values appear in your dashboard on ecosensors.cloud.
Compatible meters
The following smart meters have been tested:
| Meter | Firmware variant |
|---|---|
| Chint DTSU 666 | dtsu666 |
| Orno WE-516 / WE-517 | we517 |
Further meters can usually be added easily. Feel free to get in touch to integrate your (exotic?) ModBus meter as well.
ModBus is not the same as ModBus. A distinction is made between RTU (serial line, RS485) and TCP (Ethernet). The EcoMBR1 only supports ModBus RTU. Meters with ModBus TCP are not supported so far.
Variants
The firmware has to match the meter, because meters differ in registers and interface parameters. In addition there is a variant with Home Assistant interface (-ha) for each:
| Variant | Meter | Home Assistant |
|---|---|---|
dtsu666 |
Chint DTSU 666 | no |
dtsu666-ha |
Chint DTSU 666 | yes |
we517 |
Orno WE-516/517 | no |
we517-ha |
Orno WE-516/517 | yes |
A -ha variant must be paired with Home Assistant, otherwise the sensor restarts every 15 minutes (Pair with Home Assistant). If you do not use Home Assistant, take the variant without -ha.
Installation
Work on the meter and on the power grid may only be carried out by a qualified electrician.
Configure the meter
The sensor talks to the meter with fixed parameters. Set the meter (on its display or according to the meter manual) accordingly:
| Chint DTSU 666 | Orno WE-516/517 | |
|---|---|---|
| Interface | RS485, ModBus RTU | RS485, ModBus RTU |
| Baud rate | 9600 | 9600 |
| Parity | none | even |
| ModBus address | 4 | 1 |
Connect
- Connect the sensor to the meter's RS485 interface (A/B).
- Power the sensor.
- A load to be switched by the relay is connected via the relay contact.
The detailed wiring diagram (terminal assignment, power supply, relay data) will be added.
Commissioning
The setup is the same for all sensors of the Eco series and is described in the general guide. Your sensor is called ecombr1-<ID>:
- Set up WiFi – connect to the hot spot
ecombr1-<ID>, enter the WiFi credentials - Open the web interface at
http://ecombr1-<ID>orhttp://ecombr1-<ID>.local - Register the sensor with the EcoSensor ID (
ecombr1-<ID>) - Pair with Home Assistant – only for a -ha variant
If the web interface shows no meter values, check the wiring (A/B not swapped?) as well as baud rate, parity and ModBus address on the meter (see Configure the meter).
Configure the relay
In the web interface you will find the relay settings:
- Relay – switch the relay on or off manually
- Relay Control – switch automatic control based on grid power on or off
- Relay 1 On Limit / Relay 1 Off Limit – on and off switching point in watts (−20 000 … 20 000 W; the values are kept after a restart)
Firmware update
The EcoMBR1 fetches updates itself from the internet:
| Way | Note for the EcoMBR1 | |
|---|---|---|
| A | Update via ecosensors.cloud | in development |
| B | Update at the push of a button in the web interface | standard way: Firmware update button |
| C | Upload an update file | if the sensor has no internet; file from Firmware |
Always update to the variant that is already running on the sensor (see Variants). The general notes are under Firmware update.
Technical data
| Wireless standard | 802.11 b/g/n (2.4 GHz only) |
| Frequency range | 2.4G~2.5G (2412M~2484M) |
| Data interface | RS485 |
| Protocol | ModBus RTU, 9600 baud |
| Output | 1 relay |
| Display | Status LED |
| Supported servers | EcoSensors |
| Open hardware / open software | yes / yes |
| [/div | ] |
Appendix: ModBus registers
For developers and custom evaluations: the registers used by the firmware and those provided by the meter.
Chint DTSU 666
Registers read by the firmware (all as floating-point number FP32):
| Register | Value | Unit | Factor |
|---|---|---|---|
| 0x2006 | Voltage L1 | V | 0,1 |
| 0x2008 | Voltage L2 | V | 0,1 |
| 0x200A | Voltage L3 | V | 0,1 |
| 0x200C | Current L1 | A | 0,1 |
| 0x200E | Current L2 | A | 0,1 |
| 0x2010 | Current L3 | A | 0,1 |
| 0x2012 | Total power | W | 0,1 |
| 0x2014 | Power L1 | W | 0,1 |
| 0x2016 | Power L2 | W | 0,1 |
| 0x2018 | Power L3 | W | 0,1 |
| 0x2044 | Grid frequency | Hz | 0,01 |
| 0x101E | Total import | kWh | 1 |
| 0x1028 | Total export | kWh | 1 |
Orno WE-516/517
ModBus registers of the meter:
| Register | Name | Unit | Length |
|---|---|---|---|
| 0x0000 | Serial number | 2 | |
| 0x0002 | Modbus ID | 1 | |
| 0x0003 | Modbus Baudrate | 1 | |
| 0x0004 | Software Version | 2 | |
| 0x0006 | Hardware Version | 2 | |
| 0x0009 | SO output rate | 2 | |
| 0x000B | Combined Code | 1 | |
| 0x000C | HOLIDAY-WEEKEND Tariff | 1 | |
| 0x000D | LCD Cycle time | s | 1 |
| 0x000E | L1 Voltage | V | 2 |
| 0x0010 | L2 Voltage | V | 2 |
| 0x0012 | L3 Voltage | V | 2 |
| 0x0014 | Grid Frequency | Hz | 2 |
| 0x0016 | L1 Current | A | 2 |
| 0x0018 | L2 Current | A | 2 |
| 0x001A | L3 Current | A | 2 |
| 0x001C | Total Active Power | kW | 2 |
| 0x001E | L1 Active Power | kW | 2 |
| 0x0020 | L2 Active Power | kW | 2 |
| 0x0022 | L3 Active Power | kW | 2 |
| 0x0024 | Total reactive power | kvar | 2 |
| 0x0026 | L1 reactive power | kvar | 2 |
| 0x0028 | L2 reactive power | kvar | 2 |
| 0x002A | L3 reactive power | kvar | 2 |
| 0x002C | Total Apparent Power | kVA | 2 |
| 0x002E | L1 Apparent Power | kVA | 2 |
| 0x0030 | L2 Apparent Power | kVA | 2 |
| 0x0032 | L3 Apparent Power | kVA | 2 |
| 0x0034 | Total Power Factor | 2 | |
| 0x0036 | L1 Power Factor | 2 | |
| 0x0038 | L2 Power Factor | 2 | |
| 0x003A | L3 Power Factor | 2 | |
| 0x003C | DateTime | 4 | |
| 0x0041 | CRC code | 1 | |
| 0x0100 | Total Active Energy | kWh | 2 |
| 0x0102 | L1 Total Active Energy | kWh | 2 |
| 0x0104 | L2 Total Active Energy | kWh | 2 |
| 0x0106 | L3 Total Active Energy | kWh | 2 |
| 0x0108 | Forward Active Energy | kWh | 2 |
| 0x010A | L1 Forward Active Energy | kWh | 2 |
| 0x010C | L2 Forward Active Energy | kWh | 2 |
| 0x010E | L3 Forward Active Energy | kWh | 2 |
| 0x0110 | Reverse Active Energy | kWh | 2 |
| 0x0112 | L1 Reverse Active Energy | kWh | 2 |
| 0x0114 | L2 Reverse Active Energy | kWh | 2 |
| 0x0116 | L3 Reverse Active Energy | kWh | 2 |
| 0x0118 | Total Reactive Energy | kvarh | 2 |
| 0x011A | L1 Reactive Energy | kvarh | 2 |
| 0x011C | L2 Reactive Energy | kvarh | 2 |
| 0x011E | L3 Reactive Energy | kvarh | 2 |
| 0x0120 | Forward Reactive Energy | kvarh | 2 |
| 0x0122 | L1 Forward Reactive Energy | kvarh | 2 |
| 0x0124 | L2 Forward Reactive Energy | kvarh | 2 |
| 0x0126 | L3 Forward Reactive Energy | kvarh | 2 |
| 0x0128 | Reverse Reactive Energy | kvarh | 2 |
| 0x012A | L1 Reverse Reactive Energy | kvarh | 2 |
| 0x012C | L2 Reverse Reactive Energy | kvarh | 2 |
| 0x012E | L3 Reverse Reactive Energy | kvarh | 2 |
| 0x0130 | T1 Total Active Energy | kWh | 2 |
| 0x0132 | T1 Forward Active Energy | kWh | 2 |
| 0x0134 | T1 Reverse Active Energy | kWh | 2 |
| 0x0136 | T1 Total Reactive Energy | kvarh | 2 |
| 0x0138 | T1 Forward Reactive Energy | kvarh | 2 |
| 0x013A | T1 Reverse Reactive Energy | kvarh | 2 |
| 0x013C | T2 Total Active Energy | kWh | 2 |
| 0x013E | T2 Forward Active Energy | kWh | 2 |
| 0x0140 | T2 Reverse Active Energy | kWh | 2 |
| 0x0142 | T2 Total Reactive Energy | kvarh | 2 |
| 0x0144 | T2 Forward Reactive Energy | kvarh | 2 |
| 0x0146 | T2 Reverse Reactive Energy | kvarh | 2 |
| 0x0148 | T3 Total Active Energy | kWh | 2 |
| 0x014A | T3 Forward Active Energy | kWh | 2 |
| 0x014C | T3 Reverse Active Energy | kWh | 2 |
| 0x014E | T3 Total Reactive Energy | kvarh | 2 |
| 0x0150 | T3 Forward Reactive Energy | kvarh | 2 |
| 0x0152 | T3 Reverse Reactive Energy | kvarh | 2 |
| 0x0154 | T4 Total Active Energy | kWh | 2 |
| 0x0156 | T4 Forward Active Energy | kWh | 2 |
| 0x0158 | T4 Reverse Active Energy | kWh | 2 |
| 0x015A | T4 Total Reactive Energy | kvarh | 2 |
| 0x015C | T4 Forward Reactive Energy | kvarh | 2 |
| 0x015E | T4 Reverse Reactive Energy | kvarh | 2 |
| 0x0300 | TIME interval 1 | 12 | |
| 0x030C | TIME interval 2 | 12 | |
| 0x0318 | TIME interval 3 | 12 | |
| 0x0324 | TIME interval 4 | 12 | |
| 0x0330 | TIME interval 5 | 12 | |
| 0x033C | TIME interval 6 | 12 | |
| 0x0348 | TIME interval 7 | 12 | |
| 0x0354 | TIME interval 8 | 12 | |
| 0x0360 | TIME zone | 12 |