Hello and welcome to a new guide on how to best use Movicon.NExT™.
In this technote you will learn how the alarms of a Movicon.NExT™ project can be linked to a
statistical value of the tag.
Alarms and statistic
values
We have already seen what tags and their statistical values are
in their related videos. Now we will see what an alarm is.
The alarm is the status of a tag after its value reaches a certain
condition.
The Movicon.NExT I/O Data Server has a module, the Alarm Manager, which
is used to manage the alarms. The latter are configured in the I/O
Data Server’s Alarms tab.
As with most SCADA, you can also assign the alarm of a tag to a source
assigned to an area in Movicon.NExT. Basically, the alarms are placed
in a tree structure according to the following scheme: the Alarm Manager
has areas listed underneath it; an area contains one or more sources
that in turn have their own alarm definitions.
In addition to assigning an alarm to the tag’s absolute value, Movicon.NExT
also allows you to assign an alarm to a tag’s statistic value.
Example
Let us build an example to clarify the scenario. Open the Movicon.NExT
editor and create, or load, a project.
Inserting a communication driver
To insert an I/O Driver, the Demo driver for example, do as follows:
Open the I/O Data Server
located in the project resource tree in the Project Explorer Window
and select the I/O Driver tab to add the OPC UA Client driver.
Once
the I/O Driver has opened, right click on the workspace, and select
the Add New Driver option from the menu that appears.
Select
the Demo driver from the list that shows. Click on the arrow to
go ahead and configure it.
Leave
all settings set for default in the Driver's General Settings
window and proceed by clicking the arrow to go ahead to the next
step.
Leave
all the values set for default in the Driver's Channel properties
and go to the next step by clicking the arrow.
Leave
all the driver's Station's properties in the configuration window
set for default and proceed to configure the driver by clicking
the arrow.
To
conclude the configuration procedure, click on the Finish button
to insert the driver on the project’s driver list.
Creating a tag
Now we will create a tag to connect to the driver. To do this:
Having
the I/O Data Server open, go to the Tag List by selecting the
corresponding tab.
Right
click on the workspace and select the Add New Tag option from
the menu that appears.
Configure
the tag using the properties window in the following way:
Name:
StatTag
Model
Type: Variable
Data
Type: Int32
Enable
Tag Statistics: checked
Retentive:
checked
Confirm
the changes by clicking on the Accept Changes icon on the tag's
property window toolbar at the top.
Search
for the Physical I/O Address option in the tag's Execution property
group and click on the three dots within brackets on the far right
to access the tag's Driver address configuration.
In
the popup that shows, you can choose Simulation types from the
combobox. In our example, we will select Random as Demo Type.
Configure
the following properties in this way:
Min Value: 0
Max Value: 100
Link Type: Read Only
Station: Station0
Click
the OK button to confirm the configuration.
Confirm
the changes by clicking on the Accept Changes button on the tag's
Properties window toolbar.
Once the tag has been configured, save the project by clicking on
the Save All button on the Movicon.NExT editor's top toolbar.
Creating and associating an alarm
We will now associate the alarm to the StatTag tag's statistic value.
To do this:
Open the I/O Data Server in the project tree within the Project
Explorer window.
Select the Alarms Tab to open it.
Expand the items in the Alarms tab until you reach the source
item.
Select the source and right click to open the contextual menu
and select the Add New Alarm Definition from the menu.
Configure the new alarm in this way:
Name: NumUpdateAlarm
Alarm Type: Trip Alarm
Statistics Data: Num Updates
Activation Condition: Greater than
Activation Value: 100
Once the alarm has been configured, select and right-click
it.
Click the Assign Tag option and select the StatTag tag from
the table that shows.
Creating the screen
We shall now create a screen:
Look
for the Screens resource in the project's tree structure in the
Project Explorer window and select it.
Right-click
it and select the New option from the menu which appears. A New
Screen popup will appear to set the screen's main properties.
Configure
the screen as follows:
Width:
1920
Height:
1080
Nome:
Main
Click
the OK button to confirm the configuration.
Once the screen has been created, we can now change the project's
properties by inserting the screen as the project's Main screen to
show when the project starts up. To do this:
Select
the name of the project from the application's tree structure.
Open
the Properties window.
Change
the following project properties as follows:
Startup
Page Type: Main Screen
Startup
Screen Name: Main
Once you have finished configuring the project startup page, click
on the Save All icon the toolbar at the top to save the project.
After opened the Main screen, click on the Toolbox tab on the far
left of the editor, next to the Properties window, to open the Toolbox
library provided by the software.
Expand the Display folder and select and drag the Display object onto
the screen. Select the Display object on screen and open its Properties
window.
Go to its Tag property and click on the corresponding button with three
dots to configure it.
A window will show allowing you to select a project tag, a local client
tag, a system tag, or an item from a third-party OPC UA Server. Select
the I/O Data Server tab and select the StatTag tag we previously created.
Repeat this procedure to insert a second Display object and assign
the StatTag variable.
In addition, select a statistic value to display by expanding the Advanced
property group section and selecting Num Updates from the combobox.
The last object to add to the screen is an alarm viewer. To do this:
Open the toolbox and expand the Alarm Viewers folder.
Select and drag the Alarm Window onto the screen.
Once you have finished configuring the screen, click on the Save
All icon the toolbar at the top to save the project.
Runtime Test
Launch the project into runtime by clicking on the Start Runtime
button to test what you have created.
As soon as the number of the StatTag Tag's updates exceeds 100, a row
with the tag's related configured alarm will show in the Alarm Window.