Sei sulla pagina 1di 131

Š

%HFNKRII7ZLQ&$7 

7RWDO:LQGRZV&RQWURODQG$XWRPDWLRQ7HFKQRORJ\

6\VWHP0DQDJHU
'RFXPHQWDWLRQ
7ZLQ&$79HUVLRQ
/DVW&KDQJH
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Phone +49(5246) 963-0 / Fax +49(5246)963-149


3DJHi

Contents
1. TwinCAT System Manager – Overview 1
1.1. Introduction 1
1.2. Characteristics of the I/O system 1
1.3. Philosophy of the I/O system 2
1.4. Characteristics of NC Systems 2
Linear positioning (PTP)........................................................................... 2
Servo/master functions............................................................................. 3
Servo/slave functions ............................................................................... 3
CNC ......................................................................................................... 3
2. User interface of the TwinCAT System Manager 5
2.1. User interface 5
2.2. General operator control possibilities 6
2.3. Menu 7
2.4. Logger and watch windows 8
3. System configuration method 10
3.1. System configuration 10
3.2. PLC configuration 10
3.3. Defining an I/O device 11
3.4. Defining an I/O module 12
3.5. Defining a terminal 13
3.6. Linking variables 14
3.7. Creating mappings 17
3.8. NC configuration 19
Inserting an NC task............................................................................... 19
Inserting an NC channel......................................................................... 20
Axes and their subelements ................................................................... 20
Encoder ................................................................................................. 21
Drive ...................................................................................................... 21
Controller ............................................................................................... 21
Axis variables......................................................................................... 21
3.9. NC hand menu 21
Channel ................................................................................................. 21
Group..................................................................................................... 22
Axis ........................................................................................................ 22

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page ii

Encoder ................................................................................................. 23
Drive ...................................................................................................... 23
Controller ............................................................................................... 23
3.10. Commissioning an axis 23
4. Managing a system configuration 31
4.1. Checking the configuration 31
4.2. Activating the system configuration 31
4.3. Deactivating the system configuration 31
4.4. Saving the system configuration 31
4.5. Loading a system configuration 31
4.6. Starting / restarting TwinCAT 31
5. Reference 32
5.1. General 32
5.2. Variables 32
Variables – online................................................................................... 34
5.3. Realtime configuration 34
5.4. Additional tasks 35
Creating additional tasks ........................................................................ 36
5.5. PLC projects 36
Inserting a PLC project........................................................................... 36
Single PLC projects................................................................................ 37
Multitasking in the PLC........................................................................... 38
Inserting variables .................................................................................. 38
5.6. I/O devices (field buses) 40
Beckhoff II/O Lightbus............................................................................ 40
Profibus DP............................................................................................ 41
InterBus-S .............................................................................................. 45
CANopen ............................................................................................... 50
DeviceNet .............................................................................................. 52
SERCOS................................................................................................ 53
CANopen ............................................................................................... 54
Printer interface...................................................................................... 56
COM interface........................................................................................ 56
Beckhoff IPC – special keys and UPS.................................................... 58
Beckhoff CP9030 ................................................................................... 59
Motherboard Diagnostic – SMB.............................................................. 60
Online display of the DPRAM ................................................................. 61
5.7. Field bus boxes (bus couplers etc.) 61
General notes on field bus boxes ........................................................... 61
Bus coupler ............................................................................................ 61
Boxes specific to II/O Lightbus ............................................................... 67
Profibus devices with a GSD- file ........................................................... 71

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Phone +49(5246) 963-0 / Fax +49(5246)963-149


3DJHiii

InterBus-S devices ................................................................................. 71


CANopen Devices.................................................................................. 74
DeviceNet Devices................................................................................. 76
SERCOS Axis ........................................................................................ 77
5.8. Field bus submodules (terminals etc.) 80
Bus terminals ......................................................................................... 80
Modular Profibus devices ....................................................................... 81
5.9. NC Channels 82
Standard NC channel (for PTP axes) ..................................................... 83
Interpreter NC channel ........................................................................... 84
5.10. NC Groups 85
Group Types .......................................................................................... 85
FIFO-Group............................................................................................ 86
3D-Group ............................................................................................... 87
Minimum speed...................................................................................... 88
Segment transition speed....................................................................... 88
5.11. NC axes 92
Axis types............................................................................................... 92
Units of an axis ...................................................................................... 93
Global parameters of an axis.................................................................. 93
Dynamic parameters of an axis .............................................................. 96
Online display (manual menu) of an axis................................................ 97
Functions of an axis ............................................................................... 99
Coupled axis I: Linear Slave Axis ......................................................... 101
Compensation of axes ......................................................................... 102
Coupled axis II: Flying saws ................................................................. 104
5.12. NC encoder 107
5.13. NC drives 111
5.14. NC controller 113
NC-Controller ....................................................................................... 113
Automatic DAC offset adjustment......................................................... 113
Pilot acceleration control ...................................................................... 115
Global parameters of a controller ......................................................... 115
Position controller................................................................................. 116
Controller for special axes.................................................................... 118
Dead time compensation...................................................................... 120
5.15. NC input/output 120
Input/output for NC channels................................................................ 120
Input/output for axes ............................................................................ 121
Input/output for encoders ..................................................................... 122
Input/output for drives .......................................................................... 122
6. Glossary 123

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page iv

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 1

1. TwinCAT System Manager – Overview


1.1. Introduction
Introduction In the TwinCAT system, the inputs and outputs of the participating software
tasks and the physical inputs and outputs of the connected field buses are
managed by the TwinCAT System Manager.
The individual software tasks (e.g. PLC tasks) each operate on a private
process image of their own, with the result that the addresses of the
symbols (variables) stored in the process image are only valid and relevant
locally within the respective tasks.
The I/O information of the individual software tasks is read or entered in the
TwinCAT System Manager. Moreover, the installed field buses and
modules or boxes connected to them are described.
The logical inputs and outputs are assigned to the physical ones by
logically linking variables of the software tasks and variables of the field
buses.
Additionally, optional NC configuration is realised in the TwinCAT System
Manager. To this end, the corresponding axes are defined and, if
necessary, they are grouped and parameterised. After system start up, the
axes can also be moved and set.

1.2. Characteristics of the I/O system


Supported field buses Beckhoff II/O Lightbus
Profibus DP (master and slave)
InterBus-S
CANopen (currently only Beckhoff bus couplers)
SERCOS (in preparation)
Printer Port (8 inputs and 8 outputs on a TTL basis)
Serial bus coupler BK8100 connected to COMx
Beckhoff IPC C200X (special keys and LEDs of the Beckhoff industrial PC)

Supported software tasks ,(&  636 (up to four run time systems (cf. PLC documentation) with
up to four tasks each; the tasks of one PLC run time system share one
process image)
NC/CNC tasks
Special I/O tasks for direct forwarding to user programs
Further user-defined tasks

32
Limitations Number of variables: unlimited ( < 2 )
Number of tasks: < 64 (TwinCAT System limitation)
Number of field buses simultaneously in use: unlimited (limited by the
hardware only)
32
Size of individual process images: unlimited ( < 2 ) (IEC 1131 SPS
exception: limited to 64kByte inputs and outputs each)

Task-task communication With the aid of the TwinCAT I/O system, "Inputs and outputs" of one task
can be exchanged cyclically with the "Outputs and inputs" of another task.
Data consistency is guaranteed.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 2

Multilingual capability The user interface of the TwinCAT System Managers is multilingual. The
program automatically starts in the national language that is set in
Windows NT (if the language is available). Additionally, the required
language can be changed during the run time by selecting the "Options /
Language" menu item.
English and German are currently supported.

1.3. Philosophy of the I/O system


Variable orientation The TwinCAT I/O System is variable-oriented, i.e. the smallest addressable
and linkable unit is a variable. Variables may be single bits (e.g. input bit
"Limit switch front" or "E10.4" or in IEC 1131 convention "%IX10.4"), bytes,
16-bit words or 32-bit words,... . Variables may also be structures or arrays
(fields) consisting of other data types, however.
Variables exist both on the end of the software tasks and also on the field
bus end. A physical analogue input value that has been accepted at a field
bus module – within the meaning of the TwinCAT I/O System – a variable
of a specific type (e.g. 16-bit word) and a symbolic name.

Process images Variables are always assigned to precisely one process image, i.e. the
address of the variable is unique within its process image, but only within
this process image. Every software task and every field bus has precisely
one process image (Exception: tasks of a PLC run time system share a
common process image).

Mappings The results of the TwinCAT System Manager consist of individual


mappings that contain the created associations. Mappings are each
generated between software tasks and field bus devices and between two
software tasks whenever they possess mutually associated variables. That
is to say, when variables of a PLC task are associated with the variables of
a field bus, then precisely one association is generated between these two
elements. If the same PLC task also has variables associated with another
field bus, a second mapping is generated for this.
The mappings contain the corresponding copying specifications in order to
be able to exchange the corresponding variables during the run time.

Field bus independence The nature and structure of the field bus used need not be known when
defining and programming the software tasks participating in the TwinCAT
System. Programming is done with the aid of logical variables that are
defined locally within the respective software.
It is only in the TwinCAT System Manager that these logical variables are
associated with other variables, which correspond either to physical inputs
and outputs on the field bus or logical variables of other tasks. The type
and the special characteristics of the respective field buses need not be
known or need not be taken into account.

1.4. Characteristics of NC Systems


Linear positioning (PTP)
In software terms, an axis for linear positioning (PTP) is subdivided into the
actual axis, the setpoint generator, the encoder, the drive and the
controller.

Master axis types Servo, stepper motor axes, rapid traverse/creeping axes, table axes, virtual
axes (encoder axes), FIFO axes,

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 3

Slave axis types Servo, table slave (cam disc), multi-table slave (slave with several series
and parallel cam discs), parallel and diagonal coupling (“flying saw“).
Setpoint generators (i) Actual setpoint generators:
e.g. run time table generator in SVB task,
e.g. external for table axis.
(ii) Setpoint data retention:
e.g. run time table in abbreviated form,
e.g. table of output data,
e.g. FIFO with output data.
(iii) Tables/FIFO types:
Master table axis, generally time-controlled
Time -> (position,[speed, acceleration, ...]).
Table slave, generally as point-to-point control
Master position -> Slave position.
(iv) Setpoint output in SAF task:
e.g. offsetting of run time table data in output data and its output,
e.g. output of table data,
e.g. FIFO management and output of data.

Servo/master functions
Basic functions Start from current position to target at nominal speed, acceleration,
deceleration, jolt and possibly automatic reduction of the nominal speed if
the distance is too short to reach the nominal speed.
Stop, i.e. controlled stop.
Speed override.
Extended functions New target position: travel to a target position set online or stop if the latest
target position has been exceeded or if stopping in good time is no longer
possible.
Endless in the forwards/reverse directions.
Special functions Distance compensation with start and stop.

Servo/slave functions
Basic functions Coupling (at standstill) a slave axis to a master axis with a coupling factor
(transmission factor).
Decoupling at standstill.
Online modification of the coupling factor.
Extended functions Online decoupling with conversion of the slave axis to a master axis for
individual stopping of the slave and master axis.
Special functions Distance compensation with start and stop.
Topologies Star configuration,
Linear configuration (cascade).

CNC
Structure The topmost unit is an NC channel, which is characterised by the fact that
it possesses precisely one interpreter that defines and synchronises the
dynamics of all the channel's axes. A channel may consist of several
groups, whereby a group is characterised by the fact that it possesses
precisely one setpoint generator that converts the interpreter NC
commands for the group to synchronised dynamics of all axes in the group.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 4

Interpreter There are various types of interpreter which are special expansions of
DIN66025. The interpreter enables the realisation of radius and tool
compensations as well as geometric operations (mirroring) on the contour.
Groups Look ahead, automatic curve speed reduction

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 5

2. User interface of the TwinCAT System


Manager
2.1. User interface
The user interface of the TwinCAT System Manager consists of a mostly
two-part view. The left-hand section shows a tree structure in which all
elements of the I/O configuration (tasks, process images, variables, field
bus interface cards and field bus modules etc.) are listed.

Tree structure

The left-side of the System Manager consists of the main points:


0HDQLQJ
1&FRQILJXUDWLRQ Under this entry, the NC is configured, i.e. NC channels and
NC axes are created, configured and parameterised. An
ONLINE hand menu is also integrated.
3/&FRQILJXUDWLRQ Under this entry, all PLC projects that are running on the
local system are listed (currently up to four projects).
,2FRQILJXUDWLRQ The I/O configuration is defined under this entry.
$GGLWLRQDOWDVNV Besides the PLC, it is also possible to integrate additional
programs (Tasks) in the system (e.g. controller, NC/CNC,
...).
,2GHYLFHV Corresponding field bus interface cards are necessary to link
the control to the process level. Which cards are used must
be defined under this entry.
0DSSLQJV The result of I/O configuration is represented graphically
under this entry.
All further elements are inserted or generated under these main items.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 6

2.2. General operator control possibilities


Inserting tree elements There are several possibilities of inserting elements in the tree, all of which
lead to the same result (the requirement being that the element is marked
in the tree under which a new element is to be inserted):
1. <INS> key
2. Tool bar: by clicking the icon shown on the left
3. Context menu: by right-clicking the higher-level element in the tree
or by pressing the keystroke combination <ALT-ENTER>, the context
menu is opened. It then offers a menu item for adding or inserting.

Deleting tree elements There are also several possibilities of deleting elements from the tree (the
requirement being that the element to be deleted is marked in the tree):
1. <ENTF> key
2. Toolbar: by clicking the icon shown on the left
3. Context menu: the context menu is opened by right-clicking the
corresponding element in the tree or by pressing the keystroke
combination <ALT-ENTER>. A menu item for deleting is offered in
this context menu.

Context menu Besides insertion and deletion, further actions referring to the element may
also be offered in the context menu of a tree element, e.g.:

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 7

Element-oriented view When an element is selected in the tree, a element-oriented view is offered
– provided it is available – on the right-hand side in the form of file cards.
Depending on the element, further information is also displayed in the
bottom portion of the right-hand side (see Figure).

The file card sliders can be selected by clicking them and provide further
information or input possibilities for the respective tree object.

Keyboard operation All operator controls can also be reached by means of the keyboard and
without the mouse.
.H\V
6ZLWFKLQJIURPZLQGRZWRZLQGRZ You can switch between the individual windows by
pressing the <F6> key and the <SHIFT-F6> key
(tree -> file cards -> additional display (if available) -
> tree...).
6ZLWFKLQJEHWZHHQILOHFDUGVOLGHUV When the window with the file cards is selected,
switch with the <TAB> or <SHIFT-TAB> key
through the control elements until the tab has the
focus. Then select the desired tab with the arrow
keys.
2SHQLQJWKHFRQWH[WPHQXVRIWUHH Select the desired element and then press the
HOHPHQWV <ALT-ENTER> keys.

2.3. Menu
The menu items that exist in addition to normal Windows programs are
briefly explained below.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 8

Actions Create mapping


See "Creating mappings" on Page 17.
Save in registry...
See "Activating the system configuration" on Page 31.
Read I/O server version
When TwinCAT is active, this option allows you to query the version of the
I/O server, e.g.:

View Show logger output


When this option is active, a window is opened over the status bar in which
copies of the arriving messages in the system logger are displayed.
Show watch window
When this option is active, a window is opened over the status bar in which
watched variables and their online values.
Show current real time load
When this option is active, an area is opened in the status bar in which the
current real time load is displayed.

Show online data


Allows you to switch off or switch on a display of online data (when
TwinCAT is active).
Show subvariables
Allows you to switch off or switch on a display of subvariables in diverse
lists.

Options Language ->


Allows you to change the language of the TwinCAT System Manager
during the run time.
Check IEC1131 project changes
When this option is active, a cyclic check is run to determine whether the
IEC1131 projects in the configuration have changed. If a change is
detected, you are prompted to read the applicable project again.

2.4. Logger and watch windows


Additional windows can be opened above the status line in which outputs
of the system logger and watched variables and their online values can be
displayed.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 9

Logger and watch windows

Variables can be displayed via their context menus in the watch window or
can be removed from it.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 10

3. System configuration method


3.1. System configuration
A possible system configuration method will be described in the following
section.

3.2. PLC configuration


Reading a PLC project The individual PLC projects must be read in the System Manager to enable
TwinCAT to access the variables of these PLC projects. To do this, press
the right mouse button when the mouse pointer is above ’PLC-
configuration’.
A context menu opens, in which you must select the ’Add IEC project...’
entry (currently the only selection):

Enter the path and the name of the PLC project with its file extension (.pro)
or select the corresponding project file on your data medium.

A further point, which bears of the name of the PLC project, is added under
’PLC configuration’. The symbol and the symbol indicate an entry
contains a further sub item. The underlying entries open or close when you
click these icons.
If you now open the tree as far as possible, you arrive at the following
structure:

All variables that have been declared as inputs/outputs in the PLC program
are now listed under the ’Inputs’ and ’Outputs’ items. The notation is <POE
name>.<Variable name>.
In the case of multitasking projects, cf. "Multitasking in the PLC" on Page
38.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 11

3.3. Defining an I/O device


Defining an I/O device Once the PLC project has been added to the I/O configuration and thus all
I/O variables are known, it is necessary to specify and to define the I/O
devices (field buses). Right-click the ’I/O devices’ entry.
A context menu opens, in which you must select the ’Add device...’ entry.

Select the device type, e.g. ’II/O Lightbus C1220’. The device name can be
chosen freely.

A dialog box now opens on the right, in which you can specify the
configuration or the interface card. One important setting is the I/O address
of the C1220 card under the ’C1220’ tab, for example. If you have not
made any changes to the card’s default settings, you can accept the
existing entries.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 12

3.4. Defining an I/O module


Inserting a field bus module Open the context menu of the C1220 card (device 1) and select the ’Insert
(box) box...’ command.

Select the field bus module type, e.g. ’BK2000’. The field bus module name
can be chosen freely.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 13

3.5. Defining a terminal


If necessary, inserting sub Modular boxes consist of individual sub modules that can be specified
modules of boxes (e.g. bus under the boxes. In the case of bus couplers, the sub modules are
terminals) terminals. Therefore, the corresponding terminals are inserted.
Open the context menu of the box "BK2000 (Box 1)" and select the ’Add
terminal...’ command.

All available terminals are offered in the following dialog. Successively


select the terminals in the sequence in which they are fitted on the bus
coupler. If several terminals of the same type are needed, these can be
inserted all at once. To do this, you must specify the corresponding
quantity under "Multiple".

For example, select the terminal with the designation KL 1104. Proceed
analogously with the KL 2114 and KL 9010 terminals. In the terminal
selection, you will find the bus terminal KL 2114 under ’Digital output
terminals’ and the bus terminal KL 9010 under ’System terminals’. Make
sure that the terminals are added in the right orders. Then, the
configuration has the following structure:

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 14

Automatic generation of By the insertion of field bus devices, boxes and modules, variables are
variables on the field bus generated automatically and are placed in the process image of the
respective field bus device. For example, if a four-channel digital input
terminal is inserted, four binary input variables are generated and are
sorted into the process image of the field bus device. The address of the
variables is only relevant for internal diagnostic purposes because all
necessary address calculations are realised by the System Manager.

3.6. Linking variables


Once all software tasks and field buses have been defined or read, their
variables can be linked. The direction in which they are linked – Variable A
with Variable B or Variable B with Variable A – is left to the user's
discretion. That is to say, whether the PLC variables are linked with field
bus variables or whether field bus variables are linked with PLC variables,
for example, is identical.

Linking variables To link variables, the corresponding variable must be selected in the tree
view (if necessary, expand the display further) and you must either open its
context menu or you must click the "Linked with..." button on the right. The
following dialog opens:

Linking dialog

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 15

In this dialog, possible variables with which the currently marked variable
can be linked are displayed. The variables are displayed with their name,
address (referred to their respective process image), type and owner. In
the case of more complex variables – e.g. structure members – extended
information (hierarchical name similar to path information) can be created
when the mouse is positioned over the respective name (requirement: the
"ToolTip" check box has been selected).

Advance selection of offered The selection of offered variables can be influenced by way of the check
variables boxes and radio boxes located on the right.
6KRZYDULDEOHV
8QXVHG Only variables that have not yet been linked with
other variables are displayed
$OO Even already linked variables are displayed (this is
meaningful in the case of multiple linkings).
6KRZYDULDEOHW\SHV
6XLWDEOHW\SH Only variables are displayed that are of the same
type as the currently selected variable
6XLWDEOHVL]H Only variables are displayed that have the same
size as the currently selected variable
$OOW\SHV All variables are displayed regardless of their type
and size
Sorting the display The list of variables can additionally be sorted according to the criteria
Address, Name, Type and Owner.

Multiple Linking Multiple linkings can be realised in two ways, but their result is once again
identical.
1. One variable is linked with several others. To do this, several
variables are selected in the list of available variables in the linking
dialog (use the Ctrl and shift keys).
2. Several variables are linked with one and the same variable. To do
this, you create the first link in the normal way and, for the next links,
you must select "Show variables > All" to ensure that the target variable
already linked appears in the dialog again.
Make sure that only input variables are multiply linked. Multiple linking of
! output variables may lead to undefined states.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 16

Linking variables of differing If variables of differing size are linked ("6KRZYDULDEOHW\SHV!$OOW\SHV), the result
size of linking is no longer unique. Depending on the "&RQWLQXRXV" check box,
either the following dialog appears ("&RQWLQXRXV" nor selected):

In the example shown, the source variable is one bit large and the variable
with which it is to be linked is 9 bits large. In the dialog, you can specify an
offset so as to ensure that the desired bit in the 8 bit large variable with
which the individual bit of the source variable is to be linked can be
selected.
If the "&RQWLQXRXV" check box is selected, the variables are automatically
allocated continuously (without a corresponding dialog). That is to say, if an
8 bit large output variable, for example, is linked and if one or several bit
variables are selected in the dialog, these are linked continuously (the first
bit variable with the first bit of the output variable and the second bit
variable with the second bit etc.).

Linking of multiple linking In some cases, it is sensible to link multiple linking with the linking of
and variables of differing variables of differing sizes. For example, if eight digital inputs are defined
sizes on the field bus, but their input result actually consists of one coherent
byte, one input byte can be defined in the PLC and this byte can be linked
with the eight bits.
To do this, you select the corresponding byte in the input image of the PLC
in the tree view and you open the linking dialog. To ensure that the
required eight bits appear in the list, you must select the (" 6KRZYDULDEOHVW\SHV!
$OOW\SHV) item. All eight bits can now be marked together. When you end the
linking dialog, the above-described "Variable size difference" dialog
appears for each of the eight linkings and you can specify one offset for
nd
each bit (1st bit > Offset = 0; 2 bit > Offset = 1; ...).
Alternative An alternative approach (particularly in connection with the PLC) is offered
by the possibility available in the PLC of defining several variables at the
same address. Therefore, it is possible to define one input byte, e.g. at the
address %IB 7, and to simultaneously define eight input bits at the
addresses %IX 7.0, %IX 7.1 etc. Now, the input bits can be linked normally
with the input bits of the field bus and both bit-by-bit as well as byte-by-byte
access to the input data is possible within the PLC.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 17

Block linking A selection is made in the variable group view (see left and bottom) and a
context menu can be opened by right clicking.

Context menu: Modify single link...


The linking dialog is opened successively for each of the marked variables.
Modify multi links... (only if all addresses of the variables are in
succession)
The variables are temporarily linked in one variable and the linking dialog is
then opened. The variables – or the temporary variable – can now be
linked with one or several target variable(s).
Delete...
All links of the marked variables are deleted.

3.7. Creating mappings


The mappings can be created once all links have been completed.
Mappings (mappings) represent the complete information that is needed
for the cyclic exchange of variables belonging to two process images. This
essentially includes the copying specifications that reflect the links defined,
but also the partly field bus-specific information with which the
corresponding field bus device transports the required data via the field
bus.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 18

All necessary mappings are generated by clicking the tool bar icon shown
on the left or by selecting the "Actions / Create mappings" menu item. The
result is inserted in the tree view under the main item "Mappings".

The displayed information only serves diagnostics purposes and, with the
following exception, does not require any further treatment.

Watchdog in the case of


asynchronous mappings

Mappings are either synchronous or asynchronous. The selection is made


automatically with reference to the process image types involved.
In the case of asynchronous mappings, a watchdog can be activated that
monitors regular serving of the mapping by both process images. If the
watchdog is active (watchdog value > 0), the watchdog is triggered after n
x serving of a process image’s mapping if the other process image has not
served the mapping in the meantime.
For example, this case occurs if a PLC is stopped during mapping during
the NC and PLC (mappings between two tasks are always asynchronous).
The NC continues to get the data (enabling messages etc.) which is no
longer updated by the PLC. When the watchdog is active, the data is set to
zero by the PLC after expiry of the watchdog cycles.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 19

3.8. NC configuration
If TwinCAT is installed with NC functionality, a "NC configuration" item
exists in the System Manager’s tree view. In this menu item, the required
axes can be created and their parameters can be set. During TwinCAT’s
run time, the axes can then be moved and adjusted via corresponding
online pages (hand menus).

Inserting an NC task
Creating the NC By inserting an NC task, you integrate an NC configuration into the current
configuration: system configuration and you created the corresponding initialisation
commands for the NC server.
Besides the NC-SAF task (block execution), you implicitly also create an
NC-SVB task (block preparation). The cycle time and the priorities of the
tasks can be adapted in the corresponding dialogs:

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 20

Inserting an NC channel
Adding a channel Individual point-to-point axes (PTP) and also groups of axes (e.g. an
interpolating 3D contour group) are sorted into channels in the TwinCAT
NC System. Therefore, in the next step at least one channel must be
added under the NC-SAF task. Two kings of NC channels are currently
available for selection:
1. Standard channel: In the standard channel, axes that do not belong to
specific groups of axes during system initialisation are created. These
particularly include PTP axes, which are moved as independent axes
independently of other axes, but also of contour axes that are not
grouped – online – until after initialisation and are then interpolated
with other axes when moved. Normally, only one standard channel
exists because the sequence of the axes defined in the channel is
irrelevant.
2. Interpreter channel: an interpreter channel contains the axes that are
supplied together by one interpreter. These axes are sorted into
groups, whereby a group is defined by its own setpoint generator.
That is to say, interpolating axes of an interpreter channel are linked in
a group and any necessary auxiliary axis that is controlled by the
same interpreter, but which has a setpoint generator of its own, is
placed in a further group.

An example configuration is shown in the figure on the left. It defined two


independent PTP axes in the standard channel (axes 1 and 2) and also
has an interpreter channel in which a 3D group (axes 3-5) and an
"Auxiliary" axis (6) controlled by the same interpreter. The axes in the
standard channel are not grouped or their PTP groups are created
implicitly and are not visible in the configuration because they do not
perform any functions that are visible to the user either.
The type of a group in the interpreter channel simultaneously defines the
interpolation type or setpoint generator of the axes linked in it (see
reference).
In the configuration, or during system initialisation, all groups of an
interpreter channel needed later on must be created. However, they do not
need to be filled with the corresponding axes because this can also be
done during the run time by "taking out" the axes from other groups or also
from other channels.
Inserting a group: Only possible or necessary in interpreter channels.
Besides the name of the group, its type must also be selected (see
reference).

Inserting an axis: This is possible in standard channels or in groups of an interpreter channel.


Besides the name of the axis, its type must also be selected (see
reference)

Axes and their subelements


When axes are inserted in the NC configuration, a few subelements and
variables are automatically created (see figure on left). Each axis is
assigned an encoder, a drive and a controller, whose I/O interface and
parameters can be entered.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 21

Encoder
Selecting a type:

The type of the encoder or of its I/O port can be selected in the combo box.
When you select the "Linked with..." button, all correspondingly existing I/O
ports are listed and you can select the one your require. All necessary
variable associations are created automatically.

Drive
Selecting a type: As in the case of encoder, the type of the drive or its I/O port can be
selected and can associated with the corresponding port (see Encoder)

Controller
Selecting a type: Here, you can select the controller type. The controller does not required
an I/O association, with the result that no association is necessary.

Axis variables
Under the "Inputs" and "Outputs" items, one structure each is automatically
inserted which generally has to be associated with the PLC. To do this,
corresponding variables must be created in the PLC (the structure
definitions can be found in "PLCNC.LIB"). These structures serve the
purpose of exchanging information between the NC and the PLC (e.g.
enabling signals etc.). See also "Linking variables"

3.9. NC hand menu


The NC hand menu serves the purpose of naming, parameterising and
functionally operating channels, groups, axes, encoders, drives and
controllers and of creating the I/O interface between the axes and the PLC.

Channel
Channel menus (i) In the case of CNC channels: interpreter (selection of interpreter
types).
(ii) Online (display of the actual values and setpoints of the axes
belonging to the channel).

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 22

Group
Group menus (i) DXD (group parameters).
(ii) Online (display of the group status).

Axis
Axis menus (i) Global (general parameters).
(ii) Dynamics (dynamic parameters).
(iii) Online (axis hand menu, basic functions) .
(iv) Functions (extended functions).
(v) Coupling (master slave functions).
(vi) Compensation (special functions).

"Online" manual axis menu

The Online menu allows you to set the essential starting parameters such
as:
(i) Target position
(ii) Nominal speed,
(iii) Reference speed,
(iv) Controller Kv factor,
and to call up the fundamental axis functions such as
(i) Start,
(ii) Stop,
(iii) New target position.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 23

Encoder
Encoder menus (i) NC encoder (encoder selection)
(ii) Global (general parameters).
(iii) Incremental (special parameters).
(iv) Online (display).

Drive
Drive menu (i) NC Drive (drive selection).
(ii) Global (general parameters).
(iii) Analogue (special parameters).
(iv) Stepper motor (special parameters).

Controller
Controller menus (i) NC controller (controller selection)
(ii) Global (general parameters).
(iii) PID (special parameters).

3.10. Commissioning an axis


The following description explains all steps of commissioning an axis.
Several axis types and a whole series of different situations are covered.
Every step names all settings to be made, even if these are identical with
the settings made in the previous step. In practice, you will only actually
carry out some of the listed substeps for an axis.
If you already have experience with axis commissioning under TwinCAT, it
is not always necessary to perform each of the steps. In this case, you
should use this description as a reference work and for help with problems.
Necessary prerequisites: A few preparations must be made before the actual task of commissioning
can begin.
• Check the completeness and correctness of all electrical connections.
• All components of the axis encoder, drive, controller and PLC
interface) must be created according to the right type and must be
linked to the right resources (PLC variables and I/O hardware in the
field bus etc.).
• The NC architecture not only has to be created, but must also be
written into the Registry and TwinCAT must have been started with it.
Recommended safety As far as possible, the following safety precautions should be taken.
precautions: • Secure the system against entry or reaching into it: the machine may
exhibit unforeseeable behaviour during commissioning.
• Rule and divide: isolate the part of the system that you are currently
working. What you currently do not need should be reliably shut down
because it may only interfere or divert your attention.
• Draw the attention of all persons in the surroundings to the fact that
there is an increased risk of accidents.
• Make sure that you are undisturbed: those who do not need to be in
the proximity should not be there.
Sequence As the individual axis commissioning steps are logically based on one
another, you must keep to a specific sequence. Nevertheless, this
sequence depends on the respective axis composition, i.e. on the
combination of encoder, controller and drive types.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 24

Stepper motor drives This point concerns stepper motors only.


A stepper motor is controlled with the aid of masks. These are packets of
eight bits that correspond to the control signals of the motor. These signals
are each output in one phase and activate the affiliated winding of the
motor. A special mask is output at shutdown and serves to activate the so-
called holding current. The masks depend on the motor control and the
control cabinet wiring used and cannot be specified generally.
Refer to the drive manufacturer or electrical design document for details of
the bit combinations and enter them on the stepper motor tab of the drive.
If the axis shows incorrect behaviour during further commissioning steps,
these masks must primarily be checked.
Make inputs in the form of decimal numbers. To convert a bit pattern to the
value that needs to be entered, the weighting must be determined for each
bit with the value "1".

Bit 0 1 2 3 4 5 6 7

Weighting 1 2 4 8 16 32 64 128

Example: in the bit pattern 00101011, the bits 0, 1, 3 and 5 are "1". The
affiliated weightings are 1, 2, 4 and 32. Therefore, the total to be entered is
39.
Actual value acquisition: Without correct acquisition of actual values, an axis is "blind" and cannot
direction determination behave in a co-ordinated fashion. Therefore, commissioning must begin
here. To this end, two items of information must be determined or checked:
the counting direction and the increment evaluation.
• Find out or define which motion direction of the axis is to be "positive"
or "ascending" or "upwards". When travelling in this direction, actual
value acquisition must return ascending values.
• If you have a possibility of electrically blocking the drive and of moving
the axis manually, turn the drive so that the machine moves in the
"positive" direction, for example, and observe the actual value display
in the online display of the axis.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 25

• If this possibility is not available, you must necessarily turn the axis
with the drive. This means that you are commissioning an
unparametrised axis. Particular caution is necessary because you will
be rendering all controls and monitoring functions inactive. The axis will
be run with pure pilot control and with fictitious data. Proceed as
follows:
• If you can isolate the load from the drive (e.g. by removing belts or
other transmission elements) without also isolating the encoder,
then it is imperative that you should do this!
• Set a value of 1.0 on the global tab of the controller for the pilot
control weighting.
• If the controller has a PID tab, set the positioning control factor Kp
(and all other control factors) to zero. Deactivate the automatic
offset adjustment.
• In the global tab of the drive, set the output limits to +0.1 or–0.1.
• If the drive has an analogue tab, set the reference speed to a
fictitious (not to low a) value and set the reference output ti 1.0. Set
drift compensation to zero.
• At the maximally allowed speed, in the global tab of the axis set
the same value as in the case of the drive's reference speed. Set a
tenth of the same value under speed manual max. and speed
manual min.. Deactivate all end stop, following error and other
monitoring functions.
• Make sure that there is no one in the danger zone.
• With extreme caution (hand on the Emergency Stop button),
electrically activate the axis. It must not exhibit any motion from
any drift.
• In the online display, use the <F2> or <F3> key to now start the
axis in the "lower" or "higher" direction and observe the machine
while doing so. If the machine should move in the "higher" direction
when you press <F2> and if it should move in the "lower" direction
when you press <F3, modify the motor polarity in the global tab of
the drive and repeat this step.
• Now compare the motion direction of the machine with the
counting direction of the actual value display in the online display.
If the counting direction is opposite to the defined direction of motion,
modify the inverted encoder counting direction (polarity) parameter in the
encoder's global tab. In doing so, you should denergise the drive.
Actual value acquisition: Once the counting direction of the drive has been determined, you must set
increment evaluation the increment evaluation. This value must be set in the scaling factor on
the encoder's global tab.
• The value can be calculated if the feed rate per revolution and the
number of increments (not the number of pulses !!!) are known.
Nevertheless, check the value as follows.
• If you still do not know an increment evaluation value, at least set an
estimated value. If you have no information whatever about the value
that needs to be set, select a fictitious value such as 0.01 mm.
• When carrying out a later check, it goes without saying that you should
base your actions on the previously determined value.
• You must now "run" a trial movement (as when determining the
direction" over a known distance. The correct value is then calculated
on the basis of the currently set scaling factor multiplied by the actual
distance divided by the displayed distance.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 26

Actual value acquisition: This point is only necessary for absolute encoders.
datum offset In the case of incremental systems, at this time (with the drive switched off
followed by reset in the online display of the axis) you should set the actual
value to a meaningful value. You will find the entry boxes and function keys
needed for this purpose on the function tab of the axis. You should enter
the value 0 as the value for zero point correction. To adapt the dimension
system of the axis to the machine, on these encoders you use the
calibration function, whose parameters will be determined in a later step.
• Determine the position of the axis within the machine. No rules of
thumb can be given here. This can only be defined by the machine
manufacturer. In many cases, the distance from one reference point on
the moving machine part to a reference point on the fixed machine
body is chosen.
• If it should not be possible to determine this position to the required
degree of accuracy, make a provisional setting and repeat this step
later.
• Set the difference between the determined position and the displayed
position with the inverse sign in the datum offset on the encoder’s
global tab. If a value is already entered there, alter the existing value
by the new one by adding up. If positioning control should already be
active (when repeating this step later), you should electrically shut
down the drive and you should reset the axis before switching on
again.
• Example: the determined position is 752.0 mm, whereas the displayed
position is 1983.52 mm. Therefore, the difference is 1231.52 mm. If still
no value is entered in the datum offset, you can directly enter–1231.52.
If a datum offset should already be entered, add the new value.
Therefore, in this example, the new value–1081.52 mm would result
from +150.0.
Further encoder parameters: The encoders offer a series of operating modes as an optional setting. For
example, these include determination of the actual speed or of the actual
acceleration. If required, these measurements can be activated in the
encoder's global tab. If these values are not relevant, though, they should
be cancelled because determination of the values increases the real time
load slightly.
A modulo factor can be set as a further possibility. This is particularly
interesting in the case of round axes because the relative position within
one revolution and the number of revolutions can be determined
automatically.
The drive parameters: • Use the encoder! Limit the travel distance with the aid of the software
direction determination end stop Min / Max on the global tab of the axis.
• In the global tab of the drive, set the output limits to +1.0 and/or –1.0.
• Set a value of 2.0 on the global tab of the controller for the pilot control
weighting..
• If the controller has a PID tab, set the position control factor Kp (and all
other control factors) to zero. Deactivate the automatic offset
adjustment.
• If the drive has an analogue tab, set reference speed according to the
machine manufacturer's data to an approximately correct value and the
reference output to 1.0. Set the drift compensation to zero.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 27

• In the global tab of the axis, for Maximum allowed speed, set the same
value as for Reference speed of the drive. Set a tenth of the value
under Speed Manual Max and Speed Manual Min.
• If the controller has a PID tab, set the position control factor Kp (and all
other control factors) to zero. Deactivate the automatic offset
adjustment.
• In the online display, now start the axis with the <F2> or <F3> key in
the "lower" or "higher" direction and observe the machine. If the
machine should move in the "higher" direction when you press <F2>
and if it should move in the "lower" direction when you press <F3>,
change the motor polarity in the drive’s global tab and repeat this step.
The drive parameters: pilot This point is only necessary if the drive has an analogue tab.
control • Set a value of 1.0 for the pilot control weighting on the controller’s
global tab.
• In the drive's global tab, set the output limits to +1.0 or –1.0.
• On the PID tab of the controller, set the position control factor Kp to a
low value. If the setting is correct, the following error will be clearly
recognisable during the trial runs, but will be constant. Example: 1
(mm/sec)/mm or 60 (mm/min)/mm.
• On the drive's analogue tab, set the Reference speed to an
approximately correct value confirming to the machine manufacturer's
data. Set the drift compensation to zero. According to the machine
manufacturer's specifications, set the reference output to 1.0 if it refers
to 100% (or 10 V). For a 90% (or 9 V) setting, for example, set 0.9
accordingly.
• In the global tab of the axis, set approximately 90% of the value of the
drive's reference speed for Maximum allows speed. Under Speed
Manual Max and Speed Manual Min, set a tenth of the value.
• On the dynamics tab the axis, set a provisional value of approximately
200mm/s² for acceleration and deceleration and a jolt of 500mm/s³. If
the constant speed should not be reached on the available travel
distance with these values, then increase the values while retaining the
ratio.
• In the online display, now start the axis with the <F2> or <F3> key in
the "lower" or "higher" direction and observe the signs of the overall
outputs and of the controller output.
• If both values have the same signs, the axis is reacting at a lower
speed than taken into account by the pilot control. In this case, reduce
the Reference speed. If the signs are opposite, the axis is faster than
planned by the pilot control. Then, increase the Reference speed.
• If the controller output is clearly lower than 10% of the overall output,
the Speed Manual Max can be set in steps to higher values up to
approximately 50% of the maximum speed. Continue the trial runs with
the <F1> and <F4> keys.
• If the pilot control setting is good, the controller output should show
less than 1% of the total output. Difficult mechanical conditions do not
always allow such an exact adjustment, however.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 28

The drive parameters: This setting is only possible if the drive has an analogue tab.
Drift compensation When an analogue setpoint is specified, a voltage offset frequently occurs
between the controller and the power section. This may consist of a real
voltage drop. The cause, however, is almost always due to the fact that the
zero point adjustments of the two sides do not agree. In this case, the axis
will slowly move out of its position with the position control switched off, i.e.
it will drift. An active position controller will stop it at quite a distance from
the nominal position. This involves a greater or lesser following error,
however.
In this case, it is possible to compensate the offset with a constant speed
offset. At the same time, however, the DAC resolution of a few mV has a
disturbing effect.
Alternatively, some controllers offer the possibility of automatic offset
compensation.
The drive parameters: In some cases, it is necessary to limit the control of the power section that
output limiting is output with a drive. You will find corresponding input possibilities on the
global tab of the drive. However, you should not make this setting until you
have completed axis commissioning. Up to this time, the values–1.0 and
+1.0 should be entered there for the minimum and maximum limits.
Otherwise, the measurement described here would be manipulated.
Position control: Generally, under TwinCAT axes are operated with a pilot control weighting
pilot control weighting of 1.0. In rare cases, it may necessary to deviate from this setting. This is
case whenever the axis exhibits a highly non-linear relationship between
control and speed. Hydraulic valves with bent characteristics are an
example. In this case, the weighting must be reduced until the axis no
longer exhibits any leading behaviour. Here, it is generally necessary to
use more complex controller types with an I component in order to achieve
an acceptable positioning responses.
Position control Position control serves to compensate slight residual positioning errors.
These residual errors may be caused by load changes, friction-related and
other non-linearities, slight inaccuracies in a series of axis parameters,
offsets and temperature dependence relationships etc.
Position P controller With this controller, a compromise must be found between the wish for
control that is as complete as possible (i.e. a large Kp) and a slight
tendency of the system to oscillate (i.e. a low Kp). In practice, it has been
found that this compromise can be found swiftly by increasing the Kp value
in steps.
The method is conceivably simple, i.e. carry out trial runs in both directions.
During constant travel, pay attention to smooth running of the axis without
any recognisable position control oscillation. At the same time, a slight
noise component in the controller output can be ignored. In the approach to
the target, make sure that the axis never exhibits any tendency to oscillate
(recoil). The Kp factor can be increased in small steps (factors of 1.2 to
1.5) until the axis exhibits the first signs of a tendency to oscillate. Then,
the Kp factor should be reduced by approximately 20% to arrive at a safety
clearance from the stability limit.
As already mentioned, some controllers offer the possibility of an automatic
offset adjustment. This function can be activated on the controller's PID
tab. Then, the filter time and the pilot control limit must be specified as
parameters.
Generally, a value within the range of some seconds is advisable for the
filter time. In any case, it must be remembered that the filter time should be
very high in comparison with the response of the axis. If it is too low, a so-
called phase shifter oscillator occurs: then, the axis oscillates at a very low
frequency.
With the pilot control limit, it is possible to ensure that automatic adjustment
during active positioning is not limited by dynamic behaviour of the axis. A
nominal speed above this value results in "freezing" of the offset.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 29

Position PP controller This controller only differs from the aforementioned controller by virtue of
the fact that it is possible to apply a Kv value during active travel that is
different to the one applicable to position control around standstill.
Here, a second Kv value and a speed threshold can be set as additional
parameters. The result is a floating transition between the Kv values in the
speed range between 0 (standstill) and the threshold.
Axis parameters A series of further parameters can be set on the global tab of the axis that
define the behaviour of the axis and which control a series of monitoring
functions and status signals.
With the maximum speed, you can define what value all inputs to the axis
are to be limited to. Here, you should set a value of around 90 to 95% of
the drive’s maximum speed. The remaining modulation is needed for the
controller to ensure correct positioning.
When using an NC interpreter, certain commands position the axis with
control actions that correspond to a rapid traversing speed. Here,
approximately no more than 90% of the maximum speed of the axis should
be selected.
The Min and Max manual travel speeds can be chosen freely and depend
more or less on the operator’s "courage". In practice, it has proven
expedient to set these speeds approximately to a 1 to 5 ratio. It goes
without saying that the values must be less than the maximum speed.
Speed referencing travel in the positive direction only affects axes with an
incremental encoder. The axis travels at this speed when searching for the
calibration cam. The direction is set on the encoder’s incremental tab.
Speed referencing travel in the negative direction only affects axes with an
incremental encoder. The axis moves at this speed when moving away
from the calibration cam and when searching for the synchronisation pulse.
The direction is set on the encoder’s incremental tab.
The positive / negative direction pulse width values define the distance to
be travelled over that is covered when the axis is started by the PLC in the
corresponding travel modes. For further details, refer to the PLC module
descriptions.
You can activate a travel range limit in both the downward and upward
directions and you can set the position.
In the case of axes with an analogue tab (i.e. not in the case of rapid
traversing/creep or stepper motor axes), the following error (difference
between the nominal and actual positions) is determined constantly.
Monitoring of this value with an adjustable threshold can be activated. At
the same time, a filter time can be specified that prevents alarming
whenever the threshold is exceeded briefly, e.g. during acceleration or
deceleration.
Two windows can be placed around the target position of a motion. The
width of the windows can be chosen freely. In this way, it is possible to
generate a signal to the PLC at any distance from the target. One of these
windows additionally offers a filter time. The signal is not generated until
the axis was inside the window without interruption for the period of time
set there.
In the case of rapid traversing/creep axes, it is possible to always travel to
each target from the same direction and over a minimum distance. In the
event of asymmetrical axis response or mechanical looseness, this ensure
greater accuracy. This response can be activated and the distance can be
specified. The sign of the set distance defines the direction.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 30

In the case of servo axes, with the "Backlash on reversal compensation"


mode it is possible to balance out mechanical backlash in the axis. In this
case, the value entered as the "Backlash on reversal" defines the distance
by which a travel destination is crossed over. With the sign of the value,
you define in which direction it is crossed over. If the backlash on reversal
is positive, the target is only crossed over when travelling in the positive
direction. Travel in the direction of smaller positions is not influenced. This
response is reversed when the backlash on reversal is negative.
Axis dynamics The values for the acceleration, the deceleration and jolt limiting must be
set on the dynamics tab of the axis. Two possibilities are offered. Direct
input as numeric values or indirect definition via the ramp time and the
acceleration characteristic.
The values to be set here are the parameters to be kept to by the setpoint
generator. Often, drive manufacturer’s state values that lead to a very hard
positioning response of the axis when they are adjusted here.
The reason for this is that the stated values represent the limits of the
power section or of the motor. Then, the response of the machine is
generally already highly load-dependent. This results in substantial
following error fluctuations that trigger intervention by the position
controller. However, the axis can scarcely still react to the controller output
because it is already at the current limit.
The "correct" values for an axis depend considerably on the endeavoured
response and the characteristics of the drive technology and of the
machine. They can only be determined by test runs. In doing so, increased
values should be tested in steps by observing the following error during
starting and stopping.
In practice, it has been found that the numeric value of the jolt should be
approximately twice (for machining axes) to ten times (for transfer axes). If
this is set indirectly, it corresponds to a soft or a hard setting..
Axis calibration parameters These settings are only necessary for axes with incremental encoders.
A calibration run is started to be able to adapt the actual value system to
the reference system of the machine when using these axes. In doing so, a
series of parameters and signals are needed.
When the calibration run of an axis is started, it starts referencing travel in
the positive direction at the aforementioned speed (global tab of the axis).
The actual direction is defined on the encoder’s incremental tab. The axis
stops if the signal bit for the calibration cam is set in its PlcToNc interface.
With this cam, when using a rotating encoder system a specific pulse can
be selected with one synchronisation pulse per revolution.
The axis now starts again in order to move away from the cam. To do this,
it moves in speed referencing travel in the negative direction (global tab of
the axis) until the signal bit is cleared. Without changing the speed, the axis
continues to run until the synchronous latch of the encoder has responded.
Only now does the axis stop.
The distance between response of the latch and the place where the axis
stops is determined. The sum of this distance and of the reference position
(incremental tab of the encoder) is set as the new actual axis position.
By means of this method, an absolute position in the machine can be
assigned to the synchronisation pulse of a selected revolution of the axis.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 31

4. Managing a system configuration


4.1. Checking the configuration
To check the consistency of the complete configuration, you can click the
tool bar icon shown on the left or you can select that "Actions / Check
configuration" menu item.
A check is run automatically when you activate a system configuration (cf.
next section).

4.2. Activating the system configuration


To activate the mapping result for the next TwinCAT start, you must save
the result in the Registry. To do this, click the tool bar icon shown on the
left or select the "Actions / Saving Register.." menu item.
Saving in the Registry overwrites previously saved system configurations
completely.

4.3. Deactivating the system configuration


Deactivating the system You can activate a blank configuration if you wish to deactivate the
configuration complete system configuration without activating a new one. You produce
a blank configuration by restarting the TwinCAT System Manager or by
+ selecting the "File / New" menu item followed by "Actions / Save in
Registry...".

4.4. Saving the system configuration


You can create a file with the *.WSM extension to save the system
configuration (not to be confused with activating). You can load this file
later on again and, if necessary, you can modify it and activate it.
To do this, click the tool bar icon shown on the left or select the "File /
Save" or "File / Save As..." menu item.

4.5. Loading a system configuration


Click the tool bar icon shown on the left or select the "File / Open" menu
item to load a previously saved configuration. Any configuration already
loaded is replaced.

4.6. Starting / restarting TwinCAT


After activating a system configuration, you can start or restart the
TwinCAT system by clicking the button shown on the left.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 32

5. Reference
The information about and possible settings of the individual elements and
their context menus are described below.

5.1. General
Almost all tree elements have the "General" tab.
"General" tab

Name: designation of the marked tree element.


Id: internal Id
Type: type designation of the marked tree element.
Comment: comment box for a user-defined input.

5.2. Variables
Variables represent the "smallest" unit in the TwinCAT I/O system. In the
tree view, variables are always at the tips of the branches, i.e. variables
have no further subelements.
Cyclic I/O data exchange in the TwinCAT system takes place by the
association of individual variables from different sources.

Context menu Change association...


Calls up the variable’s association dialog.
Delete association(s)
Deletes all association of the variables and of their subvariables.
Go to associated variable
Selects the associated variable (leaving the current one).
Insert variable...
Inserts a further variable in the source variable group (see "Inserting
variables" on Page 38).
Delete variable... <Del>
Removes a variable from the I/O configuration.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 33

Write online...
Allows you to influence the value of a variable once while TwinCAT is
active.
Online force...
Allows you to influence the value of a variable permanently when TwinCAT
is active.
Release force
Cancels permanent influencing of a variable’s value.
Add to watch window
Insert a variable in the System Manager’s watch window.
Remove from watch window
Removes a variable from the Manager’s watch window.
"Variable" tab

Name: designation of the marked tree element.


Group: name of the higher-level variable group.
Address: address of the variable in its own process image.
Type: data type of the variable.
Size: size of the variable.
User ID: optional parameter which can be set and later used by the
user to uniquely describe the variable.
Associated w.: calls up the variable association dialog.
Comment: comment box for user-defined input.

"Flags" tab

Swap LOBYTE and HIBYTE: makes the TwinCAT I/O system swap the
low and high bytes of the variable when
copying.
Swap LOWORD and HIWORD: makes the TwinCAT I/O system swap the
low and high words of the variable when
copying.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 34

Variables – online
"Online" tab

Value:
The current online value of the variable is displayed here.
Force...
Allows you to permanently influence the value of a variable when TwinCAT
is active.
Cancel
Cancels permanent influencing of the variable’s value.
Write...
Allows you to influence the value of a variable once when TwinCAT is
active.

5.3. Realtime configuration


In realtime configuration, project-dependent adjustments are made to
TwinCAT realtime.

Card index tab “Online“

Base time: TwinCAT base time is the shortest possible cycle time of a
task. Multiples of the base time can also be used as a
basis for the cycle time. The base time should only be set
to less than one millisecond if required and on
correspondingly fast PC systems.. 1ms, 500µs, 333µs,
250µs, 200µs, 125µs, 100µs, 66µs and 50µs are possible.
The smaller the base time, the greater the overhead
required for the transfer between Windows and TwinCAT
real time.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 35

CPU Limit: Indicates the percentage CPU part, which the TwinCAT
real time occupies, the remainder is guaranteed reserved
for Windows (and therefore also for UI programs). The
value can be set very high, since Windows automatically
resets, when the real time tasks come to the end of their
cycle.
Fast Tick: Only for special TwinCAT expansions, which require a
faster tick, independent of the basic time (e.g. cam
switches).
Jitter Warning: The TwinCAT real time functions on almost all PC systems
with extremely low vibrations (Jitters). These vibrations are
constantly measured. If an adjustable limit is exceeded, a
warning can be produced by the system.
Router memory: Stated here is the max. memory available for TwinCAT in
the real time environment. This memory is required for
internal communication and also for the SPS symbols. If
SPS programs have a high number of symbols, this value
should be increased.

Card index tab “Online“

The Online signal provides information on the current CPU capacity


required by the real time tasks. Also, the current jitter (latency time) is
shown in the lower window.

5.4. Additional tasks


Besides supporting PLC projects, the TwinCAT system also supports
further software tasks that are capable of possessing I/O variables. These
tasks are currently managed in the TwinCAT System Manager under the
main "Additional Tasks" item.
Settings that are made in this item require a more precise knowledge of the
TwinCAT system.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 36

Creating additional tasks


In the TwinCAT System Manager, an additional task is created by adding a
task under the main "Additional Task" item. The following dialog appears:

The additional task appears in the tree and is automatically assigned the
Process image, Inputs and Outputs subitems.

"Task" tab

Task name: edits the internal name of the task


Task priority: defines the priority of the task that is valid in TwinCAT
(make sure that no priorities are assigned in duplicate).
The priority is only relevant when Auto Start is selected.
Task cycle ticks: defines the cycle time in ticks (currently tick =
1ms) of the task. The cycle time is only relevant if Auto
Start is selected.
Port: defines the AMS port number of the task. This value must
be specified!
Auto Start: causes the TwinCAT System Manager to generate the
start command for the task so that the task is automatically
started with the specified data when TwinCAT is restarted.
Disable: enables temporary disabling of the task. That is to say, the
task is ignored when generating the I/O information (e.g.
during commissioning). Nevertheless, the association
information is retained.

5.5. PLC projects


Inserting a PLC project
cf. "Reading a PLC project" on Page 10

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 37

Single PLC projects


Context menu Read new project...
When inserting, the TwinCAT System Manager reads the I/O variables
from the PLC project. If I/O variables are added in or deleted from the PLC
project, the project must be read again (cf. automatic recognition of PLC
project changes).
Delete... <Del>
Removes the C1220 field bus card and all subordinate elements from the
I/O configuration.
Change project directory...
Allows you to change the project path. It is also possible to specify a
different project (or a different version of the same project), whereby an
attempt is made to retain existing associations. The name of the respective
PLC variable is crucial here.

Automatic recognition of By default, the TwinCAT System Manager monitors the file dates of PLC
PLC project changes projects and automatically prompts you to read them again in the event of
changes.

This message can also be deactivated.


When projects are read again, new variables are added or variables that
no longer exist are deleted (including their association information).
Existing variables retain their association information if their names and
types do not change.

"IEC1131" tab

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 38

Project: shows the name of the PLC project.


Path: shows the path of the PLC project.
Run time No.: shows the number of the project’s run time system (1-4).
Port: shows the port number of the run time system.
Target system: returns the type of the run time system (i386 or 80C166(5))
twice.
Read again...: reads the project again.
Change...: allows you to change the project path. It is also possible to
specify a different project (or a different version of the
same project), in which case an attempt is made to retain
existing associations. In this case, the name of the
respective PLC variable is decisive.

Multitasking in the PLC


The TwinCAT PLC supports multitasking. All tasks of one PLC run time
system operate on the same process image. Which variables of the PLC
run time system in the cycle of which PLC task is defined in the TwinCAT
System Manager.

Example When a PLC project is read, all variables are assigned to the first PLC task
(the first PLC task is the topmost task in the task configuration within the
TwinCAT PLC Control).
Within the TwinCAT System Manager, it is now possible to assign
individual variables to a different task by moving them by means of "Drag
and Drop" to the inputs or outputs of a different task.

Result When the PLC project is later read again, the task mappings of the
individual variables are retained.
New variables added after reading again are again allocated to the first
task and can be moved in the same way.

Inserting variables
Under the Inputs and Outputs subitems, variables can be inserted which
are sorted into the process image of the task.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 39

The following dialog appears:

Name: defines the internal name of the new variable


Comment: defines an optional comment on the new variable
Start address: defines the address of the variable of the process image of
the new task. This address must agree with the one where
the task expects the corresponding variable.
Multiple: several variables of the same type can be created with
successive addresses and inserted
Variable type: lists all data types currently known in the TwinCAT System
Manager, on the basis of which the type of the new
variable(s) can be selected.
Sorted according to: allows you to sort the list of variable types
accordingly

As the result of the insertion of new variables, the size of the process
image of the task is adapted automatically.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 40

5.6. I/O devices (field buses)


Beckhoff II/O Lightbus
Beckhoff C1220 The C1220 is an active master card for the Beckhoff II/O Lightbus. Up to
254 field bus boxes can be connected in a ring structure. Individual boxes
and, to some extent, individual items of I/O data of the boxes can be
updated selectively and with priority control.
Up to 3 C1220 cards can be used simultaneously in one PC.
The DPRAM of the C1220 has a size of 4 Kbytes. No interrupts are used.

Context menu Add box... <Ins>


Adds II/O Lightbus boxes. The resulting sequence must correspond to the
physical order in the fibre-optic ring.
The following boxes are currently supported (see below for a more detailed
description of the boxes):
1. BK2000 bus coupler
2. General 32-bit box (all boxes that are not separately listed can be
operated with this
3. M2400
4. M3120
Delete device... <Del>
Removes the C1220 field bus card and all subordinate elements from the
I/O configuration.
Online Reset
Initiates an online Reset on the fibre-optic ring.
Fracture point test
Initiates a fracture point test on the fibre-optic ring.
"C1220" tab

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 41

Address: the card’s DPRAM address can/must be set here. This address
is jumpered on the card and may assume the following values
(corresponding settings of the jumpers J1 – J6):
0xC8000 00 1000
0xD0000 01 0100 (default)
0xD8000 10 0010
0xE0000 11 0001
Search: searches for existing C1220s in the computer (only when
TwinCAT is active)
Check number of boxes: when this check box is selected,
the physically existing number of boxes is compared on
initialisation of the card with the number that is specified under
this card in the System Manager. An error message is
generated if the number does not agree.
K bus update with broadcast telegram (0x80): defines whether, when
bus couplers are connected, the K-bus update is to take place
single for each bus coupler or simultaneously for all bus
couplers by means of a broadcast telegram
Reserved CDLs: the C1220 has eight priority channels (CDLs) that
are normally also used freely by the System Manager. If
individual CDLs are to be left unused – in special applications,
they must be marked here

"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Inputs diagnostics The C1220 automatically has four input bytes that describe the status of
the card of the fibre-optic ring:
DeviceState: general status, which only assumes the values 0 OK
and 1 error
DeviceIioFunc: Function number that triggered the error (cf. see C1220
manual)
DeviceIioFuncArg: function argument (cf. see C1220 manual)
BoxWithError: box number where the error occurred

Profibus DP
Siemens CP5412A2 The DPRAM of the CP5412A2 has a size of 64 Kbytes. No interrupts are
used.
– Master

Context menu Add box... <Ins>


Adds Profibus slaves (Boxes). As addressing in the Profibus system is
realised by way of permanently set station numbers, the sequence of the
added boxes does not play a role.
The following boxes are currently supported (see further below for a
detailed description of the boxes):
1. BK3000 and BK3100 bus coupler
2. General Profibus Box (GSD); a GSD file of the respective slave is
necessary for this purpose and is read in
Delete device... <Del>
Removes the CP5412A2 field bus card and all subordinate elements from
the I/O configuration.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 42

Online Reset
Initiates an online Reset on the Profibus.

"CP 5412" tab

Address: the card’s DPRAM address is set here. This address is set by
the software when the card is initialised

Port: the port address of the card that is set by means of a DIL switch
on the card is set here. By way of the port, the DPRAM address
specified above is set when the card is initialised. Available
ports (in hex) are (corresponding DIL switches 1-4):
240-243 0000 (default)
244-247 0001
248-24B 0010
24C-24F 0011
280-283 0100
284-287 0101
288-28B 0110
28C-28F 0111
300-303 1000
304-307 1001
308-30B 1010
30C-30F 1011
390-393 1100
394-397 1101
398-39B 1110
39C-39F 1111

Station No.: each Profibus station requires a unique station number –


even the master
Baud rate: the Profibus baud rate is set here. A check is made
automatically as to whether the connected slaves also support
this baud rate
Cycle ticks: the smallest possible cycle time that is possible with the
currently defined slaves is set automatically here. It can be
increased manually (in ms)

Synchronous mode.: the highest-priority task that is associated with the


corresponding device assumes control of the field bus cycle
and is therefore synchronised with the field bus. All other tasks
are served asynchronously via corresponding buffers.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 43

"Profibus" tab

The parameters to be set here are described in the PROFIBUS standard


(DIN 19245 Part 3 – PROFIBUS-DP), Chapter 7 and should only be
modified by expert users.

"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Inputs diagnostics The Siemens CP5412A2 automatically has two input bytes that describe
the status of the card and of the Profibus:
DeviceState: general status, which only assumes the values 0 OK
and1 error
DeviceDpState: DeviceDpState is a flag byte; the individual bits have the
following meanings:
0x00 = No error
0x01 = Transmitter fault
0x02 = Master address fault
0x04 = HSA fault
0x08 = Baudrate fault
0x80 = Temp fault

If the CP5412A2 is used in a Beckhoff IPC with a 24V UPS and/or special
! keys, the port address must be set from 0x240 to a different value because
0x240 is used by the IPC.

Hilscher CIF30-
DPM and -PB
Master

Context menu See "Siemens CP5412A2 – Master" on Page 41

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 44

"CIF 30 DPM / PB" tab

Address: the card’s DPRAM address can/must be set here. This


address is jumpered on the card and may assume the
following values: from 0xC8000 to 0xEF800 in increments of
0x800 (and 0x2000 in the case of CIF 30-PB)
Search: you can use this function to search for CIF-30 cards in the
computer (only when TwinCAT is active)
Stations No.: Each Profibus requires a unique station No. - even the
master
Baud rate: The Profibus baud rate is set here. a check is made
automatically as to the connected slaves also support this
baud rate
Cycle ticks: The smallest possible cycle time that is possible with the
currently defined slaves is set automatically here. It can be
increased manually (in ms)

Synchronous mode.: the highest-priority task that is associated with the


corresponding device assumes control of the field bus cycle
and is therefore synchronised with the field bus. All other
tasks are served asynchronously via corresponding buffers.

"Profibus" tab See "Siemens CP5412A2 – Master" on Page 41

"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Siemens SPC3 / With the aid of the Profibus DP – slave field bus card, the TwinCAT system
can be used as a slave in a Profibus.
IM182 – Slave The DPRAM has a size of 1536 (0x600) bytes. No interrupts are used.

Context menu Delete device... <Del>


Removes the SPC3 field bus card from the I/O configuration.
Online Reset
Initiates an online Reset on the Profibus.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 45

"SPC3 / IM182" tab

Address: the card’s DPRAM address can/must be set here. This


address is jumpered on the card
Port: the card occupies one of the two ports 0x320 or 0x330
Stations No.: each Profibus station requires a unique station No.

"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Inputs diagnostics The Siemens SPC3/IM182 automatically has one input byte that describes
the status of the card and of the Profibus:
Flags: the individual flags have the following meanings:
0x01 = NEW_OUTPUTS
0x02 = CLEAR_MODE
0x04 = NO_DATA_EXCH
0x08 = BAUD_SEARCHING
0x10 = SYNC_MODE
0x20 = FREEZE_MODE

Variables can be defined under the inputs and outputs for the exchange of
data with a Profibus master. These variables are exchanged with the
Profibus master and can be associated within TwinCAT.
Variables are inserted analogously to the "Additional tasks" in the "Inserting
variables" section on Page 38.

InterBus-S
Hilscher CIF40- The CIF40-IBSM is an InterBus-S master card.
The DPRAM of the CIF40-IBSM has a size of 2 Kbytes. No interrupts are
IBSM used.
Context menu Add box... <Ins>
Adds InterBus-S boxes.
The following boxes are currently supported (see further below for a
detailed description of the boxes):
1. BK4000 bus coupler
2. General InterBus-S box. The identification code and length must
be specified or predefined boxes must be selected

Delete device... <Del>


Removes the CIF40-IBSM field bus card and all subordinate elements from
the I/O configuration.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 46

Online Reset
Initiates an online Reset on the InterBus-S.

"CIF-40 IBSM" tab

Address: the card’s DPRAM address can/must be set here. This address
is jumpered on the card and may assume the following values:
from 0xC8000 to 0xEF800 in increments of 0x800
Search: you can use this function to search for CIF-40 cards in the
computer (only when TwinCAT is active)
Cycle ticks: the cycle time with which the InterBus-S is to be served (in
ms) is set here

Synchronous mode.: the highest-priority task that is associated with the


corresponding device assumes control of the field bus cycle
and is therefore synchronised with the field bus. All other tasks
are served asynchronously via corresponding buffers.

"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Inputs diagnostics The CIF-40 automatically has two input bytes that describe the status of
the card and of the InterBus:
GlobalFlags: The individual bits have the following meanings:
0x01 = Ctrl: parameterisation error
0x02 = W1Err: at least one defective W1 interface
0x04 = W2Err: at least one defective W2 interface
0x08 = SysErr: system error occurred
0x10 = Mod: at least one slave signals a module error
0x20 = Rec: at least one slave requests configuration

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 47

ErrorEvent: The value depends on the GlobalFlags:


IN the case of W1Err, W2Err, Mod or Rec, the number of the
affiliated slave is displayed. Otherwise, the following
conditions apply:
=101, SysErr Differences between configuration list and existing
structure
=103, SysErr Network change during bus operation
=104, SysErr Multiple data cycle error
=105, SysErr Timeout
=106, SysErr Network error that cannot be located
=108, SysErr No connection to the network
=170, Ctrl Communication has not been initialised
=171, Ctrl Too many modules (> 112) parameterised
=172, Ctrl More modules connected than parameterised
=173, Ctrl Less modules connected than parameterised
=174, Ctrl Length code not supported
=175, Ctrl Incorrectly parameterised length code
=176, Ctrl Incorrectly parameterised identification code
=177, Ctrl Incorrectly parameterised installation depth
=178, SysErr User program did not serve watchdog within the
configured time
=180, Ctrl Unknown operating mode
=181, SysErr User program has not acknowledged data cycle

Phoenix IBS ISA The IBS ISA ST-I/T is an InterBus-S Master Card.
The DPRAM (MPM) of the IBS ISA ST-I/T is 4 KByte. No interrupts are
ST-I/T used.
Context menu Add box... <Add>
Adds InterBus S boxes.
Currently, the following boxes are supported (more detailed description on
the boxes to follow):
1. BK4000 Bus coupler
2. General InterBus-S Box. The identity code and the identity length
are stated and/or pre-defined boxes are selected.

Delete... <Delete>
Deletes the IBS ISA ST-I/T field bus card and all sub-ordinate elements
from the E/A configuration.
Online Reset
Initiates an Online Reset on the InterBus S.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 48

Card index tab „IBS ISA ST-


I/T “

Address: The card’s DPRAM address can/must be set here. This address
may assume the following values: from 0xC8000 to 0xEF000 in
increments of 0x1000
Port: The card’s port address can/must be set here. This address is
jumpered on the card and may assume the following values:
from 0x100 to 0x3F8 in increments of 0x8
IBS Cycle: The running time of the Interbus is calculated approximately
using the configured equipment and then indicated.

NOTE: With newer Motherboard/BIOS, it may become necessary to reserve the


DPRAM area which uses the card in the BIOS of the computer. The
corresponding adjustment is usually stated in the PNP-BIOS and is
described as an ISA Memblock.

Syncron Mode.: The highest priority task associated with the corresponding
system, assumes control of the field bus cycle and is therefore
synchronised with the field bus. All other tasks are served
asynchronously via corresponding buffers.
Read Config: The current system configuration of the interbus can be
read in. The condition is that a TwinCAT configuration is
started, in which no system has been configured below the
Interbus Master Card! The TwinCAT system is aborted if an
error message is received (0 boxes configured and x boxes
expected). The Read Config button is then released. This
reveals the previously recognised configuration in the tree.
Card index tab „DPRAM See below “Online display of the DPRAM“ on page 61.
(Online)“

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 49

Diagnostic inputs The IBS ISA ST-I/T automatically has access to two input words, which
and/or their bits describe the condition of the card and the interbus:
State: 0x0001 = Application error
0x0002 = Periphery error
0x0004 = Bus error
0x0008 = Hardware error (access component)
0x0010 = Diagnostic routine active
0x0020 = Data transfer active
0x0040 = Selected configuration is ready for operation
0x0080 = Access component is ready for operation
0x0100 = Bus segment is disabled
0x0200 = Block command output
0x0400 = Standard function processed negatively
0x0800 = Synchronisation error appeared
0x1000 = Faulty data cycles
0x2000 = Specified waiting time exceeded
0x4000 = Specified error density exceeded
0x8000 = Signal for control applied

DiagPara: The content is dependent upon the content of State.


- If 0x0001 or 0x0008 bit is set, the
error code appears in the DiagPara.
- If 0x0002 or 0x0004 bit is set,
the segment address of the error location appears in the
DiagPara.
See Reference Handbook IBS SYS FW G4 LIB UM (Art-No.: 27 45 13 0)
under the GetIBSDiagnostic function.

Firmware service Like all SC/I-T firmware services, any TwinCAT program can be retrieved
via ADS. For this purpose, an AMS Port must be referred to the SC/I-T.
This port is activated on the card index tab side "ACyclic". The port number
is specified at 0x7000 + the ID of the SC/I-T.
“ADS“ Card Index Tab

The services can be retrieved in the following form via an


AdsReadWriteReq (see. ADS documentation):
IndexGroup = 0x00010001
IndexOffset = Code for the firmware service (e.g. 0x00000713 for
Control_Active_Configuration)
The number of parameters is automatically determined using the Write
data. The Write data is not converted by TwinCAT into the Motorola format,
this must be carried out by the user as required.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 50

The result (die Confirmation) of the firmware service is returned to the read
data.

Example: Disabling a user in The user with the logical user number 3.1 is disabled in the current bus
the current bus operation operation:
IndexGroup:
0x00010001
IndexOffset:
0x00000713 (Control_Active_Configuration)
Write data:
Word 0 0x0200 (Device_Off in Motorola Format)
Word 1 0x0100 (An entry in Motorola Format)
Word 2 0x0103 (3.1 in Motorola Format)

The write length is 6 Bytes, so that the firmware for Parameter_Count 3


(Words) is transferred.

Confirmation: Positive confirmation means:


Read data:
Word 0 0x0000
Negative confirmation means:
Read data:
Word 0 0xXXXX (Result in Motorola Format)
Word 1 0xXXXX (Add_Err_Info Motorola Format)

CANopen
Hilscher CIFx0-CAN The CIF30-CAN is a CANopen ISA master card.
The CIF50-CAN is a CANopen PCI master card.
The CIF60-CAN is a CANopen PCMCIA master card.
The CIF104-CAN is a CANopen PC104 master card.

The DPRAM of the CIF30-CAN has a size of 8 Kbytes. No interrupts are


used.
The following description relates to the CIF30-CAN. The only visible
difference between this and TwinCAT is the form factor.
Context menu Add box... <Ins>
Adds CANopen boxes.
The following boxes are currently supported (see further below for a
detailed description of the boxes):
1. BK5100 bus coupler
2. BK5110 economy bus coupler
3. BK5120 bus coupler
4. LC5100 low cost bus coupler
5. CANopen node

Delete device... <Del>


Removes the CIF40-IBSM field bus card and all subordinate elements from
the I/O Configuration.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 51

Online Reset
Initiates an online Reset on the CAN bus.

„CIF-30 CAN“ tab

Address: The card’s DPRAM address can/must be set here. This


address is jumpered on the card and may assume the
following values: from 0xC8000 to 0xEE000 in increments of
0x2000
Search: by means of this function, you can search for CIF-30 cards
in the computer (only when TwinCAT is active)
Synch Cycle: here, you set the cycle time with which Sync telegrams are
sent
Baud rate: here, you set the baud rate with which the CAN bus is
operated
Watchdog: Watchdog monitored with the CANopen card.
AutoClear: If this box is selected, a node is dropped to abort the entire
network, otherwise an attempt is made to re-enter the node
and continue the operation.
Synchronous mode.: the highest-priority task that is associated with the
corresponding device assumes control of the field bus cycle
and is therefore synchronised with the field bus. All other
tasks are served asynchronously via corresponding buffers.
Firmware Update... Here, the CIF-30 CAN firmware can be updated. In the
window, the firmware version loaded appears in red, if
TwinCAT knows a more recent version.
"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Inputs diagnostics The CIF-30 automatically four input bytes that describe the status of the
card and of the CAN bus:
GlobalFlags:The individual bits have the following meanings:
0x01 = Ctrl: parameterisation error
0x02 = ACtrl: device stopped communication owing
to a guarding to a node
0x04 = NData: at least one node is not communicating
or has a configuration error
0x08 = Fatal: severe bus error occurred
0x10 = Event: communication error detected
0x20 = NRdy: host is not ready

ErrorRemAddr: address of the node causing the problem; address 255 is


the master card itself

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 52

ErrorEvent: If ErrorRemAddr shows 255, the following conditions apply:


=52 Unknown Handshake mode configured
=56 Baudrate not defined
=60 Node address assigned in duplicate
=220 Host watchdog error
=210 No database
=212 Invalid database

ErrorCounter: number of occurring bus errors

DeviceNet
Hilscher CIFx0- The CIF30-DNM is a DeviceNet ISA master card.
The CIF50-DNM is a DeviceNet PCI master card.
DNM
The CIF60-DNM is a DeviceNet PCMCIA master card.
The CIF104-DNM is a DeviceNet PC104 master card.
The DPRAM of the CIFx0-DNM is 8 KBytes. No interrupts are used.
The following description relates to the CIF30-DNM. The only visible
difference between this and the TwinCAT is the form factor.
Context menu Add Box... <Add>
Adds DeviceNet boxes.
Currently, the following boxes are supported (more detailed description on
boxes to follow):
1. BK5200 bus coupler
2. BK5210 economy bus coupler
3. LC5100 low cost bus coupler
4. DeviceNet Node

Delete... <Delete>
Removes the CIF30-DNM field bus card and all sub-ordinate elements
from the E/A configuration.
Online Reset
Initiates an Online Reset on the DeviceNet.

Card index tab “CIF-30


DNM“

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 53

Address: Here, the card’s DPRAM address can/must be set. This


address is jumpered and/or configured on the card and may
assume the following values: from 0xC8000 to 0xEE000 in
increments of 0x2000
Search: Can search for existing cards in the computer CIF-30.
MAC-ID Here, the node address of the master (scanner) card is set.
This must not be given again in the network.
Heartbeat: Here, the rate at which the DeviceNet card transmits a
heartbeat message (not currently supported) is set.
Baudrate: Here, the baudrate at which the DeviceNet is operated, is
set.
Watchdog: Watchdog monitored with the DeviceNet card TwinCAT.
VendorID: States the vendor ID with which the scanner card in the
network identifies (e.g. in the duplicate MAC ID Detection
Protocol)
AutoClear: If this box is selected, a node is dropped to abort the entire
network, otherwise an attempt is made to re-enter the node
and continue the operation.
Syncron Mode: The highest-priority task that is associated with the
corresponding device assumes control of the field bus cycle
and is therefore synchronised with the field bus. All other
tasks are served asynchronously via corresponding buffers.
Firmware Update... Here, the CIF-30 CAN firmware can be updated. In the
window, the firmware version loaded appears in red, if
TwinCAT knows a more recent version.

Card index tab “DPRAM See under “Online display of the DPRAM“ on page 61.
(Online)“

SERCOS
Indramat SERCANS SERCANS SCS-P is a SERCOS master card for up to eight axes.
The DPRAM of the SERCANS SCS-P is 4 KByte. One interrupt is used,
SCS-P which triggers the card and is used in the TwinCAT system for
synchronisation.
Context menu Add box... <Add>
Adds a SERCOS axis.

Delete... <Delete>
Deletes the SERCANS SCS-P field bus card and all sub-ordinate elements
from the E/A configuration.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 54

Card index tab Sercans


SCS-P“

Address: Here, the card’s DPRAM address can/may be set. This


address is jumpered on the card and may assume the
following values: from 0xC0000 to 0xEF000 in increments of
0x1000
Search: Here, existing SERCANS cards can be searched for in the
computer
Cyclic IRQ: The cyclic interrupt used is entered. It must agree with the
card setting (Jumper). The non-cyclic interrupt of the card is
not required and must not be jumpered on the card.

Card index tab “DPRAM See under “Online display of the DPRAM“ on page 61.
(Online)“

CANopen
Hilscher CIF30-CAN The CIF30-CAN is a CANopen master card.
The DPRAM of the CIF30-CAN has a size of 8 Kbytes. No interrupts are
used.
Context menu Add box... <Ins>
Adds CANopen boxes.
The following boxes are currently supported (see further below for a
detailed description of the boxes):
6. BK5100 bus coupler

Delete device... <Del>


Removes the CIF40-IBSM field bus card and all subordinate elements from
the I/O Configuration.
Online Reset
Initiates an online Reset on the CAN bus.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 55

"CIF-30 CAN" tab

Address: The card’s DPRAM address can/must be set here. This


address is jumpered on the card and may assume the
following values: from 0xC8000 to 0xEE000 in increments of
0x2000
Search: by means of this function, you can search for CIF-30 cards
in the computer (only when TwinCAT is active)
Cycle ticks: here, you set the cycle time with which Sync telegrams are
sent
Baud rate: here, you set the baud rate with which the CAN bus is
operated

Synchronous mode.: the highest-priority task that is associated with the


corresponding device assumes control of the field bus cycle
and is therefore synchronised with the field bus. All other tasks
are served asynchronously via corresponding buffers.

"DPRAM (Online)" tab See "Online display of the DPRAM" on Page 61.

Inputs diagnostics The CIF-30 automatically four input bytes that describe the status of the
card and of the CAN bus:
GlobalFlags:The individual bits have the following meanings:
0x01 = Ctrl: parameterisation error
0x02 = ACtrl: device stopped communication owing
to a guarding to a node
0x04 = NData: at least one node is not communicating
or has a configuration error
0x08 = Fatal: severe bus error occurred
0x10 = Event: communication error detected
0x20 = NRdy: host is not ready

ErrorRemAddr: address of the node causing the problem; address 255 is


the master card itself

ErrorEvent: If ErrorRemAddr shows 255, the following conditions apply:


=52 Unknown Handshake mode configured
=56 Baudrate not defined
=60 Node address assigned in duplicate
=220 Host watchdog error
=210 No database
=212 Invalid database

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 56

ErrorCounter: number of occurring bus errors

Printer interface
Eight inputs and outputs each are available with the aid of the "field bus" of
the printer interface.
"LPT Port" tab

Three port addresses are available for selection. These reflect the LPT1,
LPT2 and LPT3 interfaces in standard PCs. Refer to the PC manual or the
current setting in the BIOS for details of which LPT port on your computer
corresponds to which port address.
When you insert the printer interface under I/O devices in the tree view,
eight bit variables each are automatically generated under the inputs and
outputs. In the case of the inputs, you must pay attention to the fact that
the logic of the individual bits differs. Most of the inputs return a logical one
when the respective pin is not connected to earth and a logical zero when
the pin is connected to earth. In the case of inputs marked inv, the logic is
precisely the other way around.
A bi-directional interface is needed for proper operation of the "field bus".

COM interface
The COM interfaces of the PC can be used by. Two modes of operation
are available:
1. Uninterrupted power supply (USV)
2. COM Port operation
The COM Port operation is sub-divided into the following secondary
modes:
a) Connect series bus couplers (BK8xx0)
b) General data interface (simulation of terminal 6xx1)

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 57

Card index tab


Series interface

Operating mode: USV In the USV mode, an external USV can be connected to the series
interface and controlled by TwinCAT. Currently, the pin assignment is
supported by APC and EFFEKTA.
In contrast to the USV service which exists within Windows NT, the
behaviour of the USV, which is controlled via TwinCAT corresponds to that
required by a machine control. The NT service attempts to supply voltage
for as long as possible and only tries to stop the computer if the battery
voltage falls.
If the USV is controlled via TwinCAT (the NT Service must not be
activated), the computer is run down after a specified waiting time.

Mode: COM – BK8xx0 Series bus couplers can be added below the E/A system, which can be
equipped with any terminals.

NOTE: In order to operate RS485 (BK80x0), an intelligent interface card is


RS485 –Operation required which controls the RTS/CTS lines independently (sends and
receives).

Operating mode: COM – The type KL6xx1 terminals facilitate series communication, e.g. from the
KL6xx1 SPS via a field bus – bus coupler and – the terminal to an external series
system (e.g. a barcode reader). The data bytes are exchanged and the
required handshake is controlled by the processing image of the terminal.
This function can be mirrored for the series interfaces in the PC. On the
one hand, a significantly higher data flow rate can be achieved, since the
baud rate can be adjusted upwards and also more data bytes can be
transferred per cycle (maximum five on T6xx1).

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 58

Data bytes: The maximum number of databytes to be transferred can be set at


between 16 and 4096. In addition, the internal buffer size can be set which
is required in particular to receive databytes (between 4096 and 65535).
The handshake takes place via the Ctrl and Status Word. These words are
very similar to the Ctrl. and status byte of T6xx1, the difference being that
the stated data length is 12 bits instead of 3 (maximum 4096).
Status Bit 0: TA: Transmit Accepted
Bit 1: RR: Receive Request
Bit 2: IA: Init Accepted
Bit 3: BUF_F: Buffer overload (possible data loss)
Bit 4-12: nIn Level of data in buffer
Ctrl Bit 0: TR: Transmit Request
Bit 1: RA: Receive Accepted
Bit 2: IR: Init Request
Bit 3: Unused
Bit 4-12: nOut Level of data to be sent

TA / TR If TR changes condition, the level of data specified in nOut (maximum 4096


bytes) of Data0-DataN is loaded into the transmit buffer. The interface
signals execution of this command via TA.
RA / RR If RR changes condition, the interface informs the control that the level of
data indicated in nIn is located in Data0-DataN. Data acceptance is exited
in the control word with RA, new data is then transferred from the interface
to the control.
IA / IR If IR is high, the interface executes an initialisation process. The sending
and receive functions are blocked, the FIFO signals are reset. Initialisation
is exited from the interface with IA.
BUF_F The receive buffer is full of data. Data which is being received is lost.

Beckhoff IPC – special keys and UPS


Additional special keys and LEDs integrated them are offered on some of
the Beckhoff industrial PCs. These keys and LEDs can be used and
associated as normal inputs and outputs.
When you insert the Beckhoff PC under I/O devices in the tree view, ten bit
variables each are automatically generated under the inputs and outputs.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 59

"UPS" tab

Some Beckhoff industrial PCs also have an integrated 24 V UPS


(continuous power supply), which is addressed via ports. The check box
must be selected in order to activate the UPS under TwinCAT.

Beckhoff CP9030
The CP9030 card serves as a PC side connection to the Beckhoff Panel
Links. This enables remote control panels to be connected to the PC by a
coaxial cable. In addition to transferring the image signal, mouse mat/touch
screen and key entries, the control panels may also have additional special
keys and LEDs, which can be read and/or written via TwinCAT (See
Fehler! Verweisquelle konnte nicht gefunden werden.).
Card index tab “„CP9030“

Address: Here, the card’s DPRAM address can/must be set. This


address is jumpered on the card and may assume the
following values: from 0xC8000 to 0xEF000 in increments of
0x1000
Search: Can search for CP9030 cards in the computer
Scan: The number of special keys can be set on the control panel.
LEDs: The number of LEDs can be set on the panel

Card index tab “USV“ See Fehler! Verweisquelle konnte nicht gefunden werden.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 60

E/A Variables: S1 - Sn: Input status of the corresponding special keyboards


KBusErr: Error status of any K buses connected to the control
panel
CnfErr: Configuration error
PDLenErr: Processing data length error
ExtVoltageOk: Condition of external voltage (when USV is active)
AkkuVoltageOk: Condition of battery voltage (when USV is active)
AkkuCharging: Battery is charged (when USV is active)
AkkuNotPresent: Battery not found (when USV is active)
AkkuCharged: Battery fully charged (when USV is active)
AkkuWaiting:
IdentSwitch: Value of dip switch set on card
ComErr: Communication error between control panel and CP9030
card

LED 1 –n: Output bits to control LEDs


EnableUPS: Output bit for manual activation of USV (to be used only
when USV is not activated via the USV configuration)
DisplayOff: Switches off the background light of the control panel
KbdOff: Switches off the keyboard on the connected control panel
(important, if several control panels are connected via
several CP9030 cards)

NOTE: So that the data is exchanged between the control panel and CP9030 , at
least one variable must be linked and the lined task must run! Otherwise,
the handshake between PC and CP9030 is not actuated and no data is
exchanged with the control panel

Motherboard Diagnostic – SMB


Newer motherboards have diagnostic chips which can monitor
temperature, fan speeds and operating voltages of the PC. These values
can be read into the TwinCAT using the "Motherboard – SMB (System
Management Bus)" "E/A-System". Unfortunately, there is currently no
unified standard which states how these values should be provided.

Newer motherboards with Intel chip sets are supported. These are usually
accessible through the PCI-ISA-Bridge PIIX-4. However, other chip sets
can also be used to determined individual values (if they have a LM75 or
compatible chip). The values which can be measured on a special board
must therefore be tested.

Temperatures are given in °C.


The fan speed is given in rotations per minute.
The voltage is given in 1/100 Volt.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 61

Online display of the DPRAM


"DPRAM (Online)" tab

When TwinCAT is active, direct read access to the DPRAM of the


respective field bus card is possible for diagnostic purposes. For more
detailed information, refer to the description of the respective card.

5.7. Field bus boxes (bus couplers etc.)


General notes on field bus boxes
Context menu Insert box...
Inserts a further field bus box above the marked one.
Delete box... <Del>
Deletes the currently marked box and its subelements from the I/O
configuration.
Import box...
Inserts a field bus box above the marked one. The description of the new
box and of its subelements is read out of a file with the "*.ioe" extension.
This file is created with the following menu item.
Export box...
Exports the information of the currently selected box and its subelements
to a file with the "*.ioe" extension.

Bus coupler
The Beckhoff bus terminal represents an open field bus-neutral peripheral
concept that consists of electronic modular terminals. The bus coupler with
an interface for the field bus is the header of an electronic modular
terminal.
Context menu Add terminal... <Ins>
Adds a bus terminal under the bus coupler. The dialog shown on Page 13
under "If necessary, inserting sub modules of boxes (e.g. bus terminal"
appears.
Otherwise, see "Field bus boxes " on Page 61

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 62

BK2000 The BK2000 bus coupler is used in the Beckhoff II/O Lightbus field bus.
The characteristics specific to the BK2000 that differ from other bus
couplers are described below.

"BK2000" tab

2 byte PLC interface: when this is selected, one input and one output
variable each for the 2 byte PLC interface are inserted
under the coupler.
Check terminals on start: when this is selected (only possible if the 2
byte PLC interface is active), the configured and
physically existing terminals on the coupler are
compared during the system start up phase. If
discrepancies are detected, the system start up phase
is aborted and a corresponding message is issued.
Generate own K bus update: update of the terminal bus can be
influenced. If this update is not realised by a broadcast
telegram from the C1220 (cf. C1220), a separate K bus
update must take place (default).
After own data: the update takes place directly after transfer of your
own data.
After all data: the update takes place after all data of the current CDL
has been transferred.
In separate CDL: the update takes place in a separate CDL (this requires
corresponding handling in the server).

Input and output diagnostics One input byte and two output bytes are provided for diagnostic and setting
purposes:
State: contents of the first byte of the word 255 from the bus
coupler’s process image (cf. BK2000 manual).
Ctrl0: contents of the first byte of word 255 from the bus
coupler’s process image (cf. BK2000 manual).
Ctrl1: contents of the second byte of word 255 from the bus
coupler’s process image (cf. BK2000 manual).

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 63

BK3000 / BK3100 The BK3000 and BK3100 bus couplers are used in the Profibus. The
specific characteristics that differ from those of other bus couplers are
described below.

"Profibus" tab

Stations No.: each Profibus station requires a unique station No.


response monitoring: activates a watchdog functionality. The duration
can be set when response monitoring is on (in ms).
PrmData: allows editing of the Profibus-specific parameter
data (a special knowledge of Profibus is required
for this purpose). The size of the current parameter
data is displayed.)

"BK3x00" tab

2 byte PLC interface: activates the coupler’s 2 byte PLC interface to


enable register settings in the coupler, e.g. from the
PLC.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 64

Inputs diagnostics each Profibus Slave field bus box is assigned two diagnostic input bytes
that signal the status of the respective slave during the run time and which
can be associated with the PLC, for example:
BoxState: 0 = No error
1 = Error
DpState: 0 = No error
1 = Station deactivated
2 = Station not exists
3 = Master lock
4 = Invalid slave response
5 = Parameter fault
6 = Not supported
7 = Config fault
8 = Station not ready
9 = Static diagnosis

BK4000 The BK4000 bus coupler is used in InterBus-S. The specific characteristics
that differ from those of other bus couplers are described below.

"BK4000" tab

Ident code: displays the bus coupler’s identification code. It is


calculated dynamically, depending on the connected
terminals.
Length code: displays the bus coupler’s length code. It is calculated
dynamically, depending on the connected terminals.
Installation depth: displays the bus coupler’s installation depth. It is
calculated dynamically, depending on the hierarchical
structure of the InterBus-S.
Diagnostics: inserts two bytes of diagnostics data each in the
process images of the inputs and outputs (see
BK4000 manual).
2 byte PLC interface: inserts the two byte PLC interface into the process
image of the inputs and outputs.

