Вы находитесь на странице: 1из 30

Proficy HMI/SCADA - iFIX

TM

USING DDE

Version 4.0 December 2005

All rights reserved. No part of this publication may be reproduced in any form or by any electronic or mechanical means, including photocopying and recording, without permission in writing from GE Fanuc Automation.

Disclaimer of Warranties and Liability


The information contained in this manual is believed to be accurate and reliable. However, GE Fanuc Automation assumes no responsibilities for any errors, omissions or inaccuracies whatsoever. Without limiting the foregoing, GE Fanuc Automation disclaims any and all warranties, expressed or implied, including the warranty of merchantability and fitness for a particular purpose, with respect to the information contained in this manual and the equipment or software described herein. The entire risk as to the quality and performance of such information, equipment and software, is upon the buyer or user. GE Fanuc Automation shall not be liable for any damages, including special or consequential damages, arising out of the user of such information, equipment and software, even if GE Fanuc Automation has been advised in advance of the possibility of such damages. The user of the information contained in the manual and the software described herein is subject to the GE Fanuc Automation standard license agreement, which must be executed by the buyer or user before the use of such information, equipment or software.

Notice
GE Fanuc Automation reserves the right to make improvements to the products described in this publication at any time and without notice.

2005 GE Fanuc Automation. All rights reserved. Microsoft is a registered trademark of Microsoft Corporation. Any other trademarks herein are used solely for purposes of identifying compatibility with the products of GE Fanuc Automation. We want to hear from you. If you have comments, questions, or suggestions about our documentation, send them to the following email address: doc@gefanuc.com

Table of Contents
About This Guide ............................................................................................................................ 1 DDE Overview ................................................................................................................................ 1 iFIX DDE Client Support ............................................................................................................. 2 iFIX DDE Server Support............................................................................................................ 2 Understanding the DDE Address.................................................................................................... 3 DDE Addressing ......................................................................................................................... 3 Example .................................................................................................................................. 4 NetDDE Addressing.................................................................................................................... 4 Example .................................................................................................................................. 4 Using DDE Client Support .............................................................................................................. 5 Understanding DDE Client Support ............................................................................................ 5 DDE I/O Driver Configuration...................................................................................................... 6 Using DDE Client Support in the Database ................................................................................ 6 Using DDE Client Support in Input Blocks .............................................................................. 7 Using DDE Client Support in Output Blocks ........................................................................... 7 Using DDE Client Support in Digital Blocks ............................................................................ 7 Sharing Data Between iFIX DDE Databases .......................................................................... 7 Troubleshooting DDE Client Support in the Database................................................................ 8 DDE Client Task Messages .................................................................................................... 8 DDE Client Task Dialog Box ................................................................................................... 8 DDE Client Task Items.......................................................................................................... 12 Getting Started Using the DDE Server ......................................................................................... 13 Understanding the DDE Server ................................................................................................ 13 DDE Server Configuration ........................................................................................................ 14 Configuring DDE Server Support.......................................................................................... 14 Configuring NetDDE Server Support .................................................................................... 15 iFIX DDE Addresses ................................................................................................................. 18 iFIX DDE Local Addresses ................................................................................................... 18 iFIX NetDDE Addresses ....................................................................................................... 19 Starting DDE............................................................................................................................. 20 Setting the Update Time ....................................................................................................... 20 System Messages ........................................................................................................................ 21 Startup Messages......................................................................................................................... 22 Communication Messages ........................................................................................................... 22 Index ............................................................................................................................................. 25

iii

Using DDE

iv

About This Guide


The Using DDE manual is intended for iFIX software users who need to incorporate DDE data in the process database. Reference Documents For related information about iFIX, refer to the following documents: Trending Historical Data Building a SCADA System Setting up the Environment Implementing Alarms and Messages

DDE Overview
Dynamic Data Exchange (DDE) is a form of communication that uses shared memory to exchange data between applications. iFIX supports Microsoft's DDE. Your iFIX DDE client and server support allows you to: Pass process information into other applications such as MRP (Materials Requirements Planning) or SPC (Statistical Process Control) programs. Incorporate data from other applications into the process database to perform alarming and trending.

DDE differs from the clipboard method of data transfer in that it is typically used for ongoing updates. Data is updated automatically between applications, without user intervention. When sharing data, the application that requests the information is referred to as the client and the application that supplies the data is considered the server. An application can be a DDE client, a DDE server, or both a DDE client and a DDE server. The syntax used to reference the data is called a DDE address. Each program that uses DDE as a form of transferring data uses a specific DDE address to reference its data. Refer to the Understanding the DDE Address chapter for more information about the addressing syntax used to transfer data. iFIX provides both client and server support. DDE server support allows you to pass process information from iFIX to other applications for analysis. DDE client support allows you to pass information from other applications into iFIX for use in the database.

Using DDE

iFIX DDE Client Support


iFIX DDE client support lets you use data from other applications in your process database. It allows you to read from and write to DDE addresses. Using the DDE I/O Driver and a DDE address in your block configuration, you can incorporate information in your process database from another application, a DDE device driver, or another SCADA node. Because the data is available in the database, you can incorporate the data in chains and perform alarming and trending. The following figure illustrates how data is transferred from a DDE server application, in this case Excel, to an iFIX database block.

DDE Client Support in the Database For more detailed information on how to configure your database blocks to use DDE addresses, refer to the Using DDE Client Support chapter and the Building a SCADA System manual.

iFIX DDE Server Support


iFIX DDE server support lets you transfer data from your iFIX database to other DDE client applications. The following figure illustrates how a DDE server application, in this case Excel, is updated with realtime data to provide timely reports.

Using DDE

DDE Server Support

Understanding the DDE Address


A DDE client requests data from a DDE server using a DDE address. The syntax used in the DDE address is different depending on whether the server is local or remote. A local DDE server is a DDE application that is located on the same computer as the client application. A remote DDE server is a DDE application that is located on a different computer than the client application. The following sections describe the addressing used by both local and remote DDE servers: DDE Addressing NetDDE Addressing

DDE Addressing
A local DDE server is accessed using a three part address know as an ATI, or a remote reference formula if you are using Excel. The address consists of the application, the topic, and the item. The documentation for the DDE server that you are using provides the specific syntax you must use in order to access its data. The following is a general description of the parts of a DDE address: Application the name of the DDE server where the data resides. In many cases, the software program uses its name as the application name. Topic the name of the group of data on the DDE Server. The topic name can be the spreadsheet or file name containing the data to access. Item the individual piece of data to transfer. The item name depends on the method by which data is stored in the server application. IMPORTANT: If the Item name contains a hyphen (-), you must enclose it in single quotes.

Using DDE

Example
To access data in an Excel workbook, use the following syntax:
=EXCEL|[FILE.XLS]SHEET1!R1C1

Excel allows you to create multiple sheets within a workbook. In this example, the DDE address retrieves the value in the first row and column of SHEET1 in the FILE.XLS workbook. NOTE: iFIX can access any third-party software package that uses DDE addressing. Refer to your third-party software documentation for more information on the proper DDE address for your software package. I/O addresses are used in process database blocks. When entering an I/O address, the application name can use up to 26 characters, the topic name can use up to 20 characters, and the item name can use up to 79 characters. If the item name contained a hyphen (-), you must enclose it in single quotes. For example:
=DMDDE|DATA!'NODE1.REPORT-TEST.F-CV'

NetDDE Addressing
iFIX allows you to use the NetDDE server and client support provided as part of the Windows 2000 operating system. NetDDE allows a DDE-compliant application to request and receive data from another DDE-compliant application on a remote node within the network. If you are accessing information on a remote DDE server using NetDDE, the DDE address syntax is different from the addressing described in the DDE Addressing section. The NetDDE address consists of the following four parts:
=\\Computername\NDDE$|DDEShare.DDE!Item

Computername the computer or workstation name of the server node. This name is defined in the Computer Name field of the Network settings, accessed by clicking the Network icon in the Control Panel and selecting the Identification tab. NDDE$ the reserved name that indicates that NetDDE is used to transfer data. DDEShare the DDEShare name that you configure for each application and the topic with which you will communicate. The DDEShare name is an alias that you define. Make sure you include .DDE in the share name when you specify the address. For more information on defining DDEShare names, refer to the DDE Server Configuration section. Item the individual piece of data to transfer. The item name depends on the method by which data is stored in the server application. IMPORTANT: If the Item Name contains a hyphen (-), you must enclose it in single quotes.

