# Modbus rtu

**URL:** <https://community.openenergymonitor.org/t/modbus-rtu/20499>\
**Category:** emonPi\
**Tags:** modbus\
**Created:** [16 May 2022 13:14 UTC](https://community.openenergymonitor.org/t/modbus-rtu/20499 "2022-05-16T13:14:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kabeziller](https://community.openenergymonitor.org/user_avatar/community.openenergymonitor.org/kabeziller/32/18749_2.png) [@kabeziller](https://community.openenergymonitor.org/u/kabeziller)\
**Post date:** [16 May 2022 13:14 UTC](https://community.openenergymonitor.org/t/modbus-rtu/20499/1 "2022-05-16T13:14:21Z")

</div>

We have a heat pump that uses the MODBUS RTU protocol. Is this compatible with EmonPi?

Having issues with the interface but wanted to check compatibility before attempting to debug further!

Many thanks 🙂

---

<div class="post-metadata">

**Author:** ![TrystanLea](https://community.openenergymonitor.org/user_avatar/community.openenergymonitor.org/trystanlea/32/31_2.png) [@TrystanLea](https://community.openenergymonitor.org/u/TrystanLea)\
**Post date:** [20 May 2022 17:24 UTC](https://community.openenergymonitor.org/t/modbus-rtu/20499/2 "2022-05-20T17:24:41Z")

</div>

Hello @kabeziller I see your post here [M-Bus to UART Converter -\> EmonTx?](https://community.openenergymonitor.org/t/m-bus-to-uart-converter-emontx/20454) The emonPi can be used to read modbus using the emonhub modbus interfacer, but my guess is that using it with your heat pump to do what you want to do may not be as straight forward.

Here’s an example configuration for emonhub EmonHubMinimalModbusInterfacer interfacer, reading from a SDM120 modbus meter.

```auto
[[SDM120]]
    Type = EmonHubMinimalModbusInterfacer
    [[[init_settings]]]
        device = /dev/ttyUSB0
        baud = 2400
    [[[runtimesettings]]]
        pubchannels = ToEmonCMS,
        read_interval = 10
        nodename = sdm120
        # prefix = sdm_
        registers = 0,6,12,18,30,70,72,74,76
        names = V,I,P,VA,PF,FR,EI,EE,RI
        precision = 2,3,1,1,3,3,3,3,3

```

You need to specify specific register id’s that you want to read data from and it’s limited to only reading data not doing any kind of control. I dont know enough about modbus to know how applicable the same approach is for other equipment so you may want to look into the code itself to understand what it does and if it is compatible with what you want to do, see the code here: [emonhub/EmonHubMinimalModbusInterfacer.py at master · openenergymonitor/emonhub · GitHub](https://github.com/openenergymonitor/emonhub/blob/master/src/interfacers/EmonHubMinimalModbusInterfacer.py)

---

<div class="post-metadata">

**Author:** ![kabeziller](https://community.openenergymonitor.org/user_avatar/community.openenergymonitor.org/kabeziller/32/18749_2.png) [@kabeziller](https://community.openenergymonitor.org/u/kabeziller)\
**Post date:** [24 May 2022 09:12 UTC](https://community.openenergymonitor.org/t/modbus-rtu/20499/3 "2022-05-24T09:12:41Z")

</div>

Hello Trystan,

Many thanks for coming back to me on this - very helpful. We’ll do some more testing and see how far we get 🙂
