ICP DAS CR Win GRAF EtherCAT User Manual
- June 11, 2024
- ICP DAS
Table of Contents
Win-GRAF EtherCAT
User Manual
Ver. 1.0.0, AUG. 2022
CR Win GRAF EtherCAT
WARRANTY
All products manufactured by I CP DAS are warranted against defective
materials for a period of one year from the date of delivery to the original
purchaser.
WARNING
ICP DAS assumes no liability for damages consequent to the use of this
product. I CP DAS reserves the right to change this manual at any time without
notice. The information furnished by I CP DAS is believed to be accurate and
reliable. However, no responsibility is assumed by I CP DAS for its use, nor
for any infringements of patents or other rights of third parties resulting
from its use.
COPYRIGHT
Copyright © 2022 by I CP DAS. All rights are reserved.
TRADEMARK
Names are used for identification only and may be registered trademarks of
their respective companies.
CONTACT US
I f you have any questions, please feel free to contact us via email at :
service@icpdas.com,
service.icpdas@gmail.com
SUPPORT
EMP-2848M
Introduction
EtherCAT (Ethernet Control Automation Technology) is a series of Ethernet- based industrial communication buses. I t has established the mainstream in the industrial automation industry pursuing high precision, high efficiency, and low cost due to its high-speed communication performance and instant communication system.
Features:
-
EtherCAT is industrial Ethernet
The optimized EtherCAT data is included in the I EEE 802.3 Ethernet frame. The frame travels through the media at 100 Mbps in full-duplex mode. -
Flexible Topologies
With two EtherCAT ports on all devices, no additional switches are required to create a linear network. EtherCAT junction slaves can be used to build tree and star topologies. -
Distributed Clocks
The EtherCAT node slave measures the time difference between incoming and returning frame timestamp. With these timestamps the master can determine the propagation delay offset to the individual slave accurately. This mechanism ensures accurate synchronization between devices with less than 1 s jitter. -
Simple cabling
100Base-TX EtherCAT uses standard 100BASE-TX Ethernet communication very effi ciently, over standard shielded Ethernet cables and connectors. No need for network switches. -
Easy use, easy connect
When compared to a classic fieldbus system, EtherCAT is the obvious choice: node addresses can be set automatically, there’s no need for network tuning, and onboard diagnostics with fault localization make pinpointing errors a snap. Despite these advanced features, EtherCAT is also easier to use than I ndustrial Ethernet: there are no switches to configure, and no complicated handling of MAC or I P addresses is required. -
Processing on the fly
The slave devices extract and/ or insert data on the fly. This method assures the highest possible throughput.
This manual describes how to use the ENI file generated by the EMP-2848M website to configure Win-GRAF EtherCAT Fieldbus and how to map the local variables to these configuration variables to control the EtherCAT slave modules.
Software Installation
Workbench
The Win-GRAF workbench setup program “Win-GRAF_Workbench_xxxx_Setup”
automatically installs the necessary EtherCAT plugin library
C: Program Files (x86) Win-GRAF Workbench Win-GRAF Wb xx.xx I OD K5BusEcat.dll
EtherCAT Fieldbus
This chapter describes how to create an interface for the PLC application to
access EtehrCAT. The Win-GRF workbench provides a graphic plugin that allows
the user to map local PLC variables to the EtherCAT Process I mage shared
memory.
The EtherCAT Process I mage shared memory can be divided into read/ write
segments, which define the variables to be exchanged for the slave module PDO
communication. When the local variables are mapped to the EtherCAT Process I
mage variables, Win-GRAF Runtime will update the EtherCAT Process I mage
variable data in each cycle task, and exchange the Process I mage data in the
next EtherCAT communication cycle.
EtherCAT Variable Mapping
The following steps describe how to configure the EtherCAT Fieldbus. [ Steps]
-
Please follow the steps A~ D of the Slave Free-Run/ DC Setup and Control section in the website user manual to create the ENI file and execute EtherCAT Runtime.
-
Start the Win-GRAF workbench and create a new project.
-
Open the Fieldbus Configurations window by clicking on the ‘Fieldbus Configuration’ button in the toolbar or double clicking the ‘Fieldbus Configuration’ node in the workspace.
-
Click ‘Insert Configuration’ button of the toolbar on the left of the ‘IO Drivers’ editor and select ‘EtherCAT (I CPDAS)’ from the ‘Add Configuration’ dialog.
-
Change the communication settings of Win-GRAF according to the hardware I P address.
-
Right-click on the ‘EtherCAT (I CPDAS)’ node and click on the ‘Import ENI ‘ option in the right-click menu.
-
Click the ‘Download ENI ‘ button from the Import ENI dialog to download the ENI file, wait for 100% progress and click the ‘OK’ button on the Download dialog to close the window, and then click the OK button on the Import ENI dialog to close the Import ENI dialog. The following describes the parameters and buttons of the I mport ENI dialog.
– Open the ENI file to create the configuration.
– Download the ENI file from the hardware to create the configuration. Declare variables in database – Automatically create and map the global variables to the Process I mage variables. -
After downloading the ENI file from the hardware to create the configuration, the ‘EtehrCAT Master’ and ‘Motion Control’ (only when the motion control function is activated) nodes will be created automatically under the ‘EtherCAT (I CPDAS)’ node.
-
Under the ‘EtehrCAT Master’ node there are master and slave Process I mage variables that can be mapped. The parameters of the variable nodes are described below: The following describes the parameters of the variable node.
Symbol – Name of the local variable to be mapped.
Tag – Variable name.
Data Type – Variable data type.
Index – Variable index.
Mode – Variable data flow direction.
Input: Read master or slave variables to local variables.
Output: Write local variables to master or slave variables
Bitoffs – Variable offset on Process I mage.
BitSize – Variable size. -
As shown in the figure below, you can double-click the Symbol parameter to map the local variables or drag and drop the local variables to map.
-
If the motion control function is enabled, the axis nodes are automatically generated under the ‘Motion Contorl-> Axes’ node and mapped to the automatically generated ‘MC_AXI S_xxx’ variables in the global variables. The data type of ‘MC_AXI S_xxx’ variable is ‘AXI S_REF_xxx’. These axis reference variables are used for PLCopen function block.
Quick Start
This chapter explains how to map PLC program variables to EtherCAT Fieldbus and read/ write these variables to control the slave modules.
Control Slave Module Steps
This section describes how to configure the EtherCAT Fieldbus and control the
slave modules with the connected slave modules ECAT-2055 (DI / DO), ECAT-2011H
(AI ), ECAT-2028 (AO).
[ Steps]
-
Please follow the steps A~ D of the Slave Free-Run/ DC Setup and Control section in the website user manual to create the ENI file and execute EtherCAT Runtime
-
Open the Fieldbus Configurations window by clicking on the ‘Fieldbus Configuration’ button in the toolbar or double clicking the ‘Fieldbus Configuration’ node in the workspace.
-
Add ‘EtherCAT (I CPDAS)’ configuration.
(1) Click ‘I nsert Configuration’ button.
(2) Select ‘EtherCAT (I CPDAS)’. -
Change the communication settings of Win-GRAF according to the hardware I P address.
-
Automatically create a list of EtherCAT Process I mage variables by importing ENI .
(1) Right-click on the ‘EtherCAT (I CPDAS)’ node.
(2) Click on the ‘I mport ENI ‘ option in the right click menu. -
Use the I mport ENI dialog to download the ENI file.
(1) Click on the ‘Download ENI ‘ button.
(2) Wait for progress to 100% .
(3) Click the ‘OK’ button in the download dialog to close the window.
(4) Click the ‘OK’ button in the I mport ENI dialog to close the window. -
Mapping local variables to control slave modules.
I . Slave DI / DO module read/ write control. Connect the ECAT-2055 (DI / DO) pins DI x to DOx.
(1) Add variables do_8 (USI NT), di_8 (USI NT).
(2) Map the variables do_8, di_8 to the slave ECAT-2055 variables Digital Outputs. Output, Digital Inputs. Input.
(3) I n the Structured Text program, write the variable do_8 to the value 165.
(4) Compile Win-GRAF program.
(5) Download Win-GRAF program to hardware.
(6) Run Win-GRAF program and perform online debugging.
(7) I n online debug mode, check whether di_8 in the variable list is 165.
II . Slave AI / AO module read/ write control, connects slave ECAT-2011H (AI ), ECAT-2028 (AO) channel 0 pins.
(1) Add variable ai0_raw (I NT).
(2) Map the variable ai0_raw to the slave ECAT-2011H variable AI 0.Value.
(3) Add variable ao0_raw (I NT).
(4) Map the variable ao0_raw to the slave ECAT-2028 variable AO0.Output.
(5) Add variable ai0_volt (LREAL), ao0_volt (LREAL).
(6) AO/ AI use default range ± 10V. I n the Structured Text program, output AO 5V.
(7) Compile Win-GRAF program.
(8) Download Win-GRAF program to hardware.
(9) Run Win-GRAF program and perform online debugging.
(10) I n online debug mode, check whether ai0_volt in the variable list is 5V.
Motion Control Steps
This section illustrates how to use the EtherCAT Fieldbus motion control function by connecting the CiA402 slave module. [ Steps]
-
Please follow the steps A~ F in the Motion Control Setup and Control section of the web site user manual to create the ENI file and run EtherCAT Runtime.
-
Start the Win-GRAF workbench and create a new project.
-
Open the Fieldbus Configurations window by clicking on the ‘Fieldbus Configuration’ button in the toolbar or double clicking the ‘Fieldbus Configuration’ node in the workspace.
-
Click ‘Insert Configuration’ button of the toolbar on the left of the ‘IO Drivers’ editor and select ‘EtherCAT (I CPDAS)’ from the ‘Add Configuration’ dialog.
-
Change the communication settings of Win-GRAF according to the hardware IP address.
-
Right-click on the ‘EtherCAT (I CPDAS)’ node and click on the ‘Import ENI ‘ option in the right-click menu.
-
Click the ‘Download ENI ‘ button from the Import ENI dialog to download the ENI file, wait for 100% progress and click the ‘OK’ button on the Download dialog to close the window, and then click the OK button on the Import ENI dialog to close the Import ENI dialog. The following describes the parameters and buttons of the Import ENI dialog.
– Open the ENI file to create the configuration.
– Download the ENI file from the hardware to create the configuration. Declare variables in database – Automatically create and map the global variables to the Process Image variables. -
Verify that the ‘Motion Contorl-> Axes-> Axis_xxx’ variable is generated under the ‘EtherCAT (I CPDAS)’ node and mapped to the automatically generated ‘MC_AXI S_xxx’ variable in the global variable.
-
Enable Store complex variables in a separate segment.
(1) Right-click on the project node in the workspace.
(2) Click on the ‘Settings’ option in the right click menu.
(3) Click on the ‘Options’ item.
(4) Set the Store complex variables in a separate segment function to Yes. -
Programming PLCopen Function Block motion control program.
(1) Add variable axis0_pwr_en (BOOL), axis0_pwr_status (BOOL), axis0_reset_exec (BOOL) , axis0_mv_abs_exec (BOOL), axis0_mv_abs_pos (LREAL, 10), axis0_mv_abs_vel (LREAL, 5) , axis0_mv_abs_acc (LREAL, 50), axis0_mv_abs_bm (MC_BUFFER_MODE_EMP2K), axis0_get_pos_en (BOOL, TRUE) , axis0_act_pos ( LREAL)
(2) Add MC_POWER_EMP2K, MC_RESET_EMP2K, MC_MOVEABSOLUTE_EMP2K, MC_READACTUALPOSI TI ON_EMP2K Function Block in the Function Block Diagram (FDB) Editor.
(3) Connect each variable to the Function Block.
(4) Compile Win-GRAF program.
(5) Download Win-GRAF program to hardware.
(6) Run Win-GRAF program and perform online debugging. -
Absolute position movement control in online debugging mode.
(1) Set axis0_pwr_en = TRUE to power ON the single axis.
(2) I f an error occurs in a single axis, set axis0_reset_exec = TRUE to clear the error.
(3) Set axis0_mv_abs_exec = TRUE to start absolute position movement.
(4) Verify that the final movement position of the single axis matches the input position.
Revision History
Revision | Date | Description |
---|---|---|
1 | 2022/07 | Initial issue |
Copyright © 2022 I CP DAS CO., Ltd. All Rights Reserved.
Documents / Resources
| ICP
DAS CR Win GRAF
EtherCAT
[pdf] User Manual
CR Win GRAF EtherCAT, CR Win, GRAF EtherCAT, EtherCAT
---|---
Read User Manual Online (PDF format)
Read User Manual Online (PDF format) >>