This object is in archive! 

Why does seperate When rules work better than Combined with mulitple IF statements?

Cristian Carlsson shared this question 6 years ago
Answered

I is sitting and testing rules for my Nodon button there I want to use both click double click and pressed.

If I create three rules with three different When blocks, it seems to work fine, they trigger everytime

example:

WHEN {NodonButton) Button1 Click

do stuff..


But if I create a single When block with the first check on the Any of the button it seems to fail 2 times out of 10 and more often on the lower if blocks..

Example:

WHEN {NodonButton) ANY

IF {NodonButton) Button 1 Click

do stuff..

IF (NodonButton) Button 1 Double click

do stuff..

I have tried to put in a join block but it doesn't seems to make any difference,

Is there anything I have missed? Should I add something else? Or is it better to create 12 seperate rules?

Replies (2)

photo
1

That is a good one, I have a few rules like that for my Zipato Remote and Fibaro Button, Zipato remote works fine but never really made a test like you did, Fibaro Button works but it is unreliable I thought this was a problem with the device. I will test with many rules to see if they work better than one rule.

In theory should work the same.

photo
1

I was only pressing the different buttons for like ten times, and if it is this kind of rules it fails 1-2 out of ten times.. Especially the lower ones..

photo
photo
1

Hi!! I have this kind of rule with a Nodon soft button and it works great for me:


WHEN Any

If BUTTON 1

Do this

end

If BUTTON 2

Do that

End

If...


Yesterday I had some issues with rule creator not saving/modifying my rules. Maybe is this?

photo
1

It looks exactly like my rules..


Don't think it is saving the rules, I have logged out and in again and changed the same rule and they do work sometimes when it is "any" with it...


I do have it with scenes, so also are using the button 1 doubleclick, do you use that?

photo
Leave a Comment
 
Attach a file