Closed dzink3 closed 3 months ago
I'm pretty sure wood blinds allow you to set the tilt, not the position.
Yes, my language might not have been clear. With position I meant the tilt. When I was following the integration of these wood blinds, it sounded like some of the positioning functions of shades can be reused for the wood blinds and they would make the blinds tilt to certain angles. I am trying to confirm whether some part of the implementation is not working correctly or whether my setup is not correct.
Maybe some more details on my setup: I am using home assistant with the lutron caseta integration. A year ago I tried to add the wood blinds, but the integration was still missing. Last month I updated to the newer versions and the wood blinds were detected and showed up in home assistant. Again, if I fully open or close them through home assistant everything is working, however if I use the slider to set a tilt in between, I get the above exception.
I suspect that the integration is trying to set position rather than tilt. The response from the bridge (405 Not Implemented) is what you'd expect to get back when you try a method that isn't supported in a RESTful service (the LEAP service is designed to be RESTful).
I suspect "Open" and "Closed" work because they're special-cases. However, anything else is probably (erroneously) sent as GoToPosition (or something like that), while it should be sent as GoToTilt.
Exact names may well be (and probably are) wrong, but that's the basic idea.
I see! This is what was described in this thread I guess: https://github.com/gurumitts/pylutron-caseta/pull/89.
I was under the impression that the code would check what type of blind it is (e.g., by checking device['tilt'] is not None
) and then call the right function accordingly. But it seems I would have to do that myself, is that right?
I don't have much experience with HA, but do I have to write my own scripts to call the right functions? Some rough pointers would be greatly appreciated!
I think my issue is the same as the one reported here: https://github.com/home-assistant/core/issues/81525.
If I follow the stack trace, it seems that in pylutron_caseta/smartbridge.py
the function set_value
is called, not set_tilt
. From this comment (https://github.com/gurumitts/pylutron-caseta/pull/89#issuecomment-1132333127), it sounds like one could distinguish on the device object which blind it is and redirect to the set_tilt
function accordingly. The other alternative would be to call the set_tilt
function directly from HA (instead of going through the set_value
function at all). Which route to take seems to be a higher level design question that is hard to answer without knowledge of the project, but I am happy to try either way. Maybe @swails or @mdonoughe could help with what path is appropriate here.
I have a PR open here to address tilt functionality in serena wood blinds https://github.com/home-assistant/core/pull/113791, it works in my local testing. I'm using the latter method, to call set_tilt
from HA rather than set_value
Hey @wujiaqi, That's fantastic news! Thank you for putting the work in to fix this and for letting me know! Is there anything I can help with to get this landed?
The PR was merged, I'm new to the HA project so I don't know the full release train, but my hope is that it's pending to make it to a release!
It looks like the change is now present in the latest HA core release. I see the UI change and it works now. However it seems like blinds do not work with Google Home via Nabu Casa, as I see a separate issue related to this https://community.home-assistant.io/t/blinds-not-controllable-via-google-assistant-nabu-casa-user/420859/7
When setting the position of one of the serena wood blinds I get a 405 MethodNotAllowed exception. The logs show the following stack trace:
I can open and close the blinds fully with the respective buttons, just not setting them to a state in between.
Is this an issue with my setup? Or is this an issue with the integration of serena wood blinds?
Thanks!