Inputs diagnostics Each InterBus-S field bus box is assigned one diagnostic input byte that
signals the status of the respective slave during the run time and which can
be associated with the PLC, for example:
BoxState: 0x01 = Rec: reconfiguration
0x02 = Mod: module error
0x04 = W2Err: error at the W2 interface
0x08 = W1Err: error at the W1 interface
0x10 = W2: inactive state of the W2 interface
0x20 = W1: inactive state of the W1 interface

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 65

BK5100 The BK5100 bus coupler is used in the CANopen bus. The specific
characteristics that differ from those of other bus couplers are described
below.

"BK51x0" tab

Node Id: sets the node Id of the CAN bus station (between 1
and 99). This value must agree with the value set on
the bus coupler.
K bus update: calculates the presumable duration of a complete
update of the terminal bus (this depends on the
connected terminals).

Inputs diagnostics Each CANopen field bus node is assigned one diagnostic input byte that
signals the status of the respective slave during the run time and which can
be associated with the PLC, for example:
BoxState: 1: node does not exist
2: Emergency Buffer Overflow
3: invalid configuration data

BK52x0 The BK52x0 bus coupler is set in the DeviceNet bus. The characteristics
which differentiates this from other bus couplers are described below.
Card index tab “BK52x0“

MAC Id: Sets the node Id of the DeviceNet user (between 1


and 99). This value must agree with the value set on
the bus coupler.
Prod. Inhibit Time: Specifies the transmission delay between I/O
messages. Evaluated by the master as a cycle time
(repeat transmission) of the I/O connection.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 66

