HY-TTC 32: Quick Start Guide For CODESYS
HY-TTC 32: Quick Start Guide For CODESYS
HY-TTC 32: Quick Start Guide For CODESYS
Redistribution is prohibited.
HY-TTC 32
TTControl GmbH
Schoenbrunner Str. 7, A-1040 Vienna, Austria, Tel. +43 1 585 34 34-0, Fax +43 1 585 34 34-90, [email protected]
The information contained in this document does not affect or change any General Terms and Conditions of TTControl and/or any
agreements existing between TTControl and the recipient regarding the product or Sample concerned.
The reader acknowledges that this document may not be reproduced, stored in a retrieval system, transmitted, changed, or translated, in
whole or in part, without the express prior written consent of TTControl.
The reader acknowledges that any and all of the copyrights, trademarks, trade names, patents (whether registrable or not) and other
intellectual property rights embodied in or in connection with this document are and will remain the sole property of TTControl or the
respective right holder. Nothing contained in this legal notice, the document or in any TTControl web site shall be construed as conferring to
the recipient any license under any intellectual property rights, whether explicit, by estoppel, implication, or otherwise.
The product or Sample is only allowed to be used in the scope as described in section “System Overview”. Please note that based on the
current state of the art in science and technology, it is impossible to develop software that is bug-free in all applications.
Copyright © 2017 TTControl GmbH. All rights reserved. Subject to changes and corrections
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
Revision Chart 2
Revision Chart
A revision is a new edition of the document and affects all sections of this document.
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
Contents 3
Contents
Revision Chart 2
1 Overview 4
3 Starter Kit 4
4 Connections 5
4.1 HY-TTC 32 Module Cabling Harness . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
4.2 HY-TTC 32 Module CAN Connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
4.3 HY-TTC 32 Module Power Supply . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
5 CODESYS Installation 7
8 Configuration 19
8.1 Communication Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
8.2 PLC Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
8.3 Download Timeout Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
8.4 PIN Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
10 Going on 26
References 28
Legal Disclaimer 29
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
1 Overview 4
1 Overview
The purpose of this document is to give a short overview of how to setup HY-TTC 32 ECU CODESYS
environment and write a first simple application.
3 Starter Kit
HY-TTC 32 CODESYS Starter Kit consists of the following components:
• HY-TTC 32 programming in CODESYS, Prototype Control unit with Infineon XC2200 CPU
• Case
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
4 Connections 5
4 Connections
4.1 HY-TTC 32 Module Cabling Harness
Connect HY-TTC 32 to the connector interface board with the provided 1-1 cabling harness.
• Connect pin B2 and A2 (CAN termination low line) to activate 120 Ohm termination resistance.
• Connect PEAK PCAN USB adapter to the CAN DSUB 9 connector of connector interface board
(Figure 2).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
4 Connections 6
• Put jumper KL15 mode to "Always on" to activate K15 (Figure 3).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 7
5 CODESYS Installation
When obtaining the CODESYS release package, you get a setup file with the name
TTControl_HY-TTC_32_Installer_x.x.x.x_yyyyy.exe, where x.x.x.x indicates the current version
and yyyyy the release name (e.g. 2016d). Double-click this setup file to start the installation process
and open the TTControl HY-TTC 32 Installer Setup wizard (Figure 4).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 8
In the setup wizard, click Next to proceed to the TTControl HY-TTC 32 Installer Setup dialog, which
prompts you to select the components to be installed. Mark the components you want to install. For
example select 3S CoDeSys V2.3, Target Files, HY-TTC 32 and click Next to confirm the settings
made and proceed to the next step, where you are prompted to select the destination folder for your
installation (Figure 5).
Click the Browse button to select the destination directory of your choice. It is recommended to use
default
c:\TTControl\...
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 9
At this point, the installer starts extracting all the components, which can take a few seconds (Figure
7).
Once the extraction of the components is finished, the setup of CODESYS is started, and the CODESYS
IDE - InstallShield Wizard dialog will appear. Click Next to confirm installation (Figure 8).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 10
Click Yes to accept the license agreement and select the desired destination directory for your installa-
tion. Click Next to confirm the settings made (Figures 9, 10).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 11
In the Select Components dialog, select CODESYS V2.3 and and the other components you want to
install and than click Next to confirm the settings (Figure 11).
In the Select Program Folder dialog select the default program folder which is to appear in the start
menu. Click Next to confirm your settings (Figure 12).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 12
In the Configuration overview dialog, which shows a summary of the CODESYS installation settings,
click Next to start copying the program files. Depending on the performance of your PC, this step can
take around 10 minutes until it is completed. (Figures 13, 14).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
5 CODESYS Installation 13
The InstallShield Wizard complete dialog shows that the installation of CODESYS and its additional
components has completed successfully. Click Finish to complete the installation of the CODESYS
and exit the setup wizard (Figures 15, 16).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
6 Flashing the Runtime System Software (RTS) 14
At this point the installation of CODESYS is finished, and you are ready for starting development. Please
note, that a system reboot may be necessary to finalize the software installation process.
<install dir>\Targets_<release>\<target>\bin
eg.: c:\TTControl\Targets_2016d\HY-TTC_32\Bin
• Connect PEAK PCAN USB adapter to the USB port of the PC.
• Connect PEAK PCAN USB adapter to the CAN DSUB 9 connector of connector interface board.
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
6 Flashing the Runtime System Software (RTS) 15
• While the tool sends "Connect" messages (which is indicated by a progress bar), perform a power
cycle of HY-TTC 32.
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
7 Starting New Project 16
From Target Settings dialog select HY-TTC 32, Vx.x.x and click OK button (Figure 20).
Check the Target Settings configuration and click OK if it matches with the following screenshot (Figure
21).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
7 Starting New Project 17
Confirm Library dialogs will pop up. Check the libraries and click OK(Figures 22, 23, 24).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
7 Starting New Project 18
In New POU dialog the Name of the new POU has to be named PLC_PRG and the Type of POU
must be a Program. The programming Language of the POU for the main program can be chosen
arbitrarily by the user. Than click OK (Figure 25).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
8 Configuration 19
8 Configuration
8.1 Communication Method
To configure communication parameters click Online menu and select Communication Parameters
(Figure 26).
In Communication Parameters dialog click New and select CANopen DSP302 click OK. New entry
is generated. Change the following entries to the specified values (Figure 27).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
8 Configuration 20
Double click on PLC Configuration the following window will open (Figure 29)
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
8 Configuration 21
The module parameters for this main node allow to change the CODESYS communication behavior
of the HY-TTC 32.You can find more information related to Module parameters in HY-TTC 32 Driver
Manual for CODESYS [1].
In Options dialog select Desktop and set the following entries to the specified values (Figure 31).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
8 Configuration 22
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
9 Main Program and Downloading an Application 23
By clicking on Module parameters tab you can configure pin’s parameters which are specific for each
pin (e.g. Polarity, OverloadLimit, DiagMargin and etc.) (Figure 33).
You can find more information about pin configuration in HY-TTC 32 Driver Manual for CODESYS.[1]
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
9 Main Program and Downloading an Application 24
The default cycle time of the task is 10 ms. So, the default program PLC_PRG will be executed every
10 ms. Any inputs will be read at the beginning of the tasks. Any outputs will be written at the end of
the task.
In extracted developer package directory (Figure 35) you can find Templates and Tutorials, which can
help you to start quickly.
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
9 Main Program and Downloading an Application 25
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
10 Going on 26
After building click Online menu and select Login to flash the application. (Figure 37)
10 Going on
For further Codesys assistance, check out online help either by pressing F1 or via the menu (Figures
38, 39).
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
10 Going on 27
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
References 28
References
[1] TTControl GmbH. HY-TTC 32 Driver Manual for CODESYS. D-TTC-X-G-20-009.
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.
HY-TTC 32 Quick Start Guide for CODESYS Rev. 1.0
Legal Disclaimer 29
Legal Disclaimer
THE INFORMATION GIVEN IN THIS DOCUMENT IS GIVEN AS SUPPORT FOR THE USAGE OF THE
ECU/DISPLAY UNIT AND SHALL NOT BE REGARDED AS ANY DESCRIPTION OR WARRANTY OF
A CERTAIN FUNCTIONALITY, CONDITION OR QUALITY OF THE ECU/DISPLAY UNIT. THE RECIP-
IENT OF THIS DOCUMENT MUST VERIFY ANY FUNCTION DESCRIBED HEREIN IN THE REAL
APPLICATION. THIS DOCUMENT WAS MADE TO THE BEST OF TTCONTROL’S KNOWLEDGE.
NEVERTHELESS AND DESPITE GREATEST CARE, IT CANNOT BE EXCLUDED THAT MISTAKES
COULD HAVE CREPT IN. TTCONTROL PROVIDES THE DOCUMENT FOR THE ECU/DISPLAY UNIT
“AS IS” AND WITH ALL FAULTS AND HEREBY DISCLAIMS ALL WARRANTIES OF ANY KIND, EI-
THER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ACCURACY OR COM-
PLETENESS, OR OF RESULTS TO THE EXTENT PERMITTED BY APPLICABLE LAW. THE EN-
TIRE RISK, AS TO THE QUALITY, USE OR PERFORMANCE OF THE DOCUMENT, REMAINS WITH
THE RECIPIENT. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW TTCONTROL
SHALL IN NO EVENT BE LIABLE FOR ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUEN-
TIAL DAMAGES WHATSOEVER (INCLUDING BUT NOT LIMITED TO LOSS OF DATA, DATA BEING
RENDERED INACCURATE, BUSINESS INTERRUPTION OR ANY OTHER PECUNIARY OR OTHER
LOSS WHATSOEVER) ARISING OUT OF THE USE OR INABILITY TO USE THE DOCUMENT EVEN
IF TTCONTROL HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
IF THE ECU/DISPLAY UNIT IS MARKED AS “PROTOTYPE”, THE DELIVERED ECU/DISPLAY UNIT
IS A DEVELOPMENT SAMPLE (“SAMPLE”). THE RECIPIENT ACKNOWLEDGES THAT HE IS AL-
LOWED TO USE THE SAMPLE ONLY IN A LABORATORY FOR THE PURPOSE OF DEVELOPMENT.
IN NO EVENT IS HE ALLOWED TO USE THE SAMPLE FOR THE PURPOSE OF SERIES MANU-
FACTURING.
TTCONTROL PROVIDES NO WARRANTY FOR ITS PRODUCTS OR ITS SAMPLES, INCLUDING
BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE AND TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW
DISCLAIMS ALL LIABILITIES FOR DAMAGES RESULTING FROM OR ARISING OUT OF THE AP-
PLICATION OR USE OF THESE PRODUCTS OR SAMPLES.
THE EXCLUSION OF LIABILITY DOES NOT APPLY IN CASES OF INTENT AND GROSS NEG-
LIGENCE. MOREOVER, IT DOES NOT APPLY TO DEFECTS WHICH HAVE BEEN DECEITFULLY
CONCEALED OR WHOSE ABSENCE HAS BEEN GUARANTEED, NOR IN CASES OF CULPABLE
HARM TO LIFE, PHYSICAL INJURY AND DAMAGE TO HEALTH. CLAIMS DUE TO STATUTORY
PROVISIONS OF PRODUCT LIABILTY SHALL REMAIN UNAFFECTED.
Copyright © 2017 TTControl GmbH. All rights reserved. Document Number: D-TTC-X-GU-20-002
TTControl Confidential – For use by authorized customers only. Redistribution is prohibited.