First off I'm brand new to Hubitat and I hope I selected the right forum topic. If not, I apologize in advance.
I want to make a fairly complex rule, and I'm not quite sure how to go about it in Hubitat's ecosystem. My son is struggling with staying on track with his school schedule, so I want to make it a bit easier for him to know when he's "in class" vs on break/lunch. I have a Zigbee RGB bulb that I want to configure as follows.
1 minute before his first class starts, turn on the bulb at red. At class start time, change to white. When class ends, change to green. I want to repeat that 7 times throughout the day, with one longer green period in the middle for lunch.
Outside of HE I can think of several ways to do it.
- Set up cron entries for each change time throughout the day calling individual scripts/commands to set the bulb state.
- Have one big script that has the times to change in it, and calling that script once per minute via cron
- Have a script that changes green for 3 minutes, red for one, then white, and call it via cron 4 minutes prior to the first class, and 4 minutes prior to the next class starting throughout the rest of the day.
I'm sure there are others if I sat down and put a bit more thought into it. The problem I can see with trying to do it really any of those methods in Rules Machine (or even Simple Automation Rules) is it's going to clutter up the rule list, and/or it will be "expensive" to run in terms of system load due to checking every minute to see if there is something that needs to be run, and having "waits" in the scripts.
If Rules Machine isn't the best way to accomplish this, I would be open to any suggestions. Simple Automation seems like it would suffer from the same concerns. Thank you in advance for any pointers in the right direction so I can learn the "proper" way to do this within HE.