Example
Assume you have an Excel workbook, FILE.XLS, with two worksheets, SHEET1 and SHEET2. Also assume a DDEShare is set up for each worksheet. To access information in SHEET2 of the FILE.XLS workbook, use the following syntax:
=\\NODE1\NDDE$|$SHIFT2.DDE!R1C1

Using DDE

Where NODE1 is the remote server node's computer name, NDDE$ indicates that NetDDE is used, $SHIFT2.DDE uses the DDEShare name for SHEET2, and R1C1 uses the first column and row. When entering an NetDDE address, up to 26 characters can be used for the computer name and the reserved name NDDE$, up to 20 characters can be used for the DDEShare name, and up to 79 characters can be used for the item name. If you are trying to access iFIX data from an Excel spreadsheet using NetDDE, you must enclose the Computer Name and NDDE$ keyword, and the DDEShare name in single quotes. For example:
=`\\NODE1\NDDE$'|`DMDATA.DDE'!`SCADA1.AI1.A_CV'

If the Item Name contains a hyphen (-), you must enclose it in single quotes. For example:
=DMDDE|DATA!'NODE1.REPORT-TEST.F_CV'

Using DDE Client Support


DDE client support is available in iFIX. This chapter explains how to configure DDE client support and how to troubleshoot your DDE connections. Refer to the following sections for more details: Understanding DDE Client Support DDE I/O Driver Configuration Using DDE Client Support in the Database Troubleshooting DDE Client Support in the Database

Understanding DDE Client Support


DDE client support allows you to pass data into iFIX for use in the process database. If you want to incorporate DDE data into your process database, you must purchase the DDE I/O Driver. The following figure illustrates how your iFIX DDE client support works with application programs that use Dynamic Data Exchange.

DDE Client Illustration

Using DDE

NOTE: If your source data contains multiple fields, such as spreadsheet data, iFIX only reads data up to the first carriage return and line feed. All other data is not used.

DDE I/O Driver Configuration


To use DDE data in the process database, you must purchase and configure the DDE I/O driver. The DDE I/O driver can be installed as one of your I/O driver selections during software installation. The DDE driver requires the DDE Client Task to function properly. If you add the DDE driver during software installation, and an SCU file exists, the DDE Client Task, DDECLNT.EXE, is not added to the configured task list in the SCU. Once installation is complete, ensure that the DDE Client Task has been added to the configured task list in the SCU. If it does not appear, add the DDE Client Task to your configured task list manually. Refer to the Setting up the Environment manual for instructions on adding a task to the configured task list. Alternatively, you can delete the DDE driver from the SCU and then add it back manually. When you add the DDE driver manually, the DDE Client Task is automatically added for you. For more information on configuring iFIX, refer to the Setting up the Environment manual.

Using DDE Client Support in the Database


iFIX DDE client support allows you to read and write information from another DDE application, a DDE device driver, or another SCADA node using the DDE I/O driver. Because the data is available in the process database, you can incorporate the data into your strategy to: Pass data in chains. Alarm on DDE data. Trend DDE data.

You can enter a DDE address as an I/O address in any I/O-based database block. The data updates on a time-based or exception-based rate depending upon how you configure the scan time in the block. Do not use a one-shot scan time when you are configuring a block to use DDE data. The following example demonstrates how to configure the Hardware Specifications section of an I/Obased block to access DDE information:
Device: DDE Hardware Options: I/O Address: =EXCEL|[FILE.XLS]SHEET1!R1C1 Signal Conditioning:

In this example, the device driver entry (DDE), indicates that the source of the data is a DDE server. The DDE address entered into the I/O Address field requests data from the first row and column of Sheet1 of the Excel workbook, FILE.XLS. Signal conditioning is not performed on DDE data and the Hardware Options field is not used. NOTE: Your operating system's International Number Format must be configured identically in the nodes sharing data. All iFIX applications use this configuration.

Using DDE

For more detailed information on how to configure your database blocks, refer to the Building a SCADA System manual.

Using DDE Client Support in Input Blocks


You can include DDE data in the database using input blocks, such as the Analog Input block. The standard alarming configuration in the blocks can be used to trigger alarms. Because the information is stored in the database, it can be passed in a chain and used to perform both historical and real-time trending.

Using DDE Client Support in Output Blocks


You can write to DDE locations using output blocks, such as the Analog Output block. By addressing the output block, as shown in the previous example, the output is sent to the DDE address when the output block is processed. NOTE: When using Analog Register and Digital Register blocks, you cannot use offsets greater than zero.

Using DDE Client Support in Digital Blocks


Information that is brought into iFIX using the DDE I/O driver is in ASCII format. This can present a problem when using Digital Input blocks since the ASCII version of the block's current value is a userdefinable text string. In order for the value to be properly stored in the database, ensure that the values you use in the DDE server application are the same as the OPEN and CLOSE labels you configured in the destination database block. The Multistate Digital Input block uses OPEN and CLOSE as its defaults for the 0 (zero) and 1 (one) values, respectively.

Sharing Data Between iFIX DDE Databases


Using the DDE I/O driver and your iFIX DDE server, you can transfer data between SCADA nodes. This method automatically updates both databases when information changes, eliminating unnecessary duplicate connections to an I/O device. For example, you can configure two SCADA nodes, NODE1 and NODE2, to share data. Using this configuration, the blocks in NODE2 update when the data updates in NODE1. This allows you to use the same source information from an I/O device in two different databases without creating two separate connections to the I/O device. NOTE: Using your iFIX DDE server, only ASCII fields (A_) can be used to write data. Both ASCII (A_) and Floating Point (F_) fields can be used to read data. For more information on your iFIX DDE server and DDE addressing for iFIX, refer to the iFIX DDE Local Addresses section.

Using DDE

Troubleshooting DDE Client Support in the Database


iFIX provides the following methods for accessing troubleshooting information about your DDE client communication sessions: DDE Client Task Messages DDE Client Task Dialog Box DDE Client Task Items

DDE Client Task Messages


The iFIX DDE Client Task can be configured to display messages on startup and during run-time. Messages generated by the DDE Client Task are sent to all configured message destinations. The DDE Client Task displays the following types of messages: Startup problems. Failure to establish a DDE conversation. Failure to establish a DDE advise loop. Failure to complete an output.

Refer to the Startup Messages and Communication Messages chapters for a complete listing of the messages generated by the DDE Client Task. For more information about configuring message destinations and filtering, refer to the Implementing Alarms and Messages manual. NOTE: iFIX messages are not sent to the Alarm Summary Link. They can be configured to go to a file, a printer, or the Alarm History window. For more information about configuring startup tasks, refer to the Setting up the Environment manual.

DDE Client Task Dialog Box


The DDE Client Task dialog box displays statistical information about your DDE client sessions. This information can be used to: Monitor DDE updates and outputs. Enable and disable DDE client messages. View run-time error messages.

When you maximize the DDE Client Task, the DDE Client Task dialog box appears, as shown in the following figure.

Using DDE

DDE Client Task Dialog Box This dialog box contains several counters and error messages that you can use to troubleshoot your DDE connections. The counters are reset to the number zero (0) or the word None under the following conditions: Starting the DDE Client Task. Reloading the database. Resetting the counters manually using the Reset button.

The following list describes the fields and buttons on the dialog box: Runtime Error displays any problem that caused the DDE Client Task to suspend its operations. Most run-time errors occur during DDE Client Task startup and indicate a resource or memory problem. Conversations DDE conversations are the connections to a DDE server through the application and topic portions of the DDE address. If you are using NetDDE for communication, the application column displays the computer name, and the topic column displays the DDEShare name of the NetDDE address. Active displays the number of currently active DDE conversations. NOTE: If you are using NetDDE to communicate between two iFIX nodes and the DDE server software is not running, the number of active conversations toggles between one

Using DDE

