basbruss / adaptive-cover

An Adaptive Cover component for HomeAsisstant to control covers based on the sun's position
MIT License
71 stars 10 forks source link

During stationary time, changes are applied #110

Closed mguyard closed 4 months ago

mguyard commented 4 months ago

System Health details

System Information

version core-2024.4.3
installation_type Home Assistant Supervised
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.12.2
os_name Linux
os_version 5.10.0-28-amd64
arch x86_64
timezone Europe/Paris
config_dir /config
Home Assistant Community Store GitHub API | ok -- | -- GitHub Content | ok GitHub Web | ok GitHub API Calls Remaining | 5000 Installed Version | 1.34.0 Stage | running Available Repositories | 1403 Downloaded Repositories | 26
Home Assistant Cloud logged_in | true -- | -- subscription_expiration | 19 juin 2024 à 02:00 relayer_connected | true relayer_region | eu-central-1 remote_enabled | false remote_connected | false alexa_enabled | false google_enabled | true remote_server | eu-central-1-18.ui.nabu.casa certificate_status | ready instance_id | 381927b4921b47a797e587e8790e1775 can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Debian GNU/Linux 11 (bullseye) -- | -- update_channel | stable supervisor_version | supervisor-2024.04.0 agent_version | 1.5.1 docker_version | 26.0.0 disk_total | 194.4 GB disk_used | 20.9 GB healthy | true supported | true supervisor_api | ok version_api | ok installed_addons | Studio Code Server (5.15.0), Samba Backup (5.2.0), AppDaemon (0.16.4), Mosquitto broker (6.4.0), Zigbee2MQTT (1.36.1-1), Z-Wave JS UI (3.4.2)
Dashboards dashboards | 2 -- | -- resources | 12 views | 9 mode | storage
Recorder oldest_recorder_run | 24 février 2024 à 10:15 -- | -- current_recorder_run | 16 avril 2024 à 12:21 estimated_db_size | 1671.70 MiB database_engine | sqlite database_version | 3.44.2

Checklist

Describe the issue

I’ve configured cover to don’t move before 10am. But before this hour, If I change a configuration who change the calculated cover position, cover will update his position.

In my case, sun wasn’t in my window and I’ve change the default position.

Reproduction steps

  1. Define the hour before cover keep stationary (in the future)
  2. Change a configuration who change the calculated position
  3. Look the cover moving

Diagnostics dump

No response

basbruss commented 4 months ago

This is because every reload whether it be the full HA core system or configuration setup calls another function that does not go through all conditions to be able to set the cover to the correct starting position for auto-control.

Although it could be useful to limit this behaviour only after the initial setup start time, accompanied with a button entity that can reset the correct position without considering one of the conditions for auto-control.

x4N70pHyLL commented 4 months ago

Another aspect of (what it seems to me) the same issue is, that it could or even should work the other way round:

Issue: I have to manually set the position one time on activating the automation switch. There I would expect that once activated it sets the correct position/tilt.