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
73.33k stars 30.63k forks source link

ADS - does not restore the connection after a short drop #99258

Open Murcin86 opened 1 year ago

Murcin86 commented 1 year ago

The problem

Communication is not restart after short disconnection, I make a lot of test ... when everything working I can for example unplug RJ45 and plug again and communication will NOT reconnect

I make small INT sensor in PLC and counting from 1 to 6 and HA just monitoring that image

but from a longer perspective here we can see that communication lost and even if PLC still working that HA have no connection and only restart HA helps with that

image

What version of Home Assistant Core has the issue?

2023.8.4 (and all previous versions)

What was the last working version of Home Assistant Core?

never :)

What type of installation are you running?

Home Assistant OS

Integration causing the issue

ADS

Link to integration documentation on our website

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

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

should be option that monitor real connection, and after reconnect should be everything working

Additional information

No response

home-assistant[bot] commented 1 year ago

ads documentation ads source

ferreto1978 commented 11 months ago

I've been having the same issue. To work around this, I tried to figure out how to restart ADS integration only, but I couldn't figure out how. It would be nice to have a service added that can restart this integration, or reset/restart the connection, as some kind of workaround.

issue-triage-workflows[bot] commented 8 months ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

ferreto1978 commented 8 months ago

Issue is still not resolved 2024 February 25, so please leave open.

murcin commented 8 months ago

I confirm... problem Still exist ;( Tej best would be to create some services to restart connection

issue-triage-workflows[bot] commented 5 months ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

ferreto1978 commented 5 months ago

Issue is still not resolved 2024 May 25, so please leave open.

issue-triage-workflows[bot] commented 2 months ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

murcin commented 2 months ago

Unfortunetly problem still exist ;( no idea how to solved but still everytime when connection is Lost for even one second we need to restart HomeAssistant to Connect again

ferreto1978 commented 2 months ago

I can confirm this issue still exists

ferreto1978 commented 1 month ago

For the moment there are 2 ways that I handle this: 1) Create a "heartbeat" in de PLC and monitor this on the Home Assistant side 2) Communication over MQTT

Heartbeat

This basically increases a counter in the PLC (every cycle) and send the new value (every 3s) to the ADS variable that Home Assistant monitors. When the value has not been changed for 60s (that 20 heartbeats missed) Home Assistant will restart itself. The downside on this is that Home Assistant might reboot on a very inconvenient time.

MQTT

For my more crucial data (lights) I just converted to MQTT, but this is quite some work (compared to ADS) and requires an additional licence on the PLC side. On the up side, it unlocks quite some features.

I know it is not a solution, but this is the best I can do given my limited coding experience. Hopefully this info is somewhat helpfull.