Remote access to the WAGO Ethernet controller/coupler using an

WLAN Access to the
WAGO Ethernet Controller
Using an iPod Touch
Application Note
Last Update: 30.03.11
2•
General
Copyright  2011 by WAGO Kontakttechnik GmbH
All rights reserved.
WAGO Kontakttechnik GmbH
Hansastraße 27
D-32423 Minden
Phone: +49 (0) 571/8 87 – 0
Fax:
+49 (0) 571/8 87 – 1 69
E-mail: [email protected]
Web:
http://www.wago.com
Technical Support
Phone: +49 (0) 571/8 87 – 7 77
Fax: +49 (0) 571/8 87 – 87 77
E-mail: [email protected]
Every conceivable measure has been taken to ensure the accuracy and completeness of this documentation. However, as errors can never be fully excluded, we always appreciate any information or suggestions for improving
the documentation.
We wish to point out that the software and hardware names, as well as the
trademarks of companies used and/or mentioned in the present manual, are
generally protected by trademark or patent law.
Application Note
Contents
•3
TABLE OF CONTENTS
1 Important Notes ......................................................................................... 4
1.1
Legal Principles ..................................................................................... 4
1.1.1 Copyright ............................................................................................... 4
1.1.2 Personnel Qualification.......................................................................... 4
1.1.3 Intended Use .......................................................................................... 4
1.2
Scope of Validity ................................................................................... 5
1.3
Symbols ................................................................................................. 5
2
Description.................................................................................................. 6
3
Material....................................................................................................... 6
4
Set-Up.......................................................................................................... 7
5 Program Description ................................................................................. 8
5.1
CoDeSys Program.................................................................................. 8
5.2
Determining the MODBUS Addresses.................................................. 8
5.3
Visualization Interface......................................................................... 10
6 iPod Configuration .................................................................................. 11
6.1
WLAN Settings.................................................................................... 11
6.2
ScadaMobile App ................................................................................ 12
6.3
Communication Settings...................................................................... 13
6.4
Processing the Configuration File ....................................................... 13
6.5
Operating Interface .............................................................................. 15
6.6
Access to Multiple Controllers ............................................................ 16
7 Appendix................................................................................................... 17
7.1
Required Files for WAGO-I/O-PRO CAA.......................................... 17
Application Note
4 • Important Notes
1
Important Notes
To ensure quick installation and start-up of the units, please carefully read and
adhere to the following information and explanations.
1.1 Legal Principles
1.1.1 Copyright
This document, including all figures and illustrations contained therein, is subject to copyright protection. Any use of this document that infringes upon the
copyright provisions stipulated herein is prohibited. Reproduction, translation,
electronic and phototechnical filing/archiving (e.g., photocopying) as well as
any amendments require the written consent of WAGO Kontakttechnik
GmbH, Minden, Germany. Non-observance will involve the right to assert
damage claims.
WAGO Kontakttechnik GmbH reserves the right to enact changes that serve
technical progress.
WAGO Kontakttechnik GmbH owns all rights arising from the granting of
patents or from the legal protection of utility patents. Third-party products are
always mentioned without any reference to patent rights. Thus, the existence
of such rights cannot be excluded.
1.1.2 Personnel Qualification
The use of the product detailed in this document is geared exclusively to specialists having qualifications in PLC programming, electrical specialists or
persons instructed by electrical specialists who are also familiar with the valid
standards. WAGO Kontakttechnik GmbH assumes no liability resulting from
improper action and damage to WAGO products and third-party products due
the disregard of the information contained in this document.
1.1.3 Intended Use
For each individual application, the components are supplied from the factory
with a dedicated hardware and software configuration. Modifications are only
admitted within the framework of the possibilities documented in this document. WAGO Kontakttechnik GmbH will be exempted from any liability in
case of changes in hardware or software as well as to non-compliant usage of
components.
Please send your requests for modified and new hardware or software configurations directly to WAGO Kontakttechnik GmbH.
Application Note
Important Notes
1.2
•5
Scope of Validity
This application note is based on the stated hardware and software from the
specific manufacturer, as well as the associated documentation. This application note is therefore only valid for the described installation.
New hardware and software versions may need to be handled differently.
Please note the detailed description in the specific manuals.
1.3 Symbols
DANGER
Always observe this information to protect persons from injury.
NOTICE
Always observe this information to prevent damage to the device.
NOTE
Boundary conditions that must always be observed to ensure smooth operation.
Note
Routines or advice for efficient use of a device and software optimization.
Additional Information
References to additional literature, manuals, data sheets and INTERNET
pages.
Application Note
6 • Description
2
Description
This application note describes the basic procedures for access to the WAGO
Ethernet Controller 750-8xx or the WAGO Ethernet Coupler 750-3xx using an
iPod Touch. An iPhone can also be used as an alternative.
The connection is established using a WLAN access point. The protocol used
is MODBUS TCP.
3
Material
Supplier
Qty.
Designation
Item No.
WAGO
1
Programmable fieldbus controller
750-8xx
WAGO
1
Digital input module
750-402
WAGO
1
Digital output module
750-504
WAGO
1
End terminal block
750-600
-
1
iPod Touch
-
1
WLAN access point
-
1
Switch + Patch cable
The following software is also required for programming and commissioning:
WAGO
WAGO-I/O-PRO CAA
759-333
SweetWilliam ScadaMobile or ScadaMobile Lite
Additional Information:
The libraries and documentation used are available at www.wago.com
/Service/Downloads/Libraries
Additional Information:
Information about the different versions, manuals, and the required CSV file
templates is available at http://www.sweetwilliamautomation.com/
Application Note
Set-Up
4
•7
Set-Up
Illus. 4.1: Network set-up
The controllers are connected to a WLAN access point. The network settings
must be adapted from the access point to the controller's IP addresses (see
illus. 4.1).
Note:
The set-up described is only one example. The set-up can be expanded as
required by the respective application.
Application Note
8 • Program Description
5
Program Description
5.1 CoDeSys Program
Illustration 5.1 shows the set-up of an example program in the CoDeSys software.
Illus. 5.1: CoDeSys program
The declared variables are distinguished according to bit and register access
and are referenced at the corresponding flag addresses. These flags can then
be read and described using corresponding MODBUS addresses.
5.2 Determining the MODBUS Addresses
The MODBUS addresses for bit and register access, which are a function of
communication direction, are listed in the following tables.
Note
The included tables show only an excerpt of the MODBUS communication
addresses. The complete tables are available in the manuals for the controller
and coupler in the chapter “MODBUS Access Mapping”.
Application Note
Program Description
Bit Read Access
MODBUS address
[dez]
[hex]
Memory area
Description
0...511
512...1023
4096...8191
0x0000...0x01FF Physical input area (1) First 512 digital inputs
0x0200...0x03FF Physical output area (1) First 512 digital outputs
0x1000...0x1FFF %QX256.0...%QX511.15 PFC-OUT-Area
Volatile PLC output variables
12288...32767 0x3000...0x7FFF %MX0...%MX1279.15 Flag area
Pos: 116.23/All series (general modules)/Fieldbus communication/MODBUS/MODBUS register mapping - bit write access (using FC5, FC15) (Controller, x41) @ 3\mod_1235398841703_6.doc @ 27594 @
Bit Write Access
MODBUS address
[dez]
[hex]
Memory area
Description
512...1023 0x0200...0x03FF Physical output area (1) First 512 digital outputs
8192...12287 0x2000...0x2FFF %IX256.0...%IX511.15 PFC-IN-Area
Volatile PLC input variables
12288...32767 0x3000...0x7FFF %MX0...%MX1279.15 Flag area
Register Read Access
MODBUS address
[dez]
[hex]
IEC-61131address
Memory area
0...255
256...511
0x0000...0x00FF
%IW0...%IW255
Physical input area (1)
0x0100...0x01FF %QW256...%QW511 PFC-OUT-Area
Volatile PLC output variables
512...767
0x0200...0x02FF
%QW0...%QW255 Physical output area (1)
12288...24575 0x3000...0x5FFF %MW0...%MW12287 Flag area
Pos: 116.20 / All series (general modules)/Fieldbus communication /MODBUS register mapping - register access (using FC6, FC16, FC22, FC23) (Controller, x41) @ 3\mod_1235392386281_6.doc @ 27579 @
Register Write Access
MODBUS address
[dez]
[hex]
512...767
768...1023
Pos: 116.22/All series (general modules)/Fieldbus communication/MODBUS/MODBUS register mapping - bit read access (using FC1, FC2) (Controller, x41) @ 3\mod_1235394387921_6.doc @ 27586 @
Pos: 116.21/All series (general modules) Fieldbus communication/MODBUS/MODBUS register mapping - section Coil services, bit access @ 3\mod_125393917265_6.doc @ 27582 @@
Pos: 116.22/All series (general modules)/Fieldbus communication/MODBUS/MODBUS register mapping - bit read access (using FC1, FC2) (Controller, x41) @ 3\mod_1235394387921_6.doc @ 27586 @
Application Note
%QW0...%QW255
%IW256...%IW511
Memory area
Physical output area (1)
PFC-IN-Area
Volatile PLC input variables
12288...24575 0x3000...0x5FFF %MW0...%MW12287 Flag area
Pos: 116.21/All series (general modules) Fieldbus communication/MODBUS/MODBUS register mapping - section Coil services, bit access @ 3\mod_125393917265_6.doc @ 27582 @@
0x0200...0x02FF
0x0300...0x03FF
IEC-61131address
•9
10 • Program Description
5.3 Visualization Interface
The declared variables are changed or displayed using elements in the visualization interface (see illus. 5.2).
Illus. 5.2: Visualization with examples
Note:
WAGO-I/O-PRO CAA visualization requires that the PC is connected to the
WAGO fieldbus controller. Depending on the fieldbus controller used, two
options are available.
The first option is available for all types of fieldbus controllers. Here, connection to the fieldbus controller's service interface is established via 750-923
Communication Cable. With ETHERNET fieldbus controllers, connection is
also possible using the ETHERNET interface.
Application Note
iPod Configuration
6
• 11
iPod Configuration
6.1 WLAN Settings
The first step is to establish WLAN (WiFi) communication. In order to accomplish this, the WLAN access point must be established and activated in the
iPod settings (see illus. 6.1).
Illus. 6.1: WiFi network settings
Application Note
12 • iPod Configuration
The iPod's Safari browser can be used for a first communication test. Enter the
controller's IP address in Safari's address bar (see illus. 6.2). For example:
“192.168.1.81”.
Illus. 6.2: Safari web browser
If the WLAN communication functions between the iPod and the WAGO controller, the WAGO WebBasedManagement for the corresponding ETHERNET
controller will be displayed on the iPod.
Note
The browser does not support JAVA, therefore, web pages created with
CoDeSys cannot be displayed!
6.2 ScadaMobile App
In the next step, the application (app) “ScadaMobile” must be loaded on the
iPod.
As an alternative, “ScadaMobile Lite” can also be used. This is a ‘lite’ version
which can communicate up to 4 data points.
In the example, “ScadaMobile” version 1.5.1 was used. The manual is available at the following homepage:
http://www.sweetwilliamautomation.com
Application Note
iPod Configuration
• 13
6.3 Communication Settings
In the “ScadaMobile” app, a few basic communication settings have to be set
in the “Settings” tab. All of the following steps can be also be found in the
“ScadaMobile User Manual”.
Illus. 6.3: Communication settings in ScadaMobile
Illustration 6.3 shows the typical settings for MODBUS communication. The
WAGO controller's IP address can be entered under “Default Connection”,
which should be considered a standard setting. In addition, the following settings are required:

Local Port:
502

Remote Port:
502

Address:
e.g.: 192.168.1.81
6.4 Processing the Configuration File
The file server is launched using the “File Server” tab, and enables the exchange of data between the PC and the iPod. After starting, the server address
is displayed (see illus. 6.4). This address is entered in Internet Explorer and
displays the CSV configuration files saved on the iPod. If no files are displayed, the templates can be loaded using “Load Examples”. Then select the
file
“DataTypesModbusES.csv” and save it to the PC.
Application Note
14 • iPod Configuration
Illus. 6.4: Turning on the file server on the iPod
The saved template can now be opened and processed using Excel. The entries
should be adapted to the example program shown in chapter 6. The columns
have the following meaning:
Column A: Variable name, as it should be displayed in the iPod
Column B: Data type of the CoDeSys variables
Column C: MODBUS range and MODBUS address
Column D: Additional parameters (appearance, headers, and commentary)
When entering the MODBUS address in column C, you must pay attention to
the fact that in general, an offset of 1 must be added to the addresses documented in the WAGO manual. If 32bit variables are entered (e.g. DINT or
REAL), the attribute “word_swap:=true;” must be entered one time in column
D (see illus. 6.5). After all changes have been made, the file should be saved
using a different name.
Illus. 6.5: Example of a configuration file (WAGO_iPod_Example_1.csv)
Note
More complete documentation and further details about the entry possibilities
are available in the “ScadaMobile Manual”.
Application Note
iPod Configuration
• 15
In the file server, select and upload the processed file using “File Upload”.
This file will then have to be actively switched on in ScadaMobile (see illus.
6.6).
Illus. 6.6: Selected file
6.5 Operating Interface
The display is turned on using the “Connections” tab. The green LED light indicates an error-free MODBUS connection. The variables specified in the
CSV file are displayed in the “Home” tab. The variables can be modified with
write access (see illus. 6.7).
Illus. 6.7: Operating interface
Application Note
16 • iPod Configuration
6.6 Access to Multiple Controllers
Multiple WAGO controllers can be accessed using ScadaMobile. A separate
CSV file must be generated for each controller. In each file, the attribute “local_ip:=x.x.x.x” must be present once in column D (see illus. 6.8). Files that
do not contain this attribute will be assigned to the controller using the IP address from the standard settings.
“
Illus. 6.8: Configuration file with IP address (Wago_iPod_Example_2.csv)
The second CSV file is also uploaded to the file server and activated in the
“Files” tab with a check. The “Tags” from all active files are displayed under
“Home” (see illus. 6.9). The order of the tags within the sections can be
changed using the “ord” attribute in the CSV file.
Illus. 6.9: Operating interface for two CSV files
Application Note
Appendix
7
Appendix
7.1 Required Files for WAGO-I/O-PRO CAA
No special libraries are required for these applications.
Application Note
Library
Description
-
-
• 17
WAGO Kontakttechnik GmbH
PO Box 2880 •
D-32385 Minden
Hansastraße 27 • D-32423 Minden
Phone:
+49 (0) 571/8 87 – 0
Fax: +49 (0) 571/8 87 – 1 69
E-mail: [email protected]
Online: