Rules

Hey all,

I would like to hear how you are managing rules. My hub has Rules 1.0. I've seen posts about rules machine 4 for example... Now I see webcore is coming too.

I have a background working with If Then logic so am good with more text base too

Thoughts?

You definitely don't have Rule 1.0 on Hubitat (it pre-dates Hubitat) but possibly Basic Rule 1.0, which is a newer app and a different app, part of Basic Rules and not Rule Machine. The latest version under Rule Machine is Rule 5.1, but you are still likely to see a lot of posts about Rule 4.0 and others. All this to say there are many "rule" options on Hubitat, including:

  • Rule Machine: the most powerful option, but it is a large and complex app that can be difficult to learn if you're new
  • Basic Rule: a simple "when this happens, do this" builder; despite the name, it can still do quite a lot but has a simpler interface that is probably more in line with how people think about creating automations
  • Simple Automation Rules: formerly called Simple Lighting and originated with that purpose in mind, but it was expanded to support more device types and "actions"; I probably wouldn't recommend starting with it at this point given the other options

Soon, there will also be another built-in option:

  • webCoRE: a community-maintained app (which I assume will still be the direction even after integration) that originated on SmartThings but was ported to Hubitat early on, featuring a web-based "piston" (rule) editor

There's more history on webCoRE (and RM) too, but that's a basic summary. :slight_smile:

If you're comfortable with IF THEN logic, Rule Machine or webCoRE will be your best bets (notably, this kind of logic is not possible in Basic Rule, at least not on a granular level using this exact terminology). There are certainly some things that are easier to do or edit in webCoRE, but Rule Machine is a lot more powerful and has an improved interface now compared to earlier versions, so many people who originally avoided it in favor of other options find that it can now do what they want instead.

RM is likely a tad more efficient being all "native" Groovy on Hubitat, though a small purpose-built app will likely be a bit better than either. It's likely to get better "official" support being built-in and supported by a dev who is also a founder, but I'm not sure what the plans for webCoRE are (my guess is ongoing community support from the current maintainers, who have done a great job, along with staff, at optimizing things--so I'm certainly not implying there is no support!).

My personal approach is to use the simplest app that meets my needs; hence, I have my automations spread out among many built-in options, like Notifications, Basic Rule, Mode Manager, Rule Machine, and others -- plus a variety of custom apps I've written for various purposes. Maybe webCoRE will become part of that again; I've always kept it around on a test hub since it has some following, but I haven't done much with it in years in favor of the other options. As usual with Hubitat, there are multiple ways to do the same thing, and some of it just depends on your preferences. :slight_smile:

7 Likes

Thank you for that, yes, I stand corrected, it looks like it is Basic Rule 1.0, So Rule Machine, is this an app I should look to install? At this point, I need to see the various options out there. Last night wanted to look for a way to prevent a rule from running because it was Dec 24. Basic Rule didn't offer anything related to specific dates.

So a lot of the apps are basically subsets of RM that don't have everything that RM can do for simplicity. Go ahead and install RM to open everything,.

It's installed now, next need some time to dig in... Thanks

There's also extensive documentation for Rule Machine (Rule 5.1 is the current version).

https://docs2.hubitat.com/apps/rule-machine

For an alternative viewpoint, all apps are different, generally not just souped-up or pared-down versions of each other. Basic Rule, to my knowledge, was not based on Rule Machine (and the interface certainly wasn't!), but there is a way to "import" a Basic Rule into RM if you want to move in that direction without rewriting (and similar features in a couple other apps, like Room Lighting being able to import a Groups and Scenes app to create the same). I imagine this took a lot of effort to implement on their part, but that's another story.

Rule Machine is "just" an app that lets you create custom automations, including lots of complexity, without writing custom apps in code form--which if you're comfortable with that is certainly another option, and there is a growing collection of developer documentation that may help you get started. But there are some things other apps can do that Rule Machine can't, e.g., Zigbee group broadcasting in Groups and Scenes (really just groups) or Room Lighting, and some things that are a lot easier to do with a purpose-built app that re-creating similar logic inside a rule.

With this in mind, again, my approach is to use the simplest app possible that meets my needs. So, I have a lot under Notifications, many Groups and Scenes (I might have done these as Room Lighting if I started today, but I'm not changing what works...), a variety of custom apps I wrote, some Basic Rules, and, yes, lots of Rule Machine (and now Rule Machine Legacy, which you won't see if you're just starting today) rules. :slight_smile: But that's not my starting point for everything.

Again, your preferences may vary--just thought I'd throw some other viewpoints out there!

2 Likes

Thank you everyone, I appreciate the feedback and direction. Time isn't always my friend, but full expect to pour time into my HE as I can, eventually want to be able to help support like you are . It's going to be a marathon, not a fast race.

Brett

There's one reason why a newer/less experienced user might want to use the Simple Automation Rules. The operation is more intuitive for things like a lighting schedule. Basic Rule uses a wait condition where the 2nd action only happens if the first part of the rule is successfully triggered. SAR schedules both actions.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.