Scad A Tutorial Us

  • May 2020
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Scad A Tutorial Us as PDF for free.

More details

  • Words: 30,145
  • Pages: 148
Supervision and Control System

ELIPSE SOFTWARE

TUTORIAL  Copyright 2002 - 2. 22 SP 20 - Elipse Software Ltda. All rights reserved.

Summary 1.

INTRODUCTION .................................................................................................................... 1-1

2.

INSTALLATION ..................................................................................................................... 2-1 2.1. 2.2. 2.3. 2.4. 2.5.

SYSTEM SET UP .................................................................................................................... 2-1 INSTALLING .......................................................................................................................... 2-1 UPDATING............................................................................................................................. 2-1 ABOUT THE HARDKEY .......................................................................................................... 2-2 HARDKEY UPDATE ................................................................................................................ 2-2

3.

CASE STUDY........................................................................................................................... 3-1

4.

STARTING UP......................................................................................................................... 4-1 4.1. SHORTCUT KEYS .................................................................................................................. 4-2 4.1.1. Configurator .................................................................................................................. 4-2 4.1.2. Runtime ......................................................................................................................... 4-3 4.2. COMMAND LINE OPTIONS ..................................................................................................... 4-3

5.

TAGS ......................................................................................................................................... 5-1 5.1. TAGS TYPE ........................................................................................................................... 5-2 5.1.1. Rules for Tags names .................................................................................................... 5-2 5.2. CREATING TAGS ................................................................................................................... 5-3 5.2.1. PLC ............................................................................................................................... 5-3 5.2.2. Tag DDE ..................................................................................................................... 5-10 5.2.3. Tag Demo .................................................................................................................... 5-12 5.2.4. Tag Block .................................................................................................................... 5-13 5.2.5. Tag Ram ...................................................................................................................... 5-16 5.2.6. Tag Matrix ................................................................................................................... 5-17 5.2.7. Tag Bit ......................................................................................................................... 5-19 5.2.8. Tag Expression ............................................................................................................ 5-21 5.2.9. Tag Chrono .................................................................................................................. 5-24 5.2.10. Tips about Tags ........................................................................................................... 5-25 5.2.11. Alarms Page ................................................................................................................ 5-27 5.2.12. Alarms and Alarms Group ........................................................................................... 5-29

6.

SCREEN CREATION ............................................................................................................. 6-1 6.1.1. 6.1.2.

7.

Screen General Properties ............................................................................................. 6-2 Screen Style Properties .................................................................................................. 6-4

SCREEN OBJECTS ................................................................................................................ 7-1 7.1.

SCREEN OBJECT EDITION ..................................................................................................... 7-2

7.2. SCREEN OBJECT PROPERTIES ............................................................................................... 7-4 7.2.1. Frame page .................................................................................................................... 7-4 7.2.2. Tags Page ...................................................................................................................... 7-6 7.2.3. Size and Pos Page .......................................................................................................... 7-8 7.2.4. Object Inserting and Running ........................................................................................ 7-9 7.2.5. Bitmaps Utilization ........................................................................................................ 7-9 7.2.6. Drills ............................................................................................................................ 7-12 8.

SCRIPTS ................................................................................................................................... 8-1 8.1. GENERAL CONSIDERATIONS ................................................................................................. 8-1 8.2. APP BROWSER & X-REFERENCE........................................................................................... 8-3 8.3. OPERATORS & CONSTANTS .................................................................................................. 8-5 8.4. FLOW CONTROL.................................................................................................................... 8-7 8.4.1. If…ElseIf…Else…EndIf Command .............................................................................. 8-7 8.4.2. For…Next Command .................................................................................................... 8-8 8.4.3. While…Wend Command .............................................................................................. 8-8 8.4.4. Repeat…Until Command .............................................................................................. 8-8 8.5. SPECIAL FUNCTIONS ............................................................................................................. 8-8 8.6. TIPS AND OPTIMIZATION ....................................................................................................... 8-9 8.7. DRILL ................................................................................................................................. 8-13

9.

HISTORICAL .......................................................................................................................... 9-1 9.1. HISTORICAL TYPES ............................................................................................................... 9-1 9.2. HISTORICAL ANALYSIS ......................................................................................................... 9-4 9.2.1. Analysis Setting ............................................................................................................. 9-6 9.3. TIPS AND OPTIMIZATION ....................................................................................................... 9-8 9.4. DRILL ................................................................................................................................. 9-11

10.

REPORTS ............................................................................................................................... 10-1

10.1. 11.

DRILLS ................................................................................................................................ 10-1

RECIPES ................................................................................................................................ 11-1 11.1.1. 11.1.2.

Recipe General Properties ........................................................................................... 11-1 Editing Recipes............................................................................................................ 11-3

12.

PASSWORDS ......................................................................................................................... 12-1

13.

DATABASES .......................................................................................................................... 13-1

14.

REMOTE APPLICATION ................................................................................................... 14-1

15.

OPTIMIZATION ................................................................................................................... 15-1

16.

EXHIBITS .............................................................................................................................. 16-1

16.1.

DRIVER KLOCKNER MOELLER ............................................................................................ 16-1

16.2.

DRIVER SIEMENS 3964R..................................................................................................... 16-4

Welcome

W

elcome to the training. This manual introduces the Elipse Scada training module and it aims to aid the learning of the contents given during training classes. For a better learning, we suggest that you read this manual carefully, make your own notes during the class, ask the trainer as much as you can to solve any questions, and pratice what you learned. We appreciate your interest and wish you success with your new tool.

this…

Conventions Check the following list for syntaxis and some conventions used in this manual. Example

Description

SILO6.BMP

Capital letters indicate file names and other terms in the operational system level.

General

Bold characters indicate field names that must be searched on the screen, in menus or in the object filling cards.

“Agitacion”

Characters in quotation marks must be typed in the indicated field without the quotation marks.

Screen1.Show()

Italic expressions are program parts (scripts) that must be typed in the reserved spaces, and then compiled to verify errors.

.enabled

Expression between the < > sign must be replaced by the referred object name (Screen objects or Tags) while editing a script.

Tank01.High.Limit

Bold italic characters indicate Tags’names and/or their properties.



Click in firld A

CTRL+ENTER

The directions with markers in the beginning of the sentence are part of a procedure or task. Small capital letters are used to identify key names in the keyboard. When they are followed by a (+) signal, you must hold the first key down while pressing the other.

1

I N T R O D U C T I O N

Capítulo

1.

Introduction

T

He Elipse Scada is a software for the creation of process supervision and control applications for several areas. It can be completely configured by the user which allows the monitoring process variables in real time through graphs and objects that are related to field physical variables. Furthermore, the user will be able to operate and send or receive information to the data acquisition equipment. It is also possible to make calculations using the programming language, to create historical databases, reports, recipes, and even to supervises and control remotely a process. The software is avilable in four modules: View, MMI (Man Machine Interface), Professional and Power. All the forementioned modules have Configurator, Runtime, and Master versions. The Configurator is dedicated to the process supervision applications development. In order to conductor tests, the Configurator can run applications up to ten minutes. The Runtime is used to run process supervision applications after they have been developed making use of the Configurator. The Master embodies in the same tool one Configurator module and one Runtime module, which allow the set up and running in one sole product. In the absence of a protection device (hardkey), the software can be run in demo mode. The Demo is used to asses the software and it has all the existing resources as in the Configurator. However, it works with a maximum f 20 Tags, allowing the communication with the data acquisition equipment up to 10 minutes, with the condition that there is the respective communication driver. It does not use a hardkey and can be freely reproduced.

 Elipse Software

1-1

Elipse Scada

I N T R O D U C T I O N

In order to know which version we are using, at any time, even in runtime mode, we just have to press the combination: CTRL + SHIFT + V. See the following for an abstract of the functional feactures of each version: PRODUCT

TAGS

ENVIRONMENT

ELIPSE VIEW

Unlimited 300 or 75

ELIPSE MMI

Unlimited 300 or 75

Windows 95/98/2000 Me/NT/XP Windows 95/98/2000 Me/NT/XP

ELIPSE PRO

Unlimited 300 or 75

ELIPSE POWER

Unlimited

Windows 95/98/2000 Me/NT/XP Windows 95/98/2000 Me/NT/XP

MAIN FUNCTIONS

 Monitoring  Driver  Supports DDE

Elipse View plus:  Historical analysis  Alarms  Recipes  Reports  SPC (CEP) Elipse MMI plus:  Support to ODBC  Network Support Elipse PRO plus:  Support to Oscilographies, SOE (Sequence of Events), COS (Change of States of DNP 3.0/IEC-870-5 protocols)

Further, as additional modules, there are two tools that can work together with any of the above mentioned products, which are the Elipse Watcher and the Elipse Web. The Elipse Watcher is an “Add-on” to image monitoring, registry and digital transmission in real time, making it possible the visualization of images with programmable definitions and size by the user, besides allowing an image databases creation with search for period or event, and image transmission in real time to remote stations via local network or dialed line. On the order hand, the Elipse Web is a supervision application server to Internet, where by means of a navigatior such as the Netscape or the Internet Explorer it is possible to get connected with a station and send/receive data in real time.

 Elipse Software

1-2

Elipse Scada

2

I N S T A L L A T I O N

Chapter

2.

Installation

2.1. System Set up See the following for the minimum requirement for the machine (PC):  Pentium 100 MHz or superior  Memory 16 MB (32 MB recommended)  SVGA Monitor(800 x 600, 256 colors or superior)  Microsoft Windows 95 / 98 / Millenium/ XP or NT  1 parallel port.

2.2. Installing 1 – Insert the Hardkey in your computer parallel port, if there is already a printer in this port place the hardkey first and then connect the printer in the same port. 2 – Introduce the floppy disk or CD-ROM in the respective drive, and through the Start button choose the Run option. 3 – In the unit that you are using, choose the INSTALL.EXE command, and follow the instructions that are displayed on the screen.

2.3. Updating Periodically, Elipse launches new software Releases that contain new tolls and/or updates for the already existing ones. Such updates can be obtained through common media (Floppy disk or CD-ROM) or through our site: www.elipse.com.br. In the case

 Elipse Software

2-1

Elipse Scada

I N S T A L L A T I O N

of updating, only the files that change with each release are available in Internet which turns the updated version smaller than the installed one.

2.4. About the Hardkey Some older keys have some compatibility difficulties with HP (Hewlett-Packard)® printers, when running in the “Bi-directional Communication” mode. For the correction of such problem there are two procedures: a) Run through the Running command of your Windows or one of the MS_DOS sections the hinstall.exe program that is copied during the installation process to the same directory in which the software was installed) that is responsible for the hardkey installation according to the syntax below, selecting the Bi-directional option. HINSTALL.EXE [options] Options: /i – Installs the hardkey driver (HASP) /iu – update /r – remove /portmode= tipo:

Normal – normal port mode ECP – Enchanced Control Port modo BiDi –Bidirecional mode Auto –automatic mode

b)To run a printer set up utility in the c:\Windows directory or your machine equivalent, disabling the Bi-directional communication option..

2.5. Hardkey update In the case you need an eventual version change (e.g. MMI to PRO) or even the increase in the number of tags in one application, the safety key will be able to be remotely programmed. For that purpose, besides the usual commercial procedures, the user will be able to follow the next steps, so that the update is performed as fast as possible:

 Elipse Software

2-2

Elipse Scada

I N S T A L L A T I O N

 

Put the key in the parallel port. Run CUSTOMER.EXE, program that is copied in the same installation directory, and select Get ID option.  Select Save option, providing a name to the file with any extension (sugestion : .TXT).  Send the file via e-mail to Elipse Software®. When you receive a new file, run again the CUSTOMER.EXE program.  

Run Config option.. Provide the received file name, and the key will be programmed.

 Elipse Software

2-3

Elipse Scada

S…P

C A S E

3

S T U D Y

Chapter

3.

I

Case Study n our training example, we will create an application as shown below.

The mentioned System shows a candy plant sunoptic. For the production, it is necessary four basic products: water, syrup, glucose and sugar, whose qualities are controller for each new type of candy to be produced through the use of recipes that are programmed by the operator. After the individual weighing of each products, they are homogenized in the mixer which in turn transfers the moisture to a storage tank. This transference between tanks can be automatic or controlled by a valve drive. From the storage tank, the moisture is transferred to the cookers through pumping that it also controlled by the application. The system operator can visualize each tank temperature in the same screen, control the engines frequency and open or close valves that drive the moisture to the cookers. The system will also show alarm status, in the case the parameters exceed the established limits. (e.g. excessive temperature increase), besides creating temperature trend graphics, generate operating database and its respective reports. Throughout the register screen, it is possible to create new products and edit the already existing ones. There is also a Query procedure for batch processes that allow historical data Query, visualization and printing.

 Elipse Software

3-1

Elipse Scada

C A S E

S T U D Y

1 – Dosage Screen

3 – Printing Screen

2 – Register Screen  Elipse Software

3-2

Elipse Scada

C A S E

S T U D Y

4 – Opening Screen

5 – Historical Alarms Visualizing Screen

 Elipse Software

3-3

Elipse Scada

C A S E

S T U D Y

6 – Bath Screen

 Elipse Software

3-4

Elipse Scada

C A S E

S T U D Y

7 – Trend Screen

 Elipse Software

3-5

Elipse Scada

4 4T

S T A R T I N G

Chapter

4.

Starting Up

O start up the Elipse Scada:

 Click the Start button in the Windows task bar;  Select Programs, after the Elipse Windows 32 and Windows 32 group. Elipse Scada Initial Screen:

Menu bar

Toolbar

Work area

 Elipse Software

4-1

Elipse Scada

U P

S T A R T I N G

4.1. Shortcut Keys 4.1.1.Configurator ALWAYS AVAILABLE

KEYS

ACTION

Ctrl + O

File / Open the Application

Shift + Ctrl + V

Help / About Elipse Windows

F1

Help

Shift + F1

Context Help

ONLY WITH AN OPEN APPLICATION

KEYS

ACTION

Ctrl + S

File / Open the Application

F10

File / Run the Application

Alt + O

File / Organizer

Ctrl + N

Screen / New

F8

Screen / Monitoring

Shift + Ctrl + Alt + I

Counts the items number in the application

ONLY IN THE SCREEN EDITION

KEYS

ACTION

Ctrl + F4

Screen / Close

ESC

Objects / Deselect

Ctrl + A

Objects / Select All

Ctrl + X

Objects / Cut

Shift + Del

Objects / Cut

Ctrl + C

Objects / Copy

Ctrl + Ins

Objects / Copy

Ctrl + V

Objects / Paste

Shift + Ins

Objects / Paste

Del

Objects / Delete

 Elipse Software

4-2

Elipse Scada

U P

S T A R T I N G

U P

ONLY IN THE FORMAL REPORT EDITION

KEYS

ACTION

Ctrl + F4

Close the Report Editing

ESC

Objects / Deselect

Ctrl + A

Objects / Select All

Del

Objects / Delete

4.1.2.Runtime KEY

ACTION

Shift + Ctrl + V

Help / About Elipse Windows

Shift + Ctrl + Alt + I

Counts the items number in the application

4.2. Command Line Options The executable file ELIPSE32.EXE accepts the following command line: ELIPSE32.EXE [-DEMO] [-SETUP] [-EDIT] [appName] Where: OPTIONS

ACTIONS

-DEMO

(optional) is used to run the Elipse as a demo, without verifying the protection mechanism (hardkey). This option rewrites the .INI file set in the [Protection]Type=…section

-SETUP

(optional) instructs the Elipse to run the Setup program that allows you to set the options in the Elipse.INI file. It shows the same dialog box as the menu File / Options …

-EDIT

(optional) instructs the Elipse to run the Configurator. If an application name is informed in the appName of the command line, this application will be open for Set up.

appName

(optional) an application name that will automatically run (in the Runtime or in the Master module) or it will be open by the set up (in the Configurator module or while the –EDIT is specified in the master or Demo modules). It is highly recommended that you include all the application’s file path.

 Elipse Software

4-3

Elipse Scada

S T A R T I N G

U P

Note

If you have a Runtime module and the appName parameters is omitted, the Elipse Scada will request you the application’s file name to be ran (Dialog box File/Open).

Note

When you specify a command line application, the work drive and directory are set to the same as the application. The creation of an Application is the start point to assemble a process supervision system using the Elipse Scada. In the Application, the user will be a:  Application File: .APP  Password File: APX  Application Backup: BAK  Database: .DAT , HDR (Cabeçalhos)  Recipe File: RCP  Communication Drivers: DLL  Arquivos de imagens (BMP, JPG, GIF, etc)

Drill: Task: To create a new Application.  Click the button New application.  Save application as Example.App, operation that is automatically requested.

 Elipse Software

4-4

Elipse Scada

S T A R T I N G

U P

In order to allow a simple and organized view of the entire application, the Elipse Organizer command in the File menu or pressing the

button in the toolbar.

The organizer structure can be compared to a directory tree of the Windows Explorer. In this way, the application structure starts in the upper left corner with the application’s root. All application objects go down from the root , grouped according to their type: tags, Screen, Alarms, recipes, Historical, reports, Drivers, databases, User’s List and Remote Applications. Selecting any of the tree legs of the application will make it expand showing its content – so you will be able to navigate through the application having all the set up options available for any object. Starting from the Organizer, you can create all your application only but navigating through the application tree. Selecting any of this legs, the selected object properties will be editing. For instance, if you select Tags in the Organizer tree, new Tags can be created, and its properties can be edited selecting the page you wish from the tabs in the top of the window. The Organizer Toolbar buttons allow you to quickly perform certain tasks without using the menus. There are 13 buttons as you may see in the following table:

 Elipse Software

4-5

Elipse Scada

S T A R T I N G

BUTTON

NAME

U P

ACTION

Delete

It deletes all the selected items in the Organizer.

Duplicate

It duplicates the selected item of the Organizer tree. (shortcut = CTRL + RightClick)

App Browser Cross Reference Compile

It opens the App Browser, a window that contains the application tree and all the objects functions and attributes. It shows the object cross-references in the App Browser, that is, in which places or other objects the current object has a reference. It compiles the Script that is being used.

Build

It compiles all the Scripts that are not compiled.

Rebuild All

It recompiles all the Application Scripts allowing the user to access each Script with a double click. It generates a list of the compiled Scripts showing in red the ones with errors.

If

It inserts an If command in the selected Script in the place where the cursor is.

Else...If

It inserts an Else...If command in the selected Script in the place where the cursor is.

Else

It inserts an Else command in the selected Script in the place where the cursor is.

For...Next

It inserts a For...Next command in the selected Script in the place where the cursor is.

While...Wend

It inserts a While…Wend command in the selected Script in the place where the cursor is.

Repeat...Until

It inserts a Repeat...Until command in the selected Script in the place where the cursor is.

When you select the Application root in the tree, its properties will be displayed in the right hand side. Here the generic parameters about the application will be set, as well as its behavior in relation to other programs and operational system itself. The variables that can be set up here are: FIELDS

DESCRIPTION

Description

It defines the application title (that will appear in the title bar) if the Title Bar option is enabled.

Title bar

It shows the Title Bar in the application window.

 Elipse Software

4-6

Elipse Scada

S T A R T I N G

U P

Disable task-switching

It disables the exchange among the windows programs, that means, once it is in the Elipse Scada it will no be allowed to go to other applications unless ending the section. (Disables the Alt-tab option).

Disable Screen-Saver

It disables any screen saver while running Elipse Scada.

Close Button

It enables the Close button and the System Menu.

Minimize Button

It enables the minimize button.

Maximize Button

It enables the maximize button.

Allow Close

Whenever it is Off, it makes the Runtime to complete only when the function StopRunning() is selected. When it is On it allows to turn off the Elipse by other means such as a mouse click in the close button, in the Windows shutdown, and so on. It opens a window that shows the Elipse version that last recorded the application, the total time of the application edition, the number of the

Statistics …

Find Item…

It opens a window that allow to find items (object, properties) anywhere in the application and to present it for edition.

Import…

It opens a window that allows choosing an application for import. After choosing the source application a new window will be open with a two application tree, so that the user may be able to drag objects from the origin application to the destination application.

Protection…

It opens a window for Application protection. There are two protections: for set up (Open/Modify/Save) and for Run. In the case of using a password for the set up the final user will not be able to change the application, unless he knows that the Runtime will have a password just if there the Set up has one.

Start Maximixed/Minimized/ Normal

It defines the setting of initial sizes of the application.

Use Runtime Keypad

It enables the keyboard use in the screen through the mouse or Touch Screen.

Don’t Show Mouse Pointer

It disables the display of the mouse pointer.

Use large buttons

Enables the use of large buttons in the screen objects and keypad.

Drill: Task: To degine the new application style.  Key in: “Elipse Scada Training Application” in the Description property.

 Elipse Software

4-7

Elipse Scada

S T A R T I N G

 In the Style properties choose Title bar and in the tab Window choose Initialize Maximized.

 Elipse Software

4-8

Elipse Scada

U P

T A G S

5

Chapter

5.

A

Tags Process supervision with the Elipse Scada takes place through process variable readings in the field. The values of these variables will be stored in tags.

At least one Tag or Attribute must be associate for each animation object inserted in the screen. Tags are all the variables (numerical or alphanumeric) involved in one application. It can be of several types, according to purpose of use. Attributes are data furnished by the Elipse Scada about system parameters and Application components. For instance, we can consider a tag as furnace temperature, and one of its attributes is the alarm level from which the siren will be activated. Tag values or associate Attribute value can be displayed by the animation objects in the Screen, used in calculations through the scripts, modified through the operator’s actions, and so on. In creating Tags, the user will be able to organizer them in Groups as he may wish, so to make it easier the search and identification during the set up process. To create groups, just select the Tags item in the Organizer and click in New Group. You can create groups within other groups, and if you wish to change their position, (e.g. to include it in other group) just drag it to another position and the whole content will also be moved. See the following list for the existing type of Tags:

 Elipse Software

5-1

Elipse Scada

T A G S

5.1. Tags Type TYPES

DESCRIPTION

PLC

It is used to exchange information with the data acquisition equipment (writing and reading) through communication drivers. The requested parameters are obtained through the help file that come along with each communication driver.

DDE

(Dynamic Data Exchange) – Tag for data exchange with other applications. It represents one manner of exchanging data between applications (e.g. Excel, Acces, Word, etc), or further between communication drivers “DDE Server” supplied by a manufacturer.

Demo

Tag for values simulation. It allows to create defined curves or random values from the selection in the buttons that are displayed in the window.

Expression

Tag that allows the input of a numerical or alphanumerical expression (it allows a sum between strings).

Block

Similar to the PLCType Tag, however it allows the reading of several simultaneous data. In some cases the use of Block type tags enhances the communication.

RAM

Tag of internal use to store values in the memory. Tags of RAM type are volatile that means, they store values while the application is open.

Matrix

These are RAM tags set in order to allow vector and matrix access.

Counter

It allows the creation of counters and timers.

5.1.1.Rules for Tags names In order to specify tags names some details must be followed:  The variable name cannot contain reserved characters such as: logic and arithmetic operators, ? , . , - , + , * , etc.  The variable name cannot contain space: This is also valid to the other properties that are not tags, if you wish to use them in scripts (programming language), since the compiler will take them as distinct variables.  The tag name cannot be strictly numeric. The following examples inform the tags creation procedures. If you have an equipment and wish to perform communications, choose the creation of variables type PLC or

 Elipse Software

5-2

Elipse Scada

T A G S

Block; otherwise, choose the Demo type, that will allow the simulation of values in the absence of real data.

5.2. Creating Tags To create new Tags, just select Tags item (for creating a root) or a specify group (for creating a group) and click in New Tag, where the following help box will be displayed:

In whick name (following the mentioned rules), quantity (in case you create more than automatic numbering at the end of the names will be created) and type shall be informed.

5.2.1. PLC Tags PLC type are generally used when you wish that a tag access communication driver reads/writes a value or a set of values to a single variable. Therefore, it can represent any type of variable independently as an input or an output, digital or analogical, depending on the set up and address required by the communication driver.

 Elipse Software

5-3

Elipse Scada

T A G S

Each tag PLC or Block must be associated to a communication driver, which will be responsible for the communication with the specific equipment. You must set up the communication driver at least once when a new application takes place.

5.2.1.1.Communication driver The Elipse Scada drivers are separate files with DDL extension that can be placed in and directory to be defined by user. To set up a new driver, just click in the Drivers item from the Organizer – then in the New button loading the correspondent DDL file. By choosing the Set up option it is possible to specify the general data about communication, as serial port, communication rate, and so on, according to the supplied documentation to each communication driver. To assist the set up task, you must access the Driver Help option where the driver set up parameters is displayed. FIELD

DESCRIPTION

Driver Location

It shows the path where the DDL file is.

Parameters

It allows the communication general parameters set up, such as serial port, communication rate, according to the supplied documentation and help.

Abort on Error

This option displays a dialog box requesting the annulment of the communication with the driver, in case of communication error. This option must be used only in the set up, since its running can be dangerous, in the sense that if the operator answer “Yes”, all the communication will be suspended.

Hide mouse during communication

The “Hide mouse during communication” option can be used to verify interruption conflict in the serial port (generally not used) and the “retry failure communication” can be specify a retry number in case for error (generally disabled).

Retry failed communications/ Number of Retries

Extra try number in case of communication error. Use this property with caution, because if the equipment presents continuous communication errors a general review of all communication will be necessary- otherwise it will cause delay on the general answer of the software.

Consult at the end of this manual the exhibits related to some help examples of communication driver. Through the Advanced button you will have access to more detailed set u about the driver operation.

 Elipse Software

5-4

Elipse Scada

T A G S

FIELD

DESCRIPTION

Maintain 16-bit driver behavior

When enabled, it is the normal operation mode of the 16 bits versions. If disabled, it operates the hybrid multitask mode that is 32 bits version pattern. This operation mode of the 32 bits drivers places all the communication task in a separate process, in asynchronous way compared to the Elipse Scada normal operation, speeding up the application process. This method is only suspended when there are the user’s clear restrictions to obtain a variable value, such as a script (program), where the following step dependes on the tag value update, when the process of information exchange between the communication driver and the main program becomes synchronous.

Use background writing

It also allows the writing perform in parallel process, however it allows placing the write requirement to the driver with the same priority of others requirements (low priority) or in the top of the requirement list (high priority).

Start driver at application startup

This option allows that on starting an application the communication driver be ready to exchange information, or in another works, it automatically runs its function via some script, in order to allow the communication.

Keep driver in memory

When in set up, this option allows that the elipse Scada does not unload the memory driver every time it returns to the development enviromment.

Through the extra Button, available in some drivers, you will have access to special parameters of the set up, such as modems use and Debug or trace file creation of communication Consult the driver documentation to learn more about these parameters.

 Elipse Software

5-5

Elipse Scada

T A G S

Drill: Task: To set a communication driver to be used.  Load the communication driver and with the help file assistance, fulfill the p1 to p4 parameters enabling the in Abort in Error option, and disabling the hiding mouse… option and to not use retries.

 Elipse Software

5-6

Elipse Scada

T A G S

The following screen is displayed when a tag PLC type is created, presenting the following parameters:

FIELD

DESCRIPTION

Name

Tag name. You can use as many characters as you wish, but special spaces and characters are not allowed when Tags are used in the Scripts.

Change type to

It allows the Tag type to be changed.

Expand bits…

It allows to separate the Tag in bits, creating Tags Bit to each bit or tag bits set.

Description

A brief description about the tag.

Driver

It allows selectig a communication driver to the current Tag. Drivers must be installed through the Drivers windows in order to make them available.

Driver Help

It shows the Help of the selected Driver.

 Elipse Software

5-7

Elipse Scada

T A G S

“N” Parameters

It allows the address “N” parameters set up to the current Tag according to the selected driver. This set up is contaned in the Driver Help that can be accessed by pushing the “Driver Help” button. Values can be expressed in decimal [-32768, 65535], octal [0o, 177777o] or hexadecimal [0000h, FFFFh].

Scan

It defines when the tag values will be updated (mSeg).

Scaling

By selecting this option, the Tag values will be converted on a new scale of values determined by the user as the defined limits in PLC Low, System Low, PLC High and System High.

PLC low

It defines the minimum PLC (CLP) value to be read.

System Low

It defines the new minimum value to be read in the PLC (CLP).

PLC High

It defines the maximum value to be read value conversion.

System High

It defines the new maximum value to read value conversion.

Test Connection Here

Its tests the communication with the PLC in reading and writing some values.

Enable Scan reading

If this option is enabled, this tag will be read in the specified rate in the Scan field in milliseconds, whenever there is any item in the application that is being used by the tag (Screen, Historical, Alarms, and so on).

Enable automatic reading

It enables automatic reading. It enables the tag to be read in case its value become necessary, and the last reading made is old (bigger than the scan time).

Enable automatic writing

In case of value attribution, whichever through scripts or screen objects (setpoint, slider) to a tag clp or block element, it specifies whether the driver will automatically send the new value to the equipment.

Drill: Task: To create tag PLC type to represent a digital input.  Select Tags object in the Organizer, click in New Tag button;  Key in DI in the property Tag name;  Key in 1 in the How many field;  Choose the Tag PLC type, and then click in the OK button.  Select General page. In this page, associate the communication driver, that is already set, through the driver list box. Specify the parameters from n1 to n4 according to the Help file, or through the appendage found in the end of this

 Elipse Software

5-8

Elipse Scada

T A G S

manual. In the Test Connection Here section, there is the possibility of reading/writing values directly in the variable addressed in the equipment.  If the read variable is a word whose bits are relevant digital information we can separate them. Clicking in Acess Bits will open a window to specify which bits will be expanded. The bits use can be made as if abdnormal tag, being only its reading “masquerade” with the other bits before sending it to the equipment. Such characteristics will be seen ahead with more details in section 5.2.8.

Task: To create a tag PLC type to represent a digital output.  Select Tags object in the Organizer, click in the New Tag button:  Key in DO in the property Tag name;  Key in 1 in the How many field;  Choose Tag PLC type and then click in the OK button.

Task: To create a new group of tags, with three tags of tank level of the PLC type.  Select the Tags object in the Organizer, click in the New Group button:  Key in Levels in the property Name  Select Levels group by clicking in New tag;  Key in Tank01 in the Name field;  Key in 3 in the How many field;  Choose the tag PLC type, and then click in the OK button.  3 tags of the PLC type will be created with part of the name alike, but with different numerical index (in crescent order) once there are not two tags with the same name.  If the equipment values that are being read are kept in a different scale form from that used in your system, you can specify a conversion on the tag, stipulating the inferior and superior levels in the System. By using the variable in any part of the software (except in the Organizer in the Test Connection Here function, where the values without conversion are shown), its scales will be automatically calculated in each reading or writing.

 Elipse Software

5-9

Elipse Scada

T A G S

5.2.2.Tag DDE Tag DDE is used to exchange data between the Elipse Scada and other application (Excel, Access, Word, etc.) using DDE (Dynamic Data Exchange). In a Windows network, Elipse Scada uses NET DDE and becomes able to exchange data with other Elipse Scada, among other ways, through Tag DDE. For that purpose, you need to specify the computer name, the server application, the topic and the item, as you can see in the following box:

FIELDS

DESCRIPTION

Name

Tag name. You can use as many characters as you wish, but special spaces and characters are not allowed when the tags are used in the Scripts.

Change

It allows changing the tag type.

 Elipse Software

5-10

Elipse Scada

T A G S

Description

It is a brief description about the tag.

Computer

It defines the computer name where the server application DDE comes across. The default computer is the current computer, but if there is a Windows network other computer is the current, but if there is a Windows network other computers will be available to exchange data using the NET DDE.

Server Name

It defines the DDE server name that can be used on a Windows application (e.g. Excel, Word, etc) or a DDE driver furnished by your equipment manufacturer. The is of available programs to DDE server is displayed when the arrow near this box is pressed.

Topic

It defines the DDE Server Topic, depending on the Server type. It can be a document (e.g. an Excel table). The available Topic list is displayed when the arrow near this box is pressed.

Item

It defines the DDE Server Item, depending on the Server type. It can be a document item (e.g. a cell of an Excel table).

Test Connection

It allows that you test the DDE set up. A message can indicate a connection error or a received value by the set item.

Scalling

By selecting this option, the Tag values will be converted into a new value scale established by the user according to the defined limits in the Server Low, System Low, Server High and System High.

Server Low

It defines the minimum value to be read by the Server.

System Low

It defines a new minimum value to read conversion values.

Server High

It defines the maximum value to be read by the Server.

System High

It defines a new maximum value to read conversion values.

Drill: Task: To create a link between an Excel cell and a Tag DDE type.  Select the Tags object in the Organizer, and click in the New Tag button:  Key in Spreadsheet in the property Tag name;  Key in 1 in the How many field;  Choose the Tag DDE type, and then click in the OK button.  Open the Microsoft Excel, and key in any value in the first cell on a new spreadsheet.  In the Spreadsheet tag, choose Server Name: Excel, Topic: Sheet1, Item: R1C1 or L1C1 (depending on the excel, if in English or in Portuguese);  Click in Test Connection and key in value in the cell will be displayed.

 Elipse Software

5-11

Elipse Scada

T A G S

5.2.3.Tag Demo The Tag Demo is used to the value simulation. It allows you create defined curves or random values according to the curve type selected in the six buttons of the General page of the Tag Demo (see picture below).

FIELD

DESCRIPTION

Name

Tag name. You can use as many characters as you wish but special space and characters are not allowed when the Tags are used in the Scripts.

Change type to

It allows changing the Tag type.

Expand bits…

It allows separate Tags in bits, creating Tag Bits for each Tag bit or bit set.

Description

It is a brief description about Tag.

Type

It defines the curve type to be used by the current tag Demo.

Low Limit

It defines a minimum value to the Tag Demo.

 Elipse Software

5-12

Elipse Scada

T A G S

High Limit

It defines a maximum value to the Tag Demo.

Increment

It defines the increment to the Tag Demo when a saw tooth curve is selected.

Delay

It defines the period number between each value creating to the Tag Demo. For instance, if it is 1, a value is created in each period, if it is 2, it create a value in each two periods, and so on. It is used together with the period attribute to control the time range to data variation.

Period

It defines the msec number between the creation of each new value to the Tag Demo. It is used together with the delay attribute to control the time range to data variation.

Enabled

It defines the initial status of the Tag Demo. Enabled or Disabled. The Tag Demo values are created only when this option is selected, otherwise, the tag Demo value will remain the same.

Task: To create a Tag Demo type to the mixer animation in the Funnel.  Select the Tags object in the Organizer, and choose New Tag. In the name property key in Mix, and accept it with the OK button.  In the Mix tag properties, choose the triagonal wave option, with inferior 0 and superior 9 limits.

5.2.4.Tag Block The Tags Block have the same purpose as the PLC tags, that means, they exchange information with the data acquisition equipment through the communication drivers supplied by Elipse Software. Its goal, however, is to allow that several tags have its values read or written simultaneously, increasing the phisical environment and decreasing the scanning medium time of the variables. In general, each block must be associated to a communication driver. It has a scan time that is the same for all its variable. If you have an application with too many PLC tags, and want to change them into block element tags, you can use the Change type option where the destiny block must be chosen (if changing block). From that on the tag will be changed into a block element, including the change in all its internal references (use of screen, expressions, scripts and other objects).

 Elipse Software

5-13

Elipse Scada

T A G S

FIELDS

DESCRIPTION

Name

Tag name. You can use as many characters as you wish, but special spaces and characters are not allowed when the tags are used in the Scripts.

Change type to

It allows changing the tag type.

Description

It is a brief description about the tag.

Driver

It allows the selection of a communication driver to the current Tag. The drivers must be installed through the Drivers window in order to make them available.

Driver Help

Is shows the help of the selected Driver.

“B” Parameters

It allows the set up of the address “B” parameters to the current Tag according to the selected Driver.

Scan

It allows the set up of the address “B” parameters to the current Tag according to the selected driver. This set up is contained in the Driver Help that can be acessed by pressing the “Driver Help” button. The values can expressed in decimal [32768,65535], octal [0o, 177777o] or hexadecimal [OOOOh, FFFFh].

 Elipse Software

5-14

Elipse Scada

T A G S

Change Size

It defines when the tag values will be updated (mSeg).

Add Element

It changes the block size to be monitored by the Elipse Scada.

Enable scan reading

It allows you to add a new element in the selected Tag.

Enable automatic reading

It enables automatic reading in block.

Enable automatic writing

It enables automatic writing to the block.

BLOCK ELEMENTS

Each Tag Block element has properties that can be accessed by selecting the element you seek in the application tree of the Organizer. The following page will be then displayed in the right side of the window. The same regards made to the PLC tags is valid to block elements, namely:  Use of scales in the elements;  Writing and reading in the elements;  Changing into bits;  Alarms use.

 Elipse Software

5-15

Elipse Scada

T A G S

FIELD

DESCRIPTION

Name

Tag name. You can as many characters as you wish, but special space and characters are not allowed when the tags are used in the Scripts.

Description

It is a brief description about the tag.

Expand bits …

