com.tom codesys getting started - industrialnets.ru

18
com.tom CODESYS Getting Started V2.2 Copyright © 2018 Beck IPC GmbH Page 1 of 18 com.tom CODESYS Getting Started

Upload: others

Post on 13-Jan-2022

6 views

Category:

Documents


2 download

TRANSCRIPT

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 1 of 18

com.tom CODESYS Getting Started

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 2 of 18

TABLE OF CONTENTS

1 INTRODUCTION .................................................................................................. 3

2 SCOPE ................................................................................................................. 3

3 SYSTEM START-UP ............................................................................................ 3

3.1 WHAT DO WE NEED TO GET STARTED? .................................................................................. 3

3.2 STEP 1 – CABLE THE DEVICE ................................................................................................ 3

3.3 STEP 2 – SETUP CODESYS ................................................................................................ 3

3.4 STEP 3 – CONFIGURE THE DEVICE ........................................................................................ 4

3.5 STEP 4 – CONFIGURE YOUR I/OS AND VARIABLES .................................................................. 5

3.6 STEP 5 – INSTALL THE TARGET DESCRIPTION FILE .................................................................. 6

3.7 STEP 6 – CREATE AN APPLICATION ....................................................................................... 8

3.8 STEP 6 – SET UP PORTAL COMMUNICATION ......................................................................... 11

3.9 STEP 7 – USE THE PORTAL’S WEB INTERFACE ...................................................................... 14

4 ADVANCED SETTINGS ..................................................................................... 16

4.1 CELLULAR MODEM CONFIGURATION..................................................................................... 16

5 WHERE TO GET FURTHER INFORMATION .................................................... 18

5.1 GETTING STARTED ............................................................................................................. 18

5.2 CODESYS ONLINE HELP .................................................................................................. 18

5.3 UPDATES, TOOLS, DOCUMENTATION .................................................................................... 18

5.4 SUPPORT ........................................................................................................................... 18

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 3 of 18

1 Introduction This document will help you get started with com.tom and CODESYS. CODESYS is the leading IEC61131-3 compatible PLC (Programmable Logic Controller) environment. It runs on many variants of the CTI (com.tom INDUSTRY) devices. The CODESYS development environment enables comfortable software development for industrial applications. The special com.tom CODESYS runtime system allows mapping variables of the PLC program to the com.tom PORTAL.

2 Scope This documentation covers the com.tom CODESYS software package. com.tom CODESYS runs on devices with the following name pattern: CTI <network interfaces> . <type> . <wireless connection> . C e.g. CTI 140.MBUS.UMTS.C

3 System start-up

3.1 What do we need to get started?

Required hardware components:

CTI device running the com.tom CODESYS software

Power supply unit

Ethernet cable Required software components:

Ethernet network interface

Microsoft Windows XP/Vista/7/8/10

Internet connection

Web-browser (We recommend Mozilla Firefox or Chrome)

com.tom-IP-Tool (can be downloaded at https://www.com-tom.de/download)

CODESYS (can be downloaded at https://www.codesys.com/download.html) Required skills by the developer:

Basic knowledge in CODESYS V3

3.2 Step 1 – Cable the device

Use an Ethernet cable to connect the CTI device to your PC. If you have an existing network infrastructure, use a patch cable to connect the com.tom to your hub or switch. If not, use a crossover cable to directly connect the com.tom’s Ethernet jack to your PC’s Ethernet jack. Now connect the power supply unit to the CTI’s power supply jack to power the device.

3.3 Step 2 – Setup CODESYS

Before getting in contact with the com.tom CODESYS you have to install the CODESYS development environment. You can download the latest version at https://www.codesys.com/download.html.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 4 of 18

3.4 Step 3 – Configure the device

To be able to access the com.tom’s, the device must have a valid IP address and we have to know it. Therefore we’ll use the com.tom-IP-Tool. If you have not yet downloaded and installed this tool, please do so now. You can get it at https://www.com-tom.de/download. When you start the com.tom-IP-Tool it will scan for com.tom devices on the local network. The MAC IDs of the devices will be put on a list. Select the MAC ID of your device from the list. The MAC ID can be found on the label on the device’s housing.

You’ll now be shown the actual IP configuration of the device. By default the device will try to get an IP address from a DHCP server at start. If this does not work, an auto IP will be activated. Check if the current settings match the needs of your network. If you are in doubt, ask you network administrator.

If the configuration does not match, you may change it. Deselect the Use DHCP checkbox. Change the addresses as required and eventually click the Configure button. The IP-Tool will

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 5 of 18

ask for a password. By default this password is com.tom. Wait for the confirmation “Configuration completed”.

If you’re running a firewall, make sure that it does not block any network functions of the com.tom-IP-Tool.

3.5 Step 4 – Configure your I/Os and variables

Go to the web interface of your CTI device and configure your inputs/outputs (e.g. Modbus):

Now configure the variables you want to communicate with the portal.

Save your settings by pressing ‘OK’ and reboot your device.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 6 of 18

When the device has been rebooted, please go to ‘Services’ > ‘CODESYS export’ and click on ‘Download’ to save the CODESYS device description file.

3.6 Step 5 – Install the target description file

Open your CODESYS workbench and go to ‘Tools’ > ‘Device Repository’

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 7 of 18

Click ‘Install’ and select the device description file you exported before in step 4:

Now you can close the device repository and continue with Step 6. If you later want to change the I/O configuration, please repeat this step, right click on the device and select ‘Update device’.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 8 of 18

3.7 Step 6 – Create an application

Create a new project in the CODESYS workbench:

Now you can select the device you installed before:

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 9 of 18

In the next step you can start to develop your program. In this simple example the energy value is getting converted from kWh into Wh:

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 10 of 18

Now you can map the variables and I/Os you configured in Step 4 with the variables of your application.

Finally you can go online and download your project.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 11 of 18

3.8 Step 6 – Set up portal communication

Of course we want to see the counter value on the com.tom PORTAL.

Press the Settings icon to go to the settings page.

On the settings page there are several tabs on which you can adjust various configurations. On the Portal tab we have to configure the access data for the com.tom PORTAL. You have received these data when you registered the device with the com.tom PORTAL. If you have not yet registered the device, please do so first

1. Timeout field determines how long the portal

communication module will wait for replies from the portal before the connection is considered broken. The keep-alive interval determines the maximum number of seconds with no payload data traffic before the keep-alive handshake will be carried out. The required interval depends on your network infrastructure. A value of 0 disables the keep-alive mechanism. Keep-alive timeout is the number of seconds the peers wait for each other's keep-alive messages before the connection is considered broken. After entering the data, press the OK button to store your changes on the device.

1 Refer to the Getting Started documentation com.tom PORTAL Manual.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 12 of 18

It is assumed that the com.tom device has access to an existing internet connection via its Ethernet interface. If this is not true, please refer to section 4.1 on how to configure the cellular modem.

Besides the intrinsic internet connection the com.tom device needs a DNS server to resolve domain names like demo.com-tom.io into IP addresses. It is common practice to distribute the address of the DNS server via DHCP. However, if your DHCP server does not distribute a DNS server address or if you have manually set the device’s IP configuration, you will have to configure the DNS server address by hand.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 13 of 18

To do so switch to the Network tab. Here you can configure network settings like the DNS server address. You can also configure a proxy server. Proxy servers are typically used in company networks to filter network traffic.

If you are in doubt regarding the settings on this tab, please ask your network administrator.

Press the OK button to store your changes.

Then press the Reboot icon to restart your com.tom device in order to apply your changes. After some time the device’s Portal LED will light up indicating communication

with the com.tom PORTAL.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 14 of 18

3.9 Step 7 – Use the portal’s web interface

Navigate your internet browser to the web interface of your com.tom PORTAL project. In our example the URL of our project is demo.com-tom.io. Log in to the portal with the login information provided to you.

You will now see an overview of all devices registered with this project. Click on the identification of your current device to see its contents.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 15 of 18

There are several groups of values for this device. Open the variables group to see the portal variables. Now you can now change portalvar00 e.g. to 100 and see that portalvar01 changes to 100.000. Hover the button with the three horizontal lines and click on Config to switch to the Configuration site.

Navigate to the variables section and click on the button Edit next to portalvar00. This opens a view where you can edit several properties of portalvar00. The datatype is given by the local configuration of your device and because of this it cannot be changed by the portal.

Navigate back to the VIEW site.

The portal variable 1 triggers the reset of the counter. If the reset becomes true then the counter variable will be set to 0. When reset becomes false again the counter starts counting. Click on the value of portal variable 1 to modify it.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 16 of 18

4 Advanced Settings

4.1 Cellular modem configuration

In this section the configuration of the cellular modem will be described. Of course this description only applies if your com.tom device features a cellular modem. If not you should skip this section. Remove the power supply. Insert your SIM card into the SIM card slot that is located at the back side of the com.tom device. Push the card until it locks. Attach the power supply again.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 17 of 18

Go to the settings page and open the Cellular Modem tab. Check the Enable cellular modem checkbox. If your SIM card requires a PIN, enter it in the SIM PIN field. Enter your mobile phone provider’s Access point name in the APN field. If the APN requires authentication enter the appropriate values too.

Press the Save button to store your changes, then reboot your com.tom device to apply your changes. After some seconds first the com.tom’s Modem LED will light up indicating that the cellular modem has been initialised. After about a minute the GSM/GPRS LED should light up indicating that an internet connection has been established via the modem.

sd com.tom CODESYS

Getting Started V2.2

Copyright © 2018 Beck IPC GmbH Page 18 of 18

5 Where to get further information

5.1 Getting Started

All software referred to in this document can be downloaded from the Getting Started website at https://www.com-tom.de/start.

5.2 CODESYS Online Help

The CODESYS Online Help contains a com.tom specific section. You can find it in CODESYS in the menu Help | Contents | Target System | Beck IPC@CHIP Help | com.tom.

5.3 Updates, tools, documentation

Regularly check out the website at www.com-tom.de for

Firmware updates

Useful tools

Further documentation

5.4 Support

If you need support, please…

1. Check our support website at www.beck-ipc.com/ipc/support. 2. Contact our support at [email protected]. Of course you may also contact us by

phone. But please use email if possible. This not only reduces the time you spend on the phone, it also allows us to easily manage the questions and identify problem areas.

Copyright © 2000-2015 BECK IPC GmbH All rights reserved

No part of this document may be copied or reproduced in any

form or by any means without the prior written consent of

BECK IPC GmbH. The information in this document is subject

to change without notice. Devices sold by BECK IPC GmbH

are covered by warranty and patent indemnification

provisions appearing in BECK IPC GmbH Terms and

Conditions of Sale only.

BECK IPC GmbH MAKES NO WARRANTY, EXPRESS,

STATUTORY, IMPLIED OR BY DESCRIPTION,

REGARDING THE INFORMATION SET FORTH HEREIN OR

REGARDING THE FREEDOM OF THE DESCRIBED

DEVICES FROM INTELLECTUAL PROPERTY

INFRINGEMENT. BECK IPC GmbH MAKES NO

WARRANTY OF MERCHANTABILITY OR FITNESS FOR

ANY PURPOSE.

BECK IPC GmbH shall not be responsible for any errors that

may appear in this document. BECK IPC GmbH makes no

commitment to update or keep current the information

contained in this document.

Life critical applications - BECK products are not authorized

for use as critical components in life support devices or

systems unless a specific written agreement pertaining to

such intended use is executed between the customer and

BECK prior to use. Life support devices or systems are those

which are intended for surgical implantation into the body, or

which sustain life, and whose failure to perform, when

properly used in accordance with instructions for use provided

in the labeling, can be reasonably expected to result in

significant injury to the user. BECK IPC GmbH customers

using or selling these products for use in such applications do

so at their own risk and agree to fully indemnify BECK IPC

GmbH for any damages resulting from such application.

Right to make changes - Beck IPC GmbH reserves the right

to make changes without notice in the products, including

software, described or contained herein in order to improve

design and/or performance. Beck IPC GmbH assumes no

responsibility or liability for the use of any of these products.