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

Tuya light not color control in the user interface #30362

Closed
sidwin9 opened this issue Jan 1, 2020 · 41 comments
Closed

Tuya light not color control in the user interface #30362

sidwin9 opened this issue Jan 1, 2020 · 41 comments

Comments

@sidwin9
Copy link

sidwin9 commented Jan 1, 2020

Home Assistant release with the issue:

0.103.5

Last working Home Assistant release (if known):

Operating environment (Hass.io/Docker/Windows/etc.):

Hass.io
Raspberry Py 3B+

Integration:

Description of problem:
Following update 0.103.0, I no longer have the color management interface in the user interface.
image

Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):

tuya:
  username: xxx
  password: xxx
  country_code: 33
  platform: smart_life

**Traceback (if applicable):**

**Additional information:**
@davr
Copy link

davr commented Jan 2, 2020

I think #30311 #30087 #28602 are all related

@davr
Copy link

davr commented Jan 2, 2020

Related issue on tuyaha package: PaulAnnekov/tuyaha#17

@jes1417
Copy link

jes1417 commented Jan 15, 2020

Same issues here

@Ahoui-group
Copy link

Issue is still around with 104.x... This patch seems to resolve issues on short term...

#28602 (comment)

@skynet01
Copy link
Contributor

The fix in above comment does indeed work, got to patch it yourself

@ghost
Copy link

ghost commented Feb 4, 2020

Just got a Tuya device and found the same issue. It is also not returning the current brightness, it is showing brightness slider all the way down. Brightness control works, just doesn't show current value. Unsure how to patch this myself, new to HA just running Hassio.

Home Assistant 0.104.3

2020-02-04_123807

@skynet01
Copy link
Contributor

Any word on fixing this? There is a patch that fixes the issue mentioned in a comment here: #28602 (comment)
Right now all the Tuya lights that have color no longer have color options.

@hook-365
Copy link

I've tried the patch that's supposed to fix it, but no successful resolution with the patch.

@G33kDude
Copy link

@anthonyrhook I'm sorry the patch file is not working for you. I'm still using the one I provided (light_patch.py) and it's working well. Could you talk a bit about your HA installation and how you applied the file?

@skynet01
Copy link
Contributor

Another bump to get G33kDude's patch pushed live. I think there are a lot of people with Tuya who got this issue.

@joaoestevinho
Copy link

joaoestevinho commented Apr 12, 2020

I have the same issue with a Tuya RGB led strip on version 0.108.3 of HA.

@anthonyrhook I'm sorry the patch file is not working for you. I'm still using the one I provided (light_patch.py) and it's working well. Could you talk a bit about your HA installation and how you applied the file?

I have tried the patch provided by @G33kDude in his comment and it appears to fix the issue with the color picker not showing.
The brightness value is still inaccurate (always 40), but that is probably another issue.

image

@hook-365
Copy link

@anthonyrhook I'm sorry the patch file is not working for you. I'm still using the one I provided (light_patch.py) and it's working well. Could you talk a bit about your HA installation and how you applied the file?

Sure thing! I've got a supervised install -- I grabbed the Tuya components from github, and replaced them in custom_components, included file with the patched file, following this comment on bug #28602.

@davr
Copy link

davr commented Apr 13, 2020

If this patch is the correct fix, what do we need to do to get it merged so everyone gets the fix? If it's not the correct fix, what needs to be changed?

@JoseMariaFontanetPava
Copy link

He intentado el parche que se supone que lo arregla, pero no hay una resolución exitosa con el parche.

yo tampoco no he conseguido nada

@ovid-io
Copy link

ovid-io commented Apr 16, 2020

Have same issues with no rgb controls and brightness not being read correctly from the service. Hope this integration is not abandoned...

@SteveJohnSteele
Copy link

Hi
I have followed instruction written here #28602

To use this, you will need to download the Tuya component from here
https://github.com/home-assistant/home-assistant/tree/dev/homeassistant/components/tuya
and add the folder to your custom_components folder, replacing light.py with my modified version.

I create a folder called tuya
custom_components/tuya
and copied the original files into it
I renamed the light.py to original_light.py
and then I copied your version into the same folder

I then physically powered off my Raspberry Pi 3B+ running Hassio

Unfortunately the light panel still does not show the color wheel.

Please let me know if I have done this correctly, or if there is anything I need to change.

@natarajanrodrigues
Copy link

I've follow these steps and still it's not working as well.

@Letherwin
Copy link

me too, still got the problem

@qJake
Copy link

qJake commented Jun 13, 2020

Still an issue, Home Assistant 0.110.2, Lumary LED strip (division of Tuya, works with a Tuya account) I have brightness and on/off controls but no color picker.

image

@Letherwin
Copy link

Confirmed for me too, the problem is still present

@qJake
Copy link

qJake commented Jun 18, 2020

