Rule machine 5.1 question and bug?

First question....
When using and If/THEN/ELSE and a comparison, there are the expected <>>= tests, but there is one that I have NO idea what it does or how it works.
That is "in". What is this used for?

I haven't found any info on this option.

Second....
When editing in "manage conditions", and if I don't want to change a condition, a "cancel this condition" appears and IF I click on it, my condition is DELETED with NO warning!!!!

I would think a safe way to leave this editing would be to WARN of deletion, or add a "cancel editing" button WITH the warning.

I probably shouldn't answer because I don't really know. However my bet is when using the "in" comparison the next operand could be a list or map or some collection of things.

1 Like

Thanks JohnRob, that is sort of what I thought but haven't tried it yet.
I was hoping for an explanation from people that have used it, but I am open to anyone's ideas.

1 Like

I've used the "in" test when comparing numbers and it allows you to give a range. For example, your temperature sensor could be checked to be in range 68 to 72 using this feature.

Thanks kewashi. That would simplify my rule greatly and make temperature testing simpler.
I will give it a try!

1 Like

I had no idea what it meant either. so good to know. I had seen it and kept meaning to check it out and see what it was but just never did. It might have come in handy had I know that is what it was. Perhaps "In Range, or "Within" ight be a better description.

1 Like

This is where I used the "in" on my rule:

I am wondering about any overlap between the ranges affecting operation, such as
range 82.0 to 84.0
and
range 84.0 to 86.0
causing problems, but I will see what happens.

I am using the Zooz zen54 0-10 volt dimmer to control a Teco VFD driving a 3 ph. fan motor speed.
Seemed to work ok this morning, but I am going to test again tonight (7/31) to see if there is any "hunting".
My original rule looked like this:

Accomplished the same thing but was harder to create and/or modify, and didn't look as clean.

1 Like

Would be much cleaner and easier to read if you used ELSE-IF rather than ELSE … IF

1 Like

Yes I agree. I kinda noticed that AFTER I wrote the rule, but decided to quit while I was ahead.
There are several ways to write a rule and not being a hard core coder (more of a "hobby"), these things I tend to gloss over.... as long as it works!
I may get enthusiastic and re-write it to follow the correct methods.

1 Like