Ix Developer - Advanced Training - V2.0.7 (en)

  • Uploaded by: Jorge_Andril_5370
  • 0
  • 0
  • January 2021
  • 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 Ix Developer - Advanced Training - V2.0.7 (en) as PDF for free.

More details

  • Words: 5,448
  • Pages: 90
Loading documents preview...
Area for ”header box” (8,09x1,26) iXredHMI Software

Area for ”big and left” picture

Area for ”right” picture

Position from top left corner:

Position from top right corner:

Horizontal 0,5 cm Vertical 0,5 cm

Horizontal 0 cm Vertical 0,5 cm

iX Developer – Advanced Training Version 2.0.7

Agenda Basic

Advanced ▪ A1.

Visualization - Objects

▪ B1.

General

▪ A2.

Alarm Client / Server

▪ B2.

Basic Steps I

▪ A3.

Alarm Distribution

▪ B3.

Basic Steps II

▪ A4.

Data Exchange

▪ B4.

Dynamics

▪ B5.

Controller + Tags

▪ A5.

Datalogger/Trend Dynamics

▪ B6.

Actions

▪ A6.

Chart

▪ B7.

Alarm Server

▪ A7.

Audit Trail

▪ B8.

Security / User Management

▪ A8.

Report Generator

▪ B9.

Trend

▪ A9.

Screen Alias

▪ B10.

Recipe

▪ A10.

Expressions

▪ B11.

Media Controls

▪ B12.

Multi Language

▪ A11.

Web Server

▪ B13.

Text Library

▪ A12.

OPC UA Client / Server

▪ B14.

Project / Panel Handling

▪ B15.

Hints + Error Support

2

Agenda ▪ A1. Visualization – Objects Action Menu - General Action Menu – Settings Action Menu – Actions Touch Objects – General Touch Objects – Settings Screen ID Exercise [A1] ▪

A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

3

Action Menu - General ▪ Inspired by mobile GUI ▪ Touch scroll and gesture support ▪ Actions are executed when clicking on an item ▪ Three different styles (Tab, Expand and Bar)

Tab

Expand

Bar

Action Menu - Settings Style: Can be either Tab, Expand or Bar Item Width/Height: Size of each item in the menu Picture Width/Height: Size of picture (included in item) Scrollbar Width: Decides the width of the scrollbar. Value 0 removes the scrollbar

Scroll Sensitivity: Sets the sensitivity of the scroll. Minimum value is 1, maximum value is 10.

Action Menu - Actions Edit Actions: Configure Groups, Symbol, Text and Action for each item in the menu

Menu Groups: Possible to Add/Delete groups Each group consists of: Name: Also serves as the group’s text Picture: Select which picture that should be used

Actions: Possible to Add/Delete items in each group Each item consists of: Text: The item’s text Picture: Select which picture that should be used Action: Decide what should happen when clicking on the item

Touch Objects - General ▪ Inspired by mobile GUI ▪ Touch scroll and gesture support

Touch ListBox

Scrollable through gestures The item’s height is configurable

Roller Panel

User can “roll” with touch gestures, thereby changing tag value

Touch Combobox

Scrollable through gestures The item’s height is configurable

Touch Objects - Settings Configuration of the objects is very similar Settings: Mainly size properties (e.g height of item, width of scrollbar) Configure Texts: Opens dialog where texts can be defined Scroll Sensitivity: Sets the sensitivity of the scroll. Minimum value is 1, maximum value is 10.

Configure Texts Dialog: Select tag that shall control which text that is focused Each text is mapped towards a Start/End Value range. If the value of the tag is within the range then that text gets focus

Screen ID ▪ A Tag can control which screen that should be opened, this is done with the Screen ID ▪ Example: Jump to a specific screen when an alarm condition is fulfilled

Each Screen can be assigned a ScreenID The ScreenID needs to be unique

System Tags Current Screen ID: Displays value/ID of the current screen New Screen ID: When value is changed iX RT will look for screen with that ID (and change screen)

Exercise 1 - Menu Exercise [A1] 1. Open the template application 2. Update the PopupMenu screen, it shall be possible to navigate to the following screens: - Home - AlarmHistory - TrendHistory - Configuration - AuditHistory It shall also be possible to Login/logout from the PopupMenu screen 3. Test the application and make sure that the menu works as intended

10

Agenda ▪

A1.

Visualization - Objects

▪ A2. Alarm Client/Server General Alarm Server Alarm Client Exercise [A2] ▪

A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

11

Alarm Client / Server - General ▪ The Alarm Server distributes alarms to all connected Alarm Clients (via Ethernet) ▪ The alarm configuration and storage is done only on the Alarm Server ▪ Simple and efficient method, to have the same, actual alarms synchronized on different Panels ▪ Changes (e.g. Acknowledge) in one Client updates all connected Clients Alarm Server Topology: Alarm1 Alarm2 Alarm3

Alarm1 Alarm2

Alarm1

Alarm3

Alarm2 Alarm3

Alarm Client Alarm Client 12

Remote Alarm Server ▪ Alarm Server = Definition, creation and generation of alarms Alarm Client = Synchronizes with the server and displays the server alarms.

Click on Settings and select the Server Mode tab

Server Mode: Both Server Port: 1000  1000 is just an example, Client Panels must use the same Port

Alarm Basics is covered in the BASIC Training 13

Alarm Client ▪ Alarm Server = Definition, creation and generation of alarms Alarm Client = Synchronizes with the server and displays the server alarms.

Click on the Alarm Viewer Control

Extended Settings (available in Property Grid) Server Address: [IP of the Server] Clients connect to the entered IP Address Server Port: 1000 1000 is just an example, configuration must correspond to the server setting

14

Exercise 2 – Remote Alarm Server Exercise [A2] 1. Work two and two

2. Configure the Remote Alarm Server functionality on panel one 3. Configure the Remote Alarm Client/Viewer on panel two 4. Run the applications and make sure that the alarm viewers are synchronized

15

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server

▪ A3. Alarm Distribution General Configuration Enable Distribution Server Demonstration ▪

A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

16

Alarm Distribution ▪ The Alarm Distributor Server makes it possible to send alarm notifications via printer, SMS or E-mail ▪ The function can be either local (connecting to an “internal” server) or external (connecting to another panel acting as alarm distributor server)

Alarm Distributor Client

Alarm Distributor Server

Printer

E-mail

SMS

Alarm Distributor – Configuration

Add Alarm Distributor to the application Insert  Alarm Distributor

Add: Adds a route to the server A route defines a number of filtering rules for distribution of alarms. Multiple routes makes it possible to send different kinds of notifications to various receivers. Delete: Deletes the selected route Address Book: Contains list of all users (e-mail/phone number) Receiver Selection: Select which users that should be notified when alarm occurs Configure Distribution Devices: Configure Printer, SMTP Client and SMS provider

18

Alarm Distributor – Address Book

Address Book: Each user needs to have: First Name (mandatory) Last Name (optional) E-mail (optional) Phone number (optional)

Receiver Selection: Select which users that should receive SMS or Email. It’s also possible to decide if the alarms should be printed. Use the << or >> buttons to add/remove receivers to routes.

19

Alarm Distributor – Schedule & Filter

Filter (Optional): Define which alarms that should be distributed, e.g alarms in a Group named “Critical” Define which alarm states that should be distributed (default: Active only)

Scheduler (Optional): Scheduling of each alarm distribution route can be configured in the Scheduler tab. Only alarms that occur between the start and stop times will be distributed. Example: One route per production shift (day, evening, night)

20

Alarm Distributor – Email Settings E-mail Device Settings From name: Name From Email Address: Optional E-mail SMTP Server Name/IP: Address of SMTP server that will receive the alarm E-mails. Port: SMTP Server’s port number (default 25) Code page: 65001 = Unicode. If a limited E-mail client is used then it’s possible to define other code pages Authentication Mode: Decide if Authentication should be used or not. User Name/Password: Required in order to connect to Email server that requires ASMTP Subject/Body: Define the e-mails subject and content. {n}  Texts are populated automatically by iX Runtime (e.g Alarm text = {3})

21

Alarm Distributor – Print Settings

Print Settings Buffer settings: Decide if alarms shall be printed directly or when the buffer is filled Text Font Size: Font size used for the printout Body: Define the text that shall be printed. {n}  Texts are populated automatically by iX Runtime (e.g Alarm text = {3})

22

Alarm Distributor – SMS Settings

SMS Device Settings Basic URL: URL to http service (e.g 42it.eu) Distribution: Number of retries and interval between each retry Body: Define the text that shall be sent via SMS. {n}  Texts are populated automatically by iX Runtime (e.g Alarm text = {3})

23

Alarm Distributor – Enable Distribution Server

To enable sending alarms to printer, via SMS or e-mail, the Alarm Distributor Service must be enabled

Internal: Alarm Server sends events to internal Alarm Distributor Service External: Alarm Server sends events to an Alarm Distributor Service running on another panel/runtime

In addition to the settings above, the Enable Distribution option for the alarm groups and alarm items also has to be checked

24

Demonstration We will... 1. Add a few alarms to the application 2. Add the Alarm Distributor service to the template application 3. Configure the service so that it sends alarm e-mails to [email protected], SMTP: 192.168.98.1 4. Run the application and make sure that the alarms are distributed as e-mails

E-mail

25

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution

▪ A4. Data Exchange General Configuration Triggers Exercise [A3] ▪

A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

26

Controller Data Exchange - General ▪ Allows for real-time data exchange between controllers, even of different brands ▪ Selectable per tag ▪ Exchange can be triggered on event or time

Controller Data Exchange - Configuration Open the Tag Editor

By clicking on the “…”-button it’s possible to configure the direction of the Data Exchange It’s possible to transfer a value from one controller to several other controllers Example The value of D0 [Melsec] will be transferred to both DB10.DBW0 [Siemens] and Temperature [AB ControlLogix]

Controller Data Exchange - Trigger The data exchange can be triggered when: Value Change (default): When iX detects that the value has been updated then it will write the new value to the other controller(s)

Trigger: Can either be triggered on Time or when a tag changes it’s value Performance Considerations: Value Change will generate separate Write requests which might affect the application’s performance If a Trigger is used iX will try to fit as many tags in one write telegram as possible. Therefore it’s recommended to use consecutive addresses in the data exchange configuration.

Exercise 3 – Data Exchange Exercise [A3] 1. Add a new Modbus driver to the application 2. Configure the Modbus driver to connect to the localhost Simulator. Controller Settings: Communication Mode = Ethernet IP Address = 127.0.0.1 (localhost), Port = 502 3. Configure the application so that TankLevel1 (D0) is moved to ModbusReg0 (40000) 4. Use a data trigger as initiator (to get the best performance), try both tag and time 5. Run the application and make sure that data is transferred between the two Controllers

30

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange

▪ A5. Datalogger/Trend Dynamics General Historical Dynamics Exercise [A4] ▪

A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

31

Advanced Trending - General ▪ In the basic training we introduced the Datalogger and Trend Object ▪ In the advanced course we will dig deeper in the trend object‘s dynamics ▪ First parts will be repetition Edit Curves:  Name of the curve  Tag that displays the actual value  Log Item for historical trend data  Expression(e.g. Gain, Offset)  Color of the curve  Thickness of the curve  Minimum Value Tag (Optional)  Maximum Value Tag (Optional)

Value Scale  Min./Max. Value of the Scale  Major/ Minor Ticks of the Scale

Trend - General

Time Scale Time Range: Time Span which is displayed Major Ticks for Time Scale

Visibility Show Scale Show Grid

Style Different predefined Styles for the Trend Viewer

33

Trend – Historical ▪ By clicking on Insert  Data Logger a new Data Logger is added to the Project

Add new Logitem

Configure DataLogger Settings

Delete selected Logitem

Free definable name (= ColumnName in database Table)

Tag that shall be logged

34

Trend – Historical

Log on time or triggered by a tag (minium: 1s)

Max number of logged rows

35

Trend – Historical ▪ Select which log items that should be presented/visualized

36

Trend – Dynamics

Trend Dynamics – Value Scale Min/Max Tags that define the maximum/minimum Value of the Trend‘s Y-axis Can be used to Zoom in/out to get a more Detailed view

Runtime The tags (Ymax and Ymin) controls the Trend Viewer‘s Y-axis properties

37

Trend – Dynamics Trend Dynamics – Time Span Tags that defines the time range of the TrendViewer‘s X-axis (in seconds) Can be used to Zoom in/out to get a more Detailed view

Runtime The tag (TimeSpan) controls the Trend Viewer‘s X-axis property

38

Trend – Dynamics Trend Dynamics – Time Offset Tag that defines a historical offset If the tag value is 60 it means that the Trend Viewer will jump 60 seconds back in time. Can be used to Pan forward/backward in time

Runtime (Trend is in History mode) – Example 1 Tag value = 0 -> X-axis start time = time when Trend Viewer entered history mode (19:58:00) Since the trend is in History mode the automatic Update is paused.

39

Trend – Dynamics Runtime (Trend is in History mode) – Example 2 Time when Trend Viewer entered history mode is: (19:58:00) Offset value: 30 seconds X-axis time = 19:58:00 – 30 = 19:57:30 Since the trend is in History mode the automatic Update is paused.

Runtime (Trend is in History mode) – Example 3 Time when Trend Viewer entered history mode is: (19:58:00) Offset value: 30 seconds X-axis time = 19:58:00 – 30 = 19:57:30 Time Span = 2 minutes X-axis end time = 19:58:00 – 30s – 120s = 19:55:30

40

Trend – Curve Visibility Trend Viewer Legend Shows a predefined Dialog to: Make Curves visible/invisible Show the actual Tag Values

Script Alternative With script it’s possible to control the visibility of each curve Can be useful if the end-customer wants a certain look or prefers bigger/smaller buttons

41

Exercise 4 – Historical Trend Exercise [A4] 1. Add a Trend Viewer object to TrendHistory screen

2. Add a DataLogger to the application, it shall log the following tags (every second): - TankLevel1 - Valve1 3. Connect the Trend Viewer to the data logger. Use an Expression to add Offset/Gain to the boolean curve 4. Configure the Trend Viewer so that it‘s possible to Zoom and Pan (both X- and Y-axises) 5. Add buttons that toggles the visibility of curves (using C#-script) 6. Run the application

42

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics

▪ A6. Chart General Configuration Actions Exercise [A5] ▪

A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

43

Chart - General ▪ The chart object is used to display values of connected array tags ▪ The Chart object has support for many different styles, see a few examples below:

Area

Pie

Bar

Chart - Configuration

Array Tags The Chart object presents values from Array tags Array tags are defined in the normal Tag Editor. Select Data Type and the number of elements that should be included in the array (Array Size).

Configuration Most of the Chart‘s settings are found in the General ribbon tab Style: As for most other objects it‘s possible to select the Object‘s style (e.g Chrome or Black) Visibility: Defines if Scale, Header and Legend should be visible or not.

Chart - Configuration Axis Settings Visible/Grid Visible: Defines if Axis/Grid shall be visible or not Automatic Min/Max: When Automatic is enabled the object checks the data series/array and determines min/max values automatically

Chart Settings Chart Types: Select which type of chart that should be used in runtime (e.g Bar or Area) 3D View: Enable/Disable 3D-drawing. More CPU-intensive!

Chart - Configuration

Name: Symbolic name for the data series

Size: Number of data points that will be presented

X/Y Tag: Array tags that will be presented

Axis Type: Which Axis (Y1 or Y2) that the series shall be connected to

Labels: It’s possible to associate each data point with a text (e.g Monday,Tuesday, .., Sunday)

Chart - Actions Actions

Description Pan Down, Left, Right, Up Used to navigate in the Chart Reset View Chart is reset to default, Zoom and Pan values are reset Zoom In/Out Used to Zoom in or out in order to get a better overview of the presented data

Exercise 5 - Chart Exercise [A5] 1. Add a Chart object to the LevelChart screen and connect it to the following tag: TankLevelPerWeekday 2. Use TankLevelMonday – TankLevelSunday to simulate different array values 3. Test the different settings/chart types 4. Run the application

49

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart

▪ A7. Audit Trail

User Actions Tag Value Changes Viewer Backup Exercise [A6] ▪

A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

50

Audit Trail – User Actions ▪ Audit Trail = Makes it possible to log/track operator actions – it‘s possible to define which actions and tags that should be logged

Configuraton Log All/None : Check all/no checkbox FDA - Log entries are not overwritten - When 80% of the database is filled: User warning + request to export data When Max. Database size is reached: Logging will be stopped and operator will be promted to export the database Cyclic Buffering - Logged entries will be overwritten (FIFO – oldest row will be deleted) Max. Database size [MB] Size of Audit Trail Database

51

Audit Trail – Tag Value Changes When Audit Trail is added two new columns becomes visible in the Tag Editor (Others needs to be checked) 1. Log to Audit Trail Selects which Tags that should be logged 2. Audit Trail Description Customized description

Custom Audit text: Static descriptions – not dependent on tag’s value {0} = Tag‘s value berfore Write {1} = Tag‘s value after Write

Custom Audit text: Dynamic description, based on Tag value

52

Audit Trail – Viewer ▪ Audit Trail Viewer presents the database‘s content (in runtime)

Configure Columns: Double click on the control Available, addable columns: Message: System generated message Description: Customizable description Value Before: Tag value before change Value After: Tag value after change Time Stamp: Date/Time when event occurred User Name: Name of user/operator

53

Audit Trail – Database Backup Audit Trail Actions Database: can be exported/copied to:  USB media

Database -> CSV-file: can be exported/copied to:  USB media  SD Card  the Project folder “Project Files” The Project Files folder can be accessed via FTP. FTP functionality is enabled in the System tab (ribbon)

54

Exercise 6 – Audit Trail Exercise [A6] 1. Add AuditTrail to the application

2. Enable ”Log to Audit Trail” for the following controller tags: - Valve1 - Valve2 3. Add an AuditTrail Viewer object to the AuditHistory screen. Configure and decide which columns that shall be presented 4. Run the application

55

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail

▪ A8. Report Generator General Report Actions Exercise [A7] ▪

A9.

Screen Alias



A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

56

Reports - General ▪ The report generator generates excel reports based on an Microsoft Excel made report template ▪ The generated report can be printed or saved as an excel file (USB, SD or FTP)

Excel Template

Actions

1. Print

2. Save as *.xls

57

Generated Report

Reports – Tag values All Formattings, Graphics, Charts, Fonts, Colors, … can be freely configured. iX Tag values can be inserted into a cell by using a special Syntax:

<#Tag(TagName)> Examples: <#Tag(Application_PLC_PRG_Temp1)> = CoDeSys Tag <#Tag(SystemTagDateTime)> = iX System Tag

Excel Template has to be saved in the following format “Excel 97-2003-Worksheet (*.xls)” Operator Panels (e.g TxA and TxB) can only print text. This means that included charts, symbols etc. are excluded

58

Reports – Database Step 1 Create a new Sheet and name it <#Config>. This sheet will contain all database querys. When the report is generated this sheet will not be included

Step 2 The database querys needs to be defined on Row10 (and below)

Step 3 The data retrieved from the SQL database, using the queries in the configuration sheet, can be presented in the report using Named ranges in Microsoft Excel. Select the needed number of columns (in this sample 2 (Time and LogItem1)) Select Insert  Name  Define

59

Reports – Database Step 4 Enter a name for the range. The name must be entered in the following format: “__QueryName__”. Replace “QueryName” with the name that you have chosen for your SQL query

Step 5 To present the data in the report, enter the following syntax into the cells included in the named range: <#QueryName.DatabaseColumnName>

60

Reports – Add Template to application Add Template: Add  Select Template

Excel Template will be copied to the folder: Project Files\Reports\Templates

The name of the report can be freely assigned

61

Reports - Actions Actions

Description - Action: Generate report

Option 1: Print to installed (Default-) printer

Option 2: Save template in (Excel-) file with timestamp e.g. Farm_Report 01.05.2012 12.45.12.xls Locations to save: - Project files folder  Project Files\Reports - Browse  Save as Dialog will be opened - Path  Input of absolute saving path

62

Exercise 7 - Reports Exercise [A7] 1. Open the supplied Excel template

2. Modify the Basic Template sheet so that it presents the following information - Current Time (SystemTagDateTime) - Tank Level 1 (TankLevel1) - Tank Level 2 (TankLevel2) 3. Modify the Advanced Template sheet so that it presents historical data collected by the DataLogger 4. Insert a button with a Generate Report action on the Configuration Screen 5. Simulate the application and make sure that the generated report is OK

63

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator

▪ A9. Screen Alias General Alias Definition Connect Alias to Object Instances Show Screen Instance Exercise [A8] ▪

A10.

Expressions



A11.

Web Server



A12.

OPC UA Client / Server

64

Screen Alias - General ▪ Screen Alias = An alias should be treated as a property of a screen and can act as a stand-in for a tag. The alias can be used to reference a tag wherever that tag can be referenced directly. ▪ Using aliases will enable reuse of screens without having to create a new duplicated screen. 1.

Definition of Aliases, that can be defined as a stand-in for a “normal” tag

2.

Assign Alias to Objects

3.

Create (Screen-) Instances and assign the Original Tags to them

Example: Screen Alias function

Example: Popup with Alias function

65

Screen Alias – Alias Definition

Add: Inserts a new Alias Delete: Delete Alias Checkbox Data Type: Show tag data type Alias Name: Free definable stand-in name for tags Default Value: Optional definition of a default tag Data Type: Optional selection of tag data type

66

Screen Alias – Connect Alias to Object

Normal/Default: Selects a Tag Alias Function: In the Tag selector dialog: Select Aliases and choose an Alias Connect Alias instead of “real” tag to the object

An Alias always starts with a “#“-character

67

Screen Alias – Instances with Original Tags Add: Adds a new instance Delete: Deletes a screen instance Instance: Column is used to define a symbolic instance name Other Columns: Columns show the projected aliases (here with default values)

Filling / Pressure (Alias names): Columns show the projected aliases. Font Regular: Default Tags Font Bold: Inserted, projected Original Tags

68

Screen Alias – Show Screen Instance

Instance Call: Use the Show Screen Action and select which Instance that should be opened/shown

In the Show Screen Action there is a list where the different instances can be selected

69

Exercise 8 - Alias Exercise [A8] 1. The Valves on the Home screen shall be controlled from a common Popup/Faceplate 2. Add a new screen to the application and define two aliases: (TankLevelAlias & ValveAlias) 3. Create 2 Screen instances, configure so that the aliases are connected to tags as below: Screen Instance 1: Valve, TankLevel1 Screen Instance 2: Valve2, TankLevel2

4. When clicking on the valves the correct Faceplate (= ScreenInstance) should be opened

70

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias

▪ A10. Expressions General Define Reuse Exercise [A9] ▪

A11.

Web Server



A12.

OPC UA Client / Server

71

Expressions - General ▪ Expressions are used in order to scale and modify a tag’s actual value. It’s only the presentation that is affected, not the tag’s “real” value ▪ Expressions enable the developer to e.g. extract a bit from an word, add a dynamic offset or gain, and then to use this value for a specific object

Value in PLC

Tag Value

23.1

Expression

Presentation

Expressions - Creating

By clicking on the “…”-button it’s possible to connect an Expression to the selected object/tag

New: Creates a new Expression Edit: Edit an existing Expression Delete: Delete the selected Expression

Expressions - Creating Name: Name of the Expression Group: The Expression can be stored in a Group, this makes it easier to organize the Expressions Description: Comment/description, what is the purpose of the Expression?

Expression Code When the Expression has been created it‘s time to write the actual code Expression Code Code that will execute every time the tag value updates. Follows normal C#-syntax Value is the tag‘s “raw” value The Expression Code can contain Tag-values, Operators and standard C#-functions (e.g Math.ABS) When an object is connected to an Expression the “…” will be replaced with a “+”-character

Expressions – Reuse Expressions can be saved/loaded This makes it possible to reuse the Expression in future applications Library Expressions Load: Opens a dialog where the user can select which Expression(s) that should be imported Save: Saves the current Expression to a Library Delete: Deletes an Expression from a Library

iX Developer contains a few pre-installed Libraries Bit Operators: Used to extract bits from words Math: Log, Log10, Sin, Cos, Tan Temp conversion: Celsius <-> Fahrenheit

Exercise 9 - Expressions Exercise [A9] 1. Add an alarm indicator to the Home screen, make sure that it‘s Visible and Blinks when the Tank Level (TankLevel2) is greater than 90 %

2. Run the application and make sure that the configured Expression works as intended

76

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions

▪ A11. Web Server General HTML Configuration Writing Values Exercise [A10] ▪

A12.

OPC UA Client / Server

77

Web Server – General Web Server = On each iX panel, a simple web server can be activated.

▪ iX remote maintenance ▪ Screens can be projected with every HTML editor ▪ Compact information (overview) ▪ JavaScript

Ethernet / Internet

iX 2.20: Webserver supports 2 connections

78

Web Server – General Configuration

Description Web Server Configuration: System  Web Server

Web Server Activation: Enables/disables the Web Server function Port: Free definable Port. Default: 80 Authentication settings: - Checkbox unchecked:  Anonymous authentication - Checkbox checked:  Username and password can be set

79

Web Server – General Configuration

Description - The files must be stored in the folder: [Project]\Project Files\WebSite - Start page: index.html - For panel targets it’s necessary to download the websites via FTP

80

Web Server – HTML Configuration Syntax

Description

<script src="/assets/iX.js" type="text/javascript"> <script type="text/javascript"> iX.setup({});

- Initializes the SDK

Tag 1 = <span data-ix-tag="Tag1">

- Basic definition of a Tag via attribute:

- This code needs to be placed in the HTMLpage’s Head

<span data-ix-tag=“[TagName]”> - Placed in the Body area

Tag1= <span data-ix-tag="Tag1" data-ix-refresh="interval">
Example: Update interval (without parameter = 1s)

Tag2= <span data-ix-tag="Tag2" data-ix-format="0.000”>

Example: Tag formatting 1 digit / 3 decimals

Date = <span data-ix-tag="SystemTagDateTime" data-ix-format="dm-Y G:i">

Example: Tag Formatting of iX System Tag “Date”

Attributes can be combined Additional info available in the iX Reference manual

81

Web Server – Writing values Syntax

Description

Change value:

Example: Write value to tag when pressing submit button

82

Exercise 10 - Webserver Exercise [A10] 1. Enable Webserver in the application (with authentication)

2. Modify the basic HTML-page template, this allows you to read/write values 3. Modify the Advanced HTML-page template, this contains 3:rd party graphical controls 4. Store the HTML-files in the Project Files/Website folder and run the application. Make sure that the pages are working correctly

83

Agenda ▪

A1.

Visualization - Objects



A2.

Alarm Client/Server



A3.

Alarm Distribution



A4.

Data Exchange



A5.

Datalogger/Trend Dynamics



A6.

Chart



A7.

Audit Trail



A8.

Report Generator



A9.

Screen Alias



A10.

Expressions



A11.

Web Server

▪ A12. OPC UA Client / Server General Server Configuration Client Configuration Tag Configuration Exercise [A11]

84

OPC UA – General OPC UA = OPC communication type (UA = unified architecture), which has evolved from the drawbacks of the existing OPC technology. Features: ▪ Setting up Panel Network (via Ethernet) for Tag value exchange ▪ Panels can be configured as Server or Client (or both) ▪ Direct Communication to PLC‘s/Controller‘s or to generic ERP Systems

▪ No dependency on Microsoft © COM / DCOM architecture Ethernet / Internet

Controller

PLC 85

OPC UA – Server Configuration Server Configuration System  OPC UA-Server

OPC UA-Server Activation Checkbox enables the OPC UA Server function Port: Free definable Port. Default: 4840 Login: - Checkbox enabled:  Anonymous login is possible - Checkbox not set  Username and password can be defined

86

OPC UA – Client Configuration Add OPC UA Client driver In Tag Editor  Controller  Add: - Check OPC UA-Server - Enter IP Address of Server

Controller Settings URL: Syntax: opc.tcp//IP-Address Authentication settings: - Anonymous - Via username and password Namespace-Settings: - Free definable Namespaces possible - Namespace-Separator: Default “:” - Default namespace: Default NS2, “TagProvider” (iX iX)

87

OPC UA – Tag Configuration Tag Configuration

Description

Tag Configuration: Server

- OPC UA Server (e.g. T7A Panel) communicates via ModBusTCP protocol to a PLC

Tag Configuration: Client

Tag Name

Tag Address

Temperature Pressure

40000 40010

- OPC UA Client (e.g. PC as control station) communicates with OPC UA Server Tag Name

Tag Address

Temp_T7A Pressure_T7A

Temperature Pressure

Client Tag Address = Name of Server Tag Client Tag Name can be freely defined (does not need to match the server syntax)

88

Exercise 11 – OPC UA Exercise [A11] 1. Work two and two

2. Configure one of the applications to act as OPC UA Server, the other as OPC UA Client 3. Share at least one tag via the OPC UA-network, make sure that it’s possible to both read/write values and that both Server/Client updates as expected

89

iX Advanced Training

90

Related Documents