It allows separating the tags in bits, creating Tags Bit for each bit or bit set of the Tag.

Block Index

It allows changing the element order in the block by keing in the desired index.

Scaling

By selecting this option, the tag values will be converted into a new value scale estabilized by the user according to the defined limits in PLC Low, System Low, PLC High and System High.

PLC Low

It defines the minimum value to be read in the PLC (CLP).

System Low

It defines the new minimum value to the conversion of the read values.

PLC High

It defines the maximum value to be read in the PLC (CLP).

System High

It defines the new maximum value to the conversion of the read values.

Test Connection Here

It tests the communication with the PLC reading and writing some values.

Drill: Task: To create a communication box with 3 elements. Procedure: Follow the same procedures as for the tag creation, choosing now in the name property block1, in the how many field 1 and the type block. After you click in OK, it will be asked the block elements number where you must key in 3. Select now three elements keing in the text name “Temperature01”. Automatically the other blocks elements will have the following names Temperature02 and Temperature03.

5.2.5.Tag Ram Tags Ram are internally used to store values in the memory. This Tags type is volatile, therefore it keeps its values only when the application is running. There are two ways in order to establish an initial value to the RAM:

 Elipse Software

5-16

Elipse Scada

T A G S

a) Place the initial value (fix) in the Initial Value field. b) Store the desired value in one recipe (whose values are changeable), and load it in the application starting, which makes the tags present in the recipe do not be volatile. More details can be seen in chapter 11, Recipes.

Drill: Task: To create RAM variables to the register and storage of the raw material quantities. It is not necessary to specify an initial value. Procedure: To create a new tags group called Products. To create from this group the following tags RAM: Water, Sugar, Syrup, Glucose, number_recipe and Code (that will receive the products code).

5.2.6.Tag Matrix Tag Matrix allows to create data matrixes or vectors that can be used in calculations, storage, and others. It is possible to map each cell of a matrix as if were a tag, and then associate each one of them to a tag or property. In this case, once the cell value changes, the tag/property associated takes over a new value and vice versa. Keep in mind that the operation about matrixes always have row and column starting with index 1.

 Elipse Software

5-17

Elipse Scada

T A G S

FIELD

DESCRIPTION

Name

Tag name. You can use as many characters as you wish, but special spaces or characters are allowed when Tags are used in the Scripts.

Description

It is a brief description about the tag.

Columns

It defines the matrix column number.

Rows

It defines the matrix row number.

Map

It maps all or some of the matrix cells to a tag.

MAPPING CELLS TO TAGS

You can map a matrix or vector cell to a Tag by pressing the Map... button in the Tag Matrix General page, and by specifying which are the cells that you wish to map. Each mapped cell is displayed below the Tag Matrix in the application tree in the Organizer. When selecting a specific cell, its properties are displayed in the right side of the tree. Each mapped cell has 4 property pages: General, Alarms, Scripts and Tags. The 3 first pages are the same of any tag, and the tags page allows to associate a Tag or

 Elipse Software

5-18

Elipse Scada

T A G S

property to the matrix cell likewise the tags and properties are associated to Screen Objects (see 7.2.2 section).

5.2.7.Tag Bit Tag Bit can only be created starting form another tag, and it allows to individually access each bit of it. Those Tags that allow the separation in bits are: PLC, Demo, Expression, Block Elements, Ram or Remote. This resource is very useful when a read value of an equipment, such as a byte or word, actually represents 8 or 16 (or more) independent digital status (on or off). The bit value is obtained through the masking of the bit position with the tag to which it belongs. On the other hand, the writing is made in two ways: masking and writing the whole or written word of the individual bit, if the equipment supports such command that is implemented in a transparent way to the user in the communication driver. You can create a Tag Bit from the General page of any of the above mentioned tags. Clicking the Access bits… button the following windows will be displayed, where you will be able to select the bits that you wish to be mapped. The bit selection is made using the mouse and the SHIFT or CTRL keys, in the same way the items are selected in a windows list box.

The tag bit can be whether a single bit or a bit set, once they are continuous. That means that you can map one single Tag Bit, for instance, the 0,1, and 2 bits, but not the 10,11 and 24 bits. A check box existing in this window allows to specify if a Tag to each selected bit must be created or if the continuos bits that are selected must be gathered in one single Tag. In the next example, 5 tags Bit are created as follows: TAG

 Elipse Software

5-19

BITS

Elipse Scada

T A G S

BitField1

0, 1, 2

BitField2

5

BitField3

8

bitField4

12

bitField5

20, 21, 22

The tag Bit created are displayed below its respective Tag in the application tree in the Organizer. When selecting a specific tag Bit, its properties will be displayed in the right side of the tree. The Tag Bit General Properties page is displayed when the General tab is selected in the top of the Tag Bit pages. This page is shown below. Its respective fields are described in the following table.

FIELDS

DESCRIPTION

Name

Tag name. You can use as many characters as you wish, but special spaces and characters are not allowed when the Tags are used in the Scripts.

Description

It is a brief description about the Tag.

 Elipse Software

5-20

Elipse Scada

T A G S

High Word bits and Low Word bits

It defines which bits or bit is part of that Tag.

Drill: Task: To separate in bits the already created Di and DO tags. Procedure: Select through the Organizer the DI tag and then the Access Bits. Choose the bits from 0 to 7, specifying the option Create a tag for each bit. Bits, representing 8 digital inputs will be created as the tag DI “sons”. Follow the same procedure as to tag DO.

5.2.8.Tag Expression Tag Expression allows you to attribute a numerical or alphanumerical expression to a Tag. You can create equations involving any variables, whether numerical, alphanumerical, tags or attributes. When you key in the expression, which will be the operation performed by the tag, in the errors field those errors found in the edition up to that moment will automatically be displayed. The same functions, operators and constants used in the Scripts (programming module) can be used in the tags expression (see chapter 9 – Scripts). To use them when editing an expression, just click in the App Browser option (thrird icon in the Organizer toolbar), where a window will be displayed that makes it possible to copy all the function / attributes available in the application to the editing line.

 Elipse Software

5-21

Elipse Scada

T A G S

FIELD

DESCRIPTION

Name

Tag name. You can use as many characters as you wish, but special space and characters are not allowed when the tags are used in the Scripts.

Change type to

It allows changing the Tag type.

Expand bits…

It allows to separate tag in bits, creating Tags Bits for each Tag bit or bit set.

Description

It is a brief description about the Tag.

Expression

It allows the input of any valid expression to the tag.

Errors

It lists syntax errors found in the expression. The error are displayed during the expression edition, and to make a valid expression the message “No errors” must be shown in this field.

The same functions, operators and constants used in the Scripts can be used in the tag Expression (see Chapter Scripts, Constants & Operators): CONSTANTS Integer (decimal, bin, octal, hex)

 Elipse Software

EXAMPLE 1234, 1234d, -1234, 10011b, 733o, 0A100h

5-22

Elipse Scada

T A G S

Real numbers 100011b Strings “Temperature”, “pressure” OPERATORS EXAMPLE + (Sum, strings concatenation) tag001 + 34, slider.frame.title+ “ T01” - subtração, * multiplicação, / divisão, % tag001-screen1.x, tag001/tag002, tag002 resto, ** exponenciação ** 2 LOGICAL OPERATORS EXAMPLE &,|,^,~,<<,>> (bit a bit) flags & 0001h AND,OR,XOR,NOT (lógico) tag001 AND (tag002<20) LOGICAL OPERATORS EXAMPLE == (comparison), >,<,>=,<=,<> tag001==20 ATTRIBUTING OPERATORS EXAMPLE tag001 = 20 tag001 += 20, tag001 *=20 tag001 = tag001 + 20, tag001 = tag001*20

Drill: Task: To create a tag expression that will be the combination of two digital tags called Status. This tag will show a useful example when you wish to show in the screen an indication or animation that has more than two status (on, off, fault, etc…). In this case, it is necessary to creat a tag expression. Procedure: Follow the same procedures as to the Tags creation, choosing now the expression type. In the Name field key in “Status”. Now click in the expression field. At this moment there are two paths: You can directly key in the desired text, or use the App Browser tool to navigate through the application, allowing to copy the desired function, attribute or object directly to the edition place. In the first case: 

Key in “Tags.DI.CampoBit1*2 + Tags.DI.CampoBit2” in the expression field.



In which the final result will be a value from 0 to 3 as the following possibilities:

FieldBit1 0 0

 Elipse Software

FieldBit2 0 0

5-23

FieldBit3 0 1

Status 0 1

Elipse Scada

T A G S

0 0 1 1 1 1

1 1 0 0 1 1

0 1 0 1 0 1

2 3 4 5 6 7

In the second case: 

Acess the app Browser button, and click in Tags, selecting the tag DI.



Click twice in it, and search for the FieldBit1 item. After selected, click in Copy to the Script, where the desired item will be transferred to the Expression in the tag Status.



Now you must key in the “*” and “2” signals to complete the first part of the expression.



Repeat the procedure to the other field Bit.

5.2.9.Tag Chrono Tag Chronometer allows performing basic operation to time counting (increasing and decreasing) and timing, allowing execute tasks when a certain value is obtained.

 Elipse Software

5-24

Elipse Scada

T A G S

5.2.10.Tips about Tags IMPORTING TAGS FROM OTHER APPLICATIONS

In order to allow the good use of the work done in the other application or even to allow more than one person to work in the same application, you can import parts of other applications. Use the Import tool in the Application item in the Organizer to carry on such task. I will be asked the source application path that contains the desired objects to be copied. After specifying its place, the following window will display:

 Elipse Software

5-25

Elipse Scada

T A G S

MAKING COPIES OR MOVING TAGS OR TAGS GROUP

Use the duplication tool to make copies of tags or tags group. The same procedure can be used to other objects, such as Screen and Screen objects. To moves a tag or tags group through the organizer just click in the tag or group and drag it (without loosen the mouse button) to the final position that can be a root Tags group item and drop it. All its references (links with other objects or scripts) will be updated.

CHANGING TYPES

You can use the Change type to... tool that accepts multiselection, which event redo the references, that means, the links that variable has in a way to set it in the new desired type.. SETTING MULTI TAGS

Very often it is necessary to set countless Tags to several attributes in an identical way. It is possible to set up countless Tags at the same time. You must select all the desired Tags in the Organizer- drag the mouse starting from the first Tag until the last Tag in

 Elipse Software

5-26

Elipse Scada

T A G S

the list. At this moment all Tags display as selected, if you desire to select just some of them press the CTRL key while you click in each desired Tag. Now each action or key in that is made with the already selected tags will be carried on in all tags. OPT FOR THE COMMUNICATION TAGS IN BLOCKS

Whenever it is possible the use of tags block allows the inserting of the physical means, for in a generic serial communication process, great part of the characters transmitted belong to control and checking. By using blocks we make such characters to be sent in a smaller number of times due to the encapsulating of the great number of variables in the same transmission. COMMUNICATION TAGS SCAN TIME SETTING

Try to program the variable scan time with the closest real values. If a very low scan time is specified to all the variables, probably the following will take place, due to pysical means limitation: not all the variables will be collected in the specified rate, which will create a performance decrease in the communication, not allowing that certain variables that really need a faster search be in charge of the communication. TIME INFORMATION IN THE TAGS

Some equipment allow sending time information together with the variable values. The communication driver for such equipment can also return this clock information, in each consulted tags. This information can be obtained through the TimeStamp property, in all tags, with an accurcy of 1 ms. When the equipment does not support this kind of information, or when the driver is not ready for such procedure, the program itself will perform the information task at the moment of collection, filling up with the PLC watch value. Remark: In the case of Block tag type, the same TimeStamp is informed to all the block elements, once they have already been consulted at the same time. If they are distinct events they must be read as tag of PLC type.

5.2.11.Alarms Page Each Tag that is defined has an Alarms page as the one shown below in which 4 range values and priorities to Alarms can be set. Alarms are used to signalize any event that may happen with a variable, also allowing take the appropriate actions through the Scripts (programs).

 Elipse Software

5-27

Elipse Scada

T A G S

To visualize the set Alarms to a Tag, you need to insert an Alarm Screen object, something we will see later. This object can also show the spread alarms that are registered on an Alarm file or active alarms of the system. To print the spread alarms in the system you can define a Report through the Organizer and run the main function of the Print in a Script. The tags Alarms page displays when the tab Alarms is selected in the top of the Tag pages. That page is shown below and its respective fields are described in the following table.

FIELD

DESCRIPTION

Lolo

Critical Low Alarm. It defines a value range (minor equal) where the Tag is considered to be in a Critical Low Alarm status. It is used when the tag value is below the minimum, that means, extremely low.

Low

Low Alarm. It defines a value range (major equal) where the tag is considered to be in low alarm status. It is used when the Tag value is bellow the average.

High

High Alarm. If defined a value range (major equal).

 Elipse Software

5-28

Elipse Scada

T A G S

HiHi

Critical High Alarm. It defines value range (major equal) where the Tag is considered to be in HighAlarm. It is used when the Tag value is above the maximum, that means, extremelly high.

Value

It defines the priorities for each possible alarm (lolo, low, hi, hihi).

Priority

It defines the priorities for each alarm event. Small numbers indicate high priority (the priority must be a number from 0 to 999). For a better control, the high priority alarms will be displayed in foreground in the alarms window (Alarm Screen Object).

Comment

A comment or message can be defined for each alarm. Up to 100 characters can be used.

Log Alarm Return

It enables the message log of Alarm return.

Alarm Group

It defines the alarm group, whose file will receive the incident messages.

The range between the Low and High levels of the alarm (if set) represents the normal operation status of the variable. When exceeding these limits, the incident is looged as an active alarm. If the variable rturns to its normal status, the return incident is looged if this operation is selected.

5.2.12.Alarms and Alarms Group Each time an alarms is spread, all the event data are recorded, such as date/Hour, event type, tag value, etc. Each alarm can be associated to an alarm group that is defined by the user, in the Alarm item in the Organizer, as follows:

 Elipse Software

5-29

Elipse Scada

T A G S

In this page, we can set a file for alarm recording, as well as alert sounds and messages that are recognized as standard alarm group. FIELD

DESCRIPTION

Name

Alarm Group Name.

Description

Description about the group.

Enable Log

It enables data recording in disk for group.

Records

Maximum register number. The file is rotative, that means, it will only contain the number here that will be the most recent ones.

Filename

Disk file name.

Create New Alarm Group

It creates a new Alarm group.

A different alarm group can be used when you want to separate some type of tags alarms, so that they are stored in separate files. In order to visualize pr print thenm, in this case, it will be necessary to create separate objects and reports, one for each file.

 Elipse Software

5-30

Elipse Scada

T A G S

Drill: CREATING ALARMS FOR TAGS

Task: To create alarms for temperature and level tags. Procedure: Select the three temperature tags, and in the alarm page create the Low and High option specifying low level 25 and high level 150. Repeat the operation for the level tags with limits of 10 and 90. Insert the text that you consider interesting in the comment field, such asd “High cooker level 1” or “Low Area Temperature 2”.

 Elipse Software

5-31

Elipse Scada

S C R E E N

6

C R E A T I O N

Capítulo

6.

A

Screen Creation Screen can be defined as a process monitoring window, in which the objects that will do the operator interface with the system will be inserted. Each application can have an unlimited number of screen.

You can create a new Screen pressing the new Screen button in the Toolbar or using the New command in the Screen menu. In this new Screen, you can define the Screen Objects, walpaper and other specific features. For a better graffic quality of the system that is being monitored you can insert a wallpaper to the Screen. The format used today by the Elipse Scada is a grafical file with BMP, GIF or JPG extension that can be created in several specific draw Windows applications, as the paintbrush (Windows 95/98/2000/etc), CorelDraw, Paint ShopPro, Autocad and others. You can create your own drawing (bitmaps) in any size and color you wish. The Elipse Scada will automatically import them without using a conversion process. To visualize or edit the current Screen properties, double click in an empty window is displayed, containing a list of all the Screen in you application. You can create a new Screen using the New button in the right side of the page or remove and then the bdelete button.

 Elipse Software

6-1

Elipse Scada

S C R E E N

FIELD

C R E A T I O N

DESCRIPTION

List

It shows a list of all the existing Screen in its application. The same Screens will be displayed in the Organizer tree below the Screen option, and when they are selected its respective properties are displayed.

New

It creates a new Screen.

Delete

It deletes the Screen selected in the list.

Go to

It closes ythe Organizer and shows the current Screen.

Show

It shows the current Screen without is selection.

Hide

It hides the current Screen, keeping it in the application.

6.1.1.Screen General Properties Each Screen that you create for an application is displayed below the Screen option in the application tree in the Organizer. When selecting a specific Screen, its properties are

 Elipse Software

6-2

Elipse Scada

S C R E E N

C R E A T I O N

displayed in the right side of the tree, or when you double click on its background (outside the Organizer) or even through the

button in the toolbar.

The Screen general Properties is displayed when the General tab in the top of the Screen Page. This page is displayed below and its respective fields are descrived in the following table:

FIELDS

DESCRIPTION

Name

It defines a name for the current Screen. By using this name, you can open the Screen from any part of the application using the function buttons or screens, as well as to associate it to Scripts.

Title

It defines a Title for the Screen, also used as its description.

Color

It defines the background color for the current Screen. This parameters is used when there is no selected bitmap or when the bitmap or when the bitmap does no fulfill the Screen.

Bitmap

It allows to navigate in the directory structure in order to find the BMP files that are used as Screen background. The bitmap path and name are displayed below the check box.

 Elipse Software

6-3

Elipse Scada

S C R E E N

C R E A T I O N

Browser

It defines the access to the Screen that will be verified with the access level of the user when entering the Screen.

Acess level

It defines the access to the Screen that will be verified with the access level of the user when entering the Screen.

6.1.2.Screen Style Properties The Screen Style property page is displayed when the Style tab is selected in the top of the Screen pages. That page is displayed below and its respective fields are described in the following table.

FIELD

DESCRIPTION

Full Screen

It determines the Screen to occupy the whole application window.

Windowed

It determines the Screen to be displayed inside a window occupy the whole application window according to the specifications in the Size and in the Position options.

Width

It defines the Screen width in pixels.

Height

It defines the Screen height in pixels.

 Elipse Software

6-4

Elipse Scada

S C R E E N

C R E A T I O N

X

It determines the X coordinate for the left superior corner of the Screen in pixels. For instance, if you are using a windows resolution of 640x480 (VGA), your X coordinate can vary from 0 (zero) to 640 pixels to a window without scroll bar.

Y

It deteremines the Y coordinates for the left superior corner of the Screen in pixels. For instance, if you are using a Windows resolution of 640x480 (VGA), your Y coordinate can vary from 0(zero) to 480 pixels to a window without scroll bar.

Scroll Never

It determines the winodw not to have scroll bars, even when its necessary.

Scroll Automatic

Scroll bars will automatically be displayes when they become necessary.

Close

It enables the close button to be displayed in the window (button in the right superior corner). This button can only be seen in the Windows 95/98/NT/XP or superior.

Maximize

It allows to maximize the window.

Minimize

It allows to minimize the window.

Show Border

It inserts a border in the screen.

Resizable

It allows to resize the window in the running time.

Moveable

It allows the window to be moved in the running time.

Title Bar

It displays or hides the Title bar.

Initial Screen

It makes the Screen be the first display in the running.

Modal

It does not allow the user to leave the Screen without turning it off.

Pop-up

It allows the screen to be automatically closed when the user click out side the Screen.

Clip Children

When selected it makes the background drawing be totally displayed without cutting the objects.

Drill: CREATING

Task: To create the main Screen for the manufacturing monitor. Procedure: In the Organizer, select the Screen objects and press the New button, or Click in the New screen button in the toolbar, or through the menus, access the New – Screen option.

 Elipse Software

6-5

Elipse Scada

S C R E E N



C R E A T I O N

If you have already created an empty Screen (when starting a new application a screen is always automatically created) go to the next step.

From this new screen you can define new animation objects, the synoptic background draw, and all the Screen specific features. The list of existing Screens in the application is available in the toolbar for downloading during the set up process and Application creation. To set up the new Screen properties you can: 

From the Organizer, expand the Screen objects screen, selecting or not the Screen. Double click on the Screen in the Work Area, or click in the Screen Properties button

.

In the screen properties, key in “Dosage” in the property Name and “Dosage Screen” in the property Title. Select the option Bitmap, press the Find buton and select the Bitmap C:\ELIPSE32\LIB\UTIL\FUNDO MODELO.BMP. In the Style guide select the style options Full screen and Automatic scroll. Task: To create Screen for system Alarms visualizing. Procedure: Create a new screen and set the Screen with the Name “Alarms_Screen”, Title “Alarms Screen”, style with Window, Scroll Automatic, close button, option movable option selected, title bar selected and Initial Screen Selected not selected. Place the background color orange, through the Other colors option in the main page. Task: Create Trend Screens, in the same pattern as that one of the Alarm Screen. Procedure: One of the options would be to repeat the prior procedure. However other interesting option would be to duplicate the prior screen, and only change the necessary points. Through the Organizer select the Alarms Screen. Next, click in the that allow makes copies of any object. Then, a dialog second icon in the toolbar box is displayed, where must be informed the copy numbers (1). A new Screen called Alarms_Screen2 will be created. Modify this Screen putting the name “trend, the Title “trend Screen”. Choose the background color black. Task: To create the opening Screen, as Full-Screen; wine background color, Initial Screen selected; name “Opening”, title “Opening Screen”.

 Elipse Software

6-6

Elipse Scada

S C R E E N

C R E A T I O N

Task: To create the opening Screen, as Full-Screen; wine background color, Initial Screen selected; Name “Opening”, title “Recipe Screen”. Task: To create Recipe Screen, as with window, black background color, and closing button; name “Recipes”, and title “Recipe Screen”. Task: To create Bath Screen, also with window, green background color, and closing button; name “Batch”, and title “Batch Screen”. Remark: A reference for the screen look can be seen in chapter 3, Case Study.

 Elipse Software

6-7

Elipse Scada

S C R E E N

7

O B J E C T S

Capítulo

7.

A

Screen Objects N application Screen can contain background and objects bitmaps. The objects that are inserted over the bitmap constitute a secondary ground in the screen, in a way that it can be detected, copied, moved, resized, and bracketed, without damaging the background.

The screen objects, therefore, are graphical elements that are related to the tags so that it is possible to make a friendly interface with the variables. The previously available objects are as it follows: Slider: It allows to visualize or send values toa tag through a potentiometer (sliding button). Trend: It is used to visualize a trend graphic with up to 16 tags (that can be exchanged in the running), running the real time collection or in background, besides perform variable graphics by time, or the variables relating to others (XY). Button: For activating or running the specific tasks by the user through the mouse or key, being able to assume several formats and functionality.. Gauge: Displayer of analog values with the pointers. Text: This object allows attributing messages in Tags range values, called Areas, defining colors and messages fo each Area. Bars: It is used to visualize the data in volume appearance. It can be displayed up to 16 tags in each bar object. Display: Numerical/Alphanumerical displayer in real time. Animation: To create animation using bitmaps defined by the users.

 Elipse Software

7-1

Elipse Scada

S C R E E N

O B J E C T S

Setpoint: It is an editing box, for keyboarding and sending values to a variable. Alarms: It allows the visualization of the activated alarms () or the alarms logged in the alarm file (Historical). Browser: It allows the visualization of databases files in the screen. Bitmap: it allows the visualization of databases files in the screen. Video: The Video object allows you to show a video source, displaying a realtime video or a playback. Avi: The AVI object allows you to playback an AVI file. You can edit AVI properties double-clicking the object. Preview: The Preview object allows you show a video source.

7.1. Screen Object Edition The Screen Objects can be created from the toolbar Objects or through the Object Menu. Once selected the object that you wish to create, keep the left mouse button pressed in the screen area while moving the moouse (a spotted rectangle shows the size abd shape of the object). When you drop the button the object will be placed in the specified area. Insert any two objects in the screen (e.g: two buttons), so that you can verify and use the following tips: MAKING COPIES OF SCREEN OBJECTS

We can copy screen objects by pressing the CTRL key while we drag the object we wish to copy. This action will create a new screen object that will have the same properties as the copied object. You can even use the basic Copy (CTRL+C) and Paste (CTRL+ V) commands of the Windows.

 Elipse Software

7-2

Elipse Scada

S C R E E N

O B J E C T S

OBJECTS OVERLAP

If you have two screen objects, and part of one has to be over the other, you need to adjust the disposal through the Bring to Front

and Send to back

buttons.

NAVIGATING COMMAND BETWEEN OBJECTS WITH KEYBOARD/MOUSE INPUT

When inserting a series of screen objects, it is possible (in running) key to shift from one object to another by using the Tab, as two Set-points for instance. Initially, the shifting through the Tabs follows the object creation command in the screen. However, it is possible to easily change this command with a little trick:: 1) Select the objects in the desired Tab order. 2) Press the Bring to Front or Send to Back buttons. The objects that were brought to the front will be arranged firstly in the navigation command, and the other that were sent to the back will be placed lastly. The Screen Objects Edition, such as aligment, size, position and bracketing is done through the toolbar Settle or through the menu. The last selected object will have the focua in red to be used as a reference. To deselect an object use the key combination: SHIFT+CTRL+left button. SELECTING ALL THE SCREEN OBJECTS

To select all the objects contained on a screen, just press the Ctrl+A keys. SELECTING SOME SCREEN OBJECTS

To select the objects contained in an area, use the tool selection can select the objects within a mouse delimited area.

. With it you

USE OF DIRECTIONAL KEYS

In order to move an object in the Elipse Scada with the keyboard, select it an use the directional keys, as follows: Up arrow: It rises the object 1 point up;

 Elipse Software

7-3

Elipse Scada

S C R E E N

O B J E C T S

Down arrow: It descends the object 1 point down; Right arrow: It moves the object 1 point to the right; Left arrow: It moves the object 1 point to the left; Combining the directional keys with CTRL, you can make the object transference 10 times faster. Combining the directional keys with SHIFT, you can resize the object. Some examples: CTRL+Up arrow: It rises the object 10 points; SHIFT + Left arrow: It decreases in 1 point the object width; CTRL + SHIFT + Right arrow: It increases in 10 points the object width;

7.2. Screen Object Properties Once a screen object is inserted, its properties can be acessed in many different ways: a) Through a double click on the object; b) Selecting the object and using the Objects – Properties menus; c) Selecting the object and clicking in the button in the toolbar. d) Via Organizer, in which you can access the screen, and by clicking in the + symbol, the objects belonging to that screen will be displayed. All the objects have 3 property pages in common, as follows:

7.2.1.Frame page Trought the frame page we can set visual styles to the object, as Borders, tridimensional effects and titles, among others.

 Elipse Software

7-4

Elipse Scada

S C R E E N

FIELDS

O B J E C T S

DESCRIPTION

Visible

It enables or disables a frame arround the object.

Color

It defines the object frame color.

Title

It enables or disables a title in the object frame.

Text

It defines the title text.

Font

It defines the font, color and size of the Title font.

Text Line separator

It enables or disables a line separator between the text and the object.

Border

It enables or disables a border or frame.

Thickness

It defines the border tickness in pixels.

 Elipse Software

7-5

Elipse Scada

S C R E E N

O B J E C T S

Color

It defines the frame border color.

3D effect

It selects a 3D effect inside or untsides the object frame.

Thickness

It defines the thickness in pixels to the 3D effect.

7.2.2.Tags Page Through the tags page we can associate the object to one or more variables that can be attributed from any object. In the Objects windows, we have access to the objects in the Organizer tree, whose properties are displayed in the Properties window. The objects selected can be accessed through a click in the ADD button. The most usual operation that is associated to a tag is made by selecting the referred tag, and adding it in the list. A similar procedure can be used to make association, instead of the aforesaid tags, its alarm level, or its scan time, or any other property that you wish.

 Elipse Software

7-6

Elipse Scada

S C R E E N

FIELD

O B J E C T S

DESCRIPTION

Objects

It shows the application tree. According to the selected object, its properties will be displayed in the Properies window.

Properties

It allows the selection of any property of the object selected in the tree.

Tags selected

It lists the Tags that are associated to the object.

Add

It adds the selected Tags in the selected tags list.

Remove

It removes the selected Tags of the list.

 Elipse Software

7-7

Elipse Scada

S C R E E N

O B J E C T S

7.2.3.Size and Pos Page Through this table you can set some position features, besides others generic specifications.

FIELD

DESCRIPTION

X

It defines the X coordinates for the left superior corner of the Object in pixels. It is used together with the Y attribute to define the Object position bsed on the Screen source (0,0).

Y

It defines the Y coordinates fo the left superior corner of the Object in pixels. It is used together with the X attribute to define

 Elipse Software

7-8

Elipse Scada

S C R E E N

O B J E C T S

the Object position based on the Screen source (0,0). Width

It determines the Object width, in pixels. It is used together with the width attribute to define the Object size.

Height

It determines the Object height, in pixels. It is used together with the width attributes to define the Object size.

Unmovable during Development

It determines the object can be moved during the set up(It blocks up the Object position change).

Visible on application startup

It determines the Object must be visible when the application starts.

Enabled (receive mouse and keyboard input)

It enables the key and mouse access to the Object (Only valid to the objects that allow inputs via mouse or keyboard). For instance: Slider, Browser).

Show tips during runtime

It enables the object to show a tip when the mouse is over it.

7.2.4.Object Inserting and Running In some objects, such as the animation button, besides the screens, bitmaps can be used. To its editing and generation, several programs, can be used, such as the CorelDraw®, Adobe® and Autocad®, among others. We will show here an example with the Paint:, a tool of the Windows 95/98. Taking as an example the following bitmap, shown below, there are two possible ways: a) Press the F8 key or the screens.

icon that carries on the monitoring of all the opened

b) Press the F10 key or the

icon that makes the total running of the application.

In order to return to the set up mode, just click the ESC key that is already specified as a pattern for leaving the running to create a new application. To change the key or to create a new method, it is necessary to change the script of the ESC key that already existis in the Application item, or to delete it and create a new one, which will be seen in the next chapter.

7.2.5.Bitmaps Utilization In some objects, such as the animation button, besides the screens, bitmaps acn be used. To its editing and generation, several programs can be used, such as the CorelDraw®, Adobe® and AutoCad®, among others. We will show here an example with the Paint, a tool of the Windows 95/98. taking as an example the following

 Elipse Software

7-9

Elipse Scada

S C R E E N

O B J E C T S

bitmap, shown below, which is the background of the monitoring main screen of our example of application. USING THE GRAPHICAL EDITION

Our purpose is to cut a slice of the image (the engine) so that we are able to create a bitmap type button over it in the application, and when click over that area can activate a digital output in the equipment and signalize with a different color in the screen, for instance. For such procedure, we need to take the following steeps.  Select

the area that you want to animate (in this case the engine) through the

rectangular selection of the tool thus selecting the area.

, and drag the cursor in diagonal in the screen,

 Through

the Edit – Copy to menu, specify the position LIB\HYDRAULIC\MOTORS7PUMPS and save it with the name MYMOTOR1.BMP, with 256 colors (informed below the file name).

 Now,

open the file that you have just saved MYMOTOR1.BMP; fulfill a part of the drawing with a different color, so that we can signalize any event by color (e.g. engine on).

 Elipse Software

7-10

Elipse Scada

S C R E E N

O B J E C T S

 Select

the filling icon , and choose an apprioriate color in the palette, in the inferior part of the screen. Now click over the part in the drawing that you wish to color.

 Through

the menu File – Save As, save the image with the name MYMOTOR2.BMP. If you wish to have any other status information, with other colors, repeat the procedure, saving the image with other names.

See the following useful tips about the Paint:  Use

the mouse left button to draw with the front color, and the right button to draw with the background color.

 To

draw perfectly horizontal, vertical or 45 degrees lines, press and keep hold the SHIFT key, while you drag the mouse pointer.

 The

SHIFT key, used together with full and empty rectangle, allows to build perfect suares. The same takes place with rounded border rectangules. You can obtain circles with the ellipses.

 With

the selection line, we can select any drawing area. Pressing the CTRL key, and clicking the mouse over the selected area. If you use CTRL instead of SHIFT, the figure displacement will create an infinite copy effect.

 To

choose the foreground color, click with the left button over the selected color in the color palette. The back ground color can be closen by clicking with the right button over the selected color.

 A double click over a color in the palette opens a dialog box that allows its edition.  The

movement of a cropping with the mouse left button pressed implies a transparent background, that means, all the cropping area with shade equal to th color of the selected background will be opaque.

 To undo some changes, click in Edit – Undo. It can be made up to 3 operations.

 Elipse Software

7-11

Elipse Scada

S C R E E N

O B J E C T S

7.2.6.Drills DOSAGE SCREEN SET UP INSERTING TRANSPARENT IMAGES

Task:. To place the raw material supply tanks on the superior leftcorner in the screen. Procedure: 

Choose the Bitmap object, and insert it as a rectangle in the referred place.



In the Bitmap Name fied, click in Search, choosing the FUNIL2.BMP file in the library directory LIB\HYDRAULIC\TANKS.



Click in Size Setting so that the object get set in the right size if the image. Now, select the option transparent, choosing the gray background.



After placing a tank, you can copy it three times. For that, just select and drag the object, pressing together the CTRL key, and dropping it in the desired place.

Task: To place the identification number of the raw materials tank in the superior left border in the screen (1,2,3 and 4). Procedure: 

Choose the Text object, inserting it in the screen.



In order to the object become superimposed to the tank drawing, just it in the tank area and bring it to the front through the menu Arrange / Bring it to Front.



Select the property Zones/Add, in which a new message zone will be inserted.



Key in the Message field the text “1”, selecting the Pattern Zone property.

Task: To place the raw material mix funnel. Procedure: Repeat the bitmap object insert procedure, choose the file FUNNIL.BMP.

 Elipse Software

7-12

Elipse Scada

S C R E E N

O B J E C T S

Task: To place the raw material supply tanks on the inferior left corner in the screen. Procedure: repeat the bitmap object insert procedure, choose the file SILO6.BMP. Task: To place the intermediate tank to transfer the mix to the cookers. Procedure: Repeat the bitmap object insert procedure, choose the file SILO5.BMP. Task: Next to the 98 and 74 engine, in the superior left side, insert the condensers, also as bitmap objects. Procedure: Repeat the procedure inserting the bitmap CONDENS.BMP. Task: To insert the material transference valve from the funnel to the tank to manually control via mouse. Procedure: 

Choose the button object, and insert it as rectangle in the referred place.



Access the object properties, choosing Functionally On/Off and the Bitmap type.



In the message field, choose the Normal status V_VERTICAL_OFF.BMP and to the Pressing state V_VERTICAL_ON.BMP. Both files are in LIB\HIDRAULIC\VALV2.

the file the file directory

Task: To insert a button to manually control the material agitation in the funnel. Procedure: 

Insert a button in the central left side of the screen, next to the funnel.



Select the Functionally On/Off and Type – Text Message (first type).



In the frame table select visible, text Agitation.



In the message table select to normal status the next Off, and Arial font 9 White, and for the Pressing the text status On, background color blue with the same font.



In the Tags table add the property enabled off the tag mix.

 Elipse Software

7-13

Elipse Scada

S C R E E N

O B J E C T S

INSERTING ANIMATION

Task: To insert animation representing the material agitation. Procedures: 

Choose the object type animation, and place it in any place of the screen.



In the Zone pages, add from the directory LIB\MOTION\MIX, the bitmaps from AGIT_1 to AGIT_5, and from this one back up to AGIT_1, executing a total of 9 different positions or zones.



Now, select all the zones (drag them with the mouse) and click in the button AutoRange, informing from 0 to 9 as limits. Now, each zones is associated with a tag value rate that will be associated.



Also select the Zone 1 as Patterm Zone, when you select it.

 Elipse Software

7-14

Elipse Scada

S C R E E N

O B J E C T S



In the Tags page, add the Tag mix.



In the general page select transparent, background color light green, and click in the button to set the object size to the image size.



Now, drag the animation until the funnel, and click in to toolbar Bring to Front, in order to place the animation over the bitmap.

Task: To insert visualization of the condenser valve through the animation. Procedures: 

Insert another animation object over each of the condensers.

 Elipse Software

7-15

Elipse Scada

S C R E E N

O B J E C T S



In the Zone pages, insert two bitmaps: VALVE_OFF, that must be selected as pattern Zone, and VALVE_ON, selected with minimum 1 and maximum 1.



In the general page, click in setting image. In the Tags page, associate each one of them to a bit of the tag DO. As soon as a digital output, that is related to an associated bit, is in its on status, the animation will show the activated valve.

INSERTING ANIMATED BUTTONS

Task: To create buttons over the engenes in order to manually command its operation. Procedures: 

Insert a button type object over each of the engines.



In the general page, choose Bitmap type and functionality On/Off.



In the message page choose the bitmap M& to normal, value 0, and M&PUMPON to pressed value 1, that can be found in LIB\HYDRAULIC\ MOTORS&PUMPS.



Click in the image set button (Fit to image).



In the tags page, associate each one of the three button to the first bits in the tag DI.

