Manual RapidScada
Manual RapidScada
Characteristics
Rapid SCADA provides creation of automated systems of the following types:
Rapid SCADA is a software that automatically collects data communicating with controllers,
processes data and provides information to a dispatcher. Rapid SCADA supports
commonly used communication standards such as Modbus protocol and OPC that allow
using a huge amount of various devices. The list of supported devices can be extended by
developing additional drivers.
Rapid SCADA consists of the set of application and libraries. The software is a platform
which allows flexible system configuration to meet the customer needs. Rapid SCADA is
open source software, its internal data formats and communication protocols are
documented. This approach simplifies integration of Rapid SCADA with other applications
to create complex enterprise-wide solutions. Functionality of Rapid SCADA can be
enhanced by adding custom modules which implement required features.
Access to information and control functions in Rapid SCADA is restricted according to user
rights. The ability to use Active Directory for user authentication significantly increases the
safety of storing passwords. User rights management using Active Directory eliminates the
system administrator from manual input user logins and passwords.
Characteristic Value
Providing data access using web technology significantly simplifies the deployment and
maintenance of the system, which is especially important for a large number of users.
Commonly used devices controlled by a system are electricity meters, heat meters, fire and
security alarms, access controllers and other equipment.
Description of Applications
Server Application
Server manages the archive database, performs mathematical calculations and provides
information to the client applications. Server writes data to the main archive and makes the
backup copy simultaneously.
Server consists of a Windows service and a graphical shell. The shell is shown in Figure 1.
The service does not have user interface. It operates continuously in the background
regardless of user login and logout.
The application monitors user connections and checks user rights while processing
requests and passing commands. Information about the application state and performed
actions is stored in text log files. Server is designed for non-stop running.
Additional server modules allow extending the functionality of Server according to customer
requirements.
Communicator Application
Communicator interacts with controllers and transmits data to the Server application.
Communication with controllers connected to a system is executed in parallel across
multiple lines. Communicator receives current data, archive data, events from controllers
and sends commands to controllers. The application helps troubleshooting issues with
communication lines and devices.
Developers are able to implement their own device libraries (drivers) to interact with a
variety of controllers.
Webstation Application
Webstation is a web application that displays information to a dispatcher via browser in
different forms (tabular, schematic, diagrams, reports, etc.) and provides sending
commands. Reports are generated in commonly used HTML and Microsoft Excel formats.
User is able to choose a view (table or scheme) and a date to access archive data. To
show a diagram of an input channel, click an item icon in a table or an appropriate element
in a scheme.
The functionality of Webstation can be extended by additional plugins. For example, Chart
Pro Plugin extends the capabilities of Rapid SCADA charts: adds scaling, displaying of
multiple charts, export to PNG and PDF. Elastic Report Plugin allows to generate reports
according to a custom configuration. Using this plugin, you can build almost any desired
report. Developers can download Rapid SCADA source code and the documentation to
learn how to implement plugins.
Administrator Application
Administrator is designed to manage the configuration of the system (see Figure 1).
Configuring is a process of editing the configuration database, which is a structured
description of the entire automated system.
Figure 1. Administrator application
The key features of Administrator designed for fast creating and comfortable modifying the
configuration database are listed below:
1. Import and export between different configuration databases allows reusing developments.
2. Channels clone function minimizes manual input.
3. Automated creation of channels based on the available devices.
4. Backup the configuration database.
Choose the channels from the configuration database in the left pane of the window, and
add them to the table view. The contents of the table view is displayed in the right pane.
There are two options how to bind output channels to items of a view:
Hidden items of a table view are not displayed but they affect event filtering by view in
the Webstation application.
A scheme consists of textual and graphical elements which have a set of properties define
their appearance and behavior. Static elements display unchanging content. Dynamic
elements are bound to the channels of the configuration database that allows to display
current measured values and states, draw charts and send commands by user click.
Rapid SCADA contains its own built-in DBMS, so no additional charge for third-party DBMS
is needed. The software can work either on physical or virtual environment.
Software Installation
Before Installation
Rapid SCADA requires certain Windows components to be installed. Go to Control Panel >
Programs > Turn Windows features on or off. The required compontns of Microsoft .NET
Framework are shown in Figures 1 and 3. Pay attention that Windows Communication
Foundation child components of Microsoft .NET Framework 3.5 must be turned off.
The Webstation application requires Internet Information Services (IIS) that is a one of
Windows features. Webstation would be inoperable unless the set of certain IIS features
were turned on. Figures 2 and 4 show what features have to be installed. During the web
application setup the availability of these features is checked by the installer.
Figure 1. Windows 7 .NET components
Installation
Execute ScadaSetup.exe to start installation. A user account that has administrative rights
should be used. The installer is shown in Figure 5.
Microsoft .NET Framework 4.0 is required to run Rapid SCADA. It will be installed
automatically during the installation process if necessary. In case of using outdated
operating system such as Windows XP or Windows Server 2003, Microsoft .NET
Framework 3.5 SP1 has to be downloaded and installed first.
Before the installation starts, user is asked for choosing the applications and the installation
directory (see Figures 5 and 6). This directory specifies the location of the entire software.
The installer creates subdirectories required for the chosen applications. The default
directory C:\SCADA is recommended due to simplifying configuring the applications.
The web application installation options (see Figure 7) are agreed with a system
administrator. If there are no specific requirements for the web application, you should use
the default values.
Figure 7. Web application installation options
When installation is completed, it is recommended to check that the Scada web application
uses an application pool having .NET 4.0 runtime version and integrated pipeline mode. IIS
management console path is Control Panel > System and Security > Administrative Tools
> Internet Information Services (IIS) Manager.
Manual Installation
Manual Rapid SCADA setup provides full control over the process of the software
installation and uninstallation. Manual installation could be used when installing Rapid
SCADA on obsolete operating systems, such as Windows XP and Windows Server 2003
that are not officially supported.
1. Install Microsoft Internet Information Services (IIS) by selecting the appropriate Windows
features. If Windows 7 is used, open Control Panel > Programs > Turn Windows features
on or off.
2. Install Microsoft .NET Framework 4+ (install IIS before the framework).
3. Unzip files from the Arc folder of the installation pachage to the SCADA installation
directory. Recommended destination is C:\SCADA
4. Open IIS management console: Control Panel > System and Security > Administrative
Tools > Internet Information Services (IIS) Manager.
5. Add a web application to the site tree. Right click the appropriate site, Default Web Site in
most cases, then choose the Add Application menu item.
6. Enter the application alias: Scada. Check that the selected application pool uses .NET 4.0
runtime version and integrated pipeline mode. Specify the physical path to the web
application files: C:\SCADA\ScadaWeb. Then click OK.
7. Register ScadaServerService by executing ScadaServer\svc_install.bat as administrator.
8. Register ScadaCommService by executing ScadaComm\svc_install.bat as administrator.
9. Create shortcuts for the applications on the desktop if necessary.
10. Install Microsoft Silverlight required for the Scheme Editor application.
11. Run the applications.
Installation of Additional
Modules
Rapid SCADA supports additional modules which extend the software functionality. This
section contains a description of the common installation sequence that is typical for most
modules.
1. Stop the Server service using the button, and close the Server graphical shell.
2. Unzip the module installation package.
3. Copy all the files from the SCADA folder of the module installation package to the Rapid
SCADA installation directory, the default is C:\SCADA, with the hierarchy of directories
retained.
4. In case of using Windows 8 or higher, find C:\SCADA\ScadaServer\Mod\Mod*.dll, open the
file properties and unblock the file.
5. Run the Server graphical shell and go to the Modules page.
6. Click the button, then use the file dialog to select the module library and apply the
changes with the button.
7. Start the Server service using the button.
8. Perform the configuration of the module specified in the module documentation.
1. Stop the Communicator service using the button, and close the Communicator graphical
shell.
2. Unzip the driver installation package.
3. Copy all the files from the SCADA folder of the driver installation package to the Rapid
SCADA installation directory, the default is C:\SCADA, with the hierarchy of directories
retained.
4. In case of using Windows 8 or higher, find C:\SCADA\ScadaComm\KP\Kp*.dll, open the file
properties and unblock the file.
5. Run the Communicator graphical shell, then start the Communicator service using the
button.
6. The driver is ready to use.
Run Applications
The applications of Rapid SCADA can be started using the shortcuts that located in Start >
Programs > SCADA or using executable files directly.
The default startup type of the Server and Communicator services is Automatic, i.e. the
services start when an operating system starts, and services stop when the OS stops. If
auto start is not necessary, Manual startup type could be set (see Figure 1). To open a
service properties follow Control Panel > System and Security > Administrative Tools >
Services. The services names are ScadaCommService and ScadaServerService.
Figure 1. Setting Windows service startup type
Webstation is a web application which is accessible via a browser such as Chrome, Mozilla
Firefox or Microsoft Edge. The address looks like http://compname/scada/ where
compname is the host name or IP address of the computer with the installed web
application, scada is the virtual directory specified during the installation. If Webstation is
opened on the same computer on which it is installed, it is possible to
use http://localhost/scada/ or http://127.0.0.1/scada/
If the selected installation directory differs from the recommended directory C:\SCADA, the
directory settings of the applications should be checked and adjusted at the first using if
necessary.
1. Ensure that connections between the server and the devices are properly configured: the
required serial ports exist, industrial controllers available via the network, etc.
2. Install Rapid SCADA on the new server, but do not start Server and Communicator
services.
3. Stop Server and Communicator services on the obsolete server. Set Manual startup type of
these services.
4. Copy the content of the directories listed below from the obsolete server to the new server
(default directories are shown):
C:\SCADA\BaseDAT
C:\SCADA\BaseSDF
C:\SCADA\Interface
C:\SCADA\ScadaComm\Config
C:\SCADA\ScadaServer\Config
C:\SCADA\ScadaWeb\config
5. Copy the data archive located in the following directories from the obsolete server to the
new server:
C:\SCADA\ArchiveDAT
C:\SCADA\ArchiveDATCopy
6. Start Server and Communicator services on the new server.
7. Check logs.
Software Update
Updating Rapid SCADA to new versions has to be performed on the test environment first.
Carefully read the list of changes were made in the new version. If the configuration
database structure is changed or the archive or configuration files formats are changed,
special utility is required to convert data.
Only being sure that the new version of Rapid SCADA is operates properly on the test
environment, installation on the production server is allowed.
1. Make a backup copy of the all files of Rapid SCADA which located in C:\SCADA directory
by default.
2. Uninstall Rapid SCADA using the installer application ScadaSetup.exe.
3. Install a new version of Rapid SCADA and migrate the configuration from the backup copy.
4. Clear the browser cache or refresh the web application pages by pressing Shift + F5.
Software Configuration
General Configuration Sequence
Starting to work with Rapid SCADA, it is recommended to follow the general configuration
sequence described below. Having obtained some working experience, better
understanding the dependencies between the applications, the sequence can be varied for
improving efficiency.
1. Create objects, communication lines and devices in the configuration database using
Administrator application.
2. Pass the configuration database to Server by pressing button located in Administrator
toolbar. Restart the Server service.
3. Import communication lines and devices from the configuration database into
Communicator. The import feature is accessible in the communication lines popup menu by
pressing button.
4. Configure communication with devices in Communicator.
5. Accomplish tuning up the configuration database using Administrator.
6. Create views (tables or schemes) using Table Editor or Scheme Editor applications.
7. Define the created views in the configuration database in order that they appear in the
Webstation application.
The configuration database is edited using the Administrator application. The edited
instance of the configuration database is in SDF file format of Microsoft SQL Server
Compact Edition. After completing the necessary changes an administrator clicks button
to convert the database in a specially designed DAT format which is used by the other
applications. Such approach allows modifying the configuration database while the
software is running.
The configuration database consists of tables, which in turn are composed of columns and
rows. Each table belongs to one of the following groups:
1. System. This group contains the tables which define a configuration of a particular
automated system.
2. Dictionaries. This group contains the auxiliary tables. In most cases changing of these
tables is not needed and can cause incorrect operation of the software.
The following table describes the configuration database tables.
System Group
Objects Contains logical objects which input data and commands are
related to
Input channels Defines data received from the devices and data calculated on their
base
Dictionaries Group
Event types Dictionary of system event types which correspond to the input
channel statuses
Device types Dictionary of device types that can be connected to the system
Number formats Dictionary of formats which are used to display input channel
values
1. Create a backup copy of the existing database by pressing button. In addition, the
Administrator application automatically saves a copy of the database before passing it to
Server.
2. If the sample data are not needed, clear the tables of the System group. According to
relations between the tables, start clearing from the Rights table and continue till
the Objects table. Do not delete rows with identifiers from 0 to 4 of the Roles table.
3. Enter data in the tables of the System group. Use the opposite order starting from
the Objects table and finishing by Rights table. There are Create channels and Clone
channels features designed for fast automatic filling the Input channels and Output
channels tables.
4. Pass the configuration database to Server using button.
The Create channels feature (see Figure 2), which is accessible in Service menu, allows
automatic filling the Input channels and Output channels tables using information about
existing objects and devices. Rules for creating channels are defined in device libraries
(drivers) of Communicator. The device libraries are located in C:\SCADA\ScadaComm\KP\
by default. If a DLL file, specified in the Device types table, does not exist, the creation of
channels corresponding to that device type is impossible. Channels are created according
to the settings of Communicator.
To create input and output channels, tick the appropriate devices, choose or keep
undefined the object for the each device, click the Calculate channel numbersbutton, check
the calculated numbers, then click the Create button.
The Clone channels feature (see Figure 3) is also designed to make the process of creating
input and output channels faster. The objects and the devices of the cloned channels can
be replaced by the specified values during cloning.
Figure 3. Clone channels feature
Editing of input channels may be done either directly in a table or by using the form that is
shown in Figure 4. Right click an input channel row to show popup menu and click the
menu item to open this form.
Figure 4. Editing input channel properties
The Compact database feature decreases the size of the configuration database file. Use
this feature when the database editing has been completed. To execute the feature click
the Database > Compact main menu item.
Using Formulas
Formulas are used for calculating values and statuses of input channels and calculating
values of commands. Formulas processing is performed by the Server application.
Formulas are contained by the Input channels and Output channels tables of the
configuration database. To enable the formula, tick the appropriate checkbox in
the Formula used column. The Formulas table stores additional functions and data
structures which can be used in formulas for input and output channels.
1. For channels of types Discrete and Real calculation starts when the channels data are
received by Server. Use these channel types if formula does not refer to data of other
channels.
2. For channels of types Calculated * and Switching counter calculations are performed
permanent and ordered by channel numbers. A formula of a calculated channel usually
refers to data of other channels.
3. For channels of types Minute * and Hourly * calculation starts periodically once per minute
or once per hour. Use these channel types to create accumulated values, for example,
energy consumption or operating time.
4. For channels of types Discrete and Real statuses of the channels after calculating are
equal to the statuses of these channels received by Server if status calculation does not
specified explicitly.
5. For channels of the other types the statuses set to Defined if status calculation does not
specified explicitly.
6. An input channel formula that does not contain ";" (semicolon) symbol calculates the input
channel value only.
7. If an input channel formula contains ";", the formula calculates the input channel value and
status. The first part before semicolon is a formula for value calculation and the second part
after semicolon calculates status.
1. Formulas are processed for output channels having Standard and Binary command types.
2. A formula of an output channel defines command value calculation for a standard
command and defines command data calculation for a binary command.
CnlVal, Cnl double The input channel value transmitted to Server before
calculation
CnlStat int The input channel status transmitted to Server before
calculation
CnlNum int The channel number for which the formula is calculated
SetData(n, val, double Sets the current value and status of the channel n
stat)
The standard user roles and their capabilities are listed in the following table.
To restrict user access to interface objects (table views, schemes, etc.), create new user
roles in Roles table in the configuration database. Then specify access rights in
the Rights table.
If Rapid SCADA operates in a network that managed by Active Directory, it is
recommended to use the 2nd and the 3rd authentication methods because of security
reasons. The details of these methods are described below.
To allow the Server application interact with Active Directory, specify domain controller path
and tick the nearby checkbox on Common Parameters page of the application.
The 2nd authentication method is used if the standard roles are enough to manage user
rights. The benefits of this method are that rights management is performed using usual
Active Directory tools without editing the configuration database and restarting the Server
application.
To use the 2nd method it is required to create the security groups in Active Directory. The
groups correspond to the user roles:
The 3rd method combines the capabilities of the 1st and the 2nd methods. User credentials
check is performed by using Active Directory and a user role is defined by the Users table
of the configuration database. In this case, user names and user roles are defined in
the Users table, but user passwords are kept blank in the table.
Communication order and request parameters are set on the Request Sequence page (see
Figure 2).
If the Active checkbox on the Communication Line Parameters page is unset, the
appropriate communication line is disabled, and no requests are performed. If
the Active checkbox in the Selected device group box is unset, communication with the
appropriate device is disabled.
The Bound to server checkbox on the Communication Line Parameters page allows to
switch on or switch off sending the communication line data to Server.
The Bound checkbox in the Selected device group box has the similar purpose, but only for
the device. If the Use SCADA-Server checkbox on the Common Parameters page is unset,
any interaction between Communicator and Server is switched off. These options are
useful for testing new devices connecting to the system.
If the Time and Period request parameters of a device are equal to zero, the device is
requested cyclically. If Time greater than zero and Period is zero, the device is requested
once a day in the specified time. If Period greater than zero, the device is requested
periodically starting at the specified time. The Timeoutfield defines how long to wait an
answer from the device after a request. The Delay field defines a delay after each request
to the device. Command line may contain additional parameters described in
documentation of a device library.
To reset request parameters of the selected device to the default values, click button.
To open the device properties form, if it is supported by a device library of the selected
device, click button or use a popup menu of the tree. To set global properties for a
device type choose the Device Libraries page, select the device library and click
the Properties button if the button is enabled.
The import feature significantly speeds up configuring Communicator (see Figure 3). This
feature is allowable if the Use SCADA-Server checkbox on the Common Parameters page
is set and the Server service is running. To start import, click button. Such button is
located on the Request Sequence page and in a popup menu of the tree. The import
feature adds communication lines and devices to the Communicator configuration using the
information of the configuration database.
Creating Views
View is a form of data representation in the Webstation application. There are 2 types of
views supported by default: table views and schemes. Support other types of views can be
added by installing additional plugins.
Special editors are designed to create views: Table Editor and Scheme editor. Views are
stored in files which must be located in the interface directory (or its subdirectory) that is
specified in the settings of the Server application. The default interface directory is C:\
SCADA\Interface\
When view files are created, they must be defined in the Interface table of the configuration
database by the Administrator application as shown in Figure 1. View ID is an arbitrary
unique number. View path is relative to the interface directory. View title is shown in the
explorer tree of Webstation.
To apply the changes, send the database to Server by the button, restart the Server
service by the button, then logout and login again the web application.
Modules
Telegram Driver
Overview
Telegram Driver is designed to send notifications using the popular Telegram messenger.
The advantages of using Telegram is quickness of receiving notifications, no fee for the
service and easy notification group management.
Installation
Telegram Driver is installed in accordance with the general sequence of installing
Communicator drivers. The driver library file is KpTelegram.dll.
Configuring
Creating Telegram Bot
First you need to create a Telegram bot. To do this:
3. In the dialog with BotFather, run the command /newbot and follow the instructions from
BotFather.
4. Click the menu icon and create a new group to receive notifications.
Driver Settings
Configure notifications in the following sequence:
1. Using the Administrator application, open the Device types table and check that the device
type "224 Telegram" exists. If the specified record is missing, enter it manually.
2. Using Administrator, create a separate communication line and a single device of the
Telegram type that belongs to this communication line.
3. Import the created communication line and the device to Communicator. Enable sending
commands for the communication line.
4. Using Communicator, open the device properties, enter the bot token obtained when
creating the bot, and generate a bot password that is needed to manage subscriptions.
5. Go to the Registration page and register the driver using the hyperlinks on the form.
To add or remove subscriptions to the group, use the /start and /stop commands with the
previously generated password. However, by default, subscription changes are blocked. To
unlock it, send a standard command number 2 with a value of 1 by Communicator. Now
you can add or remove subscriptions.
Sending Messages
To send a message from Rapid SCADA to a Telegram group, you need send a binary
command number 1 containing the group name (or identifier) and the message text. For
example: RapidScadaBotTestGroup; Test message.
Automatic sending of notifications in case of specific conditions and events are performed
by Automatic Control Module.
Channel data trigger. The trigger fires if value or status of the input channel satisfies the
condition.
Event trigger. The trigger fires if an event satisfies the condition occurs.
Time trigger. The trigger fires on the specified dates and times.
Command trigger. The trigger fires if the Server application receives the specified
command.
Each trigger contains a set of commands which are sent if the trigger fires. The information
about firing of the triggers is accessible on the Log page or directly from the
ModAutoControl.log file. This file is located in Server logs directory C:\SCADA\
ScadaServer\Log
Installation
Automatic Control Module is installed in accordance with the general sequence of installing
Server modules. The module library file is ModAutoControl.dll. After adding the module,
you need to perform several additional actions:
Variable Description
{EvNum}, {EvTime}, {EvObj}, Parameters of the event that caused the trigger firing:
{EvDev}, {EvCnl}, {EvText} number, date and time, object, device, channel and
description
-- Insert event
INSERT INTO Events (DateTime, ObjNum, KPNum, ParamID, CnlNum,
OldCnlVal, OldCnlStat, NewCnlVal, NewCnlStat, Checked, UserID, Descr,
Data)
VALUES (@dateTime, @objNum, @kpNum, @paramID, @cnlNum, @oldCnlVal,
@oldCnlStat, @newCnlVal, @newCnlStat, @checked, @userID, @descr,
@data)
Oracle
-- Delete channel data table if it exists
BEGIN
EXECUTE IMMEDIATE 'DROP TABLE cnldata';
EXCEPTION
WHEN OTHERS THEN
IF SQLCODE != -942 THEN
RAISE;
END IF;
END;
-- Insert event
INSERT INTO events (datetime, objnum, kpnum, paramid, cnlnum,
oldcnlval, oldcnlstat, newcnlval, newcnlstat, checked, userid, descr,
data)
VALUES
(:dateTime, :objNum, :kpNum, :paramID, :cnlNum, :oldCnlVal, :oldCnlSta
t, :newCnlVal, :newCnlStat, :checked, :userID, :descr, :data)
PostgreSQL
-- Delete channel data table if it exists
DROP TABLE IF EXISTS cnldata;
-- Insert event
INSERT INTO events (datetime, objnum, kpnum, paramid, cnlnum,
oldcnlval, oldcnlstat, newcnlval, newcnlstat, checked, userid, descr,
data)
VALUES (@dateTime, @objNum, @kpNum, @paramID, @cnlNum, @oldCnlVal,
@oldCnlStat, @newCnlVal, @newCnlStat, @checked, @userID, @descr,
@data)
MySQL
-- Delete channel data table if it exists
DROP TABLE IF EXISTS cnldata;
-- Insert event
INSERT INTO events (datetime, objnum, kpnum, paramid, cnlnum,
oldcnlval, oldcnlstat, newcnlval, newcnlstat, checked, userid, descr,
data)
VALUES (@dateTime, @objNum, @kpNum, @paramID, @cnlNum, @oldCnlVal,
@oldCnlStat, @newCnlVal, @newCnlStat, @checked, @userID, @descr,
@data)
Installation
Rapid Gate Module is installed in accordance with the general sequence of installing
Server modules. The module library file is ModRapidGate.dll. After adding the module, you
need to perform several additional actions:
Configuring
To cofigure Rapid Gate Module, edit C:\SCADA\ScadaServer\Config\ModRapidGate.xml
using a text editor. The settings contains the connection parameters for the SCADA server
(target server) to which data are transferred and from which commands are received.
Note that you usually need to configure the firewall on the target server to allow
connections with it over the network.
Algorithm
The algorithm of Rapid Gate Module has the following features:
1. The module transmits only the data that are received from Communicator. The values of
the calculated input channels are not transmitted.
2. The data is transmitted to the same input channel numbers to which they are received.
3. The transmitted values are already calculated by the formulas of the input channels, which
can result in double applying of the formulas on the target server. Therefore, when using
the module, it is recommended that calculations be performed in separate input channels of
the calculated type.
4. The module has a data transfer queue, which allows restoring data in case of a short-term
connection failure with a target server.
Installation
First you need to perform the general sequence of installing plugins, and then perform
several additional actions:
Dashboard Plugin
Overview
Dashboard Plugin displays useful widgets on dashboards: charts, current data and arbitrary
frames, for example, CCTV camera stream. Settings of each dashboard allow to specify
column count and widget aspect ratio.
Installation
First you need to perform the general sequence of installing plugins, and then perform
several additional actions:
Configuring
A configuration of each dashboard stored in a separate XML file. The plugin installation
package contains a dashboard example which installs into:
C:\SCADA\ScadaWeb\storage\AllUsers\Dashboard\DashboardExample1.xml
To create a custom dashboard, copy the example configuration file with a new name, and
then edit it using any text editor. Configuration file name may be arbitrary, file extension
must be XML. The locations of dashboard configuration files:
The Widgets section contains a list of widgets that are displayed on a dashboard. Number
of widgets is arbitrary. However, too many widgets on the same dashboard can reduce the
performance of the web application.
Configuration of widgets of the Chart and CurData types must define input channel
numbers and also identifiers of the views that include these input channels. View IDs are
required for user access rights validation.
Installation
First you need to perform the general sequence of installing plugins, and then perform
several additional actions:
The plugin distributive contains the example of the report configuration file SCADA\
Interface\ElasticReport\ElasticRepExample.xml. This example includes the detailed
description of the settings and demonstrates the generation of the report sections of all
possible types.
Configuration files may be edited using any text editor. For example, the free text
editor Notepad++ supports comfortable work with XML files by the special plugin.
Report Styling
It is possible to customize the report styles: fonts, colors, cell sizes, etc.
To create custom styles, open this file in Excel and go to the Custom Styles page where
the additional styles are located. Use the styles from the Default Stylespage as an
example.
XML file, which defines PDF styles, is edited manually using any text editor. Use the default
styles located in ElasticRepPdfDefault.xml as an example.
The report styles for HTML output are configured in the file
SCADA\ScadaWeb\plugins\ElasticReport\css\customstyles.css according to the rules of
Cascade Style Sheets.
Add Report in Configuration Database
To make the report visible in the list of available reports, it is necessary to register it in
the Interface table using the Administrator application. Specify the path to the report
configuration file related to the interface directory, specify the ElasticRep report type and
enter the report title (see the Figure).
Then pass the configuration database to the Server application by clicking the button.
To apply the changes, logout the Webstation web application and login again. The report is
available on the Main Menu > Reports page.
Use Cases
Connecting Devices Using
Modbus Protocol
Written by Rapid SCADA on January 5, 2015
Updated on October 16, 2017
This article describes how to configure communication with devices using Modbus protocol.
Simple and robust, Modbus has since become a de facto standard communication protocol,
and it is now a commonly available means of connecting industrial electronic devices
(see Wikipedia). Rapid SCADA supports Modbus RTU, ASCII and TCP modes.
1. Create an object, a communication line and devices in the configuration database using
Administrator.
2. Configure communication between Communicator and the devices.
3. Create input channels in the configuration database according to the tags of the devices.
Create output channels according to the commands.
4. Create views (tables or schemes) to display data in the Webstation application. Define the
views in the configuration database.
The following is a step by step guide to setup a new Modbus device. To ensure that the
process of adding the device completely coincides with the text of the article, you have to
install Rapid SCADA with the default configuration.
Run Administrator. Open the Objects table and add a new line for the object 2 "Test object"
(see Figure 1). Then open the Communication lines table and add the line 11 "Test line"
(see Figure 2). After that open the Devices table and add the device 101 "Test device" (see
Figure 3).
Fill the following fields for the device (see Figure 3):
Right-click on the Communication Lines tree node and choose the Import communication
lines and devices item of the context menu (see Figure 4). In the window that appears, tick
the created line and device, and then click the Import button (see Figure 5). Communication
line and device appear in Communicator.
The following table contains typical serial port parameters depending on the protocol type.
In RTU and ASCII modes a baud rate of all the devices of a communication line has to be
the same. Specify this baud rate in the serial port properties. Using different Modbus types
within a one line is not allowed.
Go to the Request Sequence page and select "Test device" row in the table (see Figure 7).
If device polling time and period are not specified, the devices are polled cyclically.
Commands are sent immediately after a poll is completed.
Click the button to open device properties form (see Figure 8). In the form choose the
type of Modbus protocol, which have to be specified in the device manual.
Figure 8. Device properties
Press the button to select an existing device template, or click to create a new
template. When the create button or the edit button is clicked, Device Template
Editor is shown (see Figure 9). This article uses the existing template
KpModbus_Adam6015.xml.
Figure 9. Device template editor
Device template reflects the structure of Modbus packages. Requested data are combined
into groups of elements. Each group has its name, data table, start address and element
count. Each element is a tag of a device. Rapid SCADA identifies a tag by its signal
number. A command is described by its name, data table and address. A command
number identifies the command within Rapid SCADA.
Names of groups, elements and commands are arbitrary. The available data tables and
element addresses are usually described in device manual. Depending on the
manufacturer, addressing of elements can be zero-based or one-based, specified as
decimal or hexadecimal numbers. By default, addresses start with 1 and represented as
decimals. To switch template addressing, click the button. Template settings dialog is
opened (see Figure 10).
Figure 10. Template settings
To save Communicator settings click the button. Now it is recommended to start the
Communicator service with the button and check communication with the device.
Click Device 101 "Test device" tree node to check the device state and the availability of
data (see Figure 11). The data is not available immediately after start, retrieved values are
shown when the first polling complete.
Figure 11. Device data
In case of losing communication with the device, use a communication line log to analyze
the problem cause. To open the log, click the Communication Line Stats tree node and go
to the Communication Line Log page. Data packages can be decoded by Online Modbus
Parser.
The automatic channel creation service helps to save a time. Click Service > Create
Channels in the main menu of the application.
On the form, which is shown in Figure 12, choose "Test line" in the drop down list, then tick
the "Test device" row and choose "Test object" in the cell of the Object column. Set the
channel numbering parameters to create channels having convenient numbers. Firstly
press the Calculate channel numbers button, then press Create.
Figure 12. Creation of channels
The channels are created automatically based on the device template that has been
created and assigned to the device in the previous section of this article. To view created
channels, click the Input channels > Test device tree node and the Output channels > Test
device node. It is recommended to manually fill in the Quantity and Unit fields of the input
channels and the Command values field of the output channels. However, in the case of
the first experiment it is unnecessary.
Useful to understand that the input channels are bound to the device tags using
the Signal field. The output channels are bound to device commands in accordance with
the Command number field.
After editing the configuration database is complete, press the button to pass the
changes to Server, and then restart Server and Communicator by and buttons.
Open the Device Data page in Communicator and make sure that the input channels are
bound to the device tags – the Channel column must contain numbers of the created input
channels (see Figure 13).
Figure 13. Device data bound to channels
As a result of described actions, data should be collected from the device and stored in the
archive. It remains to customize user interface for an operator.
Open Table Editor and fill in the table view as shown in Figure 14. Add a channel in the
table (from the left side of the window to the right) by clicking the button, double-clicking
the channel row or by pressing Enter.
Save created table view in the TestTable.tbl file in the C:\SCADA\Interface\Test folder.
Please note that folder names and file names of views must contain only Latin characters.
Figure 14. Table editor
To display a table view in Webstation, define it in the Interface table of the configuration
database by the Administrator application as shown in Figure 15.
To apply the changes, send the database to Server by the button and restart the Server
service by the button.
Now start your browser and enter the address http://localhost/scada/. On the login form
use admin / 12345 (see Figure 16). If the configuration carried out correctly, after logging
in, you will see a table with the data obtained from the device, similar to Figure 17.
Another commonly used conversion is two’s complement. See Wikipedia for the details.
Formulas can be defined inline in input channel rows of the configuration database or
separately by using the Formulas table. Using of formulas is described in this section.
This article describes how to configure communication with devices using OPC standard.
OPC is designed to provide a common bridge for the software and process control devices
from different manufacturers (see Wikipedia). Rapid SCADA supports the following OPC
specifications:
1. Download and install OPC Core Components. These components can be found
at opcfoundation.org and rapidscada.org.
2. Create an object, a communication line and devices in the configuration database using the
Administrator application.
3. Configure communication between Communicator and OPC servers as described in this
article.
4. Create input channels in the configuration database according to the tags of the devices.
Create output channels according to the commands.
5. Create views (tables or schemes) to display data in the Webstation application. Define the
views in the configuration database.
The details of the 2nd, the 4th and the 5th steps are described in the Software
Configuration section. Device 21 "OPC Demo" of the default Rapid SCADA configuration is
an example of using OPC. Find "OPC demo" view in Webstation to examine the received
data. This example requires MatrikonOPC Explorer which includes an OPC simulation
server.
Create a separate communication line for each OPC server that is used. It is the most
efficient approach because it allows communicating with the OPC servers in parallel. Add
devices to the communication lines. Set Undefined communication channel type for the
created communication lines in Communicator.
Open device configuration form to select which OPC tags to receive from OPC server. Click
the button located in the device popup menu or the Request Sequence page to open
the form that is shown in Figure 1.
OPC servers installed on the local computer are available to Communicator. If data from an
OPC server, installed on another computer within a network, are required, deploy an extra
instance of Communicator on that computer and properly configure it to connect Server.
There are two ways how to bind OPC tags to input channels of the configuration database:
1. Using the Signal field of device tags and input channels to identify tags.
2. Setting input channel numbers directly in the configuration form shown in Figure 1.
Select the way that is more suitable in a particular configuration of an automated system.
When the configuration is completed, restart the Server and Communicator services.
Check OPC communication state and received data using Communicator logs (see Figure
2). If the data in Communicator seem to be true, open a browser and look for the same
data in the Webstation application.
Known issue of using OPC: unable to receive data from OPC server while OPC tag
properties are available in the device configuration form, no error messages are raised.
Possible reason is that the Communicator service operates as system user but OPC server
forbids interacting with system user.
Solution 1. Specify a user account that is used to run OPC server. To open DCOM
configuration (see Figure 3), follow the path Control Panel\System and Security\
Administrative Tools\Component Services or just run comexp.msc
Solution 2. Specify a user account that is used to run the Communicator service. Go
to Control Panel\System and Security\Administrative Tools\Services or run services.msc,
find ScadaCommService and open the service properties. Then enter user account and
password on the Log On page as shown in Figure 4. The specified user must be a
computer administrator.
Figure 4. Service properties
http://doc.rapidscada.net/content/en/use-cases/modbus-protocol.html
Conexión de dispositivos
usando el protocolo Modbus
Escrito por Rapid SCADA el 5 de enero de 2015
Actualizado el 16 de octubre de 2017
La siguiente es una guía paso a paso para configurar un nuevo dispositivo Modbus. Para
garantizar que el proceso de agregar el dispositivo coincida completamente con el texto del
artículo, debe instalar Rapid SCADA con la configuración predeterminada.
Ejecutar administrador. Abra la tabla de Objetos y agregue una nueva línea para el objeto
2 "Objeto de prueba" (vea la Figura 1). A continuación, abra la tabla Líneas de
comunicación y agregue la línea 11 "Línea de prueba" (consulte la Figura 2). Después de
eso, abra la tabla Dispositivos y agregue el dispositivo 101 "Dispositivo de prueba" (vea la
Figura 3).
Complete los siguientes campos para el dispositivo (vea la Figura 3):
Haga clic con el botón derecho en el nodo del árbol Líneas de comunicación y elija la
opción Importar líneas y dispositivos de comunicación del menú contextual (consulte la
Figura 4). En la ventana que aparece, marque la línea y el dispositivo creados, y luego
haga clic en el botón Importar (consulte la Figura 5). La línea de comunicación y el
dispositivo aparecen en Communicator.
Haga clic en el nodo del árbol Línea de prueba "Línea 4" para abrir la página Parámetros
de la línea de comunicación , configure un canal de comunicación, como un puerto en
serie. Marque la habilitado Comandos casilla de verificación si se requiere el envío de
comandos al dispositivo (véase la Figura 6).
Figura 6. Propiedades de línea de comunicación
La siguiente tabla contiene los parámetros típicos del puerto serie dependiendo del tipo de
protocolo.
Haga clic en el botón para abrir el formulario de propiedades del dispositivo (consulte la
Figura 8). En la forma, elija el tipo de protocolo Modbus, que debe especificarse en el
manual del dispositivo.
Figura 8. Propiedades del dispositivo
Presione el botón para seleccionar una plantilla de dispositivo existente, o haga clic
para crear una nueva plantilla. Cuando se hace clic en el botón Crear o en el botón
Editar , se muestra el Editor de plantillas del dispositivo (consulte la Figura 9). Este
artículo utiliza la plantilla existente KpModbus_Adam6015.xml.
Figura 9. Editor de plantilla de dispositivo
La plantilla del dispositivo refleja la estructura de los paquetes de Modbus. Los datos
solicitados se combinan en grupos de elementos. Cada grupo tiene su nombre, tabla de
datos, dirección de inicio y recuento de elementos. Cada elemento es una etiqueta de un
dispositivo. Rapid SCADA identifica una etiqueta por su número de señal. Un comando se
describe por su nombre, tabla de datos y dirección. Un número de comando identifica el
comando dentro de Rapid SCADA.
Los nombres de grupos, elementos y comandos son arbitrarios. Las tablas de datos
disponibles y las direcciones de los elementos se describen generalmente en el manual del
dispositivo. Dependiendo del fabricante, el direccionamiento de los elementos puede
basarse en cero o en uno, especificados como números decimales o hexadecimales. Por
defecto, las direcciones comienzan con 1 y se representan como decimales. Para cambiar
el direccionamiento de la plantilla, haga clic en el botón. El diálogo de configuración de
plantillas está abierto (ver Figura 10).
Figura 10. Configuración de plantilla
Haga clic en el nodo del árbol "Dispositivo de prueba" del Dispositivo 101 para verificar el
estado del dispositivo y la disponibilidad de los datos (consulte la Figura 11). Los datos no
están disponibles inmediatamente después del inicio, los valores recuperados se muestran
cuando se completa el primer sondeo.
Figura 11. Datos del dispositivo
Es útil para comprender que los canales de entrada están vinculados a las etiquetas del
dispositivo usando el campo Señal . Los canales de salida están vinculados a los
comandos del dispositivo de acuerdo con el campo Número de comando .
Después de editar la configuración de la base de datos se completa, presione el botón
para pasar los cambios al Servidor, y luego reinicie el Servidor y el Comunicador con
los botones y .
Abra la página Datos del dispositivo en Communicator y asegúrese de que los canales de
entrada estén vinculados a las etiquetas del dispositivo: la columna Canal debe contener
los números de los canales de entrada creados (consulte la Figura 13).
Como resultado de las acciones descritas, los datos deben recopilarse del dispositivo y
almacenarse en el archivo. Queda por personalizar la interfaz de usuario para un operador.
Para mostrar una vista de tabla en la estación web, defínala en la tabla de interfaz de la
base de datos de configuración mediante la aplicación de administrador como se muestra
en la Figura 15.
Figura 15. Agregar una vista en la tabla de Interfaz
Para aplicar los cambios, envíe la base de datos al servidor por el botón y reinicie el
servicio del servidor con el botón.
La conversión más simple es una proporcional que se describe con la siguiente fórmula: