You are on page 1of 32

Keithley MetraByte DAS-16/1600

I/O Server
User's Guide
Standard Automation & Control LLC
2450 South Shore Blvd., Suite 100
League City, Texas 77573
Tel: (281) 334-3293
Fax: (281) 334-4324
email: standard@stdauto.com
http://www.stdauto.com
The information in this manual is subject to change without notice and does not represent a commitment on the part of Standard Automation &
Control LLC. The software described in this manual is furnished under a license or nondisclosure agreement. This software may be used or
copied only in accordance with the terms of this agreement. No part of this manual may be reproduced or transmitted in any form or by any
means, electronic or mechanical, including photocopying and recording, for any purpose other than the purchaser's personal use without the
written permission of Standard Automation & Control LLC.
Copyright 2000 by Standard Automation & Control LLC
All rights reserved.
All brand names and product names are trademarks or registered trademarks of their respective companies.
Document Number: SA01-020-050700
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
3
Contents
INTRODUCTION ............................................................................................................................... 4
System Requirements and Specifications.................................................................................... 5
Accessing a Remote Item via the Server ..................................................................................... 6
INSTALLATION................................................................................................................................. 7
Installing the Server..................................................................................................................... 7
CONFIGURING THE SERVER.......................................................................................................... 8
CONFIGURE/DEFINE BOARD............................................................................................................... 9
Select a Board Dialog.................................................................................................................. 9
DAS16 Interface Board Configuration Dialog ............................................................................... 9
Programmable I/O Ports............................................................................................................ 11
CONFIGURE/DEFINE TOPIC .............................................................................................................. 12
Select a Topic Dialog................................................................................................................. 12
Topic Description Dialog............................................................................................................ 13
CONFIGURE/SERVER PARAMETERS................................................................................................... 14
DDE Server Setting Dialog ........................................................................................................ 14
CONTROL MENU............................................................................................................................ 15
DEBUG MENU ................................................................................................................................ 15
USING THE SERVER WITH INTOUCH........................................................................................... 16
ITEM (POINT) NAMING................................................................................................................... 20
Analog Inputs ............................................................................................................................ 20
Analog Outputs ......................................................................................................................... 20
Digital I/O.................................................................................................................................. 21
MONITORING THE STATUS OF A DDE CONVERSATION ........................................................... 23
USING DDESTATUS IN INTOUCH ...................................................................................................... 23
USING DDESTATUS IN EXCEL .......................................................................................................... 26
USING EXCEL WITH THE SERVER............................................................................................... 27
READING VALUES FROM THE SERVER INTO EXCEL .............................................................................. 27
WRITING VALUES TO THE I/O SERVER FROM EXCEL ........................................................................... 28
TECHNICAL SUPPORT.................................................................................................................. 30
APPENDIX A - CONFIGURING THE DAS-16/1600 WITH THE EXP-16 MULTIPLEXERS............. 31
INDEX.............................................................................................................................................. 32
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
4
Introduction
The Standard Automation & Control LLC Keithley MetraByte DAS-16/1600 I/O Server is a Microsoft
Windows based application that acts as a communications server allowing other Windows based
programs access to data from MetraByte DAS-16G and DAS-1600 Analog/Digital Interface
Boards. Any Windows based program capable of acting as a DDE aware client may use the Keithley
METRABYTE DAS-16/1600 I/O Server.
DDE
DDE is the acronym for Dynamic Data Exchange. DDE is a communication protocol designed by
Microsoft to allow applications in the Windows environment to send/receive data and instructions
to/from each other. It implements a client-server relationship between two concurrently running
applications. The server application provides the data and accepts requests from any other
application interested in its data. Requesting applications are called clients. Some applications such
as InTouch and Excel can simultaneously be both a client and server.
To obtain data from another application the client program opens a channel to the server application
by specifying two things: the server's application name, and the topic name of interest. Once a
channel is open, items in the topic can be read or written. For example, in the case of Excel, the
application name is "Excel", the topic name is the name of the specific spreadsheet that contains the
data and the item name is the specific cell on the spreadsheet. With InTouch the application name is
"View", the topic name is always the word "tagname" when reading/writing to/from a tagname in the
InTouch database and the item name is a specific tagname in the InTouch Data Dictionary.
When a client application sets up a link to another DDE program, it asks the server application to
advise the client whenever a specific item's value changes. These data links will remain active until
either the client or server terminates the link or the conversation. These links are a very efficient
means of exchanging data because once the link has been established, no communication occurs
until the specified item changes. InTouch uses DDE to communicate with I/O device drivers and
other DDE application programs.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
5
System Requirements and Specifications
Hardware IBM or compatible 386/486 equipped with a minimum of 4MB
RAM. May require more memory to run other Windows programs
simultaneously.
Software Microsoft Windows 95/98 or Windows NT.
Computer Interface MetraByte DAS-16G and/or DAS-1600 board installed in PC.
Protocol The Server reads and writes directly to the board using port
addresses.
Polling Rates Minimum polling interval of 55 milliseconds.
Maximum Connections Number of boards that can fit into the PC (available slots).
Devices Supported MetraByte DAS-16G1 and DAS-16G2 Interface Boards
MetraByte DAS-1601 and DAS-1602 Interface Boards
MetraByte multiplexer, when used with one of the above Interface
Boards
Accessible Data Types Without Multiplexer
16 Analog Inputs, 2 Analog Outputs, 4 Digital Inputs, 4 Digital
Outputs, additional 24 Digital I/O on DAS-1600s.
With Multiplexer
Increase Analogs up to 128 Inputs, 16 per multiplexer.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
6
Accessing a Remote Item via the Server
The DDE protocol identifies an element of data by using a three-part naming convention that includes
the application name, topic name and item name. The following briefly describes each portion of the
DDE Address:
Application Name Refers to the name of the Windows program (server) that knows how to
access the data element. In the case of data coming from or going to the
board, the application portion of the DDE address is DAS16.
Topic Name Used by the Server to identify a specific board. The operator creates
meaningful names for the board and uses these names as the topic
names for DDE conversations; e.g., Board1.
Note: To poll different points at different rates, multiple topic names can
be defined for the same device.
Item Name Indicates a specific data element within the specified topic. For the DAS-
16 I/O Server, an item is an individual digital or analog point.
Note: The item/point names are defined by the DAS-16 I/O Server as described in the Item/Point
Naming section of this manual. The term "point" is used interchangeably with the term "item" in this
manual.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
7
Installation
Note: The Server installation requires a reboot. It is recommended that all applications be terminated
prior to installing the Server.
Installing the Standard Automation security key (Dongle)
The Server requires that Standard Automation's hardware key be connected to the parallel port in
order to operate.
Installing the Server
The Server is installed by running the Setup.exe program from the Standard Automation Products CD as follows:
1. Insert the CD and navigate to the product you wish to install.
2. Select the Full or Demo options and activate the Install button. The Welcome dialog will appears.
3. Follow the directions to complete the installation.
Aborting the Installation
Selecting the Cancel button on any installation dialog aborts the installation and activates the
following dialog.
Select the Exit Setup button to end the installation program without installing the Server. Select the
Resume button to continue the installation program where it was interrupted.
Uninstalling the Application
1. Select Start/Settings/Control Panel.
2. Select the Add/Remove Program icon.
3. Select the Server listing.
4. Select the Add/Remove button activating the Uninstall Wizard.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
8
Configuring the Server
The DAS-16 I/O Server requires some configuration before use. The configuration consists of
defining the MetraByte boards, and definition of the topics and server parameters.
The Server must be running to perform the required configuration. Start the server by selecting the
Start/Programs/Standard Automation Products/MetraByte DAS 16 I/O Server command.
The Configure menu includes the following options:
Define Board
Topic Command
Server Parameters.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
9
Configure/Define Board
The user must define a logical board in the configuration to allow the Server to communicate with the
MetraByte Board in the PC. This is accomplished by selecting Configure/Define Board option. When
selected the Select a Board dialog appears.
Select a Board Dialog
The Select a Board dialog allows interface boards to be added, modified and deleted.
OK Activates the DAS16 Interface Board Configuration dialog for the selected board.
Cancel Closes the dialog.
New Activates the DAS16 Interface Board Configuration dialog allowing a new board to
be added.
Modify Activates the DAS16 Interface Board Configuration dialog allowing a board to be
modified.
Delete Deletes the selected board.
DAS16 Interface Board Configuration Dialog
The DAS16 Interface Board Configuration dialog is activated by selecting the OK, New or Modify
buttons from the Select a Board dialog. The dialog allows the interface board parameters to be
defined.
The default board name is DAS16/1. This can be changed, if so desired, by renaming it. The dialog
may appear differently than shown above depending on the Board Type chosen. The following
describes each field within the Board Configuration dialog.
Logical Board Name Name describing the logical board.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
10
Board Base I/O
Address
This corresponds to the Base Address set on the MetraByte Board. It
is entered as a hexadecimal number between the values of 200h and
3F0h. This address must match the address set by the 8 position DIP
switch on the MetraByte Board. This address allows the Server to
map to the registers on the board for communication.
Board Type Select the button for the Board Type that is being used at the address
entered as the Base Address. DAS16G includes the DAS16G1 and
DAS16G2 boards. DAS1600 includes the DAS1601 and DAS1602
boards. If DAS1600 is chosen, configuration boxes for the PIO ports
appear.
Analog Inputs Select the button that represents the number of analog inputs that the
board is configured to use. The analog input mode for the board can
be one of two settings: 8 Differential allowing 8 analog inputs, or 16
Single-Ended allowing 16 analog inputs into the board (each input
actually represented by the difference between two physical analog
signals, hence the name). The input mode is selected by a switch on
the board. On the DAS16G, the switch is labeled SYS CONFIG. On
the DAS1600, it is labeled CHAN. Activating the OK button verifies
that the switch setting matches the configuration.
Programmable Gain
Setting
All boards supported by this server have software programmable AI
gains. Select the desired gain setting under the heading of the board
type being used.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
11
Programmable I/O Ports
If the Board Type chosen is the DAS1600, the PIO ports need to be configured. The dialog will now
included the Port information displayed on the right side of the dialog.
There are three PIO Ports on the DAS1600 MetraByte Board located on the auxiliary PIO connector,
each containing 8 digital I/O. Each Port can be configured as either an output Port or an input Port.
Port C can be divided up into two 4 digital I/O ports. Simply select the radio button that expresses the
desired configuration.
Select OK to save and exit. To exit without saving select Cancel. If the configuration file is not found
in the directory specified in the Configure Server Parameters dialog, the Saving DAS16 Configuration
dialog is displayed.
Select the Save button to save the current configuration in the Path displayed or enter a new Path.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
12
Configure/Define Topic
The user must define the Topics that will be used in a DDE conversation to obtain data from the
MetraByte Board. A separate topic is required for each Board installed on the PC.
If multiple poll rates are desired, a separate topic for each poll rate is needed. Also, multiplexers are
being used, a topic for each multiplexer is required. To define a Topic, select the Configure/Define
Topic command activating the Select a Topic dialog.
Select a Topic Dialog
The Select a Topic dialog is activated using the Configure/Define Topic command. This dialog allows
topics to be added, modified and deleted.
OK Activates the Topic Description dialog for the selected topic.
Cancel Closes the dialog.
New Activates the Topic Description dialog allowing a new topic to be defined.
Modify Activates the Topic Description dialog for the selected topic.
Delete Deletes the selected topic.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
13
Topic Description Dialog
Selecting the OK, New or Modify buttons from the Select a Topic dialog activate the Topic
Description dialog. The Topic Description dialog is used to define topic parameters.
Topic Name Specifies the Topic Name. The topic name is arbitrary but should be
something meaningful to the application. It must start with an alphabetic
character and cannot contain spaces. The Topic Name is referenced later
when configuring InTouch to communicate with the DAS-16/1600 Server.
Select Board Activates the Select a Board dialog allowing a board to be selected. Each
Topic must be associated with a MetraByte board installed on the PC so
that the server will get requested data from the correct source.
Mux At least one topic must be defined for each board installed in your PC and
at least one for each multiplexer attached to that board. If the topic being
defined will be used to read data from the AIs on the boards main I/O port,
select the button None.
If defining a topic for an attached multiplexer, select the button
corresponding to the AI channel that the multiplexer is configured to use.
Note: If you use an attached multiplexer, configure the MetraByte board to
use 16 Single Ended Analog Inputs.
Update Interval Specifies the scan frequency, in milliseconds, that data will be read from
the MetraByte Board and updated in InTouch. The fastest guaranteed poll
rate is 55 msec.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
14
Configure/Server Parameters
In addition to defining the communications port and creating topics, some of the internal driver
parameters may be changed. The default settings for these parameters provide good performance
and normally do not need to be changed. This is accomplished using the DDE Server Settings
dialog.
DDE Server Setting Dialog
The DDE Server Settings dialog is activated using the Configure/Server Parameters command. The
dialog allows server parameters to be viewed and defined.
Protocol Timer Tick Specifies how often the server checks to poll or send data to the
MetraByte Board. This time expressed in msec should be 2 to 4 times
the desired update time.
NetDDE being used Select if accessing this Server over the network via NetDDE. This will
optimize the internal Server parameters for this type of access.
Configuration File
Directory
Specifies the location on the hard disk (path) where the DAS-16/1600
configuration file will be stored.
Once all entries have been made, select the OK button.
If you make changes to the server parameters, the server application must be restarted in order for
the changes to take effect.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
15
Control Menu
This menu is used to Suspend or Resume the polling process of the server.
Debug Menu
This menu is used to select the degree of information that will be logged to the Wonderware Logger.
Unless problems are occurring, the options that log to the Wonderware Logger should not be
selected.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
16
Using the Server with InTouch
InTouch can access items/points in the MetraByte Board by creating tagnames in its Tagname Data
Dictionary and associating those tagnames with an Access Name containing the topic name defined
in the Server for the board. To define a tagname type perform the following procedure:
Start up WindowMaker and invoke the Special/Tagname Dictionary... command to access the
Tagname Dictionary dialog.
Note: If this is the first time the database has been accessed, the definition for the internal system
tagname $AccessLevel will be displayed. Once a tagname has been defined and the Data Dictionary
is reaccessed, the data on file for the previously accessed tagname will automatically be displayed
when the dialog appears.
Select the New button to define a new tagname.
Enter the name to be defined, in the tagname field, for the item in the database. Tagnames can be
up to 32 characters long and the first character must be A-Z or a-z and can be followed with A-Z, a-z,
0-9, !, @, -. ?, #, $, %, _ and &.
Select the Type button to select the I/O type for the tagname. The Tag Types dialog will appear:
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
17
Select the appropriate I/O type for the item being defined. The following describes each I/O type:
I/O Discrete Discrete input/output tagname with a value of either 0 (False, Off) or 1
(True, On).
I/O Integer A 32-bit signed integer value between -2,147,483,648 and 2,147,483,647.
I/O Real Floating (decimal) point memory tagname. The floating point value may
be between +3.4e
38
. All floating point calculations are performed with 64-
bit resolution, but the result is stored in 32-bit.
I/O Message Text string input/output tagname that can be up to 131 characters long.
Once the I/O tag type is selected, the Choose tag type dialog will automatically be removed from the
screen and the Tagname Dictionary dialog will reappear along with the "Details" dialog for the I/O
type selected:
Note: If the "Details" dialog does not appear, select the "Details" radio button at the top of the
screen.
Enter all required details for defining the item. For integers and reals fill in the Min EU, Max EU, Min
Raw and Max Raw fields. These fields control the range of values that will be accepted from the
Server and how the values are scaled. If no scaling is desired, Min EU should be equal to Min Raw
and Max EU should be equal to Max Raw.
Select the Access Name button to define an Access Name for the application and topic to/from that
the I/O tagname will read/write its value. The Access Names dialog will appear.
Select the Add button to define a new Access Name. The Access Name Definition dialog will
appear as shown below.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
18
Once Access Names have been defined, they will appear in the Access Names dialog. To change
an existing Access Name definition select the name and activate the Modify button. The Modify
Access Name dialog will appear:
Access Name A shorthand nickname for an Application Name/Topic Name
pair. This field in the editing dialog must contain a unique Access
Name that is later referenced when creating tagname dictionary
entries.
Node Name Computer name.
Application Name The MetraByte Server application name, always enter DAS16.
Topic Name The name of the Topic Name selected in the Server configuration.
Note that upper and lower case letters in the Topic Name must
match the Topic name selected in the Server configuration.
Which Protocol to Use Select either DDE or SuiteLink.
When to Advise Server The Advise all items option causes the Server to scan all
configured data for this topic. The Advise only active items
causes the MetraByte Server to only scan data in visible windows
and points that are alarmed, logged, trended, or are referenced in
scripts.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
19
The final step in defining an item is entering the item name for the item/point in the board in the Item
field.
Note: It is important to understand that the Tagname is the name used within InTouch to refer to a
data value. The Item Name is the name used by the Server to get the value from the board.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
20
Item (Point) Naming
The METRABYTE Server supports I/O Discrete, I/O Integer, and I/O Real datatypes. The following
Item Names will be used as the Item: when defining a tagname in InTouch.
Analog Inputs
I/O Integer or I/O Real tag type. The value returned by the DAS16 server is the Raw A/D conversion
value. You will need to scale this value to the required Engineering Units when defining the tag in
InTouch. If the Topic associated with the Item you are defining is a topic for a multiplexer, the value
returned will be the value of the AI channel on the multiplexer.
The Item Name syntax for an AI is the channel number in decimal:
Channel #
Examples:
3 AI Channel 3
0 AI Channel 0
15 AI Channel 15
Analog Outputs
I/O Integer or I/O Real tag type. The value received by the DAS16 server should be the Raw D/A
conversion value. You will need to scale this value to the required Engineering Units when defining
the tag in InTouch. The tags that you define with this Item Name type should only be associated with
I/O Topics that were defined as No Multiplexing.
The Item Name syntax for an AO is:
DA[Channel #]
1. The first two characters must be 'DA' in either upper of lower case.
2. The third character is the channel number (0 or 1)
Examples:
DA0 AO Channel 0
da0 AO Channel 0
DA1 AO Channel 1
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
21
Digital I/O
I/O Discrete tag type.
Digital I/O on Main I/O Connector
The Item Name syntax for Digital Inputs is:
DI:[bit #]
The first three characters must be DI: in either upper or lower case.
The fourth character is the bit number in decimal (0 to 3).
Examples:
DI:0 Digital Input 0
di:2 Digital Input 2
The Item Name syntax for Digital Outputs is:
DO:[bit #]
The first three characters must be DO: in either upper or lower case.
The fourth character is the bit number in decimal (0 to 3).
Note: When using multiplexers, the four Digital Outputs on the Main I/O Connector are used to
control the channels on the multiplexers. Do not use these Item Names if you are using multiplexers.
Examples:
DO:0 Digital Output 0
do:2 Digital Output 2
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
22
Digital I/O on auxiliary PIO Connector (DAS1600 boards only)
The Item Name syntax for PIO Digital I/O is:
P[port]:[bit #]
1. The first character must be P in either upper or lower case.
2. The second character is the PIO Port (A, B, or C). May be upper or lower case.
3. The third character is a delimiter. Allowed delimiters ( :, /, - ).
4. The fourth character is the bit number in decimal (0 to 7).
Examples:
PA:3 PIO Port A, bit 3
PB:0 PIO Port B, bit 0
pc/7 PIO Port C, bit 7
Remember: Each PIO port is software configured as either Input or Output.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
23
Monitoring the Status of a DDE Conversation
WindowViewer supports a built-in topic name called DDEStatus that can be used to monitor the status
of specific DDE conversations. For example, let's assume that WindowViewer (VIEW) is
communicating with the MetraByte I/O Server to a board that has been defined in the Server with
Board1 for its topic name.
Using DDEStatus in InTouch
To monitor the status of communication between WindowViewer and the MetraByte topic Board1, the
following steps would be taken:
1. Create an I/O Discrete Tagname. For simplicity, use the same name as the topic name to be
monitored.
2. Associate our tagname with an Access Name that uses DDEStatus for the topic name. To do so,
select the Access Name... button to access the initial Access Name Definition dialog:
3. Notice that an Access Name definition named Board1 (the topic we want to monitor) currently
exists. To be sure that this is the correct Access Name (its topic name is Board1), select the
Modify... button to view it:
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
24
Note: Finding the Access Name definition containing the right topic name in this example was fairly
simple because all of the names were kept the same. This is the reason it is recommend that the
same names be used whenever possible.
4. Select the Cancel button to close the dialog and return to the initial Access Name Definition
dialog. Activate the Add... button. The Add Access Name dialog will appear.
5. For simplicity, use DDEStatus, for the Access Name. Since we are going to monitor the status in
WindowViewer, we will use VIEW for our application name and the built-in topic, DDEStatus, for
our topic name. Next, enable the Wait for change and Advise only active items options and
select the OK button to close the dialog. The initial Access Name Definition dialog will reappear
displaying the name of our new definition preselected in the list:
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
25
6. Select the Done button to close the dialog and associate the new definition with our I/O Discrete
tagname:
7. The last step is to enter the actual topic name that we want to monitor for the item, in this case,
Board1. Since our tagname is the same as the topic, select the Use Tagname as Item Name
option and the Item will be automatically entered. Once again showing that by using the same
names whenever possible, we can simplify many steps.
Note: When using the built-in topic DDEStatus to monitor a DDE conversation, the name defined for
the Access Name definition is always used as the Item.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
26
Using DDEStatus in Excel
Excel can also be used to perform this same monitoring by entering the same information in a
formula in a cell on a spreadsheet. For example, to monitor the same topic as above, the following
would be entered:
=VIEW|DDEStatus!Board1
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
27
Using Excel with the Server
Data from topics may be accessed from Excel spreadsheets. To do so, enter a formula like the
following into a cell on the spreadsheet:
=|TopicName!ItemName
In some cases, Excel requires the topic or item to be surrounded by apostrophes.
In the formula, topic is replaced with one of the valid topic names defined during the Server
configuration process. Item is one of the valid item/point names described in the Item (Point) Naming
section.
Reading Values from the Server into Excel
Values may be read directly into Excel spreadsheets from the I/O Server by entering a DDE formula
into a cell using the following format:
=applicationname|topicname!itemname
Example formula:
=DAS16|'Board1'!'3'
where:
DAS16 The application name, which is the executable name of the Server (less the
.exe).
Board1 The exact topic name defined in the I/O Server for the device.
3 The actual location in the device that contains the data value. This is the item
name.
In this example, each time the value of D0 changes in the device, the I/O Server will automatically
send the new value to the cell containing the formula in Excel.
Note: Refer to the Microsoft Excel manual for complete details on entering Remote Reference
formulas for cells
Values may also be read into Excel spreadsheets from the I/O Server by using the DDEREQUEST
method in an Excel macro:
Sub DemoDDE()
channelNumber = Application.DDEInitiate(app:="ApplicationName",
topic:="TopicName")
returnValue = Application.DDERequest(channelNumber, "ItemName")
Worksheets("Sheet1").Cells(1, 1).Formula = returnValue(1)
Application.DDETerminate channelNumber
End Sub
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
28
The following describes each of the above DemoDDE macro statements:
channelNumber = Application.DDEInitiate(app:="ApplicaitonName",
topic:="TopicName")
Opens a DDE channel to a specific topic name (defined in the I/O Server) in a particular application
name (DDE executable name less the .EXE) and assigns the number of that opened DDE channel to
channelNumber.
returnValue = Application.DDERequest(channelNumber, "ItemName")
Gets the value of ItemName from the application and topic specified in the previous DDEInitiate
method and places it in the variable returnValue.
Worksheets("Sheet1").Cells(1, 1).Formula = returnValue(1)
Places the value in returnValue into the first cell in Sheet1.
Application.DDETerminate channelNumber
Closes the DDE channel at the end of the macro. Some applications have a limited number of
channels therefore, they should be closed when finished. channelNumber is the channel number
returned by the previously executed INITIATE method.
Writing Values to the I/O Server from Excel
Values may be written to the I/O Server from Microsoft Excel by creating an Excel macro that uses
the DDEPOKE method. The proper code is entered in Excel as follows:
Sub DemoDDE()
channelNumber = Application.DDEInitiate(app:="ApplicaitonName",
topic:="TopicName")
Set rangeToPoke = Worksheets("Sheet1").Range("A1")
Application.DDEPoke channelNumber, "ItemName", rangeToPoke
Application.DDETerminate channelNumber
End Sub
The following describes each of the above DemoDDE macro statements:
channelNumber = Application.DDEInitiate(app:="ApplicaitonName",
topic:="TopicName")
Opens a DDE channel to a specific topic name (defined in the I/O Server) in a particular application
name (DDE executable name less the .EXE) and assigns the number of that opened DDE channel to
channelNumber.
Set rangeToPoke = Worksheets("Sheet1").Range("A1")
Places the range of values to be poked into the variable rangeToPoke. Sheet1 is the name of the
worksheet, A1 is the cell range containing the values.
Application.DDEPoke channelNumber, "ItemName", rangeToPoke
POKEs the value contained in rangeToPoke to the specified item name (actual location in the device)
via the channelNumber returned by the previously executed INITIATE method.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
29
Application.DDETerminate channelNumber
Closes the DDE channel at the end of the macro. Some applications have a limited number of
channels therefore they should be closed when finished. channelNumber is the channel number
returned by the previously executed INITIATE method.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
30
Technical Support
Prior to contacting technical support, please refer to the relevant documentation for a possible
solution to the problem. If it is necessary to contact technical support for assistance, please have the
following information available:
1. The version of the server that is operating.
2. The type and version of the operating system you are using. For example, Microsoft Windows NT
Version 4.0 workstation.
3. The exact wording of system error message encountered.
4. Any relevant output listing from the Wonderware Logger, the Microsoft Diagnostic utility (MSD),
or any other diagnostic applications.
5. Details and results of the attempts to solve the problem.
6. Details of how to recreate the problem.
Standard Automation Technical Support can be reached in the following ways:
Telephone 281-334-3293
Fax 281-334-4324
Email Support@stdauto.com
Internet www.stdauto.com
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
31
APPENDIX A - Configuring the DAS-16/1600 with the EXP-
16 Multiplexers
This supplemental section assumes the reader is familiar with the basic features of the MetraByte
EXP-16 multiplexer. Complete documentation of the MetraByte EXP-16 multiplexer is available from
Keithley Instruments, Inc., titled "User Guide for the Keithley MetraByte EXP-16 & EXP-16A
Expansion Multiplexer/Amplifier System".
When using the DAS-16/1600 with one or more EXP-16s, 16 singled-ended analog input mode must
be enabled. Note that each EXP-16 Multiplexer configured to the DAS-16/1600 will require one of the
analog inputs dedicated to it. The particular analog input dedicated will be any of analog input
channels 0-7, corresponding to the output channel selection 0-7 made on the EXP-16. Up to 8 EXP-
16s can be attached to a DAS-16/1600, with the resulting configuration requiring the dedication of the
first 8 analog channels of the DAS-16/1600. Each EXP-16 attached to the DAS-16/1600 can be
accessed by configuring a Topic with a Mux Channel selected that matches the output channel
jumpered on that EXP-16. Each EXP-16 and Topic can then support up to 16 analog inputs which are
multiplexed on the dedicated DAS-16/1600 analog input. Again mentioned, this dedicated DAS-
16/1600 analog input corresponds to the EXP-16 output channel jumpered. Note that although an
EXP-16 can support additional analog inputs for use, these provided analog inputs may not be
suitable for high speed operations due to the additional delays inherent in multiplexing analog inputs
on the dedicated DAS-16/1600 analog input. For high performance analog input sampling, a Topic
should be created using the "None" Mux Channel option and analog inputs wired directly into the
DAS-16/1600 using analog input channels 8-15 and any of the analog input channels of 0-7 that are
not dedicated to an EXP-16.
Note: This software should be compatible with all MetraByte multiplexers that use the four Digital
Outputs on the Main I/O Connector as the channel selection control. As of this writing, not all
multiplexers have been tested using this software.
MetraByte DAS-16/1600 I/O Server
Standard Automation & Control LLC May 2000
32
Index
A
Analog Inputs, 20
Analog Outputs, 20
Application Name, 6
C
Configure
Define Board, 9
Define Topic, 12
Server Parameters, 14
Control Menu, 15
D
DAS16 Interface Board Configuration Dialog, 9
DDE, 4
DDE Conversation
Monitoring the Status, 23
DDE Server Setting Dialog, 14
Debug Menu, 15
Digital I/O, 21
Digital I/O on auxiliary PIO Connector, 22
Digital I/O on Main I/O Connector, 21
Dongle, 7
Dynamic Data Exchange, 4
I
Installation, 7
InTouch
Using DDEStatus, 23
Using the Server with, 16
Item (Point) Naming, 20
Item Name, 6
P
Programmable I/O Ports, 11
R
Reading Values from the Server into Excel, 27
Remote Item
Accessing via the Server, 6
S
Security key, 7
Select a Board Dialog, 9
Select a Topic Dialog, 12
Server
Configuring, 8
System Requirements and Specifications, 5
T
Technical Support, 30
Topic Description Dialog, 13
Topic Name, 6
U
Using DDEStatus in Excel, 26
Using Excel with the Server, 27
W
Writing Values to the I/O Server from Excel, 28

You might also like