This object is in archive! 

The logics of SET <sensor> TO true/false

Marius shared this question 4 years ago
Answered

is the SET mySensor active TO true the same as SET mySensor inactive TO false?


This is kind of "double positives", and I wonder if both statements will work to set my virtual sensor to the active state.


(and of course vice versa when setting to sensor state to disabled)


i could of course test this, but with no debug output and a simple way to run rules, this is a pain in the b*tt.

Comments (6)

photo
1

Either my if statement is wrong (can I use between when passing midnight?) or my setting of the sensor is wrong. It allways sets my sensor to true/enabled.


Any ideas?

photo
1

Dear Marius,


No that is not the same. The field inside Set puzzle where you have "true"or "false" is automatically adjusted when you select Active/Inactive. If you manually change the "true" or "false" status inside SET puzzle (like you did in the Rule example) , you will have issues. In order to resolve this issue reattach your sensor to Set puzzle and choose "active" or "inactive" and do no change "true" and "false".


Best regards,

Pero Zovkic

photo
1

O, thanks Pero. This is a little confusing though. In my mind, enable:=true => enabled, and enabled := false => disabled.

What about the TIME BETWEEN. Will it work for a period spanning over midnight?

photo
1

Dear Marius,


If you manually change the "true" and "false" status, rule creator will ignore status before (Inactive or Active). This can cause issues in which your rule will not perform correctly.


For your second question, please see attachment.


Best regards,

Pero Zovkic

Files: Rule.JPG
photo
1

Thanks! What is the different between "TIME OF" and "TIME" puzzles?

photo
1

Dear Marius,


In TIME puzzle you can choose predefined time.

In TIME OF you will need to put something that will defined your time.


Best regards,

Pero Zovkic