Feature Request - Make rules actionable objects

I’m referring only to the Enable\Disable property. A couple of examples:

  1. With the addition of a Date function I’d have a rule to disable all my AC rules at the end of September and enable all my Heat rules at the end of October. Save energy on those shoulder months.
    Note: With date functionality on Halloween all of my outside lights would be orange or green on St Paddy’s day.

  2. Not everyone is tech savvy. If there is some rule that is annoying other members of the household then the can simply press a (Samsung) button to disable the rule. This would cut down on the irritation felt by other members of the household while the rules are being developed. For example we have a vent fan that runs based on a temperature differential. If you are having a sleepless night and the noise is bothersome a simple button press could turn it off and disable the rule so it does not come back on again. Another rule could re-enable it at 8:00 AM each morning.

2 Likes

@Gary_Milne, thanks for the feedback as these are what makes RE better. :blush:

For the AC adjustment rule based on current month/season, will that be more accurate if the condition is based on the weather/temperature instead of just the month/season?
I can see the use of enabling/disabling the rule based on the date for holiday/anniversary. Since this is the first date condition/function request we’ve received, I will need to spend some time to think about the design and see community interests to determine the priority, but I am adding this to the list.

This sounds it can be achieved based on how you described it. You can create a virtual switch and add it to the IF_Condition to determine if the rule should continue to run the desired actions. Then you can use a Samsung button or a tile to control this virtual switch’s status, and have another rule to reset its status every morning. In this case, the rule will be triggered every single time, but only executes the actions if you allow it.

I could use the Virtual Switch route but it could get messy over time.

Here is a better scenario for the use of disabling rules.
My wife works M-F 7:00 AM - 4:30 PM. I’m often home during that time so I have a variety of climate rules that I tell only to run during (Motion and Presence) her work hours. I have to add those time window conditions to each of the rules. If I want to change times, I change each rule separately.

Instead, if I could disable Rules I would simply have one Rule that disables all those M-F 7:00 AM - 4:30 PM climate rules at 7:00 AM and re-enables them all at 4:30 PM. A more graceful solution IMO.

1 Like

@josh and I just had a quick discussion on this and it sounds we can include this into the rule variable requirements/design. For example:

  1. User can change the variable state in the UI, or have a rule to be trigger by a smart button push and toggle this variable between true and false. Then this variable can be used in other rules’ IF_Condition to determine if the rule should continue to execute actions or not, like enabled or disabled basically.

  2. User can define Time data type variables, ex: start_time and end_time, and use these in the rules. So if user has multiple rules with current time between start_time and end_time as condition, then user only needs to change the start_time and end_time variables’ values, which will impact the rules referencing these variables, instead of having to change the time condition in each of them.

So this approach can be more extensible and flexible. I am noting these to my work item, but feel free to let me know if you have other thoughts.

1 Like

If I understand correctly I will be able to create a range of variables somewhere in SharpTools and then I can reference them in a rule through some kind of picker?

Would I be able to define a group of data such as @Weekdays or @WorkHours? Even better would be @ScheduleA which would contain a combination of Weekdays and Hours.

If @ScheduleWorkHours
If @ScheduleWeekend
If @ScheduleEvening
If @ScheduleSleep

So many events are time driven this would be a very useful simplifier IMO.

2 Likes

Conceptually yes, but we need to spend some time to think about how the variables UI and design is extensible in different scenarios. And this is a great feedback. Thanks.:sunglasses:

@Gary_Milne, we have released the Variables for Dashboard and Rule Engine features to SharpTools.io today, and I think you might be interested to give it a shot. :wink: You can create a True/False variable and use this variable in the rules to decide the rules should continue execution or not. This variable can also be added to the dashboard, so you can enable/disable multiple rules in the same time by tapping this variable tile in the dashboard without the need of using Virtual Switch.

See the release post for more details and let me know if you have any questions. (Date/time variable types are still in my list and are not available in this release.)

Hey having some trouble understanding the variables, i am trying to make a virtual switch (which i have made in smarthings)which will disable my door open rule which tells my google assistant to tell me a door is open, what i am trying to do is have a button in my settings dashboard to turn off these rules when the virtual switch is on to basically tell it not to sound the notification, so like at night after people are asleep i dont have the notification waking them up?

The annoying thing is you can’t insert an if argument without recreating the whole rule.

So you need to recreate your current rules, but start with an if argument. For example, instead of

  • if door open → send message
    You turn it into
  • if switch is on then if door open → send message

You can choose if you use an on - off variable for this, or make it more complex with text variables.

For example, I always fall back to my garage doors and gate as example :sweat_smile:, I can select which ones need to open when I leave.
When I take the car that’s outside, I select gate only, when I close the back door, the gate starts to open.
If I select left garage door, the rule runs a portion that reacts to the closing of the garage door and opens the garage door and the gate.