I'm using the Wemos D1 mini to control my Axa Remote by relays.
I use the following rules for opening and closing the window.
on wcraam-open do
gpio,0,0 // relay on
timerSet 1,2 // 2 seconds timer
endon
on Rules#Timer=1 do
gpio,0,1 // relay off
endon
on wcraam-dicht do
gpio,5,0 // relay on
timerSet 2,2 // 2 seconds timer
endon
on Rules#Timer=2 do
gpio,5,1 // relay off
endon
Now I want to activate the "Stop function" and my question is how can I combine both rules to one new rule with the name wcraam-stop and a pause of 20 seconds between both rules.
I have tried several possibilities but my knowledge is too limited to get this done.
Who can help me to make this possible.
Problem with rule for Axa Remote [SOLVED]
Moderators: grovkillen, Stuntteam, TD-er
Problem with rule for Axa Remote [SOLVED]
Last edited by ManS-H on 29 Aug 2021, 13:08, edited 1 time in total.
Re: Problem with rule for Axa Remote
Hmm this might get a bit complicated very easily when adding new combinations, but I guess just a stop may be managable.
I do see that we might benefit from a new feature to schedule events at a specific time.
I do see that we might benefit from a new feature to schedule events at a specific time.
Code: Select all
on wcraam-open do
gpio,0,0 // relay on
timerSet 1,2 // 2 seconds timer
endon
on Rules#Timer=1 do
gpio,0,1 // relay off
endon
on wcraam-dicht do
gpio,5,0 // relay on
timerSet 2,2 // 2 seconds timer
endon
on Rules#Timer=2 do
gpio,5,1 // relay off
endon
on wcraam-stop do
asyncevent,wcraam-open
timerSet 3,20 // 20 seconds timer
endon
on Rules#Timer=3 do
asyncevent,wcraam-dicht
endon
Re: Problem with rule for Axa Remote
Thanks TD-er,
That was the solution, asyncevent.
I control AXA with three relays for each command one relay, so i changed the code a bit. And this works as a charm.
That was the solution, asyncevent.
I control AXA with three relays for each command one relay, so i changed the code a bit. And this works as a charm.
Code: Select all
on wcraam-open do
gpio,0,0 // relay on
timerSet 1,2 // 2 seconds timer
endon
on Rules#Timer=1 do
gpio,0,1 // relay off
endon
on wcraam-dicht do
gpio,4,0 // relay on
timerSet 2,2 // 2 seconds timer
endon
on Rules#Timer=2 do
gpio,4,1 // relay off
endon
on wcraam-open/stop do
gpio,5,0 // relay on
timerSet 3,2 // 2 seconds timer
endon
on Rules#Timer=3 do
gpio,5,1 // relay off
endon
on wcraam-stop do
asyncevent,wcraam-open
timerSet 4,20 // 20 seconds timer
endon
on Rules#Timer=4 do
asyncevent,wcraam-open/stop
endon
Re: Problem with rule for Axa Remote [SOLVED]
Great 
I wonder if using a slash will ever lead to issues in an event 'name', but I guess it will not really be a problem.

I wonder if using a slash will ever lead to issues in an event 'name', but I guess it will not really be a problem.
Re: Problem with rule for Axa Remote [SOLVED]
Well you can send events via more ways than just the rules.
For example via HTTP.
Not sure what will happen if you try to send an event command via HTTP, since a slash can be part of an URL.
But I am not sure it can also be used as a GET parameter.
For example via HTTP.
Not sure what will happen if you try to send an event command via HTTP, since a slash can be part of an URL.
But I am not sure it can also be used as a GET parameter.
Who is online
Users browsing this forum: No registered users and 22 guests