Task: To create control buttons for output valves. Procedures: 

Repeat.the previous procedure, but now choose in the message page the bitmap HORIZON_CONTR to normal and HORIZON_CONTROL_ON to pressed, that can be found in LIB\HYDRAULIC\MOTORS7PUMPS.



Click in the image, associate for each one of the two valves another bit of the tag DI.



In the tags page, associate for each one of the two valves another bit of the tag DI. Choose also in the message page the value 0 to normal and 1 to pressed.

POSSIBLE TO MODIFY TEXT FOR TWO DIGITAL TAGS

Task: To insert text object that from two bits of the tag DI, which indicate if the engine is on or off, the four possible status of the combination. Procedures: 

Below the third engine (nº- 74) insert a text object and disable its frame.

 Elipse Software

7-16

Elipse Scada

S C R E E N



O B J E C T S

In the Zone Table, add three messages zones.

Zone1 – Message: “Engine Off” – Pattern Zone, background color yellow, font color red. Zone2 – Message: “ 2 Engine On ”, minimum value 1 and maximum value 1, background color black, font color green; Zone3 -- Message: “ 1 Engine On ”, minimum value 2 and maximum value 2, background color black, font color red; Zone4 -- Message: “Engines On ”, minimum value 3 and maximum value 3, background color back and font color white. 

In the tags table, associate it to the tag expression Status.



As the first bit that composed the Status indicates that the engine 1 is on/off, and the second bit the same in relation to the engine 2, the text object will show four message types, according to the received value.

FieldBit1 0 0 0 0 1 1 1 1

FieldBit2 0 0 1 1 0 0 1 1

FieldBit3 0 1 0 1 0 1 0 1

Status 0 1 2 3 4 5 6 7

Text Engines Off Engines 3 On Engines 2 On Engines 2 and 3 On Engines 1 On Engines 1 and 3 On Engines 1 and 2 On Engines On

INSERINDO DISPLAYS

Task: To insert a display with timetable in the inferior right corner in the screen. Procedure: 

Right above the raw material supply silos, insert a display. To disable the frame and choose the font as MsSanSerif regular 10.



In the format page, select string, and in the prefix field key in “Product:”



In the tags page associate the Tag Code. The code value will be explained in another example further.

Task: To insert a display with timetable in the inferior right corner in the screen. Procedure:  Choose the font Arial Regular 9, and disable the frame.

 Elipse Software

7-17

Elipse Scada

S C R E E N

 

O B J E C T S

In the tags page, select the item Global Manager, and then the property currentTime. In the format page, select Date/Hour, and through the Format button select the desired format HH:MM:SS.

Task: To insert a temperature display beside the cookers and the raw material silo. Procedimento: 

Disable the frame.



Select font MsSanSerif regular 8, white color.



The display background color blue, numeric format, and size 3.



In the suffix field, key in “ ºC ”. In the tags page, associate for each one, one of the temperature tags. Remark: To key in the symbol º, just press the keys CTRL+SHIFT+ALT.

NAVIGATING THROUGH SCREENS

Task: To create buttons for navigation through screens. Procedure: 

To create a button that will be inserted in the inferior part of the dosage screen.



In the general table, choose functionality of momentary type, and associate it to the F1 key (that can be set in the Screen field), and in the option Go to screen to the Opening screen.



In the message table, choose the font Arial regular 9- Yellow, with the background color dark green. Key in the text “F1 - Open”, for the two messages (normal and pressed).



Trough the copy tools, copy the button, and insert the others by its side. The new buttons must have the same functionality, but leading to the other screens. Choose the texts as “F2 - Alarms”, “F3 - Trend”, “F4 - Recipes”, “F5 - Historical” and “F6 - Batch”.



The calling to the Historical (F5) will not be associated to any Screen, but it will be user later on the Historical Analysis function.

VISUALIZING ACTIVATED ALARMS

Task: To insert Alarm visualization object.

 Elipse Software

7-18

Elipse Scada

S C R E E N

O B J E C T S

Procedure: In the superior right corner of the dosage screen, insert an alarm object. Select type Resumed, with the Date, Hour, Alarm Type, Comments (Size 20) and value Options. INSERTING LEVEL IN THE TANKS

Task: to insert bar objects. Procedures: 

In any space of the screen, insert a bar graphic.



Select values rate from 0 to 100; orientation downwards to upwards, deselected bipolar, spacing 0, gray background.



In the ruler page, disable it; the same is valid for the frame.



Format its size do that it has the same height of the cooker tank, and narrow enough to fit between the red lines and the right border.



In the Tags page associate it to the Tag level01.



Put it now in the position over the cooker, and choose the option Bring to Front.



Repeat the procedure with the other cooker, as tag level02 and with the raw material storage silo, as tag level03.

OPENING SCREEN SET UP

Task: To insert a title to the Screen. Procedure: 

In the opening screen, insert a text object, setting a message Zone. Select it as pattern with background color wine, and font as Bold Arial 20, color Yellow.



Key in the text “Example application – Candy Plant” .

Task: To insert a support Bar to tools. Procedures: 

To insert another text in such a way it occupies the whole screen inferior extension.



Create a message zone, selected as Pattern.

 Elipse Software

7-19

Elipse Scada

S C R E E N

O B J E C T S



Clean the text content to the message (no text).



Deselect the title and the border in the frame page. In the 3D Effect option, select inside, size 4.

Task: To insert a Button for Screen Exchange. Procedures: 

Insert button right above the bar.



Choose the momentary type, and in the item CGo To Screen, associate it to the Dosage Screen.



In the message table, place the alignment in the center and key in the text “Enter in the System” to the Normal and Pressed option.

INSERTING TREND GRAPHIC

Task: To insert a trend grahic in the trend Screen. Procedures: 

Insert the trend graphic in the trend Screen.



In the general page, graphic type section, select Time x Data, new data in the right margin, 10 second range of data.



In the advanced page select Real-Time. In the graphic page, key in for the Y axle the limits from 0 (inferior) to 250 (superior).



To associate Tags to the Object, select the pens table that will display the following tools:

BOTÃO

NOME

AÇÃO

Real Time Pen

It inserts a pen to a tag visualization or property in real-time. The use of this type of pen is enabled to the trend graphics in Real Time type.

Historical Pen

It inserts a pen to the graphical visualization in the historical field. The use of this type of pen is enabled to the objects that use files, as historical trend, historical Analisis and graphic report.

Mark Delete Pen

 Elipse Software

It inserts a mark on the graphic that can be a vertical, horizontal or point (cross) line. It deletes the selected pen.

7-20

Elipse Scada

S C R E E N

O B J E C T S

Line

It defines the selected pen to a line graphic.

Area

It defines the selected pen to an area grapghic.

Bar

It defines the selected pen to a bar graphic. In this case, the user can select bar as medium, maximum, minimum or just sample.

Up

It brings the selected pen to a position above in the pen list.

Down

It brings the selected pen to a position below in the pen list. The defined order will be obeyed in the graphic draw, so the pens that are displayed lastly will be in the back, and the first ones in front of it.

When a new pen or mark is inserted, a new line is added to the oen line, as follows:

FIELD

DESCRIPTION

Label / Icone

It shows the type of the defined pen – Real time, Historical or Mark. A double click over the icon opens a window for a tag or to the pen property association.

Label / Enabled

It defines the enabled pen. The disabled pens ca be enabled, and vice versa, in the runing.

Label / Nome

It defines a name to the pen, not necessarily the associated tag or property name. To keyboarding, just click over the text that an edition field will be opened.

Y axis

It is used to associate a tag, field or attribute to the Y axis of a pen. Clicking over the field you obtain a list of available fields, in case the pen is historical, or a window similar to the App Browser

 Elipse Software

7-21

Elipse Scada

S C R E E N

O B J E C T S

for linking any item to a pen, in case of real time or mark. X axis

It is us used to associate a tag, field or attribute to the X axis of a pen. Clicking over the field you obtain a list of available fields, in case the pen is historical, or a window similar to the App Browser for linking any item to a pen, in case of real time or mark.

Type

It indicates the graphical type to the pen; line, area or bar.

Click in the icon Real Time pen, and add a pen to the list. Double click in the icon in the list, where the following pn property window is displayed:

Select the Tags table, and next the tag Temp01. Repeat the procedure of inserting pens to the level and temperature tags.

 Elipse Software

7-22

Elipse Scada

S C R E E N

O B J E C T S

INSERTING HISTORICAL ALARMS OBJECT

Task: To insert a historical alarm in the Alarms Screen. Procedure: Insert the Alarm object in the screen reserved to it. Select type Historical, with the Date, Hour, Alarm Type , Comments (20) and value options. INSERT ALARM LEVELS IN THE TREND

Task: To insert in the trend object the alarm levels through the use of marks. Procedure: 

In the trend screen, select the trend properties by double clicking on it.



Go to the pen page and add a mark through the pen icon mark. The mark are pens that can be inserted in the trend, so that it can represent a straight line (horizontal or vertival) or a point (cross).



Once the mark is selected, there are two ways of setting it: through a double click in the mark icon or through a click in the Axle Y and Axle X field.



In the general page (accessed through a double click in the icon) select it as a horizontal line, and format it as stripped line.



In the tags page associate it to the high alarm level of the tag temp01, temp01.High.Limit. Repeat the procedure to the low alarm temp01.Low.Limit, creating a new mark.

 Elipse Software

7-23

Elipse Scada

S C R E E N

O B J E C T S

INSERTING SLIDER FOR ALARM LEVEL CHANGES

Task: To insert slider in the trend screen to cgange the alarms level. Procedure: Create in the two sliders trend screen, and associate the properties temp01.High.Limit and temp01.Low.Limit, so that they can be modified during the running. The same procedure can be made with setpoints. INSERTING BUTTONS TO ENABLE/DISABLE THE VISUALIZATION OF THE PENS IN THE TRENDS.

Task: Insert buttons in the trend screen to display or not a trend pen. Procedure: Create in the trend screen a button of check box type to each pen linked to a trend, and associate them to properties Tendencia1.Plotagem.Pen1.Penvisible, so that when

 Elipse Software

7-24

Elipse Scada

S C R E E N

O B J E C T S

you click on the button it will enable or disable the visualization of the chosen pen. For a better result, select the button text color according to the color that it represents, and the background color equal to the screen background.

 Elipse Software

7-25

Elipse Scada

S C R I P T S

8

Capítulo

8.

Scripts

T

he scripts are programming language module, in which code lines can be created that allow a higher flexibility to associate actions to specific events. Each item of the Elipse Scada application has an event list previously associated. Thus, the user will be able to create programs that will be executed in the incident of a specific event..

8.1. General Considerations In any programming language it is necessary to create methods in order to specify and organize the desired instruction running. The Elipse Scada script structure itself is already organized in this manner, once they are oriented to events. The events are incidents related to an object that can be handled in order to execute an action. The events can be physical, as for instance, a keyboard action. In this case, the relavant information would be pressing the key (among others), or if the event comes from the mouse, the relevant information would be the cursor position and the button status. The events can be internal, with a variable value change, but can have a physical association, such as a chamber temperature change from 10 to 11 degrees. The event conditions that may occur with the objects are already handled by the Elipse Scada, and areavailable to the user to connect the program (scripts) to them. Here there is an event list already available to the script running, listing the generating type of action or prevailing in the event generation, with its name and a list of objects that support the events. ACTION Keyboard – Press or release any key or keys

 Elipse Software

NAME

USED OBJECTS

OnKeyPress, OnKeyRelease

Application (To independent running of the screen being

8-1

Elipse Windows

S C R I P T S

combination

Keyboard / Time – While any key or combination is pressed

visualized). Screen (To running only when the screen with the scripts is open). WhileKeyPressed

Application (To independent running of the screen being visualized) Screen (to running only when the screen with the scripts is open)

Keyboard / Mouse – To click or move the focus (edition) to an object or screen

OnKillFocus, OnSetFocus

All the screen objects

Mouse (general events with buttons)

OnRButtonUp

All the screen objects.

OnRButtonDown OnRButtonDblClk OnLButtonUp OnLButtonDown OnLButtonDblClk OnMouseMove

Mouse

OnPress

Button Screen object

OnRelease Mouse / Time

WhilePressed

Button Screen object

Time

WhileRunning

Application (To independent running of the screen being visualized) Screen (To running only when the screen with the scripts is open).

Any Alarm type incident

OnAlarm

Alarms

Disconeccting the Supervision Network (not with the CLP)

OnDisconnect

Remote Application

Events with Tags

OnAck

Tags

OnAlarmHigh OnAlarmHiHi OnAlarmLow OnAlarmLoLo OnAlarmReturn OnValueChanged OnRead

 Elipse Software

8-2

Elipse Windows

S C R I P T S

 The

language used in the script modules are defined by the Elipse Basic, and is very similar to the C language, but with visual resource such as the Visual basic. Different from the programs in the mentioned languages, some considerations can be made :

 It

is not necessary vaiable or function declaration in the beginning of the script. The variables that can be tags/ objects/ attributes must be previously created, imported from other application, or yet it can be used as patterms that already part of any application, at the moment they are created.

 The

data type that is attributed to a tag is free, and the supported value can range from a whole number of the 8 bits to a real type of the 64 bits, or yet, a string (text). When repassed to the communication driver or received from it, the conversions to the supported types to different equipment are made . In the properties case, an icon supported type data, as listed below: Numeric attribute (whole number) Numeric attribute (real number) String attribute (text) Boleano attribute (0 or 1).

The variable (tags/attributes( and constants are the basic objects that can be manipulated in the script. The operators specify what will be carried on with therm; on the other hand, the expressions match variables and constants to procedure new values. To make the scripts edition or tags expression easier, the command buttons in the Organizer toolbar, the App Browser and the X-Reference (Crossed Reference) can be used.

8.2. App Browser & X-Reference The App Browser allows you to easily navigate in the application. When you select an object in the tree in the window left side, its attributes and functions are displayed in the right side. You can use the App Browser as reference during the script edition. A very useful feature is to select object/attribute/function that you seek to copy right to the Script in (Copy to Script ->). The App Browser window is displayed as follows:

 Elipse Software

8-3

Elipse Windows

S C R I P T S

FIELD

DESCRIPTION

Selected

It shows the selected object/attribute/function name, in the same way it will be copied to the Script.

Objects

It lists the application in hierarchy as it is displayed in the Organizer.

Info

It shows a brief description of the selected attribute/function.

Properties

It lists all the selected object attributes and functions in the Object window.

Show

It allows to filter the listed information in the property window. It selects the Attributes and/or Functions that will be displayed to the selected object.

Copy to Script

It copies the displayed text in the Selected field to the Script in the cursor current position.

Note

You can also use the App Browser in the edition of Tag expressions. To copy the selected object / property / function to a Script or Expression just double click over it. The X-Reference tool has the same structure of the App Browser, however, when you select an object in the tree in the window left side, its respective references are listed in the right side. Double click over a reference to go the referred object

 Elipse Software

8-4

Elipse Windows

S C R I P T S

8.3. Operators & Constants Here is a list of the constants (and its notations), and the operators that be used in the scripts. CONSTANTS

EXAMPLE

Integer (32 bits, dec)

1234, 1234d, -993

Integer (32 bits, bin)

11001110b (does not allow signal)

Integer (32 bits, octal)

7733o (does not allow signal)

Integer (32 bits, hex)

0A100h, 3B8h (does not allow signal) (if the first digits is A-F, place a zero before)

Real numbers (64 bits)

133.443, 344.939 (does not have scientific notation)

Strings

"Temperature", "pressure"

OPERATORS

EXAMPLE

+

Addition

tag001 + 34

+

Strings connection

slider1.Frame.title + " - PLC1" (connects two strings)

-

Diminution

tag001 - screen1.x

*

Multiplication

screen1.width * 3.141592

/

Division

tag001 / tag002

%

Remainder

tag001 % tag002 (rremainder of the tag001 / tag002)

**

Exponentation

tag001 ** 2 (tag001 square)

LOGICAL OPERATORS

EXAMPLE

&

and bit-a-bit

flags & 0F000h (isole the os bits 12-16)

|

or bit-a-bit

flags | 0F000h (arrow the bits 12-16 para 1)

^

xor bit-a-bit

flags ^ 0F000h

~

not bit-a-bit

~ flags (it denies all the flags bits)

<<

shift left

flags<<2 (it transfers the flags valu two bit to the left)

>>

shift right

flags>>2 (it transfers the flags value two bit to the right)

AND

and lógico

tagOnOff AND (tag001 > 200)

OR

or lógico

tagOnOff OR (tag001 > 200)

XOR

xor lógico

tagOnOff XOR (tag001 > 200)

NOT

not lógico

NOT tagOnOff

 Elipse Software

8-5

Elipse Windows

S C R I P T S

ATTRIBUTING OPERATORS

EXAMPLE It returns 1 if the realtion is true, 0, if it is false.

==

Comparsiob

tag001 == 20

>

Higher than

tag001 > 20

<

Minor than

tag001 < 20

>=

Higher or equal than

tag001 >= 20

<=

Minor or equal than

tag001 <= 20

<>

Different

tag001 <> 20

ATTRIBUTING OPERATORS

EXAMPLE

tag001 = 20 tag001 += 20

(tag001 = tag001 + 20)

tag001 -= 20

(tag001 = tag001 - 20)

tag001 *= 20

(tag001 = tag001 * 20)

tag001 /= 20

(tag001 = tag001 / 20)

tag001 %= 20

(tag001 = tag001 % 20)

tag001 &= 20

(tag001 = tag001 & 20)

tag001 |= 20

(tag001 = tag001 | 20)

tag001 ^= 20

(tag001 = tag001 ^ 20)

tag001 **= 20

(tag001 = tag001 ** 20)

tag001 <<= 20

(tag001 = tag001 << 20)

tag001 >>= 20

(tag001 = tag001 >> 20)

OPERATORS’ PRIORITY (RUNNING ORDER)

The table below lists the priority and association rules to all the operators. Those listed in the same line have the same priority. + - ~ NOT (unary operator) ** */% >> << > >= < <= == <> & ^ |

 Elipse Software

8-6

Elipse Windows

S C R I P T S

AND XOR OR = += -= *= /= %= &= |= ^= **= <<= >>=

Note

When attributing a value directly to a PLC tag or Block Element that has the property automatic writing enabled, the command is sent directly to the communication driver that in its turn repast it to the associated equipment. Such action does not take place only when the avlue attributed is equal to the content that was is the tag. In case you want to force a writing whatever, the tag Write() function must be executed in any script.

8.4. Flow Control In order to control the order in which the information is processed, a flux control information is used. The Elipse basic language uses the following set of controls

8.4.1.If…ElseIf…Else…EndIf Command It is used to make decisions. Formally, its syntax is: If condition1 [instruction block 1] ElseIf condição2 [instruction block 2] ] ... Else [instruction block n] ] EndIf

 Elipse Software

