Time plus or minus delta

deltat: a time lapse handler for eedomus rules

Purpose: Using Influman's Mon Réveil / My Alarm Clock plugin, it is easy to set up "when Time Of Day becomes equal to (scheduling) device xxxxxx" rules to trigger scheduled actions.

The deltat plugin allows the creation and continuous update of http sensors whose values have a given time difference with a fixed scheduling device.

Note: Influman's clock plugin is discussed at https://forum.eedomus.com/viewtopic.php?f=50&t=6020

Example: You may want to wake up every day with one of your favorite tunes. One way to do that is to create a WakeupTime sensor whose value can be adjusted, say at 07:00, and use a rule that says "when Time Of Day becomes equal to WakeupTime Sensor, trigger upnp actuator".

Now, if you wish your bedroom to warm up 30 minutes before you wake up, it can come in handy to create a scheduling device called "Warmup Time" whose value is set to 30 minutes before WakeupTime's value. You can then use a rule that says "when Time of Day becomes equal to Warmup Time, trigger heating actuator". Same if you want your coffee machine to wake up 10 mins before wakeup. Or the living room shutters to open 45 minutes before wakeup etc.

The added value of deltat is that, should you modify your wakeup time, the warmup time will auto-adjust. So will any number of deltat devices that depend on your wakeup time.

Installation After creating a new device with the deltat plugin from the eedomus store, fill in the following info: - the API code of the "source" device (ie the device whose value will be used as a reference to set the new device's value, - select plus or minus if you want the new device's value to be behind or ahead of the reference device, - provide the time difference you want kept between the new and the reference devices. The update period is defaulted to one minute at creation time.

Formats All the scheduling devices using deltat expect values formatted as hh:mm strings (ie compatible with Influman's clock plugin). In addition, deltat accepts the "N/A" (not applicable) notation that you can use if you wish to temporarily disable a scheduling device. N/A as a source value or any invalid source value format will result in the new device taking up the "N/A" value.

Caveat The Time Of Day device from Influman's My Clock has an average beat of one minute, which means it sometimes skips a minute. If you want to schedule actions based on it, you may want to create, in addition to a scheduling device (to eg wake up), a deltat device set for +00:01 compared to the first one. Your wakeup rule will then need to explicitly compare Time of Day to the first "OR" the second device with a repeat period larger than 2 minutes.

Thanks To Influman for his MyClock plugin, which does a lot more than what I use it for.