GithubHelp home page GithubHelp logo

Communication Failed about ha_tuya_ble HOT 5 OPEN

domy-sage avatar domy-sage commented on July 24, 2024
Communication Failed

from ha_tuya_ble.

Comments (5)

CH1PSET1 avatar CH1PSET1 commented on July 24, 2024

Came here to create a question for exactly the same problem, but I was already beaten to it.
Actually exactly the same situation. CUBETOUCH II works fine in HA, but after an indefinite time, my CUBETOUCH II disconnects and the connection is no longer established. And most importantly, restarting the integration doesn't help either, only restarting the entire HA.
CUBETOUCH II can work for a week, or maybe 2 days, and the moment of shutdown is also not so easy to determine. According to the device logs, it says that the interaction is taking place, but physically CUBETOUCH II does not react, then you reload the integration and CUBETOUCH II goes into the unavailable state and nothing more can be done.
In general, such logs often go:
2023-08-01 01:43:04.685 WARNING (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] DC:23:4F:01:56:29: Device unexpectedly disconnected; RSSI: -67
But this does not prevent CUBETOUCH from working stably. (and the distance to bluetooth 2 meters line of sight).
And then, with complete inaccessibility, the following logs appear:
The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/config/custom_components/tuya_ble/tuya_ble/tuya_ble.py", line 574, in _ensure_connected
client = await establish_connection(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/bleak_retry_connector/init.py", line 361, in establish_connection
_raise_if_needed(name, device.address, exc)
File "/usr/local/lib/python3.11/site-packages/bleak_retry_connector/init.py", line 310, in _raise_if_needed
raise BlackNotFoundError(msg) from exc
bleak_retry_connector.BleakNotFoundError: DC:23:4F:01:56:29 - DC:23:4F:01:56:29: Failed to connect:
2023-08-06 22:26:53.572 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] DC:23:4F:01:56:29: device not found, not in range, or poor RSSI: -73
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/bleak/backends/bluezdbus/client.py", line 204, in connect
reply = await self._bus.call(
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/dbus_fast/aio/message_bus.py", line 371, in call
await future
asyncio.exceptions.CancelledError

I would like to know what is causing this and fix the problem.
Or at least catch the problem as it occurs and fix it (preferably without rebooting the entire HA system).
I'm even ready to put a trigger that would perform some actions every few hours to keep CUBETOUCH running all the time.

from ha_tuya_ble.

jeroenvdd avatar jeroenvdd commented on July 24, 2024

Same boat here, with dongle directly connected to server,
and it's only device acting up like this
also in the logs:
This error originated from a custom integration.

Logger: custom_components.tuya_ble.tuya_ble.tuya_ble
Source: custom_components/tuya_ble/tuya_ble/tuya_ble.py:503
Integration: Tuya BLE
First occurred: 7:09:16 PM (11 occurrences)
Last logged: 7:14:43 PM

DC:23:4D:AD:81:1B: Device unexpectedly disconnected; RSSI: -35

from ha_tuya_ble.

JPM-git avatar JPM-git commented on July 24, 2024

Did any of you guys was able to solve this problem?

from ha_tuya_ble.

esguti avatar esguti commented on July 24, 2024

Same problem, recently bought Cubetouch II is unavailable, but I have an old one which is working normally.

Some traces:

2024-02-19 09:49:40.903 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: timeout receiving response, RSSI: -36
2024-02-19 09:49:40.908 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request failed
2024-02-19 09:49:40.910 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connecting; RSSI: -36
2024-02-19 09:49:47.648 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connected; RSSI: -36
2024-02-19 09:49:48.003 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request
2024-02-19 09:49:48.003 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending packet: #2 FUN_SENDER_DEVICE_INFO
2024-02-19 09:50:17.568 WARNING (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Device unexpectedly disconnected; RSSI: -36
2024-02-19 09:50:48.010 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: timeout receiving response, RSSI: -36
2024-02-19 09:50:48.013 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request failed
2024-02-19 09:50:48.253 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connecting; RSSI: -36
2024-02-19 09:50:51.875 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connected; RSSI: -36
2024-02-19 09:50:52.370 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request
2024-02-19 09:50:52.370 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending packet: #3 FUN_SENDER_DEVICE_INFO

After a while, tuya_ble get tired of trying to connect without receiving response and stop polling the device:

...
2024-02-19 23:12:20.005 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: timeout receiving response, RSSI: -26
2024-02-19 23:12:20.008 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request failed
2024-02-19 23:12:20.010 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connecting; RSSI: -26
2024-02-19 23:12:23.911 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connected; RSSI: -26
2024-02-19 23:12:24.315 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request
2024-02-19 23:12:24.316 DEBUG (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending packet: #99 FUN_SENDER_DEVICE_INFO
2024-02-19 23:12:53.971 WARNING (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Device unexpectedly disconnected; RSSI: -26
2024-02-19 23:13:24.322 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: timeout receiving response, RSSI: -26
2024-02-19 23:13:24.324 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Sending device info request failed
2024-02-19 23:13:24.326 ERROR (MainThread) [custom_components.tuya_ble.tuya_ble.tuya_ble] XX:XX:XX:XX:XX:XX: Connecting, all attempts failed; RSSI: -26

Could it be the version of the Cubetouch II firmware (v1.5)?

from ha_tuya_ble.

esguti avatar esguti commented on July 24, 2024

I have reinstalled the plugin and both Cubetouch are working fine.

from ha_tuya_ble.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.