Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nibe Integration: Entity toggling between value and Unavailable every few minutes #128818

Closed
realzoulou opened this issue Oct 20, 2024 · 9 comments

Comments

@realzoulou
Copy link

realzoulou commented Oct 20, 2024

The problem

I notice since I have set up the Integration (1-2 months ago) that Nibe F1245 coil 43416 (Compressor starts EB100-EP14) toggles between a correct value and Unavailable every few minutes.
I use LilyGo T-CAN as MODBUS40 replacement.
HA logs contain huge amount of warnings like
[nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
but also other coils

[nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
[nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode

What version of Home Assistant Core has the issue?

core-2024.10.3

What was the last working version of Home Assistant Core?

unknown/never

What type of installation are you running?

Home Assistant Container

Integration causing the issue

Nibe Heat Pump

Link to integration documentation on our website

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

Diagnostics information

2024-10-20_08h52_13

Example YAML snippet

No response

Anything in the logs that might be useful for us?

2024-10-20 08:42:10.266 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
2024-10-20 08:42:10.266 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
2024-10-20 08:42:10.267 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode
2024-10-20 08:42:15.070 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
2024-10-20 08:42:15.071 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
2024-10-20 08:42:15.071 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode
2024-10-20 08:42:23.723 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
2024-10-20 08:42:23.724 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
2024-10-20 08:42:23.724 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode
2024-10-20 08:42:29.348 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
2024-10-20 08:42:29.348 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
2024-10-20 08:42:29.349 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode
2024-10-20 08:42:34.330 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
2024-10-20 08:42:34.331 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
2024-10-20 08:42:34.332 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode

Additional information

I patched ESPHome NibeGw.cpp lines 151 ff to allow ESPHome logs of LilyGo device to show the bytes received via MODBUS from F1245-8 E EM Firmware: 9699R7 (myUplink)

#if ESPHOME_LOG_LEVEL >= ESPHOME_LOG_LEVEL_WARN
            for (byte i = 0; i < msglen && i < DEBUG_BUFFER_LEN / 3; i++) {
              sprintf(debug_buf + i * 3, "%02X ", buffer[i]);
            }
            ESP_LOGW(TAG, "%d bytes from pump: %s", msglen, debug_buf);
#endif

and in ESPHome YAML

logger:
  level: WARN
  logs:
    nibeGW: WARN

and then tried to find the hex bytes that HA Nibe Integration failed to decode:

2024-10-20 08:42:10.266 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 43416 value 8184 - failed to decode
2024-10-20 08:42:10.266 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44298 value 209f - failed to decode
2024-10-20 08:42:10.267 WARNING (MainThread) [nibe.nibe.connection.nibegw] Ignoring coil 44300 value f75d - failed to decode

matches with NibeGw.cpp logs:
[08:42:12][W][nibeGW:155]: 87 bytes from pump: 5C 00 20 68 51 44 9C 84 00 48 9C 34 01 4D 9C E1 01 4E 9C B9 01 4F 9C 0E 01 50 9C FB 00 59 9C E1 00 5A 9C E8 00 5C 5C 9C EB 00 5D 9C EE 00 EC 9F 00 00 ED 9F 00 00 01 A8 21 01 98 A9 81 84 FF FF 00 00 0A AD 20 9F FF FF 00 00 0C AD F7 5D FF FF 00 00 EA AC 00 00 AF

@home-assistant
Copy link

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

Code owner commands

Code owners of nibe_heatpump can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign nibe_heatpump Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


nibe_heatpump documentation
nibe_heatpump source
(message by IssueLinks)

@elupus
Copy link
Contributor

elupus commented Oct 20, 2024

Could you remove these registers from your logset file? My guess something is wrong with that data.

@elupus
Copy link
Contributor

elupus commented Oct 20, 2024

Also could be due to all invalid wordswap setting on your pump.

@realzoulou
Copy link
Author

Word swap checkbox is checked in the pump. If it was wrong, wouldn't then the value never be correctly shown. I added a screen shot in Diagnostic information, which shows that it toggles every now and then.

@realzoulou
Copy link
Author

@elupus I manually edited nibegw.py to match with yozik04/nibe@ed3ef0c and restarted HA.
No more HA logs "Ignoring coil ..." and also coil 43416 (Compressor starts EB100-EP14) does not toggle anymore 👍

I restarted HA at 16:37 and since then compressor starts remains stable (now at 33922)
image

@realzoulou
Copy link
Author

realzoulou commented Oct 20, 2024

@elupus But I saw now an issue with other coils.
Example: 44298 (Heat Meter - HW Cpr and Add EP14) value dropped from ~10628.5 kWh down to 4074.9 kWh
image

I also use HACS MyUplink (https://github.com/jaroschek/home-assistant-myuplink) and both 44298 and 44300 are now showing much smaller values in your integration compared to HACS MyUplink. Previously they always showed exact same value.
image

Seems yozik04/nibe@ed3ef0c is not ok.

@elupus
Copy link
Contributor

elupus commented Oct 20, 2024

You did not try what i asked you? Disable the parameters in your LOGSET file.

@elupus
Copy link
Contributor

elupus commented Oct 20, 2024

But. Nice that you tested that patch! Not sure i can merge that though

@realzoulou
Copy link
Author

@elupus I removed 43416, 44298 and 44300 from LOG.SET and reloaded the Nibe integration.
Result: No warnings in HA anymore, and astonishingly (for me at least) the coils are still reported in HA.
The values are also "stable", means they do not change to "Unavailable" state every few minutes.
So the original issue is gone and I will close this issue now.
I was under the impression that the Integration can only report coils, that I add to LOG.SET file and install then to the pump.
Apparantly my fault...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants