0% found this document useful (0 votes)
42 views

Number 118 September 4, 1998

Intouch

Uploaded by

Raul Roque Yujra
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
42 views

Number 118 September 4, 1998

Intouch

Uploaded by

Raul Roque Yujra
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 8

Number 118 September 4, 1998

Copyright 1998 Wonderware Corporation. All Rights Reserved.


Monitoring Communication Between InTouch and a PLC
by Babak Mohseni
There are two ways to monitor the communication status between Wonderware InTouch and a PLC.
The first way is to use the status bits and IOStatus bits, which are built into the I/O Server. The second
way is to create a heartbeat between InTouch and the PLC using the InTouch scripting engine. This Tech
Note describes how to use a combination of both methods to produce the most reliable results.
Note This application is developed with InTouch 7.0, a TI Direct I/O Server, and a Texas Instruments
TI555 PLC. For previous versions of InTouch, use DDE instead of I/O. For different PLC types, use the
proper I/O Server.
The illustration below shows how the status bit, IOStatus bit, and heartbeat monitor the communication
status between InTouch, the I/O Server, and the PLC.

InTouch I/O Server PLC

IOStatus Bit Status Bit

Heartbeat

The status bit is built into the I/O Server. It monitors the communication status between the I/O
Server and the PLC. A status bit is available for each I/O topic that is configured in an I/O Server.
The IOStatus bit is also built into the I/O Server. In the illustration above, it is monitoring the
communication status between InTouch and the I/O Server. It can also monitor the communication
status between two InTouch nodes or between InTouch and another DDE-aware program, such as
Microsoft Excel. Each I/O Access Name that is defined in an InTouch application has its own
IOStatus bit. The value of the bit will be 1 when there is an active conversation or 0 when the
communication is lost.
The heartbeat monitors the communication status between InTouch and the PLC. The heartbeat is
created by writing a script in InTouch.

Procedure
In this example, we have used a Texas Instruments PLC with a TI Direct I/O Server. The application
name and the I/O items will differ depending on what I/O Server is used. Follow these steps to set up the
status bit, IOStatus bit, and heartbeat so that they can monitor the communication status between
InTouch and a PLC.
Step 1 Configuring the Status Bit
1. In WindowMaker, on the Special Menu, select Access Names. Click the Add button and create an
Access Name called TIPLC. Type TIDIR for the Application Name and type TIPLC for the Topic
Name. Click the OK button.

Copyright 1998 Wonderware Corporation. All Rights Reserved.


4 September 1998 Technical Support Tech Note, No. 118 Page 3

2. Next, on the Special menu, select Tagname Dictionary. Click the New button and create an I/O
Discrete tag called status. Set the Access Name to TIPLC and select the box Use Tagname as Item
Name. Configure the tag as shown below.

Step 2 Configuring the IOStatus Bit


1. In WindowMaker, on the Special Menu, select Access Names. Click the Add button and create an
Access Name called Server_Monitor. Type view for the Application Name and type IOStatus for
the Topic Name.

Copyright 1998 Wonderware Corporation. All Rights Reserved.


4 September 1998 Technical Support Tech Note, No. 118 Page 4

2. Next, on the Special menu, select Tagname Dictionary. Click the New button and create an I/O
Discrete tag called IOSTATUS1. Set the Access Name to Server_Monitor. For the Item, type the
name of the conversation you want to monitor. In this example, the item is tiplc.

Note It is possible to create an IOStatus bit for every topic that is defined in the I/O Server. Just
remember to create a new I/O Discrete tag for each topic and then set the Item name to the proper
Access Name that contains that topic in the InTouch application.

Copyright 1998 Wonderware Corporation. All Rights Reserved.


4 September 1998 Technical Support Tech Note, No. 118 Page 5
Step 3 Configuring the Heartbeat
1. In WindowMaker, on the Special menu, select Tagname Dictionary. Click the New button and
create an I/O integer tag called heartbeat. For the item name, use an internal clock in the PLC, such
as STW143 (STW143 is specific to Texas Instruments PLCs).
2. Create a Memory Integer tag called counter.
3. Select Special/Scripts/Data Change Scripts. Create a data change script for the tag heartbeat that
resets counter to zero.

4. Create a data change script for the tag $Second that increments counter by one.

Copyright 1998 Wonderware Corporation. All Rights Reserved.


4 September 1998 Technical Support Tech Note, No. 118 Page 6

5. Create a popup window called plc_fail that contains a simple text message, such as The PLC has
failed.
6. Create a condition script that will make the window plc_fail popup every 3 seconds if the counter
value is greater than ten and the tag status is equal to zero.

Copyright 1998 Wonderware Corporation. All Rights Reserved.


4 September 1998 Technical Support Tech Note, No. 118 Page 7

7. Create another popup window called server_fail that contains a simple text message, such as The
server has failed.
8. Create a condition script that will make the window server_fail pop up every 3 seconds if the counter
value is greater than ten and the tag IOSTATUS1 is equal to zero.

Copyright 1998 Wonderware Corporation. All Rights Reserved.


4 September 1998 Technical Support Tech Note, No. 118 Page 8

After you set up the status bit, IOStatus bit, and the heartbeat according to these steps, one of the popup
windows you created will appear whenever there is communication trouble between InTouch, the PLC,
or the I/O Server.

The Technical Support Tech Note is published occasionally by the Wonderware Technical Support group. Editors: Mari
Fujii and Sabrina Haag; Director, Technical Support: Sheila Kester; Publisher: Wonderware Corporation, 100 Technology
Drive, Irvine CA 92618.
There is also technical information on the Wonderware software products on the Wonderware Technical Services web page
at www.wonderware.com/support, the WonderFax fax-on-demand system at (949) 450-5050, Wonderwares Bulletin Board
Service at (949) 727-0726 and the Wonderware Comprehensive Support Knowledge Base CD. Call Wonderware Technical
Support at (949) 727-3299 or send an e-mail to [email protected] for more information.
Copyright 1998 Wonderware Corporation. All Rights Reserved. Wonderware is a registered trademark of the Wonderware
Corporation in the United States of America and/or other countries. September 4, 1998 Number
118

Copyright 1998 Wonderware Corporation. All Rights Reserved.

You might also like