Events Reactions Scripts

This section provides reference and background information for integrating the Events Reactions Scripts extension module. For related procedures, see the step-by-step section.

This extension provides Desigo CC scripts that can execute macros in response to event status changes within a particular scope.

info

The logic of the Events Reactions script works for macros. To command points different from macros, you must modify the code of the script.

The Events Reactions Scripts

After installing the extension, you can import the Events Reactions script and open it in the Desigo CC Script Editor.

Inside the script, a scenario variable lets you set one of three options:

Three further variables, SetOfMacros_A, SetOfMacros_B, and SetOfMacros_C, let you define one or more macros to execute for each situation in the scenario, as in the table below:

 

Set of macros to execute when..

scenario

Alarms occur in the scope

First alarm acknowledged

All alarms acknowledged

All alarms cleared

1

SetOfMacros_A

SetOfMacros_B

--

--

2

SetOfMacros_A

SetOfMacros_C

--

SetOfMacros_C

3

SetOfMacros_A

--

SetOfMacros_set B

SetOfMacros_C

Scopes in the Event Reactions Script

The Events Reactions script operates within the scope rights of the Desigo CC user who starts the script. This means that:

NOTE: A scope is typically a collection of system objects of a building, district, or any other logical entity (based on the customer’s system architecture). Scopes are assigned to Desigo CC user groups, and individual Desigo CC users have access to the scopes associated with the user groups to which they belong.

Use Case Example for Event Reactions Script

The table below provides use-case examples for three scenarios in which the macros execute the following actions:

Scenarios

Script Configuration

Use Case Example with macro for activating emergency light

Scenario1

  • When an alarm occurs, setOfMacros_A will be commanded.
  • When one of the occurred alarms is acknowledged, setOfMacros_C will be commanded.

If an alarm occurs within a specific scope, the emergency light starts flashing in the specific department. When the alarm is acknowledged, the emergency light turns off.

If many alarms occur within the specific scope simultaneously, the emergency light starts flashing in the specific department. After the first alarm is acknowledged, the emergency light turns off.

Scenario 2

  • When an alarm occurs, setOfMacros_A will be commanded.
  • When one of the occurred alarms is acknowledged, setOfMacros_B will be commanded.
  • When all the alarms are cleared from Event List, setOfMacros_C will be commanded.

If an alarm occurs within a specific scope, the emergency light starts flashing in the specific department. When the alarm is acknowledged, the emergency light becomes steady. When the alarm disappears, the emergency light turns off.

If many alarms occur within the specific scope simultaneously, the emergency light starts flashing in the specific department. After the first alarm is acknowledged, the emergency light becomes steady. Only after all alarms have disappeared, the emergency light turns off.

Scenario 3

  • When an alarm occurs, setOfMacros_A will be commanded.
  • When all the alarms are acknowledged, setOfMacros_B will be commanded.
  • When all the alarms are cleared from Event List, setOfMacros_C will be commanded.

If an alarm occurs within a specific scope, the emergency light starts flashing in the specific department. When the alarm is acknowledged, the emergency light becomes steady. When the alarm disappears, the light turns off.

If many alarms occur or are present within the specific scope simultaneously, the emergency light starts flashing in the specific department. Only after all alarms are acknowledged, the emergency light becomes steady. Only after all alarms have disappeared, the emergency light turns off.