8-7

Elipse Windows

S C R I P T S

8.4.2.For…Next Command It repeats an instruction block a certain number of times. For counter = beginning To end [instruction block] Next

8.4.3.While…Wend Command It runs an instruction block while a certain condition is real. While condition [instruction block ] Wend

8.4.4.Repeat…Until Command Its runs an instruction block until a certain condition is confirmed as real Repeat [instruction block] Until condition For further information about the syntax and the permission for using control ties, consult the user’s manual. Our goal here is to supply examples and comments about the performance furing its use.

8.5. Special Functions The Elipse Scada Special Functios assist the Script edition, allowing more complex task running and a better set up of your system. The App Browser tool shows the available functions to each object during the Scripts editions. The following objects have Special Functions that can be visualized selecting the desired object in the application tree in the App Browser:

 Elipse Software

8-8

Elipse Windows

S C R I P T S

             

Global Manager Application Tags Screen Screen Objects Alarms Recipes Historics Reports Query Plotting Drivers Databases Remotes Applications

The Global Manager item has generic functions that are not specified to any type of object. In this group there ar the date and watch functions, strings manipulation and numeric conversion, files, multimedia, among other functions. The screen object functions can be accessed first through the screen selection that contain it, soon after the object. The plotting function can be found in the trend graphic objects, historical Analysis and graphic report. And the Query functions are used by the objects, histprical Analysis and graphic report. And the Query functions are used by the objects that make access to tiedisk data, such as the historical trend, the browser screen object, and the historical and reports.

8.6. Tips and Optimization SCRIPTS EDITION

To build a scripts, besides using the App Browser, you can freely edit the lines in any text editor of the Windows. Thus, the pattern operations such as Copy (CTRL+C), Paste (CTRL+V), Cut (CTRL+X) and Undo (CTRL+Z) can be used. Besides that, the Find and Replace tools, present in any script, can be used.

 Elipse Software

8-9

Elipse Windows

S C R I P T S

SCRIPTS COMPILATION

Always before running an application we must check if it does not have any errors. This is a very important task, once the scripts that contain syntax errors (that means, poperty names or wrong objects or not existing ones) will not run. Using the Compile Scripts, Build Scripts, Rebuild All Scripts buttons that are in the inferior part of the Organizer, we can make this verification in a faster manner. Use the Compile Scripts button to check script errors that are being edited in the moment. This button will not verifies only the scripts that were not yet compiled. The Rebuild All Scripts button verifies all the application scripts without considering if the they were changed or not. The time difference that this operating takes to be executed regarding the Build Scripts is slightly higher to the large application, but is very useful to avoid running errors. When using these two last options, a window click in the red line, the scripts with errors are automatically edited. SCRIPTS ERROR

If during the script running an error of the following type takes place: a) The script contain compilation errors and you run it whatever; b) You are attributing parameters of incompatible types (e.g. forcing a string to a digital attribute). c) There was a division by zero – the Script will be aborted. To avoid this kind of problem, always compile your files, and verify the change of this problems happing again. SEQUENCING SCRIPTS

As the scripts are priented to events, there is a chance of running the scripts inside others, due to the used operation sequencing. As the following example: Script OnAlarmHigh of the variable tag001 tag002 = 1 tag003=0

Script OnValueChanged of the variable tag002

 Elipse Software

8-10

Elipse Windows

S C R I P T S

Screen1.Activate() In this case, at the moment that the tag001 is in the alarm condition (that was previouly defined by the user) the first script attributes a value 1 to the tag002. When performing such task, the tag001 script is interrupted, so it can verify in the value attribution cause to the tag002. When this occurs, in general it id verified if the tag002 has any script associatd (so that will be necessary to run them too, since occurred an event to the tag002) or if there is any screen object connected to it. Thus, the script OnValueChanged of the tag002 is run, and only then is returned to the origin point, from where it stopped in the script of the tga001. COMMENTS

It can be insert comments in the scripts with two simples bars placed in the left side from the point where you want to meke a comment. Examples: Tag001 = 25 // this is a comment INTERN VARIABLE

You can create internally variable in the script. After the running, it will be destroyed. The used command is DIM. Example: DIM FLAG FOR FLAG=0 To 10 Tag001=FLAG NEXT SCRIPT RETURN

If you wantwant to leave a script before its end, use the RETURN command. Example: IF Tag001 > 10 RETURN

 Elipse Software

8-11

Elipse Windows

S C R I P T S

ENDIF Tag002=10 In the example above, if the Tag001 is higher then 10 the script is abandoned. On the contrary, its running normally continues. RESTRICTION THE USE OF INFINITE TIES

If the control ties such as While and Repeat are used to create inifite ties, they can interrupt the running of other software tasks. As the following example: WHILE Tag001 Tag002+=Tag003 WEND In the script above, the available tag001 is evaluated; if real, that is, different from zero, it start the running of the first instruction that increases the tag002 of the value of the tag003. After that, the tag001 is evaluated again, and the running continues with the possibility of receiving the answer of the communication driver with the tag001 value. In order to eliminate the problem, one of the solution is to force the reading of the tag001 in the end of each loop, as in the example: WHILE Tag001 Tag002+=Tag003 Tag001.Read() WEND LIMITATION IN THE RUNNING SCRIPTS BY TIME

The scripts WhileRunning generally spend more processing time them the other scripts. Using the ScriptWindow() function that it is also a tool you can verify while running how long each script takes to be executed. Thus, you must guarantee that a Script WhileRunningFinnish. Its execution before calling it again, in order to avaiod a running request accumulation. TOO LONG SCRIPTS

 Elipse Software

8-12

Elipse Windows

S C R I P T S

It aviods the creation of too long scripts. When you separate them in small parts the time spent consireably decreases; and as said bove, use the debugging function to optimize the scripts. A deparation between scripts sughestion could be as follows: Create a RAM type, wich can be called, for instabce, functionA. At some point, in the script to be separated, make an attribution to the functionA. Script WhileRunning – Aplication ……. ……. FunctionA=1 In FunctionA create a um script OnValueChanged, and copy the part of the first script that will be executed on it. As the last instruction, return the tag FunctionA to its initial value. Script OnValueChanged - FunctionA ……. ……. FunctionA=0 BUTTONS SCRIPTS

To the button scripts, choose the OnRelease instead of the OnPress, so that the user notices the action easier.

8.7. Drill SCREEN EXHANGE VIA SCRIPT

Task: In the calling button of the Alarm screen, F2, replace the automatic call for a script. Procedure: In the general page of the mentioned button, in the ListBox Go To Screen, choose none. In the scripts page, choose OnRealese. Through the AppBrowser,

 Elipse Software

8-13

Elipse Windows

S C R I P T S

serach the Alarm Screen, choosing its functions on the inferior right corner. Choose the function activate(). Copy it to the script, and next compile it. The final result must be: Alarmes.Activate() Run the application, testing its functionality. SCREEN EXCHANGE IN SPECIFIC ALARM INCIDENT

In one of the level or temperature variable, create a script OnAlarmHigh, running the screen exchange function to alarm screen, through the execution of the Activate() function of it. The result will be the same of the previous script, but it is being called by two different events. OBJECT COLOR EXCHANGE IN ALARM INCIDENT

In the tag temp01 make through a script OnAlarmHigh change the display color in the screen, through the property backgroundColor change, and with the help of the RGB(r,g,b) function present in the Global Manager. Example: Script OnAlarmHigh, temp01: Dosagem.Display01.backgroundColor = RGB(255,0,0) // red arrow to the background color Script OnAlarmReturn, temp01: Dosagem.Display01.backgroundColor = RGB(0,0,255) // return to blue SCREEN EXCHANGE IN ALARM WITH PRIORITY

To do the same exchange to the Alarms screen, using the OnAlarm of the alarm item in the Organizer, so that the alarm screen be called in any alarm incident with priority 2 (only equal to 2). For that, select the alarm item in the Organizer, choosing the Scripts table. Create a new script, choosing OnAlarm. Example: Script OnAlarm: IF lastAlarmPri == 2 Alarmes.Activate() ENDIF The OnMouseMove script is run when the mouse

 Elipse Software

8-14

Elipse Windows

S C R I P T S

ICONS SENSITIVE TO THE MOUSE

Task: To create an Icon that changes your draw, when you passes the move over it, in the opening screen.. Procedure: Insert a bitmap object over the created toolbar, bringing it to front (over the bar). Choose as bitmap the file LIB\UNTIL\LOGIN2.BMP, of transparent type, and background color write. Create a script to reiceve the mouse moves over it; Script OnMouseMove: Abertura.Bitmap.SetMouseCapture() IF Abertura.Bitmap.IsMouseInside() Abertura.Bitmap.fileName="c:\elipse32\lib\util\login.bmp" ELSE Abertura.Bitmap.fileName="c:\elipse32\lib\util\login2.bmp" ReleaseMouseCapture() ENDIF The OnMouseMove script is run when the mouse is moved inside or outside the object area. On the other hand, the SetMouseCapture function causes all the Windows messages, generated by the mouse, to be sent to the object in point. Thus you can test if the pointer is inside or outside the area, resulting in the changig of draws. Run the application, and when you pass the mouse over the bitmap, you will see that the drw chages from black and white to colored. CREATING MANUAL/AUTOMATIC PROCEDURES

Task: To create a button in the Dosage screen that disable the engine and valves control button. Procedure: Insert a button, aligned in the right side of the button area (inferior part of the screen). Choose the on-off type, and in the Message page key in “Auto” for Normal and “Manual” for pressed. There are two procedures that can be executed in this same button. a) Force to 0 or 1 a bit or word in the equipment, so that it signs the operation in manual or automatic. b) Disable or Enable the objects that send values to the equipment.

 Elipse Software

8-15

Elipse Windows

S C R I P T S

To run the second task, it is necessary to create two scripts: PnPress and OnRelease. The instructions of the first are to enable the objects, when you choose a manual operation, and of the script second are to disable it, according to the script. OnPress Dosagem.button1.enabled=1 Dosagem.button2.enabled=1 …… Notice that the object names can change from one application to the other. Thus, where you read FirstButton_Name, etc…, it is referred to the button that you wish to be enabled or disabled. The same is valid for the other scripts script: OnRelease Dosagem.button1.enabled=0 Dosagem.button2.enabled=0 …… CREATING SOUND SIGNAL WHEN ENTERING IN ALARM

Task: To use the Sound Signal function. Procedure: Create a script in the item Alarms in the Organizer, OnAlarm. On it, insert the StartSound command, present in the Global Manager. This command start to playe, in regular range, a sound index that that can be set in its Control panel. CREATING BUTTONS FOR STOPPING THE SOUND

Task: To use the Sound Signal function. Procedure: Insert the button over the Alarms object, and bring it to front. Choose the momentary and bitmap type, with the files Calaron.bmp e Calaroff.bmp, located in the directory LIB\BUTTON. Create a script OnRelease for it, and execute the StopSound() function, present in the Global Manger.

 Elipse Software

8-16

Elipse Windows

H I S T O R I C A L

9

Capítulo

9.

T

Historical he Historical are objects responsible for the storage of tags value in disk. The storage can be made per time or event that must be specified to the data recording.

9.1. Historical Types The Historical can be created in two different ways: Continuouns, which store the data continually during the application running (e.g. recording of a cold chamber temperature every ficteen minutes) or in Batch, in case of lots (e.g. recording of separate oven temperatures according to production lot code and operator name). In the Batch, the data is stored with one or more references, associated to a header of the Historical in which a Batch can be found. In order to be started (StartBatchProcess()) or completed (FinishBathProcess()), the batch processes need special commands, via some script. To create or edit a Historical, we need ro select the item Historical in the Organizer. When a new one is created, it will be displayed below this item in the application tree.Selecting a specific Historical, its properties will be displayed in the right side of the tree.

 Elipse Software

9-1

Elipse Windows

H I S T O R I C A L

In the set up pages we have: FIELD

DESCRIPTION

Name

It defines the Historical name that will be used in the Organizer tree and in the Scripts (it can be changed in the running).

Description

It is a brief description about Historical.

Analysis

It allows the visualization of the Historical data in graphic form. You can call Historical Analysis during the running through the Analysis() function of the Historical.

Update File

It updates the Historical File Structure when some change takes place in the Historical set up.

SPC

It calls the Processes Statistic Control (CEP) in order to proceed a statistic Analysis of the Historical Data.

Filename

It defines the file name to the current Historical.

Write time

It defines the frequency in which the data will be written in the Historical file.

Max Records

It defines a maximum number of registries to the Historical file. The Historical file is rotative, that means, when the data exceed the file size the registries will be displayed.

 Elipse Software

9-2

Elipse Windows

H I S T O R I C A L

Enable Historic at application startup

It enables the Historical file writing from the start of the application running, according to the defined rate scan. Keeo this option disabled if you want to control (using Scripts) the creating of Historical data manually.

Batch process

It defines the Historical type as being Batch. When this option is enabled, a Header file (HDR extension) is created with the same name of the Historical file. The Header file keeps the information about each batch.

Network support

It enables the network support to the Historical, that is, it allows that the Historical be accessed (only for reading) by other Elipse applications in the Network, through a Browser or Report of the Historical Analysis type. This option also makes that each change in the Historical be immediately recorded, not allowing the operational System to perform a task “appointment” for later performance according to its running priorities.

After the historical type set up, we must add the tags in the Historical that will be stored, which is made in the tags table. To each added variable we must establich the field format, which can be: Type

Numerical Capacity

Size ( Bytes )

Char

-128 a 127

1

byte

0 a 255

1

short

-32768 a 32767

2

word

0 a 65535

2

long

-2147483648 a 2147483647

4

dword

0 a 4294967296

4

Float

3.4E +/- 38 (7 digits)

4

Double

1.7E +/- 308 (15 digits)

8

Datehour

1/1/1970 a 05/02/2036

8

-

Field size.

String

 Elipse Software

9-3

Elipse Windows

H I S T O R I C A L

When you choose the historical of Batch type, it will be created another itme in the Historical object, called Header that can be acessed via Organizer. Tags must be inserted in the header, and their values will be used to identify each one of the batch processes. Following the given example about the oven temoerature storage, where we would like to have a reference via lot code and operator name. So, there must be in your application two tags, code and operator, that will be inserted associated to the header item, and will have their value recorded in the batch beginning and, so you can identify it. The header data are registered in a file with HDR extension, with the same name of the historical data file name (e.g. If you informed HIST1.DAT as historical data file name, it will be created HIST1.HDR). There must exist in the header at least one tag, set as string field (text), so that the batch search can be made.

9.2. Historical Analysis Automatically, when a new historical is created, a historical Analysis object is obtained as a subitem. This object can be created separately in the report item, in order to perform different Analysis in the historical file that is being created, or even in other files that were not created by this application. In the Analysis, the objects plotter (that is the graphic formation) and Query, that deals with the data filter that will be applied in file to be visualized, are included.

 Elipse Software

9-4

Elipse Windows

H I S T O R I C A L

FIELD

DESCRIPTION

Name

It defines the Historical Analisys name that will be used in the Organizer tree and in the Scripts.

Title

It defines the title to be displayed in the Historical Analysis window.

Analysis

It allows the visualization of the Historical Analysis data in graphic form. You can call Historical Analysis during the running through the Analysis() function of the Historical.

SPC

It calls the processes Statistic Control Cep (CEP) in order to proceed in the Historical Analisys of the Historical data. It defines the Property pages to be displayed in the Historical Analysis window:  All pages  Only the Analysis page (Graphic)  Selected pages (only the selected pages) It defines the dialog type of the Historical Analysis:  Modal (it does not allow to access any other window before being closed)  Modeless(does not need to be closed to access other screens) It defines the Style of the Historical Analysis window. Scalable font, Minimize Button, Maximize Button.

Show Property pages

Dialog Type

Styles

 Elipse Software

9-5

Elipse Windows

H I S T O R I C A L

9.2.1.Analysis Setting We can the Analisys way of work through the Graph, Pens, Pen Colors, Settings, Wuery and Setup Printer pages that are usual in the objects that consult the databases. We make here a brief explanation about two pages: Setting and Query. SETTING PAGE

FIELD

DESCRIPTION

Source Filename

It defines the source file name to the Analysis (DAT extension). In case of being used for other objects (Reports, Browser) it can be specified in the Header (HDR extension).

Browser

It allows to find the source file to be used.

All Batches

It selects all the batches to be printed. This option is available only if the source file (Source Filename) is a Historical file with an enabled batch process.

Last Batch

It selects the last batch to be printed. This option is available only if the source file (Source Filename) is a Historical file an enables batch process.

 Elipse Software

9-6

Elipse Windows

H I S T O R I C A L

Specific Batch

It select a specific bacth to be printed, as specified in the Field and Criteria. This option is available only if the source file (Source Filename) is a Historical file with an enabled batch process.

Field

It lists the field available to a specific batch selection. Only string type fields will be listed.

Criteria

It defines the value to be searched when a specific batch is selected.

QUERY PAGE

It allows to define a time range to select the file data to be visualized.

FIELD

DESCRIPTION

No query date

A filter will not used, that means, it selects all data. Select this option if the historical must visualize all the file data.

Time range

It selects the data within a specified time range. It must be provided the initial and final search date.

Newest data

It selects only the new data. Use this option when the historical must show the last acquisition in a specified period. The options shown here can be changed in running through the query properties, available in the Organizer.

Initial date

It determines the time range initial day.

 Elipse Software

9-7

Elipse Windows

H I S T O R I C A L

Final date

It determines the time range final hour.

Initial time

It determines the time range initial hour.

Final time

It determines the time range final hour.

Last

It defines the unity number used to select the most recent data.

Last/Units

It defines the used unity to select the most recent data.

There are other objects that can also work with the data files created by the historical that are the Alarm screen objects, Browser and Historical trend, and the text Report, graphic and Historical Analysis.

Drill: Task: To create a historical object for continuous recording. Procedure: From the Organizer, create a new historical, with the name Hist1. Specify the file name as CONTINUO.DAT, writing time of 1000 ms, register maximum number: 1000; enable the recording by scan, and in the query page, with no data query. In the tags table, insert the level and temperature tag. Task: To create a button in the screen, calling the function Historical Analysis.. Procedure: In the F5 button, Analysis in the Dosage Screen, choose the momentary type. Create a script OnRelease to the button, inserting the function Hist1.Analysis().

9.3. Tips and Optimization DATA FILE SIZE

