basbruss / adaptive-cover

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

Add strategy for see-through blinds to always close fully in summer mode. #163

Closed bend closed 1 month ago

bend commented 1 month ago

What version of Adaptive Cover are you using?

1.1.4

What version of Home Assistant are you using?

2024.5.3

Checklist

Describe the issue

I have setup a couple of covers at home but they act weird. Let's take one example of a store Control Method: summer Cover Position: 4% End Sun: In 5 hours Manual Override: Not running Start Sun: 5 hours ago Sun Infront : Detected

Climate mode activated, presence mode not activated and external temperature activated. The temperature of the internal sensor is 24C and the minimal temperature is 19 and maximal temperature is 21C The external temperature is 24.5C The weather is sunny.

Hence I don't understand why the cover remains open at 4%, for me it should be fully closed.

Reproduction steps

Setup an automatic cover with an external temperature sensor, internal temperature sensor, weather. Wait for the cover to be exposed to the sun, weather sunny, high temperature inside and outside (above the max range of the confort temperature) Expectation: Cover should be closed Actual: Cover is opened at 4%

Diagnostics dump

No response

basbruss commented 1 month ago

Can it be that the minimal delta position is preventing it to go from 4 to 0 zero?

bend commented 1 month ago

Screenshot_20240523-140220 Everything is set to the minimum

basbruss commented 1 month ago

presence mode not activated

With this do you mean that you have not set up a presence sensor or that the state of that sensor indicates a deactivated mode?

bend commented 1 month ago

@basbruss Indeed no presence sensor, and the minumum delta to move the store is set to 1% and 2 minutes

basbruss commented 1 month ago

Ah okay, that is the origin of the misleading position. When there is no presence sensor set it assumes there is always presence. Therefore we should first focus on blocking direct light rays while allowing natural light to come in. So even in summer mode the cover will return to the calculated optimal position that holds both conditions. If there is no presence we don't care about natural light coming into a room, so than the cover can close fully within summer mode.

bend commented 1 month ago

my covers are solar covers, so they let the light in by retaining UVs and heat. so it should be closed even is someone is at home to avoid the house to heat too much. What should I do to configure that ?

bend commented 1 month ago

If I set a presence detector, it means covers will only close if I'm not home ?

basbruss commented 1 month ago

Or add a dummy input_boolean that always returns off. I can add a strategy option for see-through covers that block UV and heat to close fully in summer mode with presence. Do you mind if I change this issue to a Feature request for that?

bend commented 1 month ago

@basbruss yes go ahead. I will do that in the meantime :) Thanks for your help

bend commented 1 month ago

@basbruss do you have any documentation on how the Control method is calculated ? (Summer, Intermediate, Winter) Thanks

bend commented 1 month ago

I've set the presence with a binary sensor like indicated I have the following now: image Covers stays opened, but sun is detected

basbruss commented 1 month ago

@basbruss do you have any documentation on how the Control method is calculated ? (Summer, Intermediate, Winter) Thanks

https://github.com/basbruss/adaptive-cover/blob/eea556dc2b7dbd4607629ffce2a596358d5ed6b9/custom_components/adaptive_cover/calculation.py#L219C4-L224C21

So basically when the reference temperature is above the maximum comfort temperature.

I've set the presence with a binary sensor like indicated I have the following now: image Covers stays opened, but sun is detected

Yes, that is right since the control method is indicating intermediate or in other words the measured temperature is within the minimal and maximum comfort temperature range. Resulting in normal adaptive behaviour.

basbruss commented 1 month ago

The control method is based on the strategy used in this paper https://www.mdpi.com/1996-1073/13/7/1731

bend commented 1 month ago

@basbruss outside temperature and inside temperature are both higher than max temp set, the weather temp however is at 19. So I guess there is a prioroty on the weather temperature ?

I've changed the max and min value to very low values and now it is in summer mode however covers stays at 0% (even though I've waited enough time to be sure that automation gets triggered).

basbruss commented 1 month ago

outside temperature and inside temperature are both higher than max temp set, the weather temp however is at 19. So I guess there is a prioroty on the weather temperature ?

That is true, now I look at it, it could be better to prioritize the outside temperature sensor over the weather attribute.

Yes, 0% means fully closed and is therefore the wanted state in summer mode.

bend commented 1 month ago

Do you have a discord so we can discuss that ? Something not clear for me.

basbruss commented 1 month ago

Yes same name tag as here on github