[Released] Rule 4.0

You can't get the new simpler model without throwing out some of the old.

2 Likes

@bravenel,

can you take a look at triggers and conditions for presence devices for a 4.0 rule? I can only select "changed". There is no option to select "arrives/arrived" or "leaves/left"

1 Like

Yep, congrats -- first bug report. Will fix...

Missing parens, from another earlier fix to remove changed from conditions. Fixed and will be in the first hot fix release.

2 Likes

I won't have a chance to play with this for a while, but based on the examples alone, I'm finding it much easier to imagine how to build new automations / rules (for me, anyhow!)

Rule Machine has gone through such a formidable evolutionary growth process. Bravo for all the work that has gone into making it so powerful, yet still approachable! Thank you!

An option for a condition of changed from ____ to ____ would very helpful. Or perhaps a better (easier?) way to implement would be a previous modifier:

IF Mode is Evening AND
previous Mode is Away THEN

Do you also make bets on this kind of "first" as well? :smile:

2 Likes

Cool, procrastinating paid off! :wink:

unfortunately found another

i tried to add a 2nd simple condition and get this

no editing got it straight as i was building the rule

now can't open the actions.

EDIT: repeatable each time on second add of simple condition

Sorry to take the "first bug report" away from you.... I saw you typing while I was typing mine :laughing:

Modes are one capability in RM that don't have changed. So no mode value history is kept.

Having said that, don't hold your breath for previous value to be incorporated. It's an interesting idea that I said I'd think about, but that's it for now. It's not on some list of new features, and I'm unconvinced of its importance.

1 Like

@bravenel HUGE update for me but I noticed a bug. In restrictions when I set a start time and end time then select ‘no selection’ it does not remove the time restrictions

You have to erase the time selections.

This one is found and fixed.

1 Like

Don't know if this was already answered but are we allowed nested if-then-else-endif in RM 4.0?

If ... then
...
if ... then
...
else
...
endif
else
...
endif

If not, I already see some limitations on the new "Select Actions to Run"

RTFM. First post in this topic.

4 Likes

reply for bruce RTFM :rofl:

YES you can :crazy_face::ok_hand::+1:

got there before me :rofl:

Silly me, I was putting 0 in instead of deleting altogether, Nothing to see here!

Is there additional documentation on how to use this "private boolean" ?? I think this will be useful somehow because I currently have a rule that only the light in the zone where is motion detected will be turned on and all others will be triggered by that to be turned off then when I move to another zone the previous zone light will be off and the new zone will be turned on. I have created a home mode called "follow me" so when I activate that mode it will only work in that way (mainly only when there is only 1 person at home) but the problem is that when this is running the hub will have performance issues and not sure if this is because if I am moving from zone to zone fast then many off commands are sent to all the other zones and I am thinking on "private boolean" as an option based on what you described in your post

There's not much to it. Each rule possesses a Private Boolean, that starts out true. You can see its current value by looking in Restrictions. It can be used as a restriction to disable a rule. It can be used as a private variable for the rule's own use. It can be set by the rule, and it can be set by other rules. It can be used as a condition, and it can be used as a trigger event. Very useful for a single bit!

Its original purpose was to replace the need for a virtual switch to keep track of some state.

1 Like

Hi, loving RM 4.0, but I have one question. What does the "cancel" option (toggle) do in actions, since it was stated that "cancel on truth change" doesn't exist any longer? I see you've used it in your examples a couple of times, so obviously an important concept to understand.

There is a new action called “Cancel Delayed Actions”. That action will cancel all the actions where the cancel flag was set. Here is the example out of the description above

https://community.hubitat.com/uploads/default/optimized/3X/2/8/28ec357b8c94548fbfd57f38ee73620815d4edff_2_690x451.png

Thanks Daniel. I do understand this no problems. What I am not sure about is the "Cancel" toggle in Actions. See Photo