The historical file size that will be created can be calculated as follow: Data File Size= Header size + Register size * in a Register Header Size = 24 + in Fields * 40 Register Size = 2 + sum of Field Size. The 2 bytes that are added correspond to the CRC16 type examine, present in each registry.

 Elipse Software

9-8

Elipse Windows

H I S T O R I C A L

MAKING RECORDING PER EVENTS

To perform the event data recording, you must disable the historical and start the application (option in the general page). So, the data will only be registered in a clear recording command, that must be done through a script. There are two different ways in scripts that can perform such operation, as listed below, supposing that Hist1 is the name of our historical example. Hist1.Open() Hist1.WriteRecord() Hist1.Close() Ou Hist1.enabled=1 Hist1.WriteRecord() Hist1.enabled=0 Basically, both perform the same operation, but the second one enables it to recording by time, while the enabled property is in 1. The writing command, WriteRecord(), obtains an updated value of the tags that are associated to the historical, creating another data line. TIME INFORMATION IN THE HISTORICAL

Each data registry that recorded has, as a patterm, a time information, that is the DataTime field, with 8 databytes (64 bits). Usually, when a data is recorded, the computer watch is consulted, and the obtained information is insert in that data line with an accuracy of 1 millisecond. You can stipulate, however, another date and hoursource. When clicking in the historical object in the Organizer, all the data field associated to it will be displayed below. The first one will always be the DataTime field. Clicking over this field, there will be the possibility to associate a tag or property, through the tag table. In this case, it can be associated to the property TimeStamp of any tag, in case the equipment with which there is information being exchanged, give support to the information sending from its local watch. So the data value recorded in the historical will not be the computer’s, but the other machine’s or equipment’s. HISTORICAL TREND

The screen object trend graphic, when previously set as historical trend, can visualize the historical data as well as the analisis. The objects associated to the trend, in this case, are not the tags themselves, but the historical fields that that are created when tgas are associated to the Historical.

 Elipse Software

9-9

Elipse Windows

H I S T O R I C A L

To choose data about the file to be associated to the trend, as well as the query manner, a Query page that can be acessed in the trend Advanced page or via Organizer – Screen – trend Object is created. The criteria settings are the same already described. The pens association to the field is done by clicking over the field Axle Y and/or Axle X in the Pens table, acessed by the Trend properties. Clicking over this field, alist with the historical field names will be displayed. To make the trend serach the data in the disk or to update its data, it is necessary, via some script, to run its function UpdateQuery(). If you want that to happen in the fix range, just insert this command in the script WhileRunning in the screen, informing its running time in milliseconds in the script. DATA COLLECTION MANNER OF THE TREND GRAPHIC

Through the Advanced page of the trend object we can determine the data collection manner. The Real Time first option does that the trend only collects data when the screen is open. When calling it again, it will be dispalyed clean. The second option causes the communication with its tag to take place independently of the screen; so, when you call it, the data will be already loaded. The thrird option, historical trend, allows to recover the data after the computer is off, or even to spread the same data recorded in disk the historical object. For that, the objects associated to the trend are not the tags themselves, but the historical field, as it has been already mentioned. INSERTING MARKS IN THE TREND GRAPHIC

Through the Pens page of the Trend object, we can associate marks ti the graphic, that can be vertical, horizontal or point (marks) lines. Each mark can be associated to a tag or property, or even be modified via script. BROWSER

The browser screen object has the same characteristics of the historical trend, but it shows the data of the text mode, not graphically. The browser does not update its data automatically, so you must run the function UpdateQuery() through some script when you want the update to take place. This object also to define some properties, such as line numbers that can be visualized, the line that is selected by the user, and son on, besides allowing each field format that will be visualized. The Browser also allows the visualization of the batch file, through the specification of the correspondent HDR file in the setting page.

 Elipse Software

9-10

Elipse Windows

H I S T O R I C A L

9.4. Drill Task: To create a historical onject with recording by Batch. Procedure: From the Organizer create a new historical, with the name Hist2. Specify the file name as BATCH.DAT. Select the historical as batch. In the Header item that can be accessed via Organizer (inside the object Hist2), and associate the tag Code (that is the product code) such as a string (text) of 10 characters, and the property Application.Username, as we will see later, is the name of the user that is logging in the system, also as a string of the 10 characters. In the Tags table in the object Hist2, add the level and temperature tag. Task: To set the screen for bath dossier. Procedure: Insert 3 buttons in the bath screen of momentary type to run three basic tasks of the batch, that are star, finish, and restart. Such actions could be run via some signal coming from the field, although, for test effect, we eill do it manually through the buttons. In the tree buttons message key in “Start”, “Finish” and “Restart”. For the first one, create a script OnRelease, to the button, running the function Hist2.StartBatchProcess(). For the second one, Hist2.FinishBatchProcess(), and for th third Hist2.RestartLastBatch(). Task: To create a procedure in the same screen mentioned above, through the use of two Browser objects, a system for choosing Analysis by batch. Procedure: Insert in the bath screen, two Browser objects. In this example, the Browser will allow choosing the batch that we want to visualize through navigating in the HDR file. So, the first one must be associated to the file BATCH.HDR(FIND THE FILE BATCH.DAT, AND THEN CHANGE THE EXTENSION TO .HDR). In the Query page select no data criteria, and in the databases page, click in the Code field, specifying the word “Code” as label and in the field Application.UsrName field use the word “Operator”, then click in “Update”. In the second Browser (Browser2), do the association to the data file BATCH.DAT. In the settings page, choose the specific batch option. Create a script to the Browser, that will be run by pressing the mouse left button twice: Script OnLButtonDblClk Header.Open()

 Elipse Software

9-11

Elipse Windows

H I S T O R I C A L

Header.GoTo(Browser.curSel) Header.Edit() Browser2.Consulta.criteria=Header.Code HAnalysis.Consulta.criteria=Header.Code Header.Close() Browser2.UpdateQuery() Basically, the script above opens the HDR file in the same line where the user is clicking in the screen. Soon after that it will be pointer as search criteria to Analysis and for the Browser2, the batch whose code is being visualized by the operator. The object Browser does not have data update, that means the data file is not reconsulted automatically in regular ranges. This task is performed only when opening in the screen that has the object, or yet, through an update function called UpdateQuery(), that is present in the last line of our example. To the second button (Finish) we can add the function UpdateQuery() so that when completing the batch, the browsers will be update. In this case this button script would have the following setting: Hist1.FinishBatchProcess() Browser1.UpdateQuery() Task: To create in the same screen above a set point for keyboarding the product code. Procedure: Insert in the dosage screen a set point object, choosing in the format page the data with the text type (String). In the tags table associate it to the Tag Code.

 Elipse Software

9-12

Elipse Windows

H I S T O R I C A L

 Elipse Software

9-13

Elipse Windows

R E P O R T S

Capítulo

10 10.

T

Reports

He reports allow to perform the historical data, header and alarm printings, as well as the immediate data. There are four types of reports:



Text Report: It can make the data printing in the line and column format including the alarm files. It also allows the printing to filling in disk.



Graphic Report: It makes the graphic printing of the historical data, with the creation of subtitles.



Form: Use this option to print a form with any texts, momentary values of variables and bitmaps.



Historical Analysis: Screen report for visualization/printing of data in the disk. Use this report when you want to hav several analyses for each file, or even to remote data analysis, created by other applications.

All the reports have Query table for the specification of the data search range, and the Setting table to choose the data and batch files, if this option is enabled.

10.1.Drills CREATING ALARM REPORTS

Task: To create a text type for the alarm printing. Procedure: Specify the Report1 name, file: ALARMS.DAT, criteria selected by date and hour. Task: To create a screen for printing range.

 Elipse Software

10-1

Elipse Windows

R E P O R T S

Procedure: To create a new screen, window type. As background bitmap, insert LIB\ELECTRIC\DATAHORA.BMP. HOW TO CHOOSE DATE AND HOUR BEFORE THE PRINTING

There are two ways of performing this task: a) To create a button, in the screen, whose script OnRelease() will call a setup function of the report query. Example: Report1.Query.EditProperties().While running a window, similiar to the one in setting, will be displayed. b) From the bitmap onserted in our printing screen, insert 12 setpoints that will allow to choose the initial and final ranges. Each setpoint will associated to one of the properties:  Report1.Query.StartHour  Report1.Query.StartMinute  Report1.Query.StartSecond  Report1.Query.StartDay  Report1.Query.StartMonth  Report1.Query.StartYear  Report1.Query.FinalHour  Report1.Query.FinalMinute  Report1.Query.FinalSecond  Report1.Query.FinalDay  Report1.Query.FinalMonth  Report1.Query.FinalYear

PRINTING FOR DISK AND FILE

Task: To create bitmap objects for printing. Procedure: Insert two objects bitmap type, in the inferior borders in the screen. The first must be associated to the bitmap LIB\UNTIL\DISQUETE.BMP and the second, LIB\UNTIL\IMPLYES.BMP. To create a script for the mouse left button as follows: OnLButtonUp Report1.PrinttoFile(“c:\teste.txt”,0,‟ „)

 Elipse Software

10-2

Elipse Windows

R E P O R T S

This scripts uses the printing fuction for file, calling the Report1.PrintToFile(file,bImprimeHeader,burster,bIndicarProgress), where the file is the file name to be printed in the disk, bPrintHeader enables printing the Header, buster is a string used to separate the fields in the printing, and bIndicar Progress shows a window with a progress indicator. For the second bitmap, a script as follows: OnLButtonUp Report1.Print() PRINTING FILTERS

Together with the previous functions we can use the function AddFilter(field,valueLow,valueHigh) before printing, to use a filter in a specific field, together with the date, where the field is the historical field where you want to apply the filter; valueLow and valueHigh are the limit values, within which the print will be made. Consult the user’s manual for further information about this function. HOW TO PRINT A SCREEN

For that, just create a report of format type, inserting a bitmaps sole object, occupying the whole page extension. Name the bitmpa as Bitmap1, and the Form as Form1. Assume that you establish the screen ALT+S to perform the printing. Follow the next steps: Procedure: Go to the screen setting(if you want the print just in one page) or to the application (if you want in all screens). Choose the scripts page, New, type OnKeyRelease. Click in the capture button and press the keys ALT+S. Now the script is created In it, key in or capture through the App Browser the following functions: CaptureScreen("c:\teste.bmp") Form1.Bitmap1.bitmapName="c:\teste.bmp" Form1.Print() HOW TO CHANGE THE PRINTER AND RECONFIGURED THE REPORTS

When the reports are saved in the application they have information about the printer page, and so on. When you change or modify some data about the printing, these data must be reconfigured.

 Elipse Software

10-3

Elipse Windows

R E P O R T S

When selecting the item Reports via Organizer, the reports already created for that application and the registered printer list will be displayed as a subtem. You can determine a certain report to use alternatively a printer or other of the list, depending on the desired conditions.

You can associate for example, the Report Form1 to the Printer. While running, the following properties can be changed.: a) Change the report printer Form1 from Printer to Printer2. (done through the Report properties edition) b) Change the Printer of a certain physical printer model to the other. (done through the Printer properties edition). Task: To create in the printer setup procedure. Procedure: Inserta bitmap object, with the file LIB\UNTIL\TOOLS.BMP. Select transparent, with background light green. To create a script OnLButtonDown: Form1.SetupPrinter() Form1.SaveCfg("c:\printer.ptr") Create also a script in the Application, OnStartRunning, so that when you restart the computer, the data about the printer also be reloaded. Form1.LoadCfg("c:\printer.ptr") ADITIONAL DRILLS

To create additional buttons to call another reports:

  

Text report to historical data printing; Graphic report to same data printing; From to momentary data printing.

 Elipse Software

10-4

Elipse Windows

R E C I P E S

Capítulo

11 11.

A

Recipes

Recipe in the Elipse Scada can be considered as a model that contains a ceratin number of variables that can have values manipulated by tags, planning to save/loading the disk or read / writing its values in the equipment.

When creating a new recipe from the Organizer, a Model is being specified. The model corresponds to the specification of the tags set. The tags make part of a model will have one or move value sets that can be read or written.

11.1.1.Recipe General Properties Each recipe that you create for an application is displayed below the recipes option in the application tree in the Organizer. Once a specific Recipe is selected, its propertis are displayed in the right side of the tree. The Recipe General Propertis page is dispayed when the general tab in the top of the recipes is selected. This page is displayed below and its respective fields are described in the following table. Though the tags pag we can associate the tags that will be part of the model that we are creating.

 Elipse Software

11-1

Elipse Windows

R E C I P E S

FIELD

DESCRIPTION

Name

It defines the Recipe Model name that will be used in the Organizer tree and in the Scripts.

Description

It is a brief description about the Recipe Model.

Recipe File

It defines the file name to the current recipe model have up to 8 characters, and it must not have the extension (Elipse Scada will always use the RCP extension). You can also specify the file path that can be an absolute location (e.g.: “ RECIPE\RCP1” ). Relative Locations are not recommended if you want to copy your application to other computer.

Edit selected label

It allows the label edition of the selected Tag in the list below. Label can be understood as a tag nickname, so that its identification in the recipe is not necessarily the same as the tag name, in order to make the operration easier.

Edit Data

It opens the window Edit Recipe where you can set the recipe defining the tgas values to be recorded in file.

Labels

It shows the labels associated to the tags of the current Recipe Model.

 Elipse Software

11-2

Elipse Windows

R E C I P E S

Tag

It shows the tags associated to the current Recipe Model. You can add or remove tags in the Tags page of the Recipe.

11.1.2.Editing Recipes This window will be displayed when pressing the button Edit data… in the Recipes General properties page. Each Recipe within a Recipe Model will be displayed in the list of the combo box beside the Recipes field. Selecting any Recipe in the list, you can edit its description and the value of each Tag.

FIELD

DESCRIPTION

Recipes

It allows the selection of a current Model recipe. You can add a new Recipe by pressing the button New Recipe.

Description

It is a brief description about Recipe.

New recipe

It creates a new recipe, adding it to the current Model Recipe list. Each recipe Model can have several Recipes.

Delete recipe

It removes the selected Recipe from the list.

 Elipse Software

11-3

Elipse Windows

R E C I P E S

Edit field value here

It allows the tag value edition to the current recipe. Use the direction arrows of the keyboard or the mouse to select the tags to be edited.

Recipe data

It lists the value of each Tag of the current Recipe.

Drill: Task: To create a recipe model for product register. Procedure: In the recipes item, create a new recipe, with the name Model1. Specify the file MODEL1.RCP, and associate the tags Water, Sugar, Syrupe and Glucose. Click in the fields of each one of the tags, and replace the label value: for Water--------------, Sugar----------------Syrup--------------- and Glucose-------------- Now click in the field Edit data, where a dialog box for registering (off-line) the several recipes (value set) that can be associated to the tags will be opened, besides the name of each recipe. At this moment, the recipes are already created, but we did not create the manipulation methods of the running value yet. For such purpose, we can the screen recipes. Task: To create setpoints for values keyboarding in the screen Recipes. Procedure: To create in the recipe Screen 5 setpoints for keyboarding/visualization of values in the tags Water, Sugar, Syrup and Glucose, and another setpoint associated to the tag Code (this last one necessarily in String (text) format). Task: To create in the screen Recipes the procedure for recipe manipulation. Procedure: To create in the screen Recipes 5 buttons, which will run the scripts in order to perform basiz tasks with the recipes that are:  Selecting and Loading: It allows at choose, model1.rcp, there can be several recipes,

that means, several values sets. Through a selection procedure, we choose which recipe we want to manipulate. For such, we need to obtain a number that is the position in the file or a recipe number, which will be stored in the tag number_recipe.

Tags.Products.number_recipe=Recipes.Model1.ChooseRecipe(“Choose the Product”,1) The line above makes a window to be opened in order to choose the desired recipe. Adding the next lines in the same script will make the selected recipe to be loaded, choose name will be copied to the tag Code.

 Elipse Software

11-4

Elipse Windows

R E C I P E S

Recipes.Model1.LoadRecipe(Tags.Products.number_recipe) Tags.Products.Code= Recipes.Model1.GetRecDescription (Tags.Products.number_recipe)  Create

a New Recipe: It allows opening a new register or a data set in the file model1.rcp.

Tags.Products.number_recipe=Recipes.Model1.CreateNewRecord(Tags.Products.Code)  Delete Recipe: From the register number of a recipe we can withdraw it from the

file model1.rcp.

Model1.DeleteRecipe(Tags.Products.number_recipe) Another suggestion to delete a recipe can be as follows: IF MessageBox("Do you really want to Delete the recipe?","Delete recipe",0124h)==6 Recipes.Model1.DeleteRecipe(Tags.Products.number_recipe) Recipes.Model1.LoadRecipe(1) Tags.Prodcuts.Code=Recipes. Model1.GetRecDescription(1) ENDIF The MessageBox function is used to make sure the user wishes to delete the recipe. This function is present in the Global Manager and is used as a dialog interface with the user, when some information or intervention is necessary. Besides that, this manner also loads the first recipe, so that the setpoints do not keep the values of a recipe that no longer exists.  Edit

Recipe: It is a ready function, present in the software, that replaces the previous procedures. It opens a pattern window, where the user can create, edit or delete recipes. In the case of this example, we will allow the data manipulation in two manners: either through the edit pattern window or through the setpoints.

Recipes.Model1.EditRecipe()  Save Recipe: It allows to load values, present in the tags, for a recipe or position in

the data files, in order to store them. For such task, we need to inform the recipe number that must be previously created..

Recipes.Model1.SetRecDescription(Tags.Products.number_recipe, Tags.Products.Code) Recipes.Model1.SaveRecipe(Tags.Products.number_recipe) Other interesting characteristic in the recipe model is that the same data file created by a recipe or template can be used by another recipe, since they have the same number of associated variables.

 Elipse Software

11-5

Elipse Windows

R E C I P E S

This allows to load a recipe file in other variable set that are not field variables, allowing the preparation, in a separate process, of forms and so on, which will be used by the operator later. RETAINING TAGS IMPLEMENTING

This tip shows how to implement tags with persistent value, that is, the tag value is registered when it exists the application, and loaded when the application is run again. Create a new recipe model (name = recipe) and associate to it the tags and properties that you want to recors. In the script OnStartRunning of the Application, or even through any other procedure, in which you want to guarantee that the files will be recorded, add the following lines: IF Recipes.Recipes1.GetRecCount() > 0 Recipes.Recipes1.LoadRecipe(1) ENDIF In the script OnStopRunning of the Application, or even through any other procedure, in which you want to guarantee that the files will be recorded, add the following lines: IF Recipes.Recipes1.GetRecCount() < 1 Recipes.Recipes.CreateNewRecord("Persistent Tags") ENDIF Recipes.Recipes.SaveRecipe(1) By doing so, every time the application is finished the tags values are saved in the first register (SaveRecipe(1)) of the recipe file. When running the application, it is verified is loaded (LoadRecipe(1)).

 Elipse Software