Some further information: When I override the supported features flag to include SUPPORTS_COLOR = 16 (so, anything with a bitwise value containing 16), then when I go to change the color on the frontend I get the following error:

Failed to call service light/turn_on. int() argument must be a string, a bytes-like object or a number, not 'NoneType'

@qJake
Copy link

qJake commented Jun 29, 2020

Updated to 0.111.4 - issue is still there.

@DavidFFerreira
Copy link

Update 0.113.0 - issue is still there.

@skynet01
Copy link
Contributor

There is a way to force it to show up and then the color picker will work. If you go to Configuration > Customization > [select your entity] the very last parameter is "supported_features" edit it and set it to 63.

@Letherwin
Copy link

There is a way to force it to show up and then the color picker will work. If you go to Configuration > Customization > [select your entity] the very last parameter is "supported_features" edit it and set it to 63.

That worked great! Thank you very much!

@hook-365
Copy link

There is a way to force it to show up and then the color picker will work. If you go to Configuration > Customization > [select your entity] the very last parameter is "supported_features" edit it and set it to 63.

Can confirm, that worked here as well.

@hmnd
Copy link

hmnd commented Jul 26, 2020

@skynet01 Do you perhaps know the supported features number to enable effects?

@skynet01
Copy link
Contributor

@skynet01 Do you perhaps know the supported features number to enable effects?

I believe it might be 191 which will add all the options not sure if they will work though

@qJake
Copy link

qJake commented Jul 28, 2020

When I change supported_features to 63 and change a color, I get the following error:

Failed to call service light/turn_on. int() argument must be a string, a bytes-like object or a number, not 'NoneType'

I'm using this Tuya-compatible Lumary product: https://www.amazon.com/dp/B07V3R436B/

Any ideas?

@guytaylor
Copy link

I get the same behaviour as @qJake

@bpsib
Copy link

bpsib commented Sep 1, 2020

There is a way to force it to show up and then the color picker will work. If you go to Configuration > Customization > [select your entity] the very last parameter is "supported_features" edit it and set it to 63.

I don't get the Customization option. I have tried in the Developer Tools instead but the color wheel appears then disappears and "supported_features" resets itself back to 3. How can I do it?

Using Home Assistant 0.114.4

@skynet01
Copy link
Contributor

skynet01 commented Sep 2, 2020

The Customization option can be accessed when you click on Configuration (its the last option on the list). You can also go to it directly http://your_homeassistant_url/config/customize. Alternatively, there is now a custom Tuya component where you can force the color option. It also fixes a few other bugs with native tuya component

@CursedDog19
Copy link

If you are trying to modify the supported features value now, there is an easier way to do it in the configuration UI. Just scroll to the bottom and click "Customizations," select the entity you want to modify, and modify the value by selecting the pen. After saving the settings should apply, no restart necessary. A good value to use is 63 for rgb lights with white color temperature.

@qJake
Copy link

qJake commented Jan 23, 2021

Is there any progress on this bug? I still can't control my Lumary (Tuya-powered) LED strips via HA because of this.

@oliverchapple
Copy link

I have the same issue try changing the number and nothing works

thanks Oliver

@dum-skywalker
Copy link

dum-skywalker commented Feb 17, 2021

same here. I have 2 LIGHTEU®, Milight Miboxer led strip controller, controlled with Smart Life platform.

edited: I fixed the isssue, editing the entities, and in the field "Supported features (JSON formatted)" I set them up to 63.

@rrakso
Copy link

rrakso commented Mar 4, 2021

As @dum-skywalker said this solution also worked for me, but I found it here earlier.

@carlos-algms
Copy link

carlos-algms commented May 28, 2021

For me, the only way to show the color-picker was including hs as a Supported color mode in customizations:
Configuration > Customization > [select your entity]

Initially, it was:
["color_temp"]
I changed to:
["color_temp", "hs"]

After restarting HA the color-picker was there, But I guess it would be enough to just turn off/on the light to update it.

PS: I got the hs value from my Chinese brandless led strip, it was the only option for it. 😅
According to the HA Developer - light docs rgb is also an option, but I cannot say the difference.

@github-actions
Copy link

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.

@github-actions github-actions bot added the stale label Aug 27, 2021
@qJake
Copy link

qJake commented Aug 29, 2021

I can confirm that as of 2021.8.x, my Tuya light strips can now correctly control color. I don't know what fixed it or when, but it's working now. I don't know if the original opener @sidwin9 had the exact same issue or not, but for me, everything is working.

@github-actions github-actions bot removed the stale label Aug 31, 2021
@frenck
Copy link
Member

frenck commented Oct 1, 2021

The Tuya integration has been replaced and will land in Home Assistant Core 2021.10.

If you are interested in testing this out already, you could join the Home Assistant Core 2021.10 beta (that is now available).

I'm closing this issue as it was created for the previous integration.

@frenck frenck closed this as completed Oct 1, 2021
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