How to use "Trigger"

Task 1. On the analog sensor frequent jumps of measured value (eg voltage transient), with direct sending messages to switch sensor mode High Alarm created too many notifications and such rigor is not required.


Option 1. You can create a logic circuit using the delay (Timeout), before the switching element in the new state when logic is triggered (see picture below). Then SMS notification will be sent only if the sensor Analog-1 moved to the High Alarm Mode, and maintained its position throughout the delay time (in this example, at least 30 seconds). However, this option does not allow for detecting transient sensor values.

 

Option 2. If it is necessary to respond to momentary sensor value jumps, but ignore the subsequent ones, if they occur too often. Then you can use the type of item "Trigger" as an intermediate event flag. First, create itself trigger and logic circuit activating it.



Then create a logic that sends a notification, and automatically turns off after a specified trigger our time, this time determines the highest frequency of notification of arrival (in this example, no more than once every 15 minutes).

Thus, the first pressure sensor Analog-1 (even short-term) under the logic Logic_02_1 will activate (turn on) Trigger_1 trigger. Trigger logic Logic_02_2, which sends a notification SMS01. In this re-activation sensor Analog-1 does not trigger Trigger_1, because it is already activated (tripped). The trigger is reset automatically after a time specified in the Timeout field Logic_02_2 logic circuits, and only then Analog-1 status change again leading to a mandrel notice.

 

Option 3. If you need to react to the 'High Alarm' sensor transition, ignore the rest until the sensor value stabilizes in a 'Normal' state.

When the sensor reaches the High Alarm state, we send a notification and set the trigger. Release the trigger, thereby allowing re-sending of the message in case of alarm, only when the sensor has been in a stable Normal state for a long time (5 minutes).

 

Task 2. When the temperature is exceeded, an alarm message is sent to the monitored room. It is necessary to temporarily block the sending of an alarm if a door opens into the room, i. The temperature jump is caused by external circumstances, and not a malfunction of the equipment.

Create a trigger that will allow you to "remember" the moment of the door sensor is triggered.

Create a logic that turns on the trigger when you open the door. You can add a delay of 2 seconds, this will avoid accidental triggering.

 

Create a logic that turns off the trigger with a delay of 15 minutes after the door is closed.

Now create the logic for sending alarm messages. The message should be sent only if the trigger is disabled.

In this way, the activation of the door sensor will block the alarm for a set time. The temperature output beyond the set limits due to the open door will not trigger an alarm. After the door is closed, enough time will elapse before the temperature returns to the normal one before the alarm is unlocked.

 

Task 3. It is necessary to send a "Keep Alive" message about the "normal" state of the ping at the specified time. If there is a ping failure, then the message is not sent.

To do this, we need a "Timer", and create a timer of the type we need (weekly). Let the message be sent from Monday to Friday at 12:00:00 p.m. Set the duration of the timer to 5 seconds (12:00:05 PM).

Create a trigger that will display the normal state of the ping.

Create a logic scheme to control the trigger. "Ping to server" is the ping element to be checked. This scheme turns on a trigger if at least one failure occurred while checking the ping.

Now, create a logic scheme to send the message. The message is sent only if there is no ping failure, i.e. trigger in normal state.

In addition, we need a logic scheme to turn off the trigger, if it was turned on. Remember that the logic scheme is activated when the “IF” condition changes. This logic will only work when the timer is turned off (normal state), i.e. at 12:00:05 PM.

Task 4. It is necessary to switch the backup load every 8 hours. 8 hours running one device, then 8 hours running another device. 

To do this, create a trigger to switch between devices. 

Then create two logic schemes to switch the trigger to ON and OFF state. 

Then create two logic schemes for device management.