JoDehli / PyLoxone

Python Loxone binding
Apache License 2.0
201 stars 43 forks source link

Scene in combination with light contoller does not work anymore - use subcontrols of the light controller. #282

Closed daes10 closed 4 months ago

daes10 commented 4 months ago

Describe the bug

Background

Today i updated from pyloxone 0.6.4 to 0.6.10, after the update all my scenes in HA aren't working anymore as expected. Because all my non loxone lights are still working, i decided to update also my loxone miniserver. To eventually resolve the issue. So i updated loxone from version 4.7.3.6 to the newest 15.0.5.29. Nothing happens, still the same problem.

Before the update, every light was flawlessly functioning and the state was saved in the scenes.

Problem

So whats actually my issue: My lights that are making problems:

When i look at my scenes, all the configured loxone lights have no color saved state. So when i call the scene, the light is not turning on. when i now set a certain color state on the light und press "save". Everythings fine. But now can go back in and the light is off in the scene.

https://github.com/user-attachments/assets/9048700c-9827-4b7e-9b48-61bec0671953

I only want to acheive that the lights turn on, in a specific color state, when i call the scene. Nothing special.

Firmware of your Miniserver

15.0.5.29

HomeAssistant install method

manual

Version of HomeAssistant

OS: 12.4 Core: 2024.7.2

Version of Pyloxone

0.6.10

Update pyloxone

yes

Log

No response

daes10 commented 4 months ago

I figured out, that i only can save the state in the scene, when i set an effect in the lightcontrol entity. Then the scene calls the effect in loxone and everything works. But the pain is now, that i can't change the scene or light from homeassistant directly, like before.

Every effect MUST be set from the loxone app.

Do someone knows a workaround?

JoDehli commented 4 months ago

@daes10 this is now the way it should be. We had a lot of problems with the old implementation. You you should define your scenes in loxone for the loxone lights and not use the scenes with homeassisant. For other lights you you could use the homeassistant way.

JoDehli commented 4 months ago

@daes10 I understand now your problem better. Maybe you have added the light controller to the scene. The light controller now is not able to set the dimmer values or the color anymore. For that you can let pyloxone create the subcontrols for the light controller. Then you can add these subcontrolls, for example a dimmer, to the scene. There you can set the dimmer value for the scene and it will be saved to the scene as before. The light controller it self is like a scene. To you can use the light controller of a scene in home assisstant. But not a light controller in scene. This does not make sense.

daes10 commented 4 months ago

Thank you @JoDehli for your fast reply.

Yes thats right. But things go really weird, when i only put the subcontrols in the scene.

I have 3 scenes in each room: one for low light, one for middle light and one for full light. Now i put only the subcontrols in the scene (like i configured it the last year and worked good in pyloxone version <=0.6.4)

The weird thing is now, when i save a dimmer state (for example a RGBW Loxone light), sometimes the dimmer don't save. And when i save the same dimmer in another scene, the new dimmer state will override the old one.

See my demonstration video:

  1. First i show that all my scenes from this room are completely off.
  2. Then i set the "wenig Licht" scene to a certain state...
  3. Afterwards i set the scene "viel Licht" to another state...
  4. Then i checked the scene "Aus", if everythings fine.
  5. When i now go back to my "wenig Licht" scene, you can see, that the "Einbauspots" were off (not as before, in the saved state). So the scene was override in the background, when i saved another state to this lights.

https://github.com/user-attachments/assets/40376a58-4b91-449c-8c5a-52344c3bce95

JoDehli commented 4 months ago

@daes10 I tested it with some lights and it worked well for me. I can not reproduce your problem.

But I think the best way is to define the Scenes in a light controller. Create a light controller for each room and define the states in the light controller. The only set the light controller effect with a scene or a service call. This should work perfect.

daes10 commented 4 months ago

Ok thanks for your try. So then i will do it, this way and create all scenes in the loxone app.

PS: Thank you for your awesome work with this Integration! I appreciate your work every day!