Exp. Packet Rate: The Expected Packet Rate states the maximum cycle
time of an I/O connection. If no Change of State
occurs within this time, the I/O message is still sent.
Simultaneously, the Expected Packet Rate
determines the watchdog value with which the slave
monitors the I/O connection.
Connection Type: Specifies the type of I/O connection.
1. Polled: Outputs are written and inputs are read in
cycles.
2. Bit Strobed: A broadcast message requests all
nodes to send their bit strobe message (up to 7
bytes of input or status data).
3. Change of State: Event controlled transmission of
I/O information.
4. Change of State / Cyclic: Even if no event has
occurred, the I/O message is sent after the
Expected Packet Rate has expired.
K-Bus Update: Calculates the expected period for a full update of the
terminal bus (depends upon which terminal is
connected).

Diagnostic inputs: Every DeviceNet field bus node receives a diagnostic input byte which
signals the status of the respective slave for the running time and which
can for example be linked to the SPS:
BoxState: 1 = Node non-existent
2 = Emergency Buffer Overflow
3 = Incorrect configuration
CouplerState: 0 = OK
1 = Error (e.g terminal bus error)
There is also another bit which indicates whether the node is in the data
exchange.

Card index tab “Attribute“

On this side, DeviceNet parameters which are sent to the mode on start-
up, are indicated/administrated. The inputs can be administrated via "new",
"delete" and "process”.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 67

Card index tab “ADS“

In order to be able to read and write attributes for running time (e.g. from
the SPS), an ADS port can be allocated to the node (bus coupler). This
enables the attribute for each ADS Read Request and/or Write Request to
be read and written.
The ADS IndexGroup contains ClassId and the ADS IndexOffset contains
InstanceId and AttributeId (InstanceId * 256 + AttributeId).

Boxes specific to II/O Lightbus


General 32-bit box All II/O Lightbus boxes that are not listed separately can be operated via
the "General 32-bit box" type. In the case of the Lightbus 32-bit or 4 byte
data is sent to the box in each telegram (outputs on the field bus) and 32-
bit data is read again (inputs on the field bus).
Refer to the respective manual of the box for details of the meanings of the
individual bits or bytes in the various boxes.

Context menu See "Field bus boxes " on Page 61

Variables Four bytes of inputs and outputs each are defined automatically under the
box. These can be addressed or associated either as bytes or as individual
bits.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 68

"32 bit" tab

The individual variables can be associated clearly for all variables


simultaneously by way of the "32 bit" tab. It goes without saying that
association is still not possible by way of the context menu or the card file
view of the respective variable.
D0 Inp...: opens the association dialog for the first input byte or for one bit
of the first input byte if a bit-by-bit selection has been made. If
variables are associated bit-by-bit, the respective relevant bit
can be selected.
D1 Inp...: ditto.

M2400 The M2400 is an analogue output box of up to four channels that also has
two digital data bytes. Whether the data bytes function as inputs or outputs
is jumpered in the box (see M2400 manual). The corresponding DACs
must be not associated if the box has less than four analogue channels.

If the box is associated with several tasks (e.g. DACs with NC and data
bytes with PLC), the data telegram is only generated for the higher-priority
task. Particular attention must be paid to this during commissioning when
only the PLC is running, for example.

Context menu See "Field bus boxes " on Page 61

Variables Four 16-bit output variables with the designations DAC 1 to DAC 4 are
created and can be associated. The two data bytes are arranged under
inputs and/or under outputs according to their affiliations. Their affiliations
are specified in the "Data bytes" tab. The data bytes can be addressed
both byte-by-byte and also bit-by-bit.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 69

"DACs" tab

The individual variables can be associated in a clearly arranged fashion for


all variables by way of the "DACs" and "Data bytes" tabs. It goes without
saying that it is still possible to establish an association via the context
menu or the file card view of the respective variable.
DAC 1...: opens the association dialog for the first analogue output
channel.
DAC 2...: ditto...

"Data bytes" tab

D 2...: opens the association dialog for the first data byte (D2
in the telegram).
Input / output: defines whether the data byte is handled as an input
or output (this must correspond to the hardware
setting).
Bytewise / bitwise: defines whether the association dialog is opened for
the complete byte or for individual bits.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 70

M3120 The M3120 is an up to four-channel incremental encoder box. Four


different versions are supplied, with one, two, three and four channels.
When the box is inserted, you must select the right version because every
channel presents itself logically as a single box and therefore the total
number of the boxes differs if an input error is made.
The channels of the M3120 are designated INC 4, INC 3, INC 2 and INC 1.
These designations correspond to the markings on the box.

Variables Each channel of the M3120 has four variables, two input variables and two
output variables:
1. Status byte (8-bit input variable), which indicates the status of the
respective channel.
2. Value (24-bit input variable), which returns the current counter status
or the latch value.
3. Control byte (8-bit output variable), which, among other things,
enables switching over between a counted and a latch value.
4. Set value (24-bit output variable) for setting the counted value.
Refer to the manual of the M3120 for a more exact description.

FOX20 The Fox-20 module has 4 plug positions which can take digital or
analogous sub-modules (the first plug position can take only analogous
sub-modules).
All possible variables are shown in the tree. Depending on how the Fox-20
module is configured, the variables must/can be linked. If a plug position is
filled by an analogous sub-module, the word variables Modx_Chny can be
lined either in the input and/or in the output area, whereby x stands for the
plug position and y stands for the channel for relevant plug position.
In the case of digital sub-modules (only one channel possible), the Bit
variables are linked below the Modx_Chn1 variables.
The links help the TwinCAT System Manager to recognise whether it is
producing LWL messages for a digital or an analogous sub-module.

FOX50 The Fox-50 module is a 2-channel SSI producer interface. One status byte
and a 24-bit value are added in the tree, these can be linked manually or
from the NC configuration (encoder type FOX50).

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 71

FOXRK001/002 The Fox-Rk001 and Fox-Rk002 module are coupler modules which couple
the LWL Ring to other LWL Rings (Rk001) or to a profibus (Rk002).
When a module is added, an enquiry is made as to the required number of
input and output words (maximum 254 Rk001 and/or 16 Rk002).

The stated number of variables are produced in the tree.


In the case of the Rk001 module, an additional IdentNo-Word is added to
the input and output area, which is exchanged with the word 0xFE in the
(RK001, each with 4 words) module.

Profibus devices with a GSD- file


GSD box Profibus devices that are known in the TwinCAT System Manager can be
read in with the aid of their master device data file (GSD. When a field bus
box of the "GSD box" type is inserted, a File open dialog appears, in which
the corresponding GSD file must be selected.

Context menu Add module... <Ins>


Adds a module in the case of modular GSD boxes (cf. "Modular Profibus
devices" on Page 81).
Otherside, see "Field bus boxes " on Page 61

Modular GSD boxes Modular GSD boxes (information from the GSD file) allow you to add or
insert modules:

"Profibus" bus See description of BK3000 / BK3100 on Page 63.


Inputs diagnostics See BK3000 / BK3100 description on Page 63.

InterBus-S devices
InterBus-S box InterBus-S boxes that are not known in the TwinCAT System Manager can
be inserted by entering their length and identification codes specific to
InterBus-S. Refer to the manual of the respective device for details of the
length and identification code, which is frequently also marked on the
device itself.
The following dialog appears when you add an InterBus-S box:

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 72

When you select the "List..." button, a list of common InterBus-S boxes of
known length and identification codes appears:

"InterBus-S" tab

Ident code: indicates the bus coupler’s identification code. It is


calculated dynamically – depending on the connected
terminals.
Length code: indicates the bus coupler's length code. It is calculated
dynamically – depending on the connected terminals.
Installation depth: indicates the bus coupler's installation depth. It is
calculated dynamically – depending on the hierarchical
structure of the InterBus-S.

Inputs diagnostics Each InterBus-S field bus box is assigned one diagnostic input byte that
signals the status of the respective slave and which can be associated with
the PLC, for example:
BoxState: 0x01 = Rec: reconfiguration
0x02 = Mod: module error
0x04 = W2Err: error at the W2 interface
0x08 = W1Err: error at the W1 interface
0x10 = W2: inactive state of the W2 interface
0x20 = W1: inactive state of the W1 interface

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 73

PCP - Some InterBus-S systems, in addition to the cyclic process data exchange,
can also communicate acyclically with the master card (IBS ISA SC/I-T
Communication only). The communication on the InterBus-S is called PCP-communication
(Peripherals Communication Protocol).
The systems are recognised by their Idend. code and have an additional
card index tab:

Through “enabling “ the PCP communication, an AMP communication is


allocated to the system, via which the PCP communication is executed.
On the InterBus side, the communication link between this system and the
master card has a communication number (CR = Communication
Reference). A password and an Access Group may also be stated (see
description of PCP communication).
PCP services Currently, the following services are supported:
Read (0x0081)
Write (0x0082)
Start (0x0083)
Stop (0x0084)
Resume (0x0089)
Reset (0x008A)
The required service is stated by recognising the service in the HIWORD of
the ADS IndexGroup (see ADS documentation).
To simplify, with the read service and an AdsReadReq and with a write
service and an AdsWriteReq, the code 0 is used.
Index The required PCP Index is stated in the LOWORD of the index group.
Subindex The required PCP sub-index is stated in the Index Offset.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 74

CANopen Devices
CANopen Node CANopen systems which are not recognised in the TwinCAT System
Manager, may also be accepted into the network by selecting the
“CANopen Node“ box. For these systems, the CAN(open) messages can
be configured directly. This guarantees maximum flexibility of this general
CANopen interface.
Since only minimum CANopen conditions can be set on the system to be
connected, general CAN systems can be integrated with very low
expenditure.
A general CANopen system, in accordance with the CANopen
specification, must have access to the object 0x1000 (Device Type, access
type, read only) in the object directory. The content of this parameter is
read out at system start via SDO (Service Data Object) access and
compared to the configured value. Communication with the running time
can be selected through free process data objects (CAN messages) or
through SDO access.
Card index tab “CAN Node“

Node ID: Here, the node address of the general CANopen system is
set. If “Auto adjustment of the PDO COB Ids“ box is
selected, the default identifier of the project data objects is
tracked when the node ID is changed accordingly.
Profile No.: After CANopen, the parameter 0x1000 “Device Type“ in the
two lowest value bytes, receives the number of the system
profile supported by the system. This is entered here and at
system start, compared with the parameters existing in the
system. If now system profile is supported, the parameter
receives a zero value.
Add Info: The additional info is located in the two highest value bytes
of the object list entry 0x1000 (Device Type).
Guard Time: The guard time determines the interval, in which the node is
monitored (node guarding). 0 means no monitoring.
Life Time Factor: Guard Time x Life Time Factor determines the watchdog
length for monitoring the CIF30-CAN through the CANopen
node (Life Guarding). 0 means no monitoring.
Emcy COB Id. And Guard COB Id. are the identifiers for Emergency
Messages and/or Guarding Protocol. These are derived from
the node address.
Automatic PDO... States whether TwinCAT is to download the PDO
communication parameter at system start.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 75

CANopen PDOs Process data objects (PDOs) and CAN messages, which transport the
process data without protocol overhead. Many producer-specific CAN
protocols can therefore be illustrated on PDOs and integrated into
CANopen networks.

Card index tab “PDO“

COB Id: The CAN identifier for this PDO. For every two send and
receive PDOs per node, CANopen provides default
identifiers. These can then be changed.
Trans.Type: The transmission type determines the transmission
behaviour of the PDOs. 255 corresponds to the event-
controlled transmission.
Inhibit Time: Transmission delay between two equivalent PDOs,
advisable especially with event-controlled transmissions.
Given in multiples of 0,1 ms.
Length: The length of the PDOs is derived from the mapped
variables and cannot therefore be edited.
From the parameters input here, TwinCAT produces corresponding entries
in the object list of the node, which are transferred through SDO at system
start. The entries can be seen on card index tab SDOs. If this behaviour is
not required, it can be de-activated via the “Auto-Download of the PDO
Parameter“ checkbox on the card index tab CAN Node.

Tree illustration: TwinCAT provides for a general CANopen node, for every second
transmission and receive PDO, which are equipped with default identifiers.
Redundant PDOs can be selected and deleted.
TxPDOs are sent from CANopen nodes and generally have inputs.
RxPDOs are received by the nodes.
The PDOs are filled with variables by clicking the right mouse button on
“inputs“ and/or. “outputs “ and selecting the corresponding variables. If
several variables of the same time are added in one action, the offset
within the PDO is automatically produced. If variables are added
consecutively, the corresponding offset (start address within the CAN
message) is set for each variable.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 76

Context menu: This menu appears by clicking the general CANopen node with the right
mouse button. Here, other Tx and/or Rx-PDOs can be added.

Card index tab “SDOs“ See. "BK5100" on page 65

Card index tab “ADS“ See. "BK5100" on page 65

DeviceNet Devices
DeviceNet Node General DeviceNet systems can be integrated by selecting the DeviceNet
node. The connection parameters can then be stated for these systems.

Card index tab “DeviceNet


Node“

MAC ID: Here, the node address of the general DeviceNet


node is set.
Prod. Inhibit Time: Specifies the transmission delay between I/O
messages. Currently evaluated by the master as cycle
time (repeat transmission) of the I/O connection.
Exp. Packet Rate: The Expected Packet Rate states the maximum cycle
time of an I/O connection. If no Change of State
occurs within this time, the I/O message is still sent. At
the same time, the Expected Packet Rate determines
the watchdog value, with which the slave monitors the
I/O connection.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 77

Connection Type: Specifies the I/O connection.


5. Polled: Outputs are written and inputs are read in
cycles.
6. Bit Strobed: All nodes are requested with a
Broadcast Message to send your Bit Strobe
Message (up to 7 Bytes input or status data).
7. Change of State: Event-controlled transmission of
I/O information.
8. Change of State / Cyclic: Even if no event has
occurred, the I/O message is sent after the
Expected Packet Rate has expired.

Watchdog Action: Specifies the behaviour when the Watchdog Function


responds (I/O connection in the Time Out).
1. Transition to Timed Out: The connection moves
into the Timed Out condition and remains there
until it is reset or deleted.
2. Auto Delete: The connection is automatically
deleted.
3. Auto Reset: The connection remains in the
Established Status and the Watchdog Timer is re-
started.

UCMM Support: Systems which support no I/O connections can


communicate with the CIF30 through Explicit
Messages. These must then be established via the
UCMM (Unconnected Message Manager). In order to
avoid the long Time-Out waiting time (3s) at Bootup
when establishing the I/O connection, this
communication method can be stated directly. The
corresponding DeviceNet Message Group for the
Explicit Message connection can then be stated.
Card index tab “Attribute“ See. "BK52x0" on page 65

Card index tab “ADS“ See. "BK52x0" on page 65

SERCOS Axis
SERCOS Axis
Card index tab “Sercos Axis“

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 78

Address: SERCOS axis address which must agree with that set on
the drive amplifier.
Operating mode: Sets the SERCOS mode of the axis. Currently, the speed
operating mode is supported, sent to the drive in the
target speed value and position is controlled in the PC.
The position operating mode is also supported, sent to
the drive at the positions and the position is controlled in
the drive.

NOTE: In the position operating mode, please ensure, that with end axis in the
weighting type for position data (S-0-0076), the module function is switched
on and the resultant module value (S-0-0103) is recognised in the
TwinCAT (see. Fehler! Verweisquelle konnte nicht gefunden werden.).
NOTE: In the speed operating mode, please ensure that the output cable for the
drive in the TwinCAT System is set correctly.

Card index tab “Startup“

Here, SERCOS parameters can be entered which at each TwinCAT Start,


are sent to the drive through the NC service channel and overwrite the
values in the drive.
Card index tab “Actual value
channel “

Here, the SERCOS parameters are entered which are exchanged in the
actual value channel of the respective axis. Corresponding variables
below the axis are created in the tree which can be lined accordingly.
An actual position value is required in every case!
Card index tab “Target value As in the actual value channel, variables are also stated here, which are
channel “ exchanged in the target value channel. Depending on the operating mode
of the axis, the speed or the actual target value must exist in the target
value channel.
Card index tab “ADS“

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 79

Card index tab “Online“

The NC service channel can be served through the online tab. TwinCAT
must be started and the SERCOS ring must be at least in Phase 2.
On this side, in addition to the imminent diagnostic, a SERCOS reset takes
place on the axis and/or the drive amplifier.
The list below shows all SERCOS parameters with their current values.
This data is read online from the drive (inc. texts and units), which means
that the pages in the list require a certain length of time. When the drive
supports this, the English and German outputs appear alternately.
The parameters are changed by double-clicking on the relevant Id No. No.,
a corresponding dialogue begins.
The list of SERCOS parameters can also be printed and exported (also by
Drag and Drop e.g. in Excel). An appropriate context menu is opened by
clicking the right mouse button.

SERCOS IDs per ADS SERCOS IDs can also be read and written for the running time by ADS
(e.g. from the SPS). An ADS Port must be allocated to the axis via the ADS
tab, which is carried out as standard.
An ADS Read or Write Request can be carried out through this port. The
IndexGroup corresponds to the required SERCOS ID and the IndexOffset
to the element of the SERCOS value:

Port No. Number from the ADS side (card index tab)

IndexGroup SERCOS-ID, e.g.:


S-0-0123 = 123
S-7-0101 = 101 + 0x7000
P-0-0002 = 2 + 0x8000
IndexOffset Required element:
0 = Value,
2 = Name (read only),
3 = Attribute (see SERCOS specification),
4 = Unit,
5 = Minimum,
6 = Maximum

Reset per ADS The drive amplifier (e.g. after a drag error) can also be reset via ADS,
whereby the values 3, 0, 3 and 0 again are sent consecutively to the ID S-
O- 0099. (This is carried out by the TwinCAT system manager, if the reset
button is pressed on the online side).

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 80

5.8. Field bus submodules (terminals etc.)


Field bus submodules are modules that are not directly connected logically
to their respective field bus interface, but which represent submodules of a
field bus box.
On the one hand, the Beckhoff bus terminals and, on the other hand,
modules of a modular Profibus slave are currently understood to be field
bus submodules..

Bus terminals
Context menu Insert terminal... <ins>
Inserts a further terminal before the currently marked terminal. The
corresponding dialog is opened
Delete terminal... <del>
Deletes the currently marked terminal.

Digital terminals Digital terminals automatically generate bit variables that correspond to the
respective type. These variables are arranged in channels, the number of
which depends on the type of the terminal.
Variables By way of example, the tree view of the digital input terminal KL1002 is
shown on the left with two channels. Two channels have been created,
each of which contains one binary input variable.

“Variables“ tab

The individual variables can be associated in a clearly arranged fashion for


all variables simultaneously via the “Variables” tab. It goes without saying
that it is still possible to associate the variables via the context menu or the
file card view of the respective variables.
Channel 1...: Opens the association dialog for the binary variable of the
first channel.
Channel 2...: ditto.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 81

Analogue terminals Analogue terminals automatically generate variables that correspond the
respective type. These variables are arranged in channels, the structure
and number of which depend on the type of terminal.
Variables By way of example, the tree view of the analogue output terminal KL4032
is shown with two channels on the left. Two channels have been created,
which each have two input and two output variables (II/O Lightbus and
Profibus).
For each channel, analogue input and output terminals have one status
byte (8 Bit input), one input word (16 Bit input), one control byte (8-bit
output) and one output data word (16-bit output. The status and control
byte are dropped in the case of the InterBus-S.

The number of variables offered per channel depends on the field bus in
use!

“Channel X” tab

The individual variables of a channel can be associated in a clearly


arranged fashion for all variables simultaneously by way of the “Channel X”
tab. It goes without saying that it is still possible to associate variables via
the context menu or the card file view of the respective variables.
Status...: Opens the association dialog for the status byte.
Data in...: Opens the association dialog for the input data word
Control...: Opens the association dialog for the control byte.
Data out...: Opens the association dialog for the output data word

Modular Profibus devices


Modular Profibus devices enable definition of the variables of a device by
the selection of one or several modules. To this end, modules and their
inputs and outputs are defined in the GSD file of the corresponding device.
The following dialog appears when you add or insert a module:

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 82

Variables The variables of a module may assume one of six types:


1. Byte (8 Bit)
2. Word (16 Bit)
3. Byte field (n * 8 Bit)
4. Word field (n * 16 Bit)
5. Byte string (n * 8 Bit, consistent)
6. Word string (n * 16 Bit, consistent)
The module may have inputs and/or outputs, even of different types.

5.9. NC Channels
As described in Chapter 3.8 “NC configuration”, several channel types are
available for selection.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 83

Standard NC channel (for PTP axes)


Context menu Add axis...
Inserts one (further) axis in the currently marked channel. At the same
time, the system components needed for operation of the axis (suitable
type of group, encoded, controller, driver) are added automatically.
Delete...
The currently marked channel (including all sub components) is deleted.
Export channel...
The data of the currently marked channel is exported as a file. This file can
be imported into another project in the context menu of the NC task, for
example.
Import axis...
The data of an axis that has been exported to a file at a previous point in
time is imported and the corresponding axis is created as a component of
the currently marked channel.
Change ID ...
The ID of the currently marked channel is modified. In doing so, the
System Manager checks whether another channel has already occupied
the chosen ID..
“General” tab

All channel types offer this tab.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 84

„Online“ tab

All channel types offer this tab. When TwinCAT is active, the most
important values of the axes are displayed here. The axes can be moved
manually. At the same time, travel distances are defined by the software
limit switches and speeds of travel by the manual travel parameters of the
respective axis. An axis error can be reset by pressing the F8 key. In the
case of axes with incremental encoders, pressing the F9 key starts
calibration travel.

Interpreter NC channel
Context menu Add group...
Adds a (further) group in the currently marked channel.
Delete...
The currently marked channel (including all subcomponents) is deleted.
Export channel...
The data of the currently marked channel is exported as a file. This file can
be imported into another project in the context menu of the NC task, for
example.
Import group...
The data of a group exported earlier to a file is imported and the
corresponding group is created as a component of the currently marked
channel.
Change ID...
The ID of the currently marked channel is modified. In doing so, the
System Manager checks whether a different channel is already occupying
the selected ID.

„Interpreter“ tab

Here, you can set the interpreter type and the size of the load buffer.
Currently only the NC interpreter DIN 66025 (Siemens dialect) variant is
available as the interpreter type. This interpreter simulates a series of DIN
add-ons (@ codes, subroutine technique).
The size of the load buffer should be set approximately twice as much as
the NC program files including subroutines that are called up. The absolute
upper limit is currently 10,000 Kbytes.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 85

When the system is started, each channel’s interpreter occupies the


memory that is specified as the load buffer size. Therefore, this memory is
no longer available for other Windows applications. So, the load buffer size
should be set to a reliably adequate value, but not to one that is
unnecessarily high. If problems should be encountered in this connection,
these can be remedied easily, however, generally by adding memory
chips.

5.10. NC Groups
IN the case of PTP axes, the groups are not visible because no parameters
or information whatever are needed or are offered. The menus and
displays described here are accessible in the case of DXD groups
(multidimensional groups that are capable of interpolation).
Group Types
Card index tab “Adding an
NC Group “

PTP Groups With PTP axis, the groups are not visible, because no parameters or
information is required or offered respectively. The menus and displays
described here are accessible with DXD groups (interpolation capable,
multi-dimension groups). No interpreter.

D3 Group D3 (and also D2, D1) Interpolation group with interpreter.


Discrete group Group for one fast/creep axis. No interpreter.
(Fast/Creep)
Phase motor group Group for one phase motor axis. No interpreter
(low cost)
FIFO Group n-dimensional FIFO group. No interpreter
(n-dimensional)

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 86

FIFO-Group
Card index tab “FIFO“

FIFO The FIFO group is an n-dimensional axis group, the target position data
(including a Fifo cycle time T_fifo) is produced externally. This data is
transferred into a storage area of variable size (Fifo length) in packets of
variable length per SPS within their cycle (T_sps). In the Fifo generator, the
data is transformed to the Saf cycle time (T_saf) and expanded by dynamic
data (speed, acceleration).
T_fifo > T_saf corresponds to a fine interpolation of Fifo data.
T_saf > T_fifo means that the Fifo is processed generally.

Sequence System Manager: Parameterise Fifo.


SPS: Fill Fifo wholly or partially.
SPS: Start Fifo.
SPS: Refill Fifo etc.
Fifo runs empty. Error or end.

Functions Start
Fill Fifo partially.
Override (instantaneous override).
Enquiry of valid lines in Fifo.
Stop ( = Override 0.0 and end)

Fifo filling level (yellow)

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 87

FIFO Parameters
No Data Unit Description
type
1 FIFO Dimensions INT Dimension of FIFO group (number of participating axes). Cannot be
>0 changed when TwinCAT is active.
2 FIFO Length INT No. of lines in the FIFO. Cannot be changed when TwinCAT is active.
>0
3 Interpolation type INT Cannot be changed when TwinCAT is active

4 Override type INT Type 1: instantaneous, Type 2: PT2 (not implemented). Cannot be
changed when TwinCAT is active.
5 FLOAT (not implemented)

6 FIFO Cycle time FLOAT s The cycle time for the FIFO is produced (can deviate from the Saf cycle
>0 time).

Card index tab ”Online“

The number of Saf entries is equal to the number of existing FIFO entries.

3D-Group
Context menu Add axis...
Inserts a (further) axis in the currently marked group. In doing so, the
devices needed for the operation of the axis (encoder, controller, driver)
are added automatically.
Delete...
The currently marked group (including all subcomponents) is deleted.
Import group...
The data of the group is exported to a file.
Import axis...
The data of an axis exported earlier to a file is imported and the
corresponding axis is created as a component of the currently marked
group.
Change ID...
The ID of the currently marked group is modified. In doing so, the System
Manager checks whether a different channel is already occupying the
chosen ID..

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 88

„DXD“ tab

The parameters listed here are used for path interpolation. They define the
transition from one path segment to the next.

Minimum speed
Vmin The minimum speed Vmin >= 0 defines, with the exception of a requested
halt at segment transitions (exact halt, programmed halt, path end) and
override requests, the minimum under which the path speed must not go
below the minimum speed. [Not implemented.]

Segment transition speed


Generally, the transition from one segment to the next is not necessarily
smooth, with the result that the speed at the transition point must be
suitably reduced to avoid dynamic instability. To this end, the transitions
are geometrically classified and the transition speed Vk is defined in three
steps.
Classification of segment Segments – as geometric objects – are considered here as curves within
transitions the meaning of differential geometry which have been parameterised by
Ck means of the arc length.
A segment transition from one segment S1 to one segment S2 is called Ck,
in terms of its geometric type, where k is a natural number (including 0) if
each segment can be constantly differentiated k times according to the arc
length and the k-th derivations at the transition point agree.
C0 C0 transitions have a bend at the transition point.
C1 C1 transitions look smooth, but are not dynamically smooth. One example
of this is the transition from the straight run to the semicircle in a stadium,
resulting in an acceleration leap at the transition point.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 89

C2 C2 transitions are for the line, circle and Helix segment types, and are
transitions that arise by splitting a whole segment of one type.
Step 1 Assuming Vi is the nominal speed on the segment Si, then the following
applies:
Vk = min(V1,V2).
Thus, we have a guarantee that, in the case V1< V2, the speed V1 is
retained up the transition point and that, in the case of V2< V1, the speed V1
is already reduced in the segment S1 with the result that V2 is reached at
the transition point.

Step 2 If the transition is of the type C2, then there is no further reduction.
If the transition is of the type C1, then further optional reduction is possible
(see below).
If the transition is of the type C0, then further optional reduction is possible
(see below).

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 90

Step 3 If necessary, increase to Vmin.. If a minimum speed differing from 0 is


specified, then
Vk <- max(Vk,Vmin)
Is set.

C1 reduction In the case of C1 transitions, an acceleration leap of the amount ∆a. which
is estimated, generally occurs. According to the theory, the speed Vk must
be reduced Vk = 0 at each C1 transition because the acceleration leap
provokes a following error leap. With the C1 factor
Vk <- Vk exp( - C1 ∆a )
is set. If you do not want to reduce at all, then you must set C1 = 0. If you
wish to reduce completely, then you must set C1 to a very high value (e.g.
1010).
C0 reduction In the case of C0 transitions, two reduction methods are offered:
Coulomb: a dynamic method analogous to Coulomb scatter,
Cosine: a purely geometric method.
The deflection angle ϕ at the transition point is the angle between the
tangent of the path at the end of the signal S1 and the tangent of the path
at the start of S2.
C0-Coulomb Analogous to the Coulomb scatter to the speed is assumed to be
proportional to the speed at infinity
Vk ∝ ( tan(0.5(π−ϕ)) )1/2
and is then reduced by means of the C0 factor
Vk <- C0 Vk.
Thus, in any case reduction to Vk takes place in the event of a reversal of
movement (ϕ =180). As the reduction is drastic in the case of small
deflection angles, however, there is an ϕlow ∈ [0,180] as from when
reduction sets in fully. If you do not want to reduce at all, then you must set
ϕlow = 180. If you want to reduce complete (except for ϕ = 0), then you must
set C1 = 0.0 and ϕlow = 0 .

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 91

C0-Cos Here, there are


1. the C0-factor ∈ [0,1],
2. an angle ϕlow ∈ [0,180],
3. an angle ϕhigh ∈ [0,180], with the result that ϕlow < ϕhigh.
Reduction scheme:
1. ϕ < ϕlow : no reduction: Vk <- Vk,
2. ϕhigh < ϕ : reduction by the C0-factor: Vk <- C0 Vk,
3. ϕlow < ϕ < ϕhigh: partial reduction, continuously interpolating between
cases 1 and 2, proportional to the cos function in the range [0,π/2].
If you do not wish to reduce at all, then you must set C1 = 1.0. If you wish
to reduce completely (except for ϕ = 0), then you must set C1 = 0.0, ϕlow =
0 and ϕhigh to a very low value, but unequal to zero (e.g. 1.0E-10).

'DWDW\SH 8QLW 'HVFULSWLRQ

Reduction mode ENUM Method of speed reduction at C0 transitions

… for C0 transition FLOAT Reduction factor at C0 transitions [0.0,DBL_MAX].


>= 0.0
… for C1 transition FLOAT Reduction factor at C1 transitions [0.0,1.0].
>= 0.0
Angle low FLOAT Degree Angle Low ∈ [0.0,180.0].
>= 0.0
Angle high FLOAT Degree Coulomb method: not available.
>0.0 Cos method: C1 ∈ (Angle Low,180.0].

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 92

„Online“ tab

When TwinCAT is active, the most important status information of the


group is displayed here. For SVB (block preparation) and SAF (block
execution), the task status and the number of entries in the buffer are each
returned here. An error state of the group is recorded here and is
displayed.

5.11. NC axes
Data types When the data type FLOAT >= 0 is specified, this means that the value
must be non-negative.
When the data type FLOAT > 0 is specified, this means that the value must
be strictly positive.
Inputs Decimal (±xxx.xxxxx) or exponential (±xx.xxxE±xxx or. ±xx.xxxe±xxx) are
possible.
-0 or –0.0 is not valid as a number.

Axis types
Card index tab “Adding an
NC axis “

Continual axis Axis with continuous speed level (servo axis).


SERCOS Axis SERCOS Axis
Encoder Axis (virtual axis)
Virtual axis, i.e. Axis with encoder but without drive and regulator.
The actual value of the encoders (filtered as an option) are copied to the
target values.
Fast/creep axis Axis with two speed levels.
Low Cost Phase Motor Axis Axis with quasi-continuous speed level, which are operated without
(dig. E/A) physical encoders (i.e. controlled but not regulated). See also separate
documentation “TwinCAT PTP ‘Low Cost‘ Phase motor axis“.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 93

Units of an axis
This menu serves to set the units in all following menus.

“Unit” tab“

The millimetre [mm] and second [s] are the basic units and thus the
defaults. At deviance with these, it is possible to select meters [m], ° or
degree as units. In addition, a deviance with the default (or selected) units,
you can additionally select display (and input) of the position in
micrometers and of the speed in millimetres/min. Finally, you can also
output the position in modulo values (which is set in the Encoder “Global”
menu.
The result of the unit selection is displayed for the position, the speed, the
acceleration and jolt.
Below, mm and s are assumed as the units.

Download Set the parameters in the axis menu as follows. Move the mouse to the line
concerned – the line appears in blue. When you press “Enter” or click the
mouse, a small window opens in which you either select from a selection
box or where you can enter a number. When you press “Enter” once again,
the small window disappears and the entered value appears in the line that
is still highlighted in blue. An asterisk additionally appears before the
entered value to indicate that the value has not yet been activated. When
you select „Download“, the value is activated and the line appears in its
normal colour. By selecting „Upload“, you can check which value is
currently active.

Global parameters of an axis


The „Global“ window contains the global parameters of the axis.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 94

Axis „Global“ tab

Parameters of the „Global“ axis menu:

No. 'DWDW\SH 8QLW 'HVFULSWLRQ

1 Maximum allowed FLOAT mm/s The speed that the axis must never exceed.
speed >0

2 Rapid traversing FLOAT mm/s Speed of feed positioning (G0) in accordance with DIN66025.
speed (G0) >0

3 Manual max speed FLOAT mm/s High speed for manual positioning with the F1 and F4 keys in the
>0 online menu.
4 Manual min speed FLOAT mm/s Low speed of manual positioning with the F2 and F3 keys in the
>0 online menu.
5 Referencing speed FLOAT mm/s Speed of reference travel in the direction towards the referencing
cam (the direction can be set in the Encode “Incremental” menu).
in positive direction >0
6 Referencing speed FLOAT mm/s Speed of referencing travel from the referencing cam in the
direction of the place where the synchronisation pulse is issued
in negative >0
(the direction can be set in the Encode “Incremental” menu).
direction
7 Pulse width in FLOAT mm Relative spatial position for extended axis start “ Puls+” in the
“Functions” menu.
positive direction
8 Pulse width in FLOAT mm Relative spatial position for extended axis start “ Puls–” in the
“Functions” menu.
negative direction
9 Mode: BOOL Deactivation/activation of the min software end stop monitoring
Min end stop
monitoring
10 Min software end FLOAT mm Position of the min software end stop

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 95

stop
11 Mode: BOOL Deactivation/activation of max software end stop monitoring
Max end stop
monitoring
12 Max software end FLOAT mm Position of the max software end stop
stop
13 Mode: position BOOL Deactivation/activation of monitoring of the position following error
with the value specified by the “Maximum position following error”
following error
parameter.
monitoring
14 Maximum position FLOAT mm Maximum permissible position following error
following error >= 0

15 Maximum position FLOAT s If the position following error exceeds the maximum permissible
position following error for longer than the maximum following error
following error filter >=0
filter time, when monitoring is active the axis is instantaneously
time stopped by means of a 0 V output and is set to the logical “error”
state.
16 Mode: position BOOL Deactivation/activation of a bit (e.g. for the PLC) when the axis is
within the position area window around the target.
range monitoring
17 Position are FLOAT mm Size of the half the position area window around the target.
window >=0

18 Mode: target BOOL Deactivation/activation of a bit (e.g. for the PLC) if the axis is within
the target position window around the target by the target position
position monitoring
window around the target by the target position monitoring time.
The bit is reset immediately when the axis position is no longer
within the target window.
19 Target position FLOAT mm Size of half the target position window around the target
window >=0

20 Mode: PEH BOOL Deactivation/activation of a bit (e.g. for the PLC) if (i) setpoint
output for positioning of the axis has logically terminate and (ii) the
timeout
axis has reached its target position (target window monitoring) and
both conditions occur at least once within the timeout (PEH =
Position End Halt).
21 Time out FLOAT s Time out of the PEH condition.
>=0
22 Mode: movement BOOL Not implemented.
monitoring [Deactivation/activation of the bits [for the PLC when the axis
physically moves within the movement monitoring window during
the movement monitoring time.]
23 Movement FLOAT mm Not implemented.
monitoring window >=0
24 Movement time out FLOAT s Not implemented.
>=0
22 Delay time between FLOAT s Time by which the target position in respect of the speed (in
speed and position >=0 position regulator) is delayed. Instead of the position regulator-
speed part
v_p(t) = k_p(p_s(t)-p_i(t))
[k_p Proportionality constant, p_s target position value, p_i
position value] is output in this function at the target position
behind the time τ
p_s(t-τ) in the form
v_p(t) = k_p(p_s(t-τ)-p_i(t))
in order to compensate for an existing system dead time.
25 Mode: loop BOOL Deactivation/activation of the property that ensures that an axis –
which must not be a servo axis – always approximates the target
distance
position from the same direction.
26 Loop distance [+/-] FLOAT mm The distance by which the axis at least approaches the target in
the direction defined by the sine.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 96

27 Mode: backlash BOOL: Deactivation/activation of backlash compensation.


compensation
28 Backlash FLOAT mm Length of backlash. In the event of movement in the direction
defined by the sine, the target is passed over by the specified
amount.

Dynamic parameters of an axis


Menu for setting the dynamic acceleration, deceleration and jolt (derived
from the acceleration) parameters.

Axis-„Dynamics“ tab

No 'DWDW\SH 8QLW 'HVFULSWLRQ

1 Acceleration FLOAT mm/s² Acceleration limit or maximum allowed acceleration


>0
2 Deceleration FLOAT mm/s² Deceleration limit or maximum allowed deceleration
>0
3
3 Manual Max FLOAT mm/s Jolt (derived from the acceleration and deceleration)
Speed >0

There are two possibilities of setting these parameters:


(i) Indirectly by specifying the ramp time or the braking time and by
selecting an acceleration profile. In this case, the acceleration,
deceleration and jolt are computed and displayed.
(ii) Directly by specifying the acceleration, deceleration and jolt values. In
this case, the ramp time or the braking time and the acceleration
profile are computed and displayed.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 97

Dynamic profile The default dynamic profile for servo axes is a 7-phase dynamic profile.
The 7 phases are (optional phases are given in brackets [])
(i) Acceleration phases:
Acceleration buildup
[constant acceleration],
Acceleration drop,
(ii) [Phase of constant speed],
(iii) Deceleration phases:
Deceleration build up,
[Constant deceleration],
Acceleration drop.
If the nominal speed cannot be reached (the distance is too short), without a
message appearing a suitable attainment nominal speed V is calculated and is
activated. Whether the acceleration/deceleration limit(s) (A+,A−) is/are reached
depends on the ratio of the acceleration/deceleration to the nominal speed. The
value of the jolt R at which the acceleration/deceleration is just reached (but is not
retained) is the critical jolt, which is given by the formulas
R+ = (A+)²/V, bzw R− = (A−)²/V
In the units mm and s.

Example of a dynamics
profile

Online display (manual menu) of an axis


The online menu is the main menu for online axis operation.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 98

Axis “Online” tab

The menu is broken down into (i) displays, (ii) input boxes and (iii) function
keys.
Online displays (i) Displays
Actual and nominal positions,
following error with minimum and maximum values since the last
reset.
Actual and nominal speeds,
Override in %, total and controller output in %, error code,
Axis status:
Ready, referenced. At standstill (logical), has job, moving higher,
moving lower, coupled, at target position (i.e. within the set target
window for a preset time), in position range (i.e. within the preset
position range).
Enabling signals for controller, feed+, feed-.,

Online inputs (ii) Input boxes


Partly with download by mouse clicking the rectangular button.

No. 'DWD 8QLW 'HVFULSWLRQ


W\SH
1 Kv factor FLOA [mm/s]/mm P controller Kv factor
T
>=0
2 Reference speed FLOA mm/s Reference speed at the maximum output quantity (e.g. at
T 10 V)
>0
3 Target position FLOA mm Target position; the download function calls up the “New
T target position” function

4 Travel speed FLOA mm/s Global nominal speed. If the distance is too short to reach
T this speed, a lower suitable nominal speed is automatically
>0 calculated and activated.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 99

Online functions (iii) Function keys


F1 Reverse travel at Manual Max Speed,
F2 Reverse travel at Manual Min Speed,
F3 Forward travel at Manual Min Speed
F4 Forward travel at Manual Max Speed
F5 Start with the values set in the entry boxes and in the “Dynamics”
menu, ,
F6 Stop,
F8 Reset,
F9 Calibrate with the values set in the „Global“ menu.

„Set“ window

This window allows you to set specific enabling signals and values without
the PLC. If a PLC is active, the set values are generally overwritten
periodically and do not take effect.

No. 'DWD 8QLW 'HVFULSWLRQ


W\SH
1 Enable: controller BOOL Without controller enabling, the controller is not active and
0 V is output.
2 Enable: feed+ BOOL Without feed+ enabling, the axis cannot be started in the
positive direction. If the axis travels in the positive direction
and feed+ enabling is cancelled, the axis is stopped (the
axis does not start again when enabling is once again set.
3 Enable: feed- BOOL Without feed- enabling, the axis cannot be started in the
positive direction. If the axis travels in the negative direction
and feed- enabling is cancelled, the axis is stopped (the
axis does not start again if enabling is set again).
4 Override FLOA % Speed override in % within the range [0.0,100.0] referred to
T the nominal speed.
>0

Functions of an axis
Special axis operation functions.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 100

Axis„Functions“ tab

The menu is broken down into displays, entry boxes and function keys.
(i) Displays
Actual and nominal positions.
(ii) Entry boxes
Contrary to the values defined in the “Dynamics” menu,
acceleration, deceleration and jolt are selected. There is a large
number of special start types.

Extended start types

Start types
Absolute

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 101

Relative
Modulo
Puls ± (relative positioning with the value set in the “Global” menu)
± 1.0 mm
± 0.1 mm
± 0.01 mm
± 0.001 mm

(iii) Function keys


Start of the selected start type, Stop.
Drive output
Output type: in ± percent of the maximum output quantity, e.g. in relation to
10 volts.
Start and stop of output.
Set actual position Allows you to set the actual position (recalibration without referencing
travel.
Reference systems: absolute, relative or Modulo
Set target position Allows you to call up the “New target position” function
Reference systems: absolute, relative or Modulo.

Coupled axis I: Linear Slave Axis


The Coupling menu serves to activate special axis functions.

Card index tab -


“Coupling “

Master/slave coupling The following must be specified:


The master axis, the coupling type (only Linear) and the gear factor (≠ 0.0),
which may also be negative
Functions:
Couple only when both axes are at standstill,
Uncouple is possible in every dynamic state of the master axis – the salve
axis is converted to master axis and then continues travelling, i.e. as if it
were still slave axis, but can be individually stopped.
Modify gear factor should only be selected during travel with dimensions
because a following error is generated.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 102

Compensation of axes
The menu compensation serves to activate the position compensation.

Card index tab axis


“Compensation“

Distance compensation Start compensation provides each master or slave axis with the ability to
catch up or lag behind by a certain distance (compensation distance)
during constant travel (process speed) over a certain distance
(compensation length), whereby certain increases in the dynamics
parameters are not exceeded. The speed profile of compensation is
trapezoidal, whereby differing tendencies of the ramps are allowed.

A virtual axis (encoder axis) can execute a compensation. If a slave axis is


coupled to a virtual axis as a master axis, the slave axis can only start and
execute a compensation if the speed filter time (the virtual axis) is
sufficiently large to prevent the axis from unintentionally changing direction.
Start parameters:
No. 'DWD 8QLW 'HVFULSWLRQ
W\SH
1 Max acceleration FLOA mm/s² Maximum allowed increase in the set acceleration.
increase T
>0
2 Max deceleration FLOA mm/s² Maximum allowed increase in the set deceleration.
increase T>0

3 Max speed FLOA mm/s Maximum allowed increase in the set nominal speed.
increase T>0

4 Process speed FLOA mm/s Basic process speed. This is generally the nominal speed
T of the axis, whereby it is assumed that this nominal speed
>0 has been reached and will also be retained during
compensation.
5 Compensation FLOA mm The distance to be compensated (this may also be
T negative).
difference

6 Compensation FLOA mm The length of the distance over which compensation takes

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 103

length T>0 place.

Compensation is realised even if the compensation difference cannot be


reached (this case is indicated by a special return code). Compensation is
designed as distance control, i.e. compensation includes all dynamics
changes in the underlying axis. Compensation can be terminated
prematurely by selecting Stop.

Compensation example

Start from 0 mm to 10000 mm at nominal speed of 120000 mm/s,


Acceleration/deceleration 4000 mm/s², jolt 15000 mm/s/s/s.
Full distance compensation with the parameters:
Max. acceleration increase 1500 mm/s²,
Max. deceleration increase 1500 mm/s²,
Max. speed increase 12000 mm/s,
Process speed 120000 mm/s,
Compensation difference 200 mm,
Compensation length 3000 mm.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 104

Coupled axis II: Flying saws


Definitions The parallel slave is a slave axis, the speed of which should be
synchronised with that of the master axis, on a running master axis at a
certain position – running parallel with the master axis. It is assumed that at
the start of the slave axis (coupling of slave axis with master axis), the
master axis is at its (constant) target speed v_m is and that the slave axis
is in its basic position (coupled position). It is effected partly by section
control (slave acceleration & slave parallel journey), and partly as time-
controlled (slave delay and & slave idle).
The Diagonal Slave is a slave axis, the speed of which should be
synchronised diagonal to a master axis on the running master axis, so that
the speed components of the slave axis is equivalent to the master speed
in the direction of the master speed. If v_sp is the instantaneous target
speed of the parallel slave axis, the speed of the diagonal axis v_sd =
v_sp/sin(θ), whereby θ, 0 < θ < 90 deg, which describes the
complementary angle between master direction and slave direction.

Slave is in basic position, master runs


Sequence Slave coupling starts the slave
4 Dynamic phases:
1. Acceleration phase: on the acceleration section, the slave is drawn to a
type-dependent profile from v_s = 0 auf v_s = v_m.
2. Constant phase: the slave runs at v_s = v_m,
3. Stop: the slave is uncoupled dynamically from the master and runs time-
controlled (and independent of the master) from v_s = v_m to v_s = 0,
4. On reaching v_s = 0, the slave stands and is dynamically (not logically)
uncoupled.
Uncouple slave
PTP Re-start at basic position

Slave types The slave types are differentiated according to the speed algorithm in the
acceleration phase and also the synchronisation phase of the algorithm.

Weak synchronous Here, the slave synchronous position is the fixed function of the slave
algorithm coupled position and also the master synchronous position and the master
coupled position:
Slave acceleration section = 0.5 master acceleration section [/sin(θ)].
In general: master synchronous position, slave synchronous position
Algorithm:
Weak synchronous algorithm:
Here, the slave synchronous position is the fixed function of the slave
coupled position and also the master synchronous position and the master
coupled position
Master synchronous position and master coupled position:
Slave acceleration section = 0.5 master acceleration section [/sin(θ)].
In general: master synchronous position = slave synchronous position.

Linear Linear in speed, i.e. not limited back, therefore quick in the interrupt. Stop
also linear.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 105

Jer restricted 3Phase algorithm limited back, complex in the interrupt. Stop in the 3Phase
algorithm with aid phase, if the slave is not force-free.

Heavy synchronous Here, the master synchronous position = slave synchronous position (or
algorithms also the slave couple position or the master couple position) is freely
selectable within certain limits.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 106

Quadratic Quadratic in speed. Short in the interrupt. Stop is linear.


The following must apply: heavily synchronised
(Sbs = |Slave acceleration section|, Mbs = |Master acceleration section|)
(3/2) Sbs <= Mbs <= 3 Sbs.
If 2Sbs < Mbs <= 3 Sbs, the return is positive and the slave start is almost
return-free.
If 2 Sbs = Mbs, the speed is linear.
If (3/2) Sbs <= Mbs < 2 Sbs, the return is negative and the slave dynamics
at the point of synchronisation is almost return free.
Diagonal slave: The following must apply:
(Sbs = |Slave parallel acceleration section|, Mbs = |Master acceleration
section|)
(3/2) Sbs/sin(θ) <= Mbs <= 3 Sbs/sin(θ).
The heavy synchronous condition is checked only at coupling/start of the
slave, but not in the acceleration phase, in order to be able to track the any
return of the master axis.

Return The logical direction of the slave is the direction of the master coupling
Return block position -> master synchronisation position. If the master performs an
inverted movement, then (in phases 1 and 2 only) the slave follows by
inverted movement per section control. If however, the return of the master
is to reach to below the master coupling position (the slave is threatens to
run under its coupled position = basic position), if the slave breaks and
remains in the slave coupled position. If the master reverses again and
runs in its original direction via the old coupled position, the slave starts to
run again.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 107

Stop The Stop must function in all phases (not in the stop phase, not in the
stand phase): in the acceleration phase and in the constance phase and
also during re-run. In the 3Phase algorithm, the actual brake phase is pre-
connected to an additional phase, if the slave is not acceleration-free. In
this additional phase, the slave runs from current acceleration to
acceleration 0.

Uncoupling The slave axis can be uncoupled from the master axis at any time,
however this generally leads to the drag distance not being achieved and
hence abortion.

Start parameter:
No Data Unit Description
type
1 Master axis INT>0 Id of the master axis.

2 Coupling types INT Coupling types: Linear (weakly synchronised, not limited back),
Jerk (weakly synchronised, limited back), quadratic (strongly
synchronised, not limited back).
3 Absolute synchronous FLOAT mm Absolute synchronous position in the co-ordinate system of the
position master axis.

4 Angle of inclination FLOAT> deg θ Complementary inclination to the angle between master and
0, <= 90 slave direction. Parallel means θ = 90.0. Orthodonal θ = 0.0 is not
permitted.

5.12. NC encoder
Context menu Change ID...
The ID of the currently marked encoder is changed. In doing so, the
System Manager checks whether another encoder is occupying the
selected ID.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 108

“NC encoder” tab

Here, the encoder type can be chosen from a constantly growing series of
supported variants. Both absolute and incremental encoders are available.

„Global“ tab

'DWDW\SH 8QLW 'HVFULSWLRQ

ENCODER mode ENUM Operating mode of the encoder:


POS = The actual position is determined
POSVELO = The actual position and the actual speed
are determined.
POSVELOACC = The actual position, the actual speed
and the actual acceleration are determined.
Inverse encoder BOOL The counting direction is reversed:
counting direction FALSE = Polarity of axis movement agrees with the
counting direction of the acquisition hardware.
TRUE = Polarity of axis movement is inverted with
respect to the counting direction of the acquisition
hardware.
Scaling factor FLOAT mm/INC Increment evaluation: distance increments are converted
to axis positions with this factor.
Datum offset FLOAT mm In the case of absolute encoders: this value is added to
the encoder position in order to determine the axis
position. It serves to define the machine-related zero
point..
Modulo factor FLOAT mm In the case of rotary axes: this is the “distance” that is
generated by one rotation. If actual values are acquired
in degrees, for example, 360.0 should be entered here.
10 Filter time achieved FLOAT> s Filter time for the PT1 Filter of the achieved position.
position 0
11 Filter time achieved FLOAT> s Filter time for the PT1 Filter of the achieved speed.
speed 0

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 109

12 Filter time achieved FLOAT> s Filter time for the PT1 Filter of the achieved acceleration.
acceleration 0

PT1 Filter

Parameterisation A PT1 filter is a transfer function which is convexly interpolated between a


PT1-Filter time new x_n value and an old x_a value (which lies behind the cycle time). The
filter time (>= 0.0) in sec. can be entered
λ = Saf-cycle time/( Saf-cycle time+filter time)
where
x = λ x_n + (1-λ) x_a, λ ∈ [0.0,1.0].
If the filter time is near to 0.0, the new value is highly weighted. If the filter
time is large, the old value is highly weighted.

Encoder filter
Parameterisation example

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 110

“Incremental” tab

'DWDW\SH 8QLW 'HVFULSWLRQ

Inverse search BOOL Inverted search direction


direction for FALSE = Cam is sought in the positive direction of travel.
referencing cam TRUE = Cam is sought in the negative direction of travel.

Inverse search BOOL Inverse search direction:


direction for Sync FALSE = Synchronisation pulse is sought in the positive direction
of travel.
pulse
TRUE = Synchronisation pulse is sought in the negative direction
of travel
Reference position FLOAT mm This is the axis position that is assigned to the synchronisation
pulse that is effective during reference travel. If the actual value of
the axis is determined in a unit other than mm, the unit is also
required here.
External Sync pulse BOOL Reserved

„Online“ tab

When TwinCAT is active, the most important status information of the


encoder is displayed here. The referencing flag (“calibrated/not calibrated”)
of the encoder and thus of the axis can be set/reset manually.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 111

5.13. NC drives
Context menu Change ID…
The ID of the currently marked drive is changed. In doing so, the System
Manager checks whether another drive is occupying the selected ID.
“NC drive” tab

Here, you can select from a constantly growing series of drive type
variants. .

“Global” tab

'DWDW\SH 8QLW 'HVFULSWLRQ

DRIVE mode ENUM Reserved.

Invert Motor Polarity BOOL Inverted direction of rotation of the motor.


FALSE = When the drive is positively controlled, the axis travels in
the direction of larger positions.
TRUE = When the drive is positively controlled, the axis travels in
the direction of smaller positions.
Minimum Drive FLOAT The output to the drive is limited to this minimum value.
Output Limitation
Maximum Drive FLOAT The output to the drive is limited to this maximum value.
Output Limitation

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 112

„Analogue“ tab

This tab is only offered for drive types with analogue speed output.
Analogue is not to be understood as representation of the speed as a
voltage (e.g.±10V) or a current (e.g. ±20mA), but that the axis allows
practically continuous setting of any values. This is naturally also possible
in the case of drives with digital interfaces, e.g. the BISSI terminals of the
type KL5051. Here, an analogue adjustable speed is transported as digital
information.

'DWDW\SH 8QLW 'HVFULSWLRQ

Reference speed FLOAT Reference speed of the axis. During pilot control, setpoint
generation of the axis will assume that, when controlled with the
reference output value, the axis will react with this speed.
Reference output FLOAT See above.

Drift compensation FLOAT This value is added to control of the drive. In this way, a constant
offset can be added to the output in order to compensate for the
zero point error of analogue drives, for example.

“Stepper motor” tab

'DWDW\SH 8QLW 'HVFULSWLRQ

Bit pattern: cycle 1 ? Output bit pattern for step switching cycle 1. Represented as a
decimal number.
Bit pattern: cycle 2 ? Output bit pattern for step switching cycle 2. Represented as a
decimal number.
Bit pattern: cycle 3 ? Output bit pattern for step switching cycle 3. Represented as a
decimal number.
Bit pattern: cycle 4 ? Output bit pattern for step switching cycle 4. Represented as a
decimal number.
Bit pattern: cycle 5 ? Output bit pattern for step switching cycle 5. Represented as a
decimal number.
Bit pattern: cycle 6 ? Output bit pattern for step switching cycle 6. Represented as a
decimal number.
Bit pattern: cycle 7 ? Output bit pattern for step switching cycle 7. Represented as a

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 113

decimal number.
Bit pattern: cycle 8 ? Output bit pattern for step switching cycle 8. Represented as a
decimal number.
Bit pattern: holding ? Output bit pattern for the idle state. Represented as a decimal
current number

5.14. NC controller

NC-Controller
The NC controller menu serves to select controllers.

“NC controller” tab

Basically, two different controller types can be selected: position controllers


(controllers whose task it is to control the actual position so that it follows
the nominal position as exactly as possible) and position and speed
controllers (controllers whose task it is (i) to control the actual position so
that it follows the nominal position as exactly as possible and (ii) to control
the actual speed so that it follows the nominal speed as exactly as
possible.
Position controller types (i) Position controller P:
Following error proportional controller.
(ii) Position controller with two P constants:
(iii) Following error proportional controller with different constants for
standstill and movement.
(iv) Position controller PID:
Position PID-T1 controller with proportional pilot acceleration
control

Automatic DAC offset adjustment


Every controller optionally offers DAC offset adjustment. This adjustment
only becomes active if pilot speed control of the axis is an adjustable
component. This prevents influencing by the dynamic response of the axis.
If this axis is in position control (or is travelling at a corresponding low
speed), an offset speed is generated by integrating the correction rate. This
is added to the output. A PT1 response, i.e. an exponential function, comes
into being as the result of negative feedback of the position control loop.

'DWDW\SH 8QLW 'HVFULSWLRQ

Offset filter time Double Sec Time constant of offset adjustment


.
Offset limit Double - Relative control above which the offset is kept constant.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 114

Example of following error


reduction with the automatic
offset adjustment

If necessary, the offset adjustment response can be influenced during the


run time. A series of “switches” are provided for this purpose. These, and
the parameters for the time constant and the pilot control limit, can be
adjusted during the run time of the PLC, for example, or of another ADS
device.

If necessary, the offset adjustment can be deactivated completely. In doing


so, an abrupt change in the output voltage is not always avoidable. Soft
deactivation can be achieved with „FadeOut“. In doing so, adjustment with
its own time response is reduced to 0. If adjustment is to be stopped
temporarily, the „Hold“ mode can be activated. For example, this is useful
whenever the power section of the drive is temporarily shut down. If
adjustment were to remain active, breakaway of the offset would be
unavoidable.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 115

Pilot acceleration control


Proportional pilot Besides containing proportional feedback of the following error, almost all
acceleration control position controllers include proportional pilot acceleration control (Ka
factor). This should generally only be used in connection with the position
controller proportional component (kV factor). A strictly symmetrical
adjustment of the axis is required:
(i) At standstill, the following error is symmetrical about 0 (DAC
offset).
(ii) During constant travel, the following error is symmetrical about 0
(reference speed).
Setting Ka (i) Set Kv.
(ii) In the middle of the acceleration/deceleration phase, measure the
extreme acceleration/deceleration a max (a−max,), and the affiliated
+
+ −
following error d max (d max).
(iii) Ka+ = Kv • d+max / a+max, Ka− = Kv • d−max / a−max,.
Set and optimise Ka ≈ (Ka + Ka−)/2..
+
(iv)

Example of following error


reduction with Ka

Global parameters of a controller


The “Global” menu contains the global controller parameters.

Controller “Global” tab

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 116

No. 'DWDW\SH 8QLW 'HVFULSWLRQ

1 CONTROLLER ENUM Controller mode: only STANDARD possible.


mode
2 To pilot control FLOAT Relative weighting of pilot control.
weighting >=0
Default 1.0 corresponds to 100 % weighting of pilot control
3 OPERATING MODE: BOOL De/activation of monitoring the position of the position drag distance with
Drag distance the value specified by the “maximum position drag distance” parameter
monitoring position
4 Maximum position drag FLOAT mm Maximum permissible position drag distance.
distance >= 0

5 Maximum drag filter FLOAT s If the position drag distance exceeds the maximum permissible position
time >=0 drag distance by more than the maximum drag filter time, with active
monitoring, the axis is stopped instantaneously at voltage output 0 V and
Position set in the logical “error” condition.

Position controller
The „PID“ menu contains the special controller parameters.
P controller

“PID” tab for position P


controller

No. 'DWD 8QLW 'HVFULSWLRQ


W\SH
1 Position controller: FLOA [mm/s]/mm Proportional gain of the P component.
proportional factor T Output speed = pilot control speed + Kv • following error.
>= 0
Kv
2 Mode: automatic BOOL Deactivation/activation of automatic offset adjustment.
offset adjustment Automatic offset adjustment is only active within the
range [-Offsetlimit,+Offsetlimit] of the relative pilot
control speed, and is calculated and activates a DAC
offset that minimises the following error during position
control.
3 Offset filter time FLOA s Time constant of the integrator.
T
>0
4 Offset limit FLOA High limit of the active range of offset adjustment in
T relative components of the output quantity.
>0

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 117

PP controller
“PID” tab for position PP
controller

No. 'DWD 8QLW 'HVFULSWLRQ


W\SH
1 Position control at FLOA [mm/s]/mm Proportional gain of the P component at standstill.
standstill T Output speed at standstill = pilot control speed + Kvs •
>= 0 following error.
Proportional factor
KVs
2 Position control FLOA [mm/s]/mm Proportional gain of the P component during travel.
T
during travel Output speed during travel = pilot control speed + Kvf •
>= 0
Proportional factor following error.
Kvf
3 Position control: FLOA Threshold speed in % of the reference speed set in the
speed threshold V T “Online” menu. Kvs applies at standstill. Linear
>=0
dyn interpolation from Kvs to Kvf takes place from starting
up to reaching of the threshold. This is inverted
accordingly for deceleration.
4 Mode: automatic BOOL Deactivation/activation of automatic offset adjustment.
offset adjustment Automatic offset adjustment is only active within the
range [-Offsetlimit,+Offsetlimit] of the relative pilot
control speed and calculates and activates a DAC offset
that minimises the following error during position
control.
5 Offset filter limit FLOA s Time constant of the integrator
T
>0
6 Offset limit FLOA High limit of the active range of the offset adjustment in
T
relative components of the output quantity
>0
7 Acceleration pre-control FLOAT s Output speed part = Ka • Target acceleration.
Proportional factor Ka >=0

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 118

PID controller
“PID” tab for position PID
controllers

No. 'DWD 8QLW 'HVFULSWLRQ


W\SH
1 Position control: FLOA [mm/s]/mm Proportional gain of the P component. Output speed = Kv •
proportional factor T following error.
>= 0
Kv
2 Position control: FLOA s Reset time of the I component (integration time)
T
reset time Tn
>=0
3 Position control: FLOA s Derivative action time of the real D component (D-T1
derivative action T element).
>=0
time Tv
4 Position control: FLOA s Damping time of the real D component (D-T1 element).
T
damping time Td
>=0
5 Operating mode: BOOL De/activation of automatic offset comparison. The automatic offset
Automatic offset comparison is active only in the
comparison [-Offsetlimit,+Offsetlimit] range of the relative pre-control speed and
calculates and activates a DAC-Offset, which minimises the drag
distance as part of the position control
6 Offset filter time FLOAT s Time constant of the integrator.
>0
7 Offset limit FLOAT Upper limit of the active range of offset comparison in relative
>0 proportions of the output size.
8 Position control: FLOAT s Output speed part = Ka • Target acceleration.
>= 0
Acceleration pre-control
Ka

Controller for special axes


Fast/creep control
Card index tab “Global“ for
fast/creep control

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 119

No Data Unit Description


type
1 CONTROLLER Mode ENUM Standard value only

2 Weighting of pre- FLOAT Relative weighting of pre-control.


control: [0,0..1.0]
Default value 1.0 equal to 100 % weighting of pre-control.

3 Operating mode: BOOL De/activation of monitoring the position drag condition with the value
specified by the parameter “maximum position drag distance”.
Position drag distance
monitoring
4 Maximum position drag FLOAT Mm Maximum permissible position drag distance.
distance >= 0

5 Maximum drag filter FLOAT S If the position drag distance exceeds the maximum permissible position
time >=0 drag distance by more than the maximum drag filter time, with active
monitoring, the axis is stopped instantaneously at voltage output 0 V and
Position set in the logical “error” condition.

Step motor control


Card index tab “Global“ for
stage motor control

No Data Unit Description


type
1 CONTROLLER Mode ENUM Standard value only

2 Weighting of pre- FLOAT Relative weighting of pre-control.


control: [0,0..1.0]
Default value 1.0 equal to 100 % weighting of pre-control.

3 Operating mode: BOOL De/activation of monitoring the position drag condition with the value
specified by the parameter “maximum position drag distance”.
Position drag distance
monitoring
4 Maximum position drag FLOAT Mm Maximum permissible position drag distance.
distance >= 0

5 Maximum drag filter FLOAT S If the position drag distance exceeds the maximum permissible
time >=0 position drag distance by more than the maximum drag filter time,
with active monitoring, the axis is stopped instantaneously at voltage
Position output 0 V and set in the logical “error” condition.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 120

SERCOS Controller
Card index tab “Global“ for
SERCOS controllers

No Data Unit Description


type
1 CONTROLLER Mode ENUM STANDARD value only

2 Weighting of pre-control FLOAT Relative weighting of pre-control.


[0,0..1.0]
Default value 1.0 equal to 100 % weighting of pre-control.
3 Operating mode: BOOL De/activation of monitoring the position drag condition with the value
specified by the parameter “maximum position drag distance”.
Position drag distance
monitoring
4 Maximum position drag FLOAT Mm Maximum permissible position drag distance.
distance >= 0

5 Maximum drag filter FLOAT S If the position drag distance exceeds the maximum permissible
time >=0 position drag distance by more than the maximum drag filter time,
with active monitoring, the axis is stopped instantaneously at voltage
Position output 0 V and set in the logical “error” condition.

Dead time compensation


Every controller has an optional compensation of dead time between target
value output and the effect of this output. The target position in respect of
the target speed is delayed by an adjustable time. The dead time
compensation is part of the target value generator of an axis .

5.15. NC input/output
Input/output for NC channels
Standard channels, i.e. for PTP axes, do not require any input/output
connections. These are only needed for interpreter channels.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 121

For each channel, a variable of the PLCTONC_CHANNEL type must be


created in the PLC. This/these variable(s) must be linked with the NC
channel variables Channelx_FromPlc (located on the Channel inputs)
For each channel, a variable of the NCTOPLC_CHANNEL type must be
created in the PLC. This/these variable(s) must be linked with
Channelx_ToPlc NC channel variables (located under Channel outputs.
These variable are needed to enable an exchange of signals between the
NC and the PLC. The following data is exchanged here:
• NC block suppression
• Interpreter operating mode
• Interpreter status and error codes
• Channel overrides
• Program numbers
• M functions as floating signal bits and as handshake.
Normally, it is necessary to link the single variables.

Input/output for axes


One variable of the NCAXLESTRUCT_FROMPLC type must be created for
each axis in the PLC. This/these variable(s) must be linked with the
Axisx_FromPlc NC axis variables (located under Axis inputs).
For each axis, a variable of the NCAXLESTRUCT_TOPLC type must be
created in the PLC. This/these variable(s) must be linked with the
Axisx_ToPlc NC axis variables (located under Axis outputs.
These variables are needed to enable an exchange of signals between the
NC and the PLC. The following data is exchanged here:
• Controller and direction-oriented feed enabling signals.
• Calibrated cam
• Calibration status
• Positioning mode
• Error codes and various items of axis status information
• Axis overrides
• Coupling status
Normally, it is not necessary to link the individual variables.

EhZ_42EDjdeV^>R_RXVc f"&
INDUSTRIE ELEKTRONIK Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Fax 05246/963-149


Page 122

Input/output for encoders


Every encoder that is not of the „Simulation“ type must be linked to an
actual value acquisition module. In doing so, attention must be paid to
ensuring that the types used are compatible with one another, i.e. a
suitable type must be selected for the encoder. In the example shown on
the left, an incremental encoder is linked to one of the four counters in a
box of the M3120-4 type.
A series of subvariables is available in the encoder or in the mapping of the
data acquisition module. These normally do not need to be linked.

Input/output for drives


Every drive that does not belong to a simulated axis must be linked with a
setpoint output module. IN doing so, attention must be paid to ensuring that
the types used are compatible with one another, i.e. a suitable type must
be selected for the drive. In the example shown on the left, a drive is linked
with one of the four DACs in a box of the M2400 type.
A series of subvariables is available in the drive or in the mapping of the
output module. These normally do not need to be linked. The KL5051
BISSI terminal, however, is an exception. In this case, one byte variable of
the PLC must be linked to the terminal’s ParaCtrl output variable. The
signals for the direction-oriented hardware enabling signals and activation
of the power section must be set in this byte.

EhZ_42EDjdeV^>R_RXVc f"&
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 123

6. Glossary
CANopen
Field bus conforming to the CAN in Automation (Cia) specification.

TwinCAT
Total Windows Integrated Control and Automation Technology

EhZ_42EDjdeV^>R_RXVc
,1'8675,((/(.7521,. Eiserstraße 5 / D-33415 Verl / Telefon 05246/963-0 / Telefax 05246/963-149


Page 125

EhZ_42EDjdeV^>R_RXVc

Potrebbero piacerti anche