home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
72.64k stars 30.41k forks source link

Modbus integration first Sensor unavailable #83937

Closed Sissi91 closed 1 year ago

Sissi91 commented 1 year ago

The problem

I use the Modbus integration to see my Ökofen pellematic. Everything is working fine, except the first Sensor I want to read out. By first Sensor I mean the first Sensor in my list of Sensors just appears as "unavailable". If I put the same Sensor in a differenct position, this problem is gone. As a workaround I put a "DummySensor" there. But isn't the prettiest solution I think. Somebody else experience this issue? Here my code:

modbus:
  - name: "PelletHeizung"
    close_comm_on_error: true
    delay: 5
    timeout: 5
    type: tcp
    host: IP_ADDRESS
    port: 502
    sensors:
      - name: "DUMMYSENSOR"
        address: 6
      - name: "ERROR 1"
        address: 5
      - name: "AMBIENT TEMP"
        unit_of_measurement: °C
        precision: 1
        address: 2
        scale: 0.1
      - name: "HC Current Room Set Temp"
        unit_of_measurement: °C
        precision: 1
        address: 19
        scale: 0.1

Results in: image

let me know if I can provide you with more informations.

What version of Home Assistant Core has the issue?

Home Assistant 2022.12.4

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Modbus

Link to integration documentation on our website

https://www.home-assistant.io/integrations/modbus/

Diagnostics information

No response

Example YAML snippet

modbus:
  - name: "PelletHeizung"
    close_comm_on_error: true
    delay: 5
    timeout: 5
    type: tcp
    host: IP_ADDRESS
    port: 502
    sensors:
      - name: "DUMMYSENSOR"
        address: 6
      - name: "ERROR 1"
        address: 5
      - name: "AMBIENT TEMP"
        unit_of_measurement: °C
        precision: 1
        address: 2
        scale: 0.1
      - name: "HC Current Room Set Temp"
        unit_of_measurement: °C
        precision: 1
        address: 19
        scale: 0.1

Anything in the logs that might be useful for us?

No response

Additional information

No response

home-assistant[bot] commented 1 year ago

Hey there @adamchengtkc, @janiversen, @vzahradnik, mind taking a look at this issue as it has been labeled with an integration (modbus) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `modbus` can trigger bot actions by commenting: - `@home-assistant close` Closes the issue. - `@home-assistant rename Awesome new title` Change the title of the issue. - `@home-assistant reopen` Reopen the issue. - `@home-assistant unassign modbus` Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


modbus documentation modbus source (message by IssueLinks)

janiversen commented 1 year ago

The test suite uses the first sensor so it does not seem to be a general problem. Can you run please run the 2 examples with debug as pr documentation so we can see what happens. The problem might be in your device or you have found a bug.

janiversen commented 1 year ago

Any progress ?

janiversen commented 1 year ago

Closing as no longer relevant.