Page 1
> > System Manual Starter kit for ecomatController EC2121 CODESYS Version 3.5 or higher English...
Page 2
Explanation of Symbols ....................... 5 Purpose of the document ..................... 5 Required previous knowledge ....................5 Required software ........................ 6 Overview: User documentation for EC2121 ................ 6 Overview: documentation for CODESYS 3.n ..............7 Change history ........................7 Prepare the controller Hardware installation ......................
Page 3
Starter kit for ecomatController EC2121 Annex The I/O simulator box ......................39 6.1.1 Inputs............................39 6.1.2 Outputs ............................40 6.1.3 Communication reset ......................... 40 Index...
Page 4
Explanation of Symbols ..........................5 Purpose of the document ......................... 5 Required previous knowledge ........................5 Required software ............................ 6 Overview: User documentation for EC2121 ..................... 6 Overview: documentation for CODESYS 3.n ................... 7 Change history ............................7 26077 >...
Page 5
These instructions describe how to prepare and program a controller of the device family for mobile applications, ecomatmobile from ifm electronic gmbh, using the CR711S controller as example. These instructions are intended for the operation in conjunction with the starter kit EC2121; it can, however, also be used independently.
Page 6
Target system configuration with CODESYS Programming the device-internal PLC using CODESYS Description of the device-specific CODESYS function libraries If any documents are not available, they can be requested from ifm or can be downloaded from the ifm website: → www.ifm.com...
Page 7
The CODESYS user manual only applies to the safety PLC with restrictions. ► Please observe this programming manual when programming the safety PLC. If any documents are not available, they can be requested from ifm or can be downloaded from the ifm website: →...
Starter kit for ecomatController EC2121 Prepare the controller Content Hardware installation ..........................8 Install UpdateTool on the PC........................8 Establish a connection between the controller and the PC via Ethernet..........9 Check and update OS version .......................12 57257 >...
Starter kit for ecomatController EC2121 > Establish a connection between the controller and the PC via Ethernet. 57260 > 2.3.1 Connect the controller and the PC 57261 To connect the controller to the PC: ► Connect the supplied network cable (Ethernet cable) to: ...
Page 10
Starter kit for ecomatController EC2121 ► Activate the Windows menu [Internet Protocol Properties Version 4 (TCP/IPv4: for example [Start] > right click > [Network Connections] > [Ethernet] > [Change adapter settings] > [Ethernet] > right click > [Properties] (→ Figure below) ►...
Page 11
Starter kit for ecomatController EC2121 > The network settings were changed. Summary of the network settings: Setting Value Internet protocol TCP/IP IP address 192.168.82.xxx (except .21 and .247) Subnet mask 255.255.255.0 Gateway IP address 192.168.82.21 > 2.3.3 Test connection between the controller and PC 57263 The connection can be tested with the UpdateTool.
Starter kit for ecomatController EC2121 ► Confirm with [Enter] twice. > The menu appears. ► Select menu item [Ping device] by entering [2] and confirming with [Enter]. > The ping replies are displayed. When the ping replies are displayed as shown in the figure, the connection is OK.
Page 13
Starter kit for ecomatController EC2121 Check OS version: ► In the menu of the UpdateTool, select the menu item [Continue update process] by entering [4] and confirming with [ENTER]. > After a short time, information about the current controller and the update menu (→ figure) appear in the window.
Page 14
Starter kit for ecomatController EC2121 > The update process starts. During the update process, various messages appear; to conclude, the following success message is displayed: ► Exit the UpdateTool with [Enter] and twice [q].
Starter kit for ecomatController EC2121 Installation Content Prepare installation ..........................15 Carry out installation ..........................17 Start CODESYS 3.5 ..........................19 Install packages ............................20 > Prepare installation 57267 The major part of the required software is on the supplied USB flash drive. Since the used controller can also be used for applications with functional safety, it is necessary for legal reasons that you download the controller-specific packages directly from ifm's website.
Page 16
Starter kit for ecomatController EC2121 ► Open tab [Downloads] > click [Target and documentation package] under [Software Download] > Login page for my ifm appears ► Log in to my ifm.
Starter kit for ecomatController EC2121 If you do not have your my ifm- access data, you have to register as customer beforehand. > The website to download safety operating systems is displayed. ► Download the package for [CR711S (Version V3.0.0.3)] and save it on your PC.
Page 18
Starter kit for ecomatController EC2121 ► Change the installation path in C:\Program Files (x86)\3S CODESYS V3.5 SP11 and confirm with [OK]. ► Activate the [Next >] button to continue the installation. > The installation wizard will guide you through the installation. It is recommended to apply the...
Starter kit for ecomatController EC2121 > Start CODESYS 3.5 57270 Administrator rights are required to install the packages on the PC. After the first program start, the packages belonging to the controller have to be installed. ► Start CODESYS as admin with: desktop symbol [CODESYS V3.5 SP11] > (right click) > [Run as administrator].
Install packages 57271 ► Install the following packages in the indicated order: 1. Package of the controller (ifm_R360-3_Vn.n.n.n.package) 2. Safety SIL2 package from 3S (3S_CODESYS_Safety_SIL2_Vn.n.n.n.package) 3. Safety SIL2 extension package from ifm (ifm_R360-3_CODESYS_Safety_SIL2_Extensions_V0.0.0.6.package) > 3.4.1 Start the package manager 57272 ►...
Page 21
Starter kit for ecomatController EC2121 > To conclude, the package manager shows all installed packages. ► Click [Close] to quit the package manager. To complete the installation of the packages, CODESYS has to be restarted. ► Exit CODESYS. ► Restart CODESYS by double-clicking on the desktop symbol [CODESYS V3.5 SP11].
Page 22
Starter kit for ecomatController EC2121 Features of a PLC Content Cyclical program processing ........................22 Time response ............................23 57274 This chapter describes some basics of programmable logic controllers. Should you have some knowledge of the operation of a PLC, you can skip this chapter.
Page 23
Starter kit for ecomatController EC2121 > Time response 57276 > 4.2.1 Cycle time 57277 The time a controller needs for one cycle is called cycle time. Typically, this time is in the ms range. The cycle time is also the time an input signal has to be present to be reliably detected by the controller.
Page 24
When all packages have been installed, a first program for test purposes should be written. To do so, a new project is created with [New project...] when CODESYS has been started. ifm provides one template each for every controller. The basic elements and configurations in these basic projects are already prepared.
Page 25
Starter kit for ecomatController EC2121 When a new project is created via [Empty project], the hardware-specific settings have to be made manually.
Starter kit for ecomatController EC2121 > Device tree On the left side of the CODESYS project view, there is the device tree. It contains all components for the configuration, administration and programming of the controller. The structure can be seen in the figure:...
Starter kit for ecomatController EC2121 The ecomatController devices contain two independent programmable logic controllers: StandardPLC (CR711S standard) SafetyPLC (CR711S SIL2) For this first introduction, only the StandardPLC is used. The distribution of the resources (e.g. memory) to the two controllers does not have to be taken into account here.
Page 28
Starter kit for ecomatController EC2121 ► Window [Select device] appears. ► Select [Gateway-1] on the left and search for the controller by clicking the [Scan network] button. > The controller appears below the gateway. It is possible that the function [Scan network] has to be executed twice.
Page 29
Starter kit for ecomatController EC2121 ► Enter user name admin and no password and confirm with [OK]. If a password was already set, it has to be entered for login. > The connection to the controller is established. > The green circle on the controller signals that the connection has been established.
Starter kit for ecomatController EC2121 > Create the program 57283 In the first small program a two-hand control is to be implemented which is used for presses, for example. There are two pushbuttons on the press which are installed so that they cannot be operated with one hand.
Page 31
Starter kit for ecomatController EC2121 5.3.3 Structured programming 57286 In principle, the complete program can be contained in only one block such as the PLC_PRG. This becomes quite confusing, however, and the fault location is difficult. It is better to distribute different program sections to different blocks. Then the blocks are activated one after the other in PLC_PRG.
Page 32
Starter kit for ecomatController EC2121 > 5.3.5 Function block diagram (FBD) 57288 FBD (function block diagram) is a graphic programming language in the standard IEC 61131-3. Blocks with symbols from the boolean algebra, for example, are added to the program.
Page 33
Starter kit for ecomatController EC2121 > 5.3.6 Program linking 57289 According to the task, the output signal must only be active if both input signals are active. This functionality can be implemented with an AND operator. The general symbol for an AND operator...
Page 34
Starter kit for ecomatController EC2121 ► Enter AND and confirm with [Enter]. > 5.3.7 Address binary inputs and outputs 57290 The links to the inputs and outputs are still missing. For the first small program, the terms from I/O mapping are used: device tree > Local_IO > Inputs >...
Page 35
Starter kit for ecomatController EC2121 To transfer the link result to the output, an assignment has to be added to the output of the AND operator: ► Drag an [Assignment] to the output of the AND operator in the section [Toolbox] and drop it at the appearing green square.
Page 36
Starter kit for ecomatController EC2121 5.3.9 Structured text (ST) 57292 The block PLC_PRG is here programmed in Structured Text (ST). This is a textual programming language of the standard IEC 61131-3 which follows the programming language PASCAL. Since commands are entered here in text format, there are no tools in this programming window.
Starter kit for ecomatController EC2121 > Transfer and test the program 57293 To test the program, it has to be transferred to the controller. A connection to the controller was already established in chapter Establish a connection between the controller and the PC via (→...
Page 38
Starter kit for ecomatController EC2121 > 5.4.2 Test program 57295 Now the program can be tested. When the potentiometers are positioned at the right end stop, both switches [IN0100] and [IN0101] can be switched on. Only if both switches are switched on, is the lamp [OUT0000] on.
Page 39
Starter kit for ecomatController EC2121 Annex Content The I/O simulator box ..........................39 57296 > The I/O simulator box 57297 The I/O simulator box is used for the simulation of input and output signals and the reset of communication parameters of the controller. Six inputs and outputs each are connected via the box.
Page 40
Starter kit for ecomatController EC2121 voltage measurement 0...32 V (IN_VOLTAGE_32) ratiometric voltage measurement / operating voltage ratio (IN_VOLTAGE_RATIO) The potentiometer forms a voltage divider to also simulate analogue values. When a value is set on a potentiometer and the corresponding switch is activated, this value is sent to the controller.
Page 41
Install UpdateTool on the PC..............9 Installation ....................17 Legal and copyright information .............. 4 Outputs ....................47 Overview documentation for CODESYS 3.n ..............6 User documentation for EC2121 ..............5 Prepare installation ................17 Prepare the controller ................9 Program linking ..................39...
Need help?
Do you have a question about the EC2121 and is the answer not in the manual?
Questions and answers