Window Coverings / Devices by düwi and Merten

Unfortunately Vera does not support the Multilevel Motor Class. If you want to close a shutter partially you need a workaround. This workaround is depending on the manufacturer of the device.

Example code:
[i][size=9pt]function SunCoverDiningRoomDown()
luup.call_action(“urn:upnp-org:serviceId:WindowCovering1”,“Down”,{ },32)
end
function SunCoverDiningRoomStop()
luup.call_action(“urn:upnp-org:serviceId:WindowCovering1”,“Stop”,{ },32)
end

function SunCoverUtilityRoomDoor()
luup.call_action(“urn:upnp-org:serviceId:Dimming1”,“SetLoadLevelTarget”,{ newLoadlevelTarget=“88” },35)
end

luup.call_timer(“SunCoverDiningRoomDown”, 1 , “5”,“”,“”)
luup.call_timer(“SunCoverDiningRoomStop”, 1 , “19”,“”,“”)
luup.call_timer(“SunCoverUtilityRoomDoor”, 1 , “35”,“”,“”)
[/size][/i]

[ul][li]The Merten device (32) closes the dining room window shutter. The Motor needs to be stopped after some seconds. So that is why we need a timer. In my case 14 seconds is what I need for a partly covered window.[/li]
[li]The düwi device reacts (for what reason ever) on the dimmer command. So we set the value of the utility room door (device 35) to “88”.[/li]
[li]The second timer ensures a delay of 30 seconds after starting to close the dining room shutter. That look’s a bit more natural when you are not at home.[/li][/ul]

To open the shutters it’s again a bit tricky. Using the dimmer command will not open the shutter to the end position but close to that. So that is why we use the window cover command class. Problem here is that düwi inverts the commands up=down and down=up.

Example code:
[i][size=9pt]function SunCoverDiningRoomEnd()
luup.call_action(“urn:upnp-org:serviceId:WindowCovering1”,“Up”,{ },32)
end

function SunCoverUtilityRoomEnd()
luup.call_action(“urn:upnp-org:serviceId:WindowCovering1”,“Down”,{ },35)
end

luup.call_timer(“SunCoverDiningRoomEnd”, 1 , “5”,“”,“”)
luup.call_timer(“SunCoverUtilityRoomEnd”, 1 , “35”,“”,“”)[/size][/i]

Thanks for sharing your Lua scripts.

Just a word of caution:

If luup.call_timer(“SunCoverDiningRoomStop”, 1 , “19”,“”,“”) fails and you are outside your home,
you may lock yourself out of your home …

If this danger applies to you, you should adjust the running time of the window/door covering by setting the manufacturer specific Z-Wave parameters (and check that the reconfiguration of your device was successful …).

merten:
http://forum.micasaverde.com/index.php?topic=1937.msg7147#msg7147

düwi:
http://forum.micasaverde.com/index.php?topic=3359.msg16142#msg16142

Thanks for the links and your concerns.

I have two other not Vera controlled doors. So being locked out is not really an issue.

Rgds,