11-6

Elipse Windows

P A S S W O R D S

Capítulo

12 12.

T

Passwords

His feature allows to control the access to the Screens through list of names, in which a password, a login and a safety level are attributed to each name.

It in the Screen specification, in the access level field a number different from 0 (0 releases the access to all the users) is specified, it is necessary a user to be logged in, and that its safety level allows the access to the Screen. According to the assigned access level, each user will have some functions available. The user with level 1 is considered a superuser, and when he is logged in he can, through the UserAdministration() function, create, change and remove the attributes of all users. By means of the same function, the other users can change their password by keyboarding the old password and by double validating the new password. The passwords and levels are recorded on an encrypted and independent file in the application directory. In order to the user be logged in the System, the function Login() must be forcingly executed. In case there were an user already logged in, this function will first provide a logout of the former user through the function Logout() and then a register of the new user.

Drill: Task: To create users and register them. Procedure: To create users with various access levels in the system screen except for the Openning screen, which will have free access to all users. Task: To create a Login procedure of the user in the Opening screen.

 Elipse Software

12-1

Elipse Windows

P A S S W O R D S

Procedure: In the login bitmap object in the opening screen, create a script OnLButtonUp, running the function Application.Login(), present in the Application. Task: To create a password maintenance procedure. Procedure: In the login bitmap object in the opening screen, create a script OnLButtonUp, running the function Application.Login(), present in the Application. Task: Insert the user’s name that was logged in the opening screen. Procedure:Insert a display in the opening screen, over the toolbar, and bring it to the front. Set the font Arial Regular 10- black, left alignment. In the prefix field key in “User” and in the tags table associate Application.UserName. Also insert a display showing the user level access, via property UserAccessLevel. Task: To create a button for calling the dosage screen, with the text: “System Login”. EXTRA DRILLS

Task: To use the Message Box functions and create the verification of users logged or not. Task: To create a user’s log registry. Procedure: Through the creation of a variable RAM called user, create a user’s log, through marking a high alarm in 1 to it. Using the script OnUser of the Application perform the following script: user.High.comment=” The user ”+Application.Name+” was logged” user=1 user=0 making the user’s historical message be logged in. Remark: the alarm of the variable user must be marked with different priority compared to other alarms in the system.

 Elipse Software

12-2

Elipse Windows

D A T A B A S E S

Capítulo

13 13.

T

Databases

He Databases option of the Elipse Scada allows to create and manipulate one or more databases using the Windows ODBC, that allows the connection with an already created databasis or to create a new one from an assistant inside the software.

To create a new connection with a new table:

  

Choose the ODBC driver that you want to use; Set the connection and the file or directory name that contain data; Create each one of the fileds, choosing name, data type and syze.

In the Organizer the new table and its respective fields will be displayed, which can be changed using the special functions of the ODBC in the Scripts: Create a new connection with the already existing databases:



Create the databasis. In the Excel case, you must use the first line of each column as a field name;

 

Close the databasis;



In the Organizer, in Databases, choose Connect to an existing table, press the button New and choose the driver ODBC that you wish to use; Choose the directory where the databasis is;

The table and its respective fields must be displayed in the tree. Manipulate the data through the function ODBC Consult the Advanced manual for further information about Databases.

 Elipse Software

13-1

Elipse Windows

R E M O T E

A P P L I C A T I O N

Capítulo

14 14.

Remote Application

T

He Remote Application are used to connect two or more applications that are linked via local network, modem, serial cable or optical fiber. In order to use this resource, you need to specify at least one server station and one data customer, beside a network driver that will be responsible for the information exchange. The following communication drivers are available: DRIVER

DESCRIPTION

Ipx.dll / Ipx32.dll

It allows the communication on a network that uses the Novell® IPX/SPX protocol

Tcpip.dll / tcpip32.dll

It is the faster and most used driver. It is necessary to install a TCP/IP driver in your computer’s network.

Serial.dll / serial32.dll

It is used for serial or optical fiber communication between two computers; the physical environment must be full-duplex.

Dialup.dll / dialup32.dll

It is used for connection via dial line

The basic procedure for creating a remote application is by specifying a server application and one costumer. In the server application, you must set the network driver, whose procedures can be found in the user’s manual. In the customer application, you can start, for example, from the server application and to transform the normal tags (PLC, BLOCK, RAM, EXPRESSION, DEMO, …) in remote tags. Remember that when it is necessary to change the type of a tag we can use the tool “Change type to…”that accepts multiselection. The change can also be made with Block Elements and Remote Tags. When changing a tag to block element, the user informs in which Block the elements will be inserted; when changing a tag to remote, the user informs in which Remote Application or remote Tags Group the new

 Elipse Software

14-1

Elipse Scada

R E M O T E

A P P L I C A T I O N

tag will be inserted; when changing the Block Element or Remote tag to another tag type, the user informs which one is the destiny tag group. Also, when a tag type is changed to Remote Tag, the Elipse copies the name and the full path of the original tag to the original tag name field in the Remote Tag. Besides that, when a tag type is changed, some properties or functions are verified to know if they will no longer exists after the type change, if that happens the change is aborted and a message is displayed to the user. Desides the remote tags, files can be transferred. The Elipse Scada uses a ressource that optimizes the file transference process, for it is able to transfer only the changes of the same file from one station to another. FILE TRANSFERENCE EXAMPLE

Here isn an example of application to the trasnference between two applications. Task: To create a specific screen that will display the transmission progress and its status. The button can call the screen called Transf_file. Script OnRelease Transf_File.Show() File_Remote1.GetFile("C:\Elipsew\Test.dat","C:\Elipsew\Test.dat") Task: To create a tag expression, with the name transf01, whose content will be and operation between two properties of the remote file. (File_Remot1.bytesDone/File_Remote1.totalLength)*100 This tag will display the bytes percentage that had already been transmitted in realation to the total. Task: to create the screen Transf_file to visualize the transference. Procedure: To create a graphic with horizontal bars associated to the tag transf01. To create another three text objects, with message zones, in order to visualize the following properties:  File_Remote1.Status:

It shows the connection status: 0 - Disconnected, 1 Connected or 2 - Connected.



File_Remote1.result: It shows the transference status: -1 without transference, 0 – default, 1 – sucessful.

 File_Remote1.totalLenght: It shows the file total bytes.

 Elipse Software

14-2

Elipse Scada

R E M O T E

A P P L I C A T I O N

A suggestion for the screen final result can be as follows:

 Elipse Software

14-3

Elipse Scada

rint this…

O P T I M I Z A T I O N

Capítulo

15 15.

T

Optimization

O run the setting tasks in the shorter time possible and to obtain a better performance in the Application running, we listed here some useful tips:

1. Communication Speed: Try communicate with the data acquisition equipment in higher rates, once there are no communication problems. In general, dealing with serial communication, the Windows supports sommunication in 19200bps, which is preferred in relation to 9600bps.

2.

Communication Try number and Scripts OnCommError: In the communication driver settings, in the option Retry Default Communication its is not advisable to run a high number of tries, once the equipment presents continous communication errors, it is necessary to revise all the communication, from physical connections to the communication driver. Just raising the try numbers makes that each tag read be retried in number of the times before the software recognize the communication error, what degrades the communication performance as a whole 1) To ver:ify and manage with a better effectiveness the communication errors the Script OnCommError in the Driver object can be created, which will be called when any communication error takes place. 2) To manipulate the errors, some of the driver functions can be used, such as:

GetErrorInfo(param) It returns the information about the last occurred error. If stop=0, it returns the communication type that caused the error (see User’s Manual). If stop=1,2,3 or 4, it returnd the parameters N1 to N4 or B1 to B4 of the PLC tag or Block that caused the error. So, if in a PLC’s network where the parameters N1 or B1 represents the number of the PLC in the network, it is possible to know which equipment is with defaults.. AddFilter(strFilter) Add a communication filter in the Driver, disabling the readings or writings in tags that have parameters specified in the filter. Thus we can disable the communication with a

 Elipse Software

15-1

Elipse Windows

O P T I M I Z A T I O N

specific maintenance equipment, for instance, avoiding errors while while it is disconnected. RemoveFilter(strFilter) It removes the filter that was added with AddFilter(strFilter). Example: Assum that we are using the Modbus driver, whose parameter N1 indicates the PLC address in the network. A script suggestion would be as follows: To create a tag of RAM type called ERRO To create a script OnCommError in the communication driver: ERRO=Driver1.GetErrorInfo(1) Driver1.AddFilter(Str(ERRO,2,0)) MessageBox("Ocorreu um erro no PLC: "+StrZero(ERRO,2,0),"Communication error",0040h) 3.

Attributes “Enable reading by scan”, “Enable automatic reading” and “Enable automatic writing”: Try to correctly set these parameters in their tags. The normal procedure is that if a variable must be normally searched, the scan and automatic reading options must be enabled. If you want to directly control the writing and reading through the functions Read() and Write(), leave all the options disabled.

4.

Tags Advice: Elipse accomplishes optimization in the communication, in order to avoid that the variables be communicated with out reason, through the use of the properties advise, that indicates if any module (screen object, alarm, historical, report, script, and so on) is in need of the variable update value. Thus a tag thatis not being used by any object will not be read. If you wish the tag to be read independently of being used or not, you must, for instance, enble the alarm or evn to force its reading through the function Read() of the tag. In the case of the expression tags, always that a variable is changed, the tag will be evaluated again, if it is in the advise mode. On the contrary, it will only be evaluated when some module requires its value.

5.

How to set up screen objects to improve its performance: Objects such as trend graphics can perform the data collection in background and redraw the graphic in higher ranges, without lossing the collection. Thus the trend refresh time can be longer yhan the scan of the variables without damagingits content. Another consideration about the screen object is related to the animation object, when the transparent spends more processing time then the normal animation.

6.

Memory: The RAM memory quality necessary to good perfornance of its system depends on the application size. Usually, each application item spends around 2kbytes. To know the total item of your application, press the key

 Elipse Software

15-2

Elipse Windows

O P T I M I Z A T I O N

Ctrl+Shift+Alt+I. If your machine is limited, you can decrease the required memory quantity, working with lower resolution draw (16 or 256 colors), and creating animation only in the areas that will be animated.. 7.

Tie Optimization: If your do not need to align several ties, choose to separate them, so the script will have a better performance. Example:

Ex : For ...

For ... Next

Next Usually is slower than: For ... Next For ... 8.

Creating shortcuts for an Elipse application: The Elipse Scada 2.0 installment automatically registers the files with APP extension. Therefore, the Elipse Scada applications can be automatically run with a double click over the created application.To create an access icon (shortcut) in the desktop (work area), just find the program (in the explorer or file manager) in the directory or work folder and “darg it” to the wanted localization.

9. Y2K: The Elipse Scada registers the dates using a format that assures the

normal operation of the software to the next millenium without changes or charges.

10. Manipulating dates in the ELIPSE: The Elipse uses the JULIAN calendar

to manipulate dates, in such case the Y2K is avoided. You can use the properties day, monyh, year, hour, minute and second, or through the attribute currentTime. To show a date in any screen format, just insert a display associated to the property currentTime, and choose the format as Date/Time and click in the format button. Observer that the mentined parameters return the current date of the system, are constantly updated and could be replaced by a value (absolute date) of a databasis (ODBC).

11. Organizing the Object Tabs of the Elipse: By using the Tabs key it is

possible to move an object, such as a Setpoint, for instance, to next object of a series.

 Elipse Software

15-3

Elipse Windows

O P T I M I Z A T I O N

Initially, the shifting through the Tabs follows the object creation order in the screen. However, it is possible to easily change this order with a little trick; Select the objects in the desired Tab order. Press the "Bring to Front" or "Send to Back" buttons. 12. Faded Pictures (bitmaps): If you wish to transport an application to

another machine, and the picture fade, the following steps can be taken: 1) Open the explorer. 2) In the menu View, click over the option Options.In this dialog box, DESELECT the option HIDE MS-DOS files extensions to registered files. 3) Close the dialog box. 4) Return to the Elipse and reopen the application. The bitmaps must be displayed again.

13. Driver Files do not Appear: If you try set a new communication driver in

your application and you can not find a file, the reason must be the Windows Explorer that is set to hide files with DLL extension. To solve this problem, follow the next steps: 1) Open the explorer 2) In the menu View, click over the option Options or Folder Options 3) Select the View table, and in the option Hidden Files choose Show all files.

14. To show Video Images: The nnew video object allows the camera videos or

TV images ro be displayed, you need to have a video board with input for theses signal. The resolution is defined by the size of the object placed in the screen, with a frequency of 30 frames/second. To know more about the video use, read the User’s Advanced manual.

 Elipse Software

15-4

Elipse Windows

E X H I B I T S

Capítulo

16 16.

Exhibits

16.1.Driver Klockner Moeller File: KLOCKNER.DLL Manufacturer: Klockner Moeller Equipment: PS3, PS4-100, PS4-200, PS306, PS316 e PS416 Release: 30/05/97 This driver is set to work with all the Klockner Moeller PLC. Parameters (p) of the Driver communication: P1 – serial port: 0 = COM1 1 = COM2 2 = COM3 3 = COM4 P2 – transmission velocity 0 = default (9600) 1 = 1200 bps 2 = 2400 bps 3 = 4800 bps 4 = 9600 bps 5 = 19200 bps P3 – timeout time (in centesimal) 0 = default (20 centesimal) > 0 = new timeout P4 – eco 1 = yes 0 = no

 Elipse Software

16-1

Elipse Windows

E X H I B I T S

Parameters (n) of address to Tags of PLC type: n1 – clp number n1=3 PS306, PS316 or PS416 n1=5 PS3 or PS4-100 n1=7 PS4-200 n2 – variable type n2= 0 reads byte low of the address n2= 1 reads byte high of the address n2= 2 reading/writtingof the address word n2= 3 reading/writing n3 – variable address (it must be even) For n1=3 or n1=7: MW wanted (0, 2, 4, ...) For n1=5 use the memory physical address (See Address Tables below in decimal) n4 – in the bit position in the word (0-15), when n2=3 Parameters (b) of address to Tags of BLOCK type: size: block size b1 – CLP number b2 – initial address (even) b3 - words number b4 – not used Address table PS3/PS4-100 (Klockner documentation): Address type n2 Symbol Access Physical (hexa) --------------------------------------------------------------intern RAM --------------------------------------------------------------L 0020 IB0.0 Digital input - master L 0021 IB0.8 Digital input - master E E L L L

0022 0023 0024 0025 ....

 Elipse Software

QB0.0 QB0.8 MB0.0 MB0.8 .....

Designation

Digital output - master Digital output - master Check Byte - master Check Byte - master

...

16-2

Elipse Windows

E X H I B I T S

L 002B MB3.8 Check Byte - master L 0035 Status word - master L 0036 Status Word - master --------------------------------------------------------------External RAM --------------------------------------------------------------L 4E85 Status word - 1. slave L 4E86 Status word - 1. slave L 4E87 Status word - 2. slave L 4E88 Status word - 2. slave L 4E89 Status word - 3. slave L 4E8A Status word - 3. slave L 4E8B Type - master L 4E8C L 4E8D L 4E8E L/E 5E00 L/E 5E01 L/E 5E02 L/E 5E03 L/E 5E04 L/E 5E05

IB1.0 IB1.8 IB2.0 IB2.8 IB3.0 IB3.8

Type - 1. slave Type - 2. slave Type - 3. slave Digital input - 1. slave Digital input - 1. slave Digital input - 2. slave Digital input - 2. slave Digital input - 2. slave Digital input - 2. slave

L/E 5E06 QB1.0 L/E 5E06 QB1.0 L/E 5E06 QB1.0 ... .... ..... ... L/E 5E0B QB3.8 L/E 5E0C MB4.0 L/E 5E0D MB4.8 ... .... ..... ... L/E 5E47 MB33.8

Digital output - 1. slave Digital output - 1. slave Digital output - 1. slave

L/E 5E4C IA0.0 L/E 5E4D IA0.1 ... .... ..... ... L/E 5E6A IA3.2 L/E 5E6B IA3.3 L/E 5E6C QA0.0 L/E 5E6D QA1.0

Analogic input 1 - master Analogic input 2 - master

 Elipse Software

Digital output - 3. slave Check Byte-master Check Byte - master Check Byte - master

Analogic input 3 - slave Analogic input 4 - slave Analogic output - master Analogic output 1. slave

16-3

Elipse Windows

E X H I B I T S

L/E

5E6E

QA2.0

Analogic output 2. slave

L/E 5E6F QA3.0 Analogic output 3. slave --------------------------------------------------------------L=READ E=WRITE

16.2.Driver Siemens 3964R File: 3964.DLL Manufacturer: Siemens Equipament: Siemens, Bosch, WEG, Mauell Protocol: 3964R Release: 28/11/96 This driver communicates via 3964R protocol with any CLP that supports this protocol. Some CPU’s have a specific communication channel for this protcol, others need an interface (RK512 or 524). Micor connection (Elipse) with the Siemens CPUs via 3964 TTY:

Parameters (p) of the Driver communication: p1 – communication port: 0=COM1 1=COM2 2=COM3 3=COM4 p2 - baud-rate: 0=2400 bps 1=4800 bps 2=9600 bps 3=19200 bps p3 – time-out in centesimals of seconds p4 – not used Parameters (n) of address to Tags of PLC type:

 Elipse Software

16-4

Elipse Windows

E X H I B I T S

n1 – not used n2 – variable type (see table 1) n3 – address part 1 (generally DB number) n4 – address part 2 (generally DW number) Parameters (b) of address to Tags of BLOCK type: b1 – variable type (see table 1) b2 – address part 1 (generally DB number) b3 – address part 2 (generally DW number) b4 – variable number to be read (words or bytes) Table 1 – variable type: Variable Typel Data block DB continuation Merker (Memory) Input Output Counter Timer Periphery System address Absolute cont. Periphery cont. Data block (with signal)

 Elipse Software

1

8 9 10

NºAddress Variables 0 DB/DW WORDS DB/DW WORDS 2 DB/DW BYTES 3 DB/DW BYTES 4 DB/DW BYTES 5 DB/DW WORDS 6 DB/DW WORDS 7 DB/DW BYTES Absoluto WORDS Absoluto WORDS DB/DW BYTES 11 DB/DW WORDS

16-5

Elipse Windows

Related Documents

Scad A Tutorial Us
May 2020 5
Scad A
May 2020 4
Scad A
April 2020 3
Scad
November 2019 5
Scad A 1
May 2020 1