and zero. This value first indicates an active session with local NetDDE. The value then changes to reflect the remote NetDDE conversation status as inactive. Failed displays the number of failed attempts to establish a DDE conversation since the DDE Client Task was started or reset. This number increases if the DDE server is not active, network problems are present, or the topic is bad. Last Error displays the last error that occurred when trying to establish a DDE conversation. Refer to the Communication Messages chapter for a complete listing of the messages that can appear in this field. Advise Loops An advise loop is a connection to an individual item. You may have multiple advise loops within one conversation. Active displays the number of currently active advise loops. Failed displays the number of failed advise loops since the DDE Client Task was started or reset. This number increases if the item is incorrect. Last Error displays the last error that occurred trying to establish an advise loop. Refer to the Communication Messages chapter for a complete listing of the messages that can appear in this field. Outputs Successful displays the number of successful writes from iFIX to the DDE application since the DDE Client Task was started or reset. Failed displays the number of failed writes from iFIX to the DDE application since the DDE Client Task was started or reset. Last Error displays the last output-related error that occurred. Refer to the Communication Messages chapter for a complete listing of the messages that can appear in this field. Buttons Pause/Resume allows you to pause or resume updating all of the counters and errors in the dialog box. When you select Pause, the button toggles to Resume and the counters stop updating. When you select Resume, the button toggles to Pause and the counters update with the additional counts that occurred during the pause. Reset resets all the fields in the dialog box. The counters are set to zero (0) and the last error fields are reset to None. Set Messages On/Off enables or disables the sending of DDE messages to the message destinations. These messages can be used to troubleshoot your DDE connections. See the DDE Client Task Messages section for more information on how to enable messages using the /M command line parameter. Show Advise Loops displays the Active Advise Loops dialog box shown in the following figure.

10

Using DDE

Active Advise Loops Dialog Box This dialog box displays all active advise loops on this node. Each currently active DDE address, or advise loop, is listed. The dialog box also displays the number of updates that have been recorded for each active advise loop in the Exceptions column. Setup allows you to modify the Access Period and Maximum Links configuration parameters for the DDE Client Task. The following dialog box appears when you select Setup.

Setup Dialog Box Maximum Links defines the maximum number of DDE addresses or links that can be active on this node. The default is 100. The valid range of entries is 1 to 10000. A warning message is sent to all configured message destinations when all slots are in use. If this occurs, additional linked blocks do not go on scan or send outputs. NOTE: If you modify the Maximum Links value, you must restart iFIX for the change take effect.

11

Using DDE

Currently in Use displays the number of DDE addresses or links that are currently active in the node. This number can be compared to the number of Maximum Links for optimization purposes. Access Period controls the length of time that advise loops remain active after the last request for data. The access period is defined once for all of the advise loops on the node. The access period is defined by selecting Enable and entering an access time. The default access period is 30 seconds. The valid range of entries is 0 to 172800 seconds. Selecting Disable allows advise loops to remain open indefinitely. The Setup dialog box configuration is saved in the DDE Client Task initialization file, DDECLNT.INI, each time OK is selected. NOTE: Advise loops to blocks with a scan time, such as Analog Input blocks, do not become inactive regardless of the access period. Save to File saves the current counter values, error messages, and active advise loops into a text file. When you select Save to File, the Save As dialog box appears and you can define the filename and path of the text file.

DDE Client Task Items


DDE Client Task Items can be accessed by reading the information into tags. The data can also be used in the database to perform alarming, trending, and calculations. The latest error messages can be read using Text blocks. For more information on using DDE client information in the database, refer to the Using DDE Client Support in the Database section. The following example demonstrates how to build the DDE address syntax for DDE Client Task Items:
=DDECLNT|DIAG!ACTIVE-CONV

where DDECLNT is the Application name, DIAG is the Topic name, and ACTIVE-CONV is the Item name. The following table lists the DDE Client Task Item names. The Application and Topic names are the same for each item. The database block type you would build to include the data in the database and a description of the item are also listed. For more information about each item, refer to the DDE Client Task Dialog Box section. DDE Client Task Items Item Block Type AI AI TX Description

ACTIVE-CONV FAILED-CONV LAST-CONVERROR ACTIVE-ADV

Displays the number of currently active conversations. Displays the number of failed conversations. Displays the last error that occurred while trying to establish a conversation. Displays the number of currently active advise loops.

AI

12

Using DDE

DDE Client Task Items Item Block Type AI TX Description

FAILED-ADV LAST-ADVERROR SUCC-OUTPUT FAILED-OUTPUT LAST-OUTPUTERROR RESET

Displays the number of failed advise loops. Displays the last error that occurred while trying to establish an advise loop. Displays the number of successful writes to a DDE server. Displays the number of failed writes to a DDE server. Displays the last error that occurred while writing to a DDE server. Resets the counters and messages to zero (0) or None when any value is written to the block. Displays the message of any problem that caused the DDE Client to suspend its operations.

AI AI TX

DO

RUNTIMEERROR

TX

Getting Started Using the DDE Server


This chapter describes the DDE Server and how to start creating reports using the DDE Server and any DDE compliant application. Refer to the following sections for more details: Understanding the DDE Server DDE Server Configuration iFIX DDE Addresses Starting DDE

Understanding the DDE Server


The DDE Server allows you to pass real-time and historical data from iFIX to any other DDE compliant application.

13

Using DDE

The following figure illustrates how your iFIX DDE server works with application programs that use Dynamic Data Exchange.

DDE Server Illustration

DDE Server Configuration


To use your iFIX DDE server software, you need to ensure that your PC is set up correctly with the correct versions of software. This section explains how to: Configuring DDE Server Support Configuring NetDDE Server Support

Configuring DDE Server Support


The following software must be installed on your computer to use a DDE client application with the DDE server: Microsoft Windows. DDE-compliant application used to request and receive data from iFIX. iFIX software.

14

Using DDE

Configuring NetDDE Server Support


iFIX supports the NetDDE feature in the Windows 2000 operating system. To configure NetDDE server support on your iFIX node, your operating system's environment must have both a NetDDE server node and a client node. These nodes must contain the following applications: NetDDE Server Node iFIX software iFIX DDE server One or more configured DDEShares NetDDE Client Node DDE-compliant application used to request and receive data from iFIX.

NetDDE addresses use DDEShare names to access a DDE application on a remote server. In order to create a DDEShare on a Windows 2000 node, you need to use the DDEShare utility. This utility lets you create each DDEShare you need by assigning different levels of permissions to the owners you select. When you select a permission (for example, read-access), the owners you have selected are granted that type of permission for the specified DDEShare. For example, assume you create a DDEShare called $TEST. Also assume you assign the owners John and Fred to the share. If you select read-access for these owners, when either John or Fred access the share $TEST, they are granted read-access only. To create a DDEShare and assign permissions: 1. 2. 3. 4. Click the Start button, and click Run. The Run dialog box appears. In the Open field, enter DDESHARE. Click OK. The DDE Share dialog box appears. Click the icon shown below:

DDE Shares Icon The DDE Shares dialog box appears.

15

Using DDE

5.

Click the Add a Share button and complete the DDE Share Properties dialog box as shown below:

DDE Shares Dialog Box NOTE: The values shown in the dialog box above are for real-time data. To set up a DDEShare for historical data, complete the dialog box with the values in column two of the following table. To create a DDEShare for a DDE application running on a server to provide iFIX with data, in this example Excel, complete the dialog box with the values in column three. Once you have created this alias, you can use $NETEXCEL in any of your NetDDE addresses to search for the requested data in SHEET1 of the workbook, FILE.XLS. You must create a different DDE Share name for each Excel sheet and workbook combination that you need to use. Share Name Application Name, Old Style Topic Name, Old Style Application Name, New Style Topic Name, New Style $DMHTR DMDDE HTR DMDDE HTR $NETEXCEL EXCEL [FILE.XLS]SHEET1 EXCEL.SHEET.5 FILE.XLS

16

Using DDE

6. 7. 8. 9.

Click the Permissions button. The DDE Share Name Permissions dialog box appears. Select the users and groups you want to have access to the DDEShare from the Name list. Select the type of access you want the selected users to have from the Type of Access list. Click OK twice.

After you assign permission for each DDEShare you create, you need to set the trust for the share. A trusted share lets an application share data and gives the currently logged-in owner rights to access shared applications. If several operators locally log into the same computer over the course of a day, you need to assign trusted shares for each operator individually. To set the trust for a DDEShare: 1. 2. 3. 4. Click the Start button, and click Run. The Run dialog box appears. In the Open field, enter DDESHARE. Click OK. The DDE Share dialog box appears. Click the icon shown below:

DDE Shares Icon The DDE Shares dialog box appears. 5. 6. Select a share name from the DDE Shares list and click the Trust Share button. Complete the Trusted Share Properties dialog box as shown below:

17

Using DDE

Trusted Share Properties Dialog Box 7. Click the Set button and then click OK.

iFIX DDE Addresses


You can use iFIX data in other DDE client applications whether they reside on the local computer or a remote computer. The following subsections describe: iFIX DDE Local Addresses iFIX NetDDE Addresses

iFIX DDE Local Addresses


DDE addressing syntax is used to transfer data from iFIX to other applications on the same computer. Refer to the following table for the syntax used to transfer real-time data. Real-Time Data Syntax String Part Application (or Service) name Topic name Item name Real-time DMDDE

DATA Node:Tag.Field (A_)

18

Using DDE

Real-Time Data Syntax An example of the syntax used to transfer real-time data is:
=DMDDE|DATA!NODE1.AI1.A_CV

where DMDDE is the Application or Service Name, DATA is the Topic Name, and NODE1.AI1.A_CV is the Item Name. If the Item Name contains a hyphen (-), you must enclose it in single quotes. For example:
=DMDDE|DATA!'NODE1.REPORT-TEST.F_CV'

iFIX NetDDE Addresses


NetDDE addressing is used to access real-time data in iFIX. Refer to the following table for the syntax used to transfer real-time data. NetDDE Real-Time Data Syntax String Part Application (or Service) name Topic name Item name Real-time `\\Server Name\NDDE$'

`$DMDATA.DDE' Node:Tag.Field (A_)

NetDDE Real-Time Data Syntax An example of the syntax used to transfer real-time data is:
=`\\ABC\NDDE$'|`$DMDATA.DDE'!`NODE1.AI1.A_CV'

where ABC is the computer or workstation name, NDDE$ indicates that NetDDE is used, DMDATA is the DDEShare name for real-time data, and NODE1.AI1.A_CV is the Item Name. If the Item Name contains a hyphen (-), you must enclose it in single quotes. For example:
=DMDDE|DATA!'NODE1.REPORT-TEST.F_CV'

19

Using DDE

Starting DDE
After starting iFIX, you can start the DDE server manually. To start the DDE server manually when iFIX is running: 1. 2. Click the Start button, and click Run. The Run dialog box appears. In the Open field, enter the full path to the DMDDE.EXE file. For example, C:\Program Files\GE Fanuc\Proficy iFIX\DMDDE. IMPORTANT: Be aware that DMDDE cannot retrieve data from Proficy Historian. 3. Click OK. The DDE task window opens to indicate that DDE is running.

You can also start the DDE server automatically by adding it to the Configured Tasks list in the SCU. See the Setting up the Environment manual for more information.

Setting the Update Time


DDE automatically updates worksheets every two seconds. You can adjust the worksheet update time from the DDE task window. To change the update time, press the spacebar when the DDE task window is active. The options shown in the following table appear. Update Time Options Press... + To... Increase update speed. Each time you press the + key, the DDE update speed increases by .2 seconds to a minimum update time of every .2 seconds. Decrease update speed. Each time you press the - key, the DDE update speed decreases by .2 seconds to a maximum update time of 40 seconds. w x Minimize or maximize the DDE task window. Exit the DDE program.

The update options above are only valid for the current session. The update time reverts to the 2 second default when you exit or return to DDE again. NOTE: If you are using DDE to perform continuous reads and writes, and some points are not updating, decrease the interval between updates to allow the DDE server task more CPU time.

20

Using DDE

System Messages
The following table describes the system messages and corresponding explanations associated with the DDE server. DDE System Messages Error Code 1150 1209 1212 1213 1314 1608 1620 1624 1750 2005 2302 1620 ?E100 E-1? ERROR:99 Explanation iFIX is not running. Invalid field. Field's value not known or block may be off scan. Invalid field. Invalid field. Network-related problem. Session not established. Cannot find remote node. Session with remote node has been lost. Tag is not defined in the database. Network-related problem. Either waiting for data or node name is not in the network table. Session not established. Cannot find remote node. Invalid node, tag, or field entered, or problem returning data. No communication established with DDE. Invalid node, tag, or field entered, or problem returning data.

21

Using DDE

Startup Messages
The following table describes the messages and corresponding explanations that can occur when starting the DDE Client Task. The error will be displayed in the Runtime Error field and the configured message destinations. DDE Client Startup Messages Message Cannot initialize DDEML Explanation A connection could not be made to the DDEML.DLL file. Either the file does not exist or it is not in the Windows search path. The system ran out of memory trying to set up the conversation list. There are too many tasks running simultaneously. You should shut down a task to free up a timer for the DDE Client task timer.

Cannot create conversation list (Check memory) Out of timer resources

Communication Messages
The following table describes the errors, associated messages, and corresponding explanations associated with the DDE Client task. These messages appear in the Last Error fields on the DDE Client Task dialog box and in the configured message destinations. Communication Messages Message None Cannot establish conversation. Server rejected request. Explanation No communication problems have occurred. If the connection is local, the error indicates that either the server is not running or the topic does not exist. iFIX prompts you to start the server the first time this error is detected. If the connection is through NetDDE, this error may indicate a network problem. Cannot establish conversation, cannot create advise list. The system has run out of memory while the DDE Client Task is attempting to make a connection to a server.

22

Using DDE

Communication Messages Message Cannot establish conversation, cannot add to list. Cannot start advise loop, server rejected request. Cannot start advise loop, cannot add to list. Cannot start advise loop, server rejected data request. Cannot start advise loop, request timed out. Explanation The system has run out of memory while the DDE Client Task is attempting to make a connection to a server.

The conversation with the DDE server has started but there is a problem with the item.

The system has run out of memory while attempting to establish communication. The server rejected the initial request for data made by the client. The advise loop has been successfully established but the server refuses to pass data back to the client. This may indicate the server is overloaded. The server took too long to acknowledge a request by the client to start an advise loop and the client timed out. This indicates the server is temporarily overloaded. The DDE client attempted to execute a command on the server.

Cannot execute command, request timed out. Server is busy. Low on memory.

The server was overloaded while a DDE transaction was attempted. The server was low on memory while a DDE transaction was attempted. The server was low on memory while a DDE transaction was attempted. The user attempted to shut down the DDE Client Task but does not have sufficient security rights to do so. The user must have the Background Task Exit application feature in his user profile in order to shut down the DDE Client Task. The user has entered an invalid character or a value out of range in the Maximum Links field. The valid range is 1 - 1000.

Memory allocation failed. User does not have rights to shut down the DDE Client Task.

Invalid Maximum Links.

23

Using DDE

Communication Messages Message Invalid access period. Explanation The user has entered an invalid character or a value out of range in the Access Period field. The valid range is 0 to 172800 seconds. The system has run out of memory while establishing communication with a server. The system ran out of memory while the user was opening the Active Advise Loops dialog box.

Cannot create I/O list (check memory). Cannot create advise loop list.

24

Index
C configuring DDE server support ..................................... 15 NetDDE server support................................ 15 D DDE................................................................... 1 DDE addresses described........................................................ 3 local ............................................................. 19 overview ........................................................ 3 DDE client support Analog Register block ................................... 7 database ......................................................... 2 described........................................................ 2 Digital Register block .................................... 7 obtaining statistical information about sessions ...................................................... 9 reading and writing information .................... 6 troubleshooting .............................................. 8 using in digital blocks.................................... 7 using in input blocks...................................... 7 using in output blocks.................................... 7 DDE client task items ............................................................ 13 messages ........................................................ 8 DDE database, sharing data............................... 8 DDE I/O driver, configuring.............................. 6 DDE server starting ......................................................... 20 O output blocks, using DDE client support ........... 7 S Setup dialog box ................................................ 9 system messages, DDE server ......................... 21 T troubleshooting, DDE client support ................. 8 U update time, DDE server.................................. 20 DDE server (cont.) update time................................................... 20 DDE server support communication messages ............................ 22 configuration................................................ 15 described ........................................................ 2 startup messages .......................................... 22 system messages .......................................... 21 digital blocks, using DDE client support ........... 7 Dynamic Data Exchange ................................... 1 I I/O driver, DDE ................................................. 6 input blocks........................................................ 7 M messages, DDE client task................................. 8 N NetDDE addresses ........................................................ 4 server configuration ..................................... 15

25

Using DDE

26