Closed Appesteijn closed 1 month ago
The distance parameter remains constant in all scenarios because it measures the distance from the window or cover to the specified shaded area, as indicated by the orange line in the diagram.
The percentage is determined using the maximum awning length. This length is adjusted using geometric calculations to account for different angles relative to a vertical blind. The length of the vertical blind, based on the sun's position, is then converted back to the length of a horizontal cover using these geometric principles.
For more details, you can check the related code here: https://github.com/basbruss/adaptive-cover/blob/07b235edb1210aa89fd8cb3b87ff48e750101d52/custom_components/adaptive_cover/calculation.py#L426-L442
Thank you!
I was too fast. With these settings
I get this:
I would expect it to be:
What am I doing wrong? :)
Can you share the diagnostics dump from the integration tab and maybe add some debug logs from the integration? There are just too many parameters that can influence the actual position.
When I change the 'Shaded area' to 2 meters, the extension is correct.
What are the percentages that HA shows when the awning is fully opened and fully closed? I suspect it's the inverse of the general HA convention that is used for covers, where 100% is fully open/extended and 0% is fully closed/not extended.
100% is open or up, 0% is closed or down.
Seems indeed the opposite as is assumed within the integration for horizontal covers. You can use the inverse option in the options menu.
Is it also for vertical covers? 100% is open and 0% is closed?
I'll test tomorrow and will close this ticket when it works. Thank you for you fast response and help!
Looks like this was the solution. The percentage should be interpreted as '% closed'. I though it was '% open'
What version of Adaptive Cover are you using?
1.3.2
What version of Home Assistant are you using?
2024.7.2
Checklist
Describe the issue
I tried to find the code, but my coding is a little bit rusty. I have the feeling that 'distance to shaded area' doesn't take an extending horizontal awning into account. For horizontal shades the distance is constant and stay's the same, but an extending awning should add the current extend (percentage_closed * awning_length) into the calculation.
Reproduction steps
When sun still reaches your 'shaded area', increase the 'distance to shaded area' in the config.
Diagnostics dump
No response