Rules engine
From eedomus - Documentation
Contents |
Introduction
The use of rule engine allows for many custom features. Caution, however, its use is reserved for expert users.
To access the rules, you must switch your account to Expert Mode (Setup / My Account).
We recommend that you familiarize yourself with the rules by beginning with simple examples.
Two trigger types are possible:
- On criteria
- On schedule
Generally, it is not needed to use scheduled triggers, rules based on criteria will trigger responses when there is a change in information. However, the use of a schedule may be helpful to force a trigger, for example in cases when there is no contact with the server or when there is no change in information for a certain period of time
Criteria
The criteria should always be checked before the rule is executed (even if it is a rule schedule).
You can use one or more criteria (values with AND and OR). The order is parenthesis ((criteria_1 and / or criteria_2) and / or criteria_3) and / or criteria_4.
Types of criteria:
A criteria is in general a device that takes on a certain value, for example, a movement detector senses a 'Movement'.
The term "equal" just very generally (the word "now", "becomes" should be used with a good understanding of their involvement).
The term "now" is an additional criterion from the date of value: the value must be obtained in time for the rule is triggered. In other words, = is now measured at time '. The term "now" should not be used on rules "schedules".
The term "becomes" (as opposed to "is"): means that the value was not equal to the target value at the previous measurement. That is equivalent to two criteria = "is" + "was not before".
The latter is a technical field (leave empty).
Suggestion:
For a rule, there is usually a single criterion "becomes" in the criteria: it is the main sensor that triggers the event. The other criteria are "is". Criteria "now" are more difficult to use, and are not generally necessary. They mean that the value has just passed in this state in a few seconds before.
An example of criteria for determining a motion detector switches to motion.
An example of a criterion to check that there is no macro that works on the device (for use with other criteria). A macro is a set of action which will execute sequentially on the device (which can be seen in brackets next to the value of the device). Macros can only exist for actuators (not for sensor).
Special case: has not changed
The criteria has not changed since xx minutes must be used with another event (it does not check itself).
Usually, you have to use a time trigger (every 1 minute, or every 0,15,20,45 minutes for example).
Actions
You can activate one or more actions. You could also have no actions but could still generate notifications on the portal, by email or SMS.
Actions are possible only to the "actuators" (or virtual states). The rules do not allow to activate another rule, change the value of a sensor, etc..
You can also start (or stop) a "macro" (i.e. a set of actions previously defined on a module).
Macros are available by default. Macros parametrise the configuration of each actuator (in expert mode).
Notifications
Notifications are a message sent to a user when initiated by a rule. Messages can be personalized.
Notifications can be sent via:
- Web (on the browser by going to secure.eedomus.com). Web notifications are not visible on the mobile version to date.
- SMS - App notification (with Premium subscription)
- Audio (Loudspeaker - eedomus+ only)
You can use multiple notifications at once, with a different message for each notification.
Special case
The rules generated automatically by Programming can not be modified, saved, or deleted. The buttons "save" and "delete" will be greyed out.
Example
An example to light a lamp every weekday at 10:00.
Tricks
If your sensor's data contains rare erroneous values, you can eliminate them in a rule with 2 criteria, such as this example of temperature readings (see image on right).