Modbus basic understanding

Hello,

i have a pluggit ventilation plant. It supports modbus. But i dont understand, how i can integrate it in home assistant.
For basic testing i used a temperature value, but i dont get any data.
i create this configuration

modbus:
  - name: "Pluggit"
    type: tcp
    host: 192.168.178.22
    port: 502
    sensors:
      - name: PluggitTest
        unit_of_measurement: °C
        slave: 1
        address: 40089

The manual says for temperature the following

What is wrong with my config? Thanks for your help.

I found the log for modbus and saw, that there was an illegal address. So i changed the input type to input.
Now my config is

modbus:
  - name: "Pluggit"
    type: tcp
    host: 192.168.178.22
    port: 502
    sensors:
      - name: PluggitTest
        unit_of_measurement: °C
        slave: 1
        address: 40089
        input_type: input
        data_type: float

But i have also no data availabe and the log says.

PluggitTest with float is not valid, trying to convert

But the docu says, it is a float. Any ideas?

40089 maybe it is holding (4)0089

        address: 89
        count: 2
        input_type: holding
        data_type: float
        swap: none

Maybe it is need to change swap

Thanks nikito. It’s working. Please, can you explain why count should be 2? And why swap?

1 Like

Because float(4bytes) is two registers

2bytes + 2bytes

Sometimes it is need to swap it: reg1reg2 or reg2reg1