Hi All,
Currently I am fighting with my weather station to create some rules for the blinds. This is just the beginning of course.
The blinds are connected to KNX. Where I am using the floowing GAs.
upDown=“2/0/4”,
stopMove=“2/2/4”,
position=“2/5/4+<2/5/0” -2/5/4 is the movement direction … 2/5/0 is the Status current position
In openhab I would like to use 4 different positions: 0; 100; 98 and 96
0 is UP
100 DOWN and closed
96 is what I see in openhab when the blind is down but slats are opened
98 is what I see in openhab when the blind is down but slats are opened partly
Does anybody have an idea for the code?
Many thanks in advance
when
Member of gWeatherStation received update
then
if (chWindGust.state > 15)
{
ObyvackaRollershutter.sendCommand(0)
}
if (chWindGust.state < 15 &&
chIntenyityLux.state < 100)
{
ObyvackaRollershutter.sendCommand(100)
}
if (chWindGust.state < 15 &&
chIntenyityLux.state >=100 && chIntenyityLux.state < 200 &&
{
ObyvackaRollershutter.sendCommand(98)
}
if (chWindGust.state < 15 &&
chIntenyityLux.state >=200 && chIntenyityLux.state < 400)
{
ObyvackaRollershutter.sendCommand(96)
}
if (chWindGust.state < 15 &&
chIntenyityLux.state >= 400)
{
ObyvackaRollershutter.sendCommand(0)
}
end