ollo69 / ha_tuya_custom

Tuya Custom Component for testing
Apache License 2.0
39 stars 18 forks source link

Bulb State not working #34

Closed tduffy83 closed 4 years ago

tduffy83 commented 4 years ago

If I change the the bulb color via the Tuya app it does not get updated in HA. If I change the bulb in HA, it's almost instantly updated in the Tuya app. Any way to get state changes in HA if HA doesn't change things?

ollo69 commented 4 years ago

The update should occur, it is only slow. Due to the issue in Tuya Cloud, update can in some case take some minutes. There is no way to improve this. I suggest to use alternative method as tuya_convert if possible to have better performance.

tduffy83 commented 4 years ago

Honestly it never updates, even after waiting several minutes. It seems like the Tuya integration was working really well, and then Tuya did something to break it and it's just not able to be fixed. Due to all the issues with Tuya cloud, I finally bit the bullet and will convert all my bulbs to tasmota. In testing I could not get the esphome template working correctly for this bulb so tasmota it is. With tasmota, the state updates immediately.

ollo69 commented 4 years ago

There is a dedicated API for HA developed some times ago by Tuya. Seems that the person that develop this API left Tuya some times ago, so the API never evolve for new devices. Recently seems that Tuya choose to reduce the resource dedicated to this API, returning a "FrequentlyInvonke" message if the device is queried more frequently that once every 300 sec. This custom integration is just a tentative to apply some work-around, but at this moment this API is unreliable, The HA teams is informed about this and is trying to contact Tuya for clarification, but for the moment the best solution is alternative firmware. Tasmota work with local network connection and MQTT, so performance is the best available. Using Alexa and Hue emulation also provide cloud control out of the box.

tduffy83 commented 4 years ago

I wish the hue emulation worked with google home, as I do not have an alexa device. Eventually I'll get google home set up on home assistant though.

ollo69 commented 4 years ago

I close this issue as resolved / worked around.