One stores the positions of my screens through the scene integration, then moves them to a preset position.
The second automation restores the old positions when the first automation is ‘deactivated’.
However, the second automation only restores the position of the first cover (cover.screen_1), I do hear cover.screen_2 move for a split second, but it does not go back to its original position and instead stays on the predefined position from the first automation.
First automation:
- alias: 'Screens: venting active'
triggers:
- trigger: state
entity_id: binary_sensor.screens_venting
from: 'off'
to: 'on'
conditions: []
actions:
- action: scene.create
data:
scene_id: screen_position
snapshot_entities:
- cover.screen_1
- cover.screen_2
- action: cover.set_cover_position
metadata: {}
data:
position: 10
target:
floor_id: 2nd_floor # Moves both cover.screen_1 and cover.screen_2
mode: single
Update: I ran a few tests, and the forgotten settings seem random. One time it’s screen 2 that gets stuck, but it can be screen 1 just as well. It just seems the scene cannot reliably store the values for both, which looks like a bug to me?
Those are two screens total, yes (the ones listed in the snapshot_entities in the automation). The screen that restores its previous position has smooth movement, I only see a single movement there. One click from the motor as well. So the subsequent open/close in the log does not seem to translate to screen movement.
I’m not sure why HA thinks the screens should open, as the screens’ positions should be restored. In this case, they were fully closed before they were moved to venting position. So they should only be closing, not opening.
The second screen clicks and stalls immediately. A bit less anonimised, where you can see it’s two screens, and only one actually gets closed:
Thanks. I already split it into two separate scenes, without the delay though. Both screens just stay stuck at 10% then. The delay does not seem to make a difference.
That doesn’t seem to work with the second automation, the variables seem scoped. When thinking about how to integrate it all in one automation, I realised we won’t be going back to the original positions most of the time - the shades will either be fully closed or opened - manually. So the automation is gone, and we now have a few buttons to open/close the shades, and to set them to a venting position.
I don’t think the KNX integration is part of the issue here; I have been using floor_id to steer all the shades for a while, and that has worked fine so far. Both shades on that floor react at the same time. So to me, it looks like something goes wrong with the scene bit.