Sunteți pe pagina 1din 68

Axes and Drives in SIMOTION

SIMOTION
Siemens AG 2012. All rights reserved.

Date:
File:

09.02.2012
MC-SMO-SYS_05.1

Content

SITRAIN Training for


Automation and Drive Technology

Page

Connecting Electrical Drives ...............................................................................................................


Symbolic Assignment Between Control and Drive .............................................................................
Automatic or Manual Message Frame Selection ................................................................................
Structure of Standard Message Frames (1) .......................................................................................
Structure of Standard Message Frames (2) .......................................................................................
Overview: Drive Coupling ...................................................................................................................
Technology Objects (TO) in SIMOTION ............................................................................................
The "Axis" Technology Object ...........................................................................................................
Creating and Configuring an Axis ......................................................................................................
The Basic Configuration of an Axis ....................................................................................................
Selectively Removing Drive Enable Signals
...................................................................................
Calling the Expert List .........................................................................................................................
Specifying Mechanical Data ...............................................................................................................
Parameterizing Default Settings .........................................................................................................
Specifying Limit Switches and Maximum Velocities ..........................................................................
Specifying the Maximum Acceleration and Jerk ................................................................................
Filtering the Actual Value for Master Value Coupling .........................................................................
Position Control in SIMOTION ...........................................................................................................
Position Controller Optimization without Precontrol ...........................................................................
Position Control with Precontrol ........................................................................................................
Selecting a Suitable Balancing Filter Type .........................................................................................
Optimizing the Balancing Time Constant (vTc) .................................................................................
Position Control with DSC the PROFIdrive DSC Structure ............................................................
Position Controller Optimization with Precontrol and DSC ................................................................
SITRAIN Training for

Automation and drive technology

Page 1

4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27

MC-SMO-SYS
Axes and Drives in SIMOTION

Axes and Drives in SIMOTION

SIMOTION
Siemens AG 2012. All rights reserved.

Date:
File:

09.02.2012
MC-SMO-SYS_05.2

Content

SITRAIN Training for


Automation and Drive Technology

Page

Dynamic Adaptation for Synchronous Axes ......................................................................................


Checking the Dynamic Adaptation Using the Circularity Test ............................................................
Positioning and Standstill Monitoring .................................................................................................
Open-Loop Speed Controlled Motion - Standstill Signal ....................................................................
Following Error and Velocity Error Monitoring ...................................................................................
Signal Flow Representation of the Closed-Loop Axis Control ...........................................................
Programming Traversing Motion .......................................................................................................
Enabling and Disabling Axes .............................................................................................................
Processing Motion Commands ..........................................................................................................
Transitional Behavior of Motion Commands .....................................................................................
Program Advance for Motion Commands ..........................................................................................
Synchronous and Asynchronous Program Execution ........................................................................
Dynamic Settings for the Positioning Command ...............................................................................
Start axis, Closed-Loop Position or Speed Controlled ......................................................................
Stop Axis ...........................................................................................................................................
Continue Motion .................................................................................................................................
Homing Axes with Incremental Measuring Systems ........................................................................
Active Homing with/without Zero Mark . . . ........................................................................................
Passive Homing with/without Zero Mark . . . .....................................................................................
Adjusting an Absolute Encoder .........................................................................................................
Setting the Reference System ..........................................................................................................
Diagnostics of Axes or Drives - Service Overview
.........................................................................
Diagnostics of a TO - Querying the System Variables ......................................................................
Significance of the Service Display ...................................................................................................
SITRAIN Training for

Automation and drive technology

Page 2

28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51

MC-SMO-SYS
Axes and Drives in SIMOTION

Axes and Drives in SIMOTION

SIMOTION
Siemens AG 2012. All rights reserved.

Date:
File:

09.02.2012
MC-SMO-SYS_05.3

Content

SITRAIN Training for


Automation and Drive Technology

Page

Technological Alarms .......................................................................................................................


Configuring Technological Alarms .....................................................................................................
Acknowledging Technological Alarms ...............................................................................................
Using the Technology Object Trace (1) ............................................................................................
Using the Technology Object Trace (2) ............................................................................................
If You Want to Know Even More ........................................................................................................
Using Axis Data Sets ........................................................................................................................
2. Adding an Encoder to an Axis .......................................................................................................
Basic Configuration - Encoder Type and Mode .................................................................................
Mode of Operation of an Incremental, Optical Sin/Cos Encoder ......................................................
Settings for Incremental Encoders - "Cyclic Actual Value" ................................................................
Mode of Operation of an Absolute Encoder ......................................................................................
Settings for Absolute Encoders - "Absolute Actual Value" ................................................................
Settings for Absolute Encoders - Encoder Type ...............................................................................
Settings for Travel to Fixed Endstop .................................................................................................
Travel to Fixed Endstop - "Determining the Reference Torque" ......................................................
Travel to Fixed Endstop - "Settings in the Command" ......................................................................

SITRAIN Training for

Automation and drive technology

Page 3

52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68

MC-SMO-SYS
Axes and Drives in SIMOTION

Connecting Electrical Drives


For example

....via PROFIBUS-DP

MASTERDRIVES
MC
... via PROFINET

SINAMICS
S120

... via analog or stepping


motor interface
SIMODRIVE
611U

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.4

SITRAIN Training for


Automation and Drive Technology

Interface to the
drive

The functional interface to the drive is the speed setpoint interface.


Digital as well as analog, electric drives can be directly connected to a
SIMOTION C2xx. For SIMOTION P350 and SIMOTION D4x5, digital drives can
be directly connected via PROFIBUS or PROFINET and analog drives via
ADI4 or IM174.

Drives on
PROFIBUS/
PROFINET

With connection via PROFIBUS or PROFINET all data between the drive
system and SIMOTION are exchanged via this medium. Standard message
frames are used to enter the setpoint for digital drives connected to PROFIBUS
as well as the feedback data from the encoder.
It goes without saying that the drive must also support the selected message
frame type. The type of selected message frame defines the maximum
supported functionality of an axis. It goes without saying that in SIMOTION, the
axis can only execute the functions, which the connected drive also supports.
Axes that are operated in the positioning mode must be connected via the
isochronous PROFIBUS or via PROFINET IRT to ensure correct functioning. It
is sufficient for simple speed-controlled applications to be connected to a "not
isochronous" PROFIBUS DP or a PROFINET RT. In this way you can connect
all standard DP slaves that do not support isochronous operation.

Analog drives/
stepping motors

analog drives can be directly connected at C2xx or via PROFIBUS at the ADI4
or IM174. In this case the speed controllers are supplied with +/- 10 V via the
analog outputs.
The position actual values can either be taken from the encoder connected to
SIMOTION C or ADI4, or from the pulse encoder emulation of the converter.
The corresponding digital I/Os are available for feedback signals and controller
enable signals.
From V3.2 and higher, stepping motors can also be directly connected to the
C2xx.

SITRAIN Training for

Automation and drive technology

Page 4

MC-SMO-SYS
Axes and Drives in SIMOTION

Symbolic Assignment Between Control and Drive


Advantages

Communication between an axis and drive is


automatically set up (PROFIdrive axis message
frames as well as addresses)

Message frame extensions and interconnections


in the drive are dependent on the selected TO
technology (e.g. SINAMICS Safety Integrated)

Axes and drives can be independently


configured from one another

Communication connections are automatically


established when configuring I/O on
SINAMICS I/Os

The assignment is kept even for address


offsets

Activating/deactivating via the menu command:


Project -> using a symbolic assignment

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.5

Interconnection control

SITRAIN Training for


Automation and Drive Technology

New in V4.2

The most significant innovation in the SIMOTION SCOUT engineering system is


the significantly simplified connection to the SINAMICS drive system. With this
step, users are supported as a result of the essentially automated integration of
drives and their associated elements in SIMOTION SCOUT.
Up until now, to connect drives according to PROFIdrive, users had to configure
the appropriate communication, both on the drive side as well as on the control
side. As result of the new symbolic assignment of technology objects (TOs) and
I/Os to drive objects (Drive Objects/DOs), users no longer have to involve
themselves in the PROFIdrive communication with message frames and
addresses. The engineering system now takes care of all this.
For "Save and compile changes" or at the latest before a download, message
frames and addresses are automatically generated. Users only have to
download the project data into the target system.

New control

The symbolic assignment is now realized using a new interconnection control.


It is supported by technology objects axis, external encoder, cams, cam track
and measuring input. Further, the onboard I/Os of the devices SIMOTION D,
CX32/CX32-2, Control Units for SINAMICS S120 as well as the Terminal
Modules and TB30 can now be symbolically assigned.
In this dialog, all pass-capable partners are hierarchically listed; connections are
realized symbolically by simply selecting the components to be interconnected.
SINAMICS drives and/or devices and terminal modules with their available I/Os
can be selected in the control. In this case, only the pass-capable elements are
listed with symbolic identifiers; whereby even the terminal designations of the
modules are listed.

Note

If a project is upgraded to SIMOTION device firmware version V4.2 SP1, then


the symbolic assignment can be subsequently selected. The assignments are
automatically determined from the logical addresses. Individual TOs and DOs
can be excluded from the symbolic assignment (refer to the next page)

SITRAIN Training for

Automation and drive technology

Page 5

MC-SMO-SYS
Axes and Drives in SIMOTION

Automatic or Manual Message Frame Selection

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.6

SITRAIN Training for


Automation and Drive Technology

PROFIBUS/
PROFINET
coupling

With the coupling via PROFIBUS/PROFINET, all information between the drive
system and SIMOTION is exchanged using standard message frames
according to the PROFIDRIVE profile V4.0. The structure and type of the
information being exchanged uniquely defines the number of the message
frame.

Message frame
selection

In the "Settings for ....." dialog, you can switch over to automatic or user-defined
PROFIdrive message frame setting and/or automatic message frame extension
for the selected drive object.
Automatic PROFIdrive message frame setting: This setting (standard) is
selected if the drive unit is to participate in the "Symbolic assignment" with
SIMOTION. A PROFIdrive message frame (including message frame extension)
is automatically determined with "Save and compile".
You must configure PROFIsafe message frames yourself; the configuration of
the safety data block (SIDB) however is performed automatically.
User-defined: The following options are available for the user-defined setting of
the process data transfer:
Semi-automatic message frame configuration (selection: "Automatic
message frame extension" and "Permit automatic address adaptation".
With this setting, the PROFIdrive message frame is selected, necessary
message frame extensions and address adaptations are performed by the
system when "Save and compile" is selected.
Manual message frame configuration: With this setting, you select the
PROFIdrive message frame and the message frame extension yourself, but
leave the address adaptation to the system (select. "Permit automatic
address adaptation").

SITRAIN Training for

Automation and drive technology

Page 6

MC-SMO-SYS
Axes and Drives in SIMOTION

Structure of Standard Message Frames (1)


PZD number
Setpoint

1
CW 1

2
NSET_A

PSD number
Setpoint

1
CW 1

2
3
NSET_B

4
CW 2

PZD number
Actual value

1
STW 1

2
NACT_A

PSD number
Actual value

1
STW 1

2
3
NACT_B

4
STW 2

Standard message frame 1 (16 bit nset) Standard message frame 2 (32 bit nset, without encoder)
PSD number
Setpoint

1
CW 1

2
3
NSET_B

4
CW 2

5
Enc1_CW

PSD number
Actual value

1
STW 1

2
3
NACT_B

4
STW 2

5
Enc1_STW

6
7
Enc1_XACT 1

8
9
Enc1_XACT 2

Standard message frame 3 (32 bit nset, with encoder)


PSD number
Setpoint

1
CW 1

2
3
NSET_B

4
CW 2

5
Enc1_CW

6
Enc2_CW

PSD number
Actual value

1
STW 1

2
3
NACT_B

4
STW 2

5
Enc1_STW

6
7
Enc1_XACT 1

8
9
. . .
Enc1_XACT 2

10
Enc2_STW

11
12
Enc2_XACT 1

13
14
Enc2_XACT 2

. . .

Standard message frame 4 (32 bit nset, with 2 encoders)

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.7

SITRAIN Training for


Automation and Drive Technology

Standard
message frame 1

Is designed for simple speed-controlled applications. The message frame


has a control and a status word via which the basic functionality regarding
activation, deactivation, pulse and controller enable is handled. A 16-bit data
word is used for transferring the speed setpoint. The actual speed value is also
transferred back from the drive in 16 bits.
In SIMOTION, this message frame can only be used for the "speed axis"
function.

Standard
message frame 2

Is designed for more complex speed-controlled applications. In addition to


the control and status word, the speed setpoint is transferred using a 32-bit data
word. The actual speed value is also transferred back from the drive in 32 bits.
In addition this message frame has a second control and status word which
handles the "travel to fixed endstop" functionality (clamping torque must be
configured in the drive, is not used in this form by SIMOTION for the "travel to
fixed endstop" function).
In SIMOTION, this message frame can only be used for the "speed axis"
function.

Standard
message frame3

Is designed for positioning applications. It also has an encoder control word,


an encoder status word and a 4-word interface to a measuring system.
SIMOTION functions, such as reference point approach and measuring input,
can be implemented via this encoder control word.
In SIMOTION, this message frame can be used for the "positioning axis"
function.

SITRAIN Training for

Automation and drive technology

Page 7

MC-SMO-SYS
Axes and Drives in SIMOTION

Structure of Standard Message Frames (2)


PSD number
Setpoint

1
CW 1

2
3
NSET_B

4
CW 2

5
Enc1_CW

PSD number
Actual value

1
STW 1

2
3
NACT_B

4
STW 2

5
Enc1_STW

XERR

KPC

6
7
Enc1_XACT 1

8
9
Enc1_XACT 2

Standard message frame 5 (32 bit nset, with 1 encoder + DSC)


PSD number
Setpoint

1
CW 1

2
3
NSET_B

4
CW 2

5
E1_CW

PSD number
Actual value

1
STW 1

2
3
NACT_B

4
STW 2

5
E1_STW

6
7
E1_XACT 1

8
9
E1_XACT 2

. . .

10
E2_STW

11
12
E2_XACT 1

13
14
E2_XACT 2

Standard message frame 6 (32 bit nset,


with 2 encoders + DSC)

6
E2_CW

PSD number
Setpoint

1
CW 1

2
3
NSET_B

4
CW 2

5
MOMRW

6
E1_CW

PSD number
Actual value

1
STW 1

2
3
NACT_B

4
STW 2

5
MSGW

6
E1_STW

XERR

10
KPC

. . .

10

XERR

KPC

7
8
E1_XACT 1

9
10
E1_XACT 2

SIEMENS message frame 105 (32 bit nset, with 1 encoder + DSC + torque reduction)

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.8

SITRAIN Training for


Automation and Drive Technology

Standard
message frame 4

This message frame is designed for connecting a second encoder. It is used in


SIMOTION for coupling positioning axes with a 2nd measuring system.

Standard
message frame 5

Is intended, just like standard message frame 3 for positioning applications.


However, it has two additional double words in the setpoint for transferring the
following error and the servo gain (KPC gain).
In SIMOTION, this extension is required for the DSC functionality (dynamic
servo control). When this function is selected, the dynamic part of the position
controller is transferred from SIMOTION to the drive and calculated with the
sampling frequency of the speed controller. As part of this process, the following
error (XERR) and servo gain KPC are transferred from SIMOTION to the drive.
Due to the higher sampling frequency in the drive, the position control can now
be operated with a higher servo gain.

Standard
message frame 6

Like standard message frame 4 with DSC, or standard message frame 5 with a
2nd encoder. This is used in SIMOTION for coupling positioning axes with a 2nd
measuring system.

SIEMENS
message frame
102 . . . 106

SIEMENS message frames 102 to 106 are created from the associated
standard message frames 2 to 6 by inserting an additional word in the setpoint
(after control word STW2) or a word in the actual value (after status word
ZSW2).
This extension is required for the dynamic torque reduction at the drive. The
torque limit is specified in the setpoint; in the actual value the drive among
others returns whether the torque limit (current limit) was reached or not.
This extension is used in SIMOTION to implement the functions "Travel with
torque limit" and "Travel to fixed endstop".

SITRAIN Training for

Automation and drive technology

Page 8

MC-SMO-SYS
Axes and Drives in SIMOTION

Overview: Drive Coupling


ADI4

SINAMICS

Analog
drives

S120

PROFIBUS
interface

MASTERDRIVE

MICROMASTER/
SINAMICS G120

MC

MM410/420/440

Posmo
S/CA/CD

611U

DP standard
slave

Isochronous on PROFIBUS DP(DRIVE)

DP cycle clock

1ms, 0.5 ms granular

TO connection

3 ms

Speed-controlled
axis, positioning, synchronism, cam

Preferred
message frame

Drive
configuration

SIMODRIVE

1ms, 0.5 ms
granular
Speed-controlled
axis

105

105

Proprietary

Starter

SimoComU

Drive monitor

Starter

Drive ES

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Drives on
PROFIBUS MC

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.9

SITRAIN Training for


Automation and Drive Technology

The following applies to drives connected to PROFIBUS DP: On an isochronous


PROFIBUS MC, only drives can be operated in the isochronous mode that also
comply with PROFIDRIVE-profile V4.0.
All other drives (standard slaves) can be connected to the isochronous
PROFIBUS MC - but not operated in the isochronous mode.
The following drives are integrated in the STEP 7 project via the hardware
configuration:
SINAMICS S120
SIMODRIVE 611U
SIMODRIVE POSMO CA
SIMODRIVE POSMO CD
SIMODRIVE POSMO SI
ADI4
MASTERDRIVE MC
MASTERDRIVE VC
MICROMASTER 420/430/440
COMBIMASTER 411
MICROMASTER 420/430/440 and SINAMICS S120 can be configured,
assigned parameters and commissioned directly with SIMOTION SCOUT.

Automation and drive technology

Page 9

MC-SMO-SYS
Axes and Drives in SIMOTION

Technology Objects (TO) in SIMOTION


Configuration
data
Cam
System
variable

Configuration
data

Alarms

System
functions

System
functions

System
variable

SynSystem
chronous funcoperation tions

Configuration
data

Alarms

Encoder System
funcSystem
tions
variable
Alarms

Output
cam
System
variable

Date:
File:

Siemens AG 2012. All rights reserved.

Technology objects

SITRAIN Training for

Axis
System
functions
Alarms

Configuration
data

Alarms

SIMOTION

Configuration
data

System
variable

Measuring
input
System
variable

Configuration
data

System
functions

Alarms

09.02.2012
MC-SMO-SYS_05.10

SITRAIN Training for


Automation and Drive Technology

The technology objects in SIMOTION are provided in the form of technology


packages that can be loaded. Each of these technology packages provides
complete functionality for the technology in question. For instance, the "Position"
technology package includes all of the functions, which are required to traverse
and position axes.
In SIMOTION, for each "physical" automation object, for example, an axis, an
external encoder, a measuring input etc., an appropriate technology object (TO)
is created (instantiated). Each TO in SIMOTION encompasses:
Configuration data: Using configuration data, the created objects are adapted
to the requirements of the specific task or application.
System data: In the system data, a TO provides information about its present
state. The system data of an axis TO will therefore display information such
as position setpoint, actual position value, following error etc.
Using system variables, standard values and settings can also be read or
entered.
System functions: Using system functions, the user program accesses the
functionality to control the associated "physical" object. For example, for an
axis TO, there are powerful system functions available for positioning,
reference point approach, stopping etc. of an axis.
For example, the motion sequences of an axis are specified using motion
commands issued to that axis. The user program can be used to query the
motion status at any time and to control specific aspects of the motion.
Motions can be aborted, overridden, appended, or superimposed.
Alarms:If an event (error, note) occurs on a technology object, the TO issues
a technological alarm.
The TO alarms cause subsequent responses in the system. For each alarm,
certain effects are set as default. However, these settings can be adapted to
the specific requirements.

Automation and drive technology

Page 10

MC-SMO-SYS
Axes and Drives in SIMOTION

The "Axis" Technology Object

4 versions

Motion with speed setpoint


Specification of a velocity
profile (time-controlled)
Traversing with torque limiting

Synchronous
axis
Positioning
axis

Path
interpolation
axis

Synchronous axis

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

SITRAIN Training for

Positioning axis
Positioning via
Positioning command or via profile
input (velocity, position)
Traversing to a fixed endstop

Speedcontrolled
axis

Axis TO

Speed-controlled axis

Following axis in gearing or


camming operation

Path axis

Linear, circular and polynomial


interpolation in 2D and/or 3D

support of various kinematics

09.02.2012
MC-SMO-SYS_05.11

SITRAIN Training for


Automation and Drive Technology

The axis motion control functionality is implemented in SIMOTION using the


technology object (TO) axis. When creating an axis with SIMOTION SCOUT, a
distinction is made between the following axis technologies:
Speed-controlled axis: Motion control is performed using a speed setpoint
without position control. The actual speed is monitored if an encoder is
configured for the axis.
Positioning axis: Motion control for position-controlled axes. The position
as well as the dynamics of the axis are specified. The operation is realized in
the closed-loop position controlled mode. The functionality of the speedcontrolled axis is included in the positioning axis.
The positioning axis in SIMOTION has a position controller. With electrical
axes, the speed controller is implemented in the drive.
Synchronous axis: The functionality is identical with that of a positioning axis.
In addition, additional functions are available for the master value coupling in
the form of gearing and camming
Path axis: From Version V4.1, SIMOTION provides path interpolation
functionality. This functionality encompasses that of the positioning axis.
Additionally up to 3 path axes can be traversed along paths. In addition,
a position axis can be traversed synchronously with the path. Paths can be
combined from segments with linear, circular, and polynomial interpolation in
2D and 3D.
Further, using this technology, the following kinematics are supported:
- Cartesian linear aches
- SCARA
- Roller picker
- Delta 2D /3 D picker
- Articulated arm
The "Axis" technology object can be used for axes with electric drives, with
stepping motors, hydraulic actuators/valve (hydraulic axis) and on virtual axes.

Automation and drive technology

Page 11

MC-SMO-SYS
Axes and Drives in SIMOTION

Creating and Configuring an Axis

Using
parameter
screens

Using
expert list

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Configuration
of TOs

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.12

SITRAIN Training for


Automation and Drive Technology

You will need to work through several steps before you can use technology
objects. In the first step, the configuration creates an instance of the TO. A TO is
configured using the SCOUT engineering system. You are supported by the
corresponding Wizards (parameterizing screen forms) to create an object and
configure it.
Inserting an axis instance is implemented in the Project Navigator in the
directory Axes, by double-clicking on the entry "Insert axis". The axis wizard
then automatically starts and helps the user create and configure an axis.
Certain object-specific properties are determined in the first configuration (e.g.
speed-controlled axis, positioning axis, synchronized axis). This definition also
determines the "size", i.e. the number of configuration and system variables of
the technology object.
It is therefore not possible to subsequently change properties such as speedcontrolled axis, positioning axis, etc. If a speed-controlled axis TO is to be
converted into a positioning TO, it is necessary to delete the original speedcontrolled TO and insert a new positioning axis TO.
Configuration data generally determines the static properties of a TO. Certain
properties determined by the configuration can also be changed during the
runtime.

Automation and drive technology

Page 12

MC-SMO-SYS
Axes and Drives in SIMOTION

The Basic Configuration of an Axis


Configuration

Name and technology


of the axis

Associated drive

Associated encoder

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Basic configuration

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.13

SITRAIN Training for


Automation and Drive Technology

The basic properties of the axis are defined in the basic configuration of an axis.
The following settings can be adapted in this basic configuration.
Technology/processing cycle: The execution level for axis interpolation is
defined in this selection box. The following can be selected:
IPO for dynamic axes
IPO2 for auxiliary axes which have low dynamic requirements
Servo for axes demanding a high dynamic performance
From V4.2 and higher, for axes connected to PROFINET (these are generally
hydraulic axes) the following level is also available:
fast IPO
fast servo
Axis type: Under this dialog, axis type changes can be made (linear or rotary
and electrical, hydraulic or virtual).
In addition, control options can be adapted, for example, standard or standard
+ pressure/force.
Drive assignment: Under drive assignment, the connection to the associated
drive object can be changed.
Function: This part involves settings to an additional technology data block in the
message frame between the TO axis and drive object A technology data block is
required for the "Winder" technology.
Further, settings can be made to withdraw enable signals for critical TO alarms
(refer to the next page).
Further, settings can be made for extended safety functions that are integrated
in the drive.

Automation and drive technology

Page 13

MC-SMO-SYS
Axes and Drives in SIMOTION

Selectively Removing Drive Enable Signals

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.14

SITRAIN Training for


Automation and Drive Technology

Settings to the
drive

Here, there is the option, for technology alarms with local alarm response
RELEASE_DISABLE (withdraw enable), to specifically withdraw the enable
signals in STW1 of the corresponding standard message frame.
This means, for example, when implementing a brake control in the drive, for
_disableAxis() as well as for RELEASE_DISABLE as a result of a fault
response, e.g. initially to withdraw OFF3 (STW1.Bit2), and then when the drive
is stationary and the brake is closed, the power is disconnected (OFF2)
(STW1.Bit1).
Also when using the extended Safety Integrated function, an adaptation is
absolutely necessary at the drive. For an integrated stop response of the drive,
withdrawing the AUS2 bit must be prevented, as otherwise the drive will coast
down in an uncontrolled fashion.

Stop modes for


PROFIdrive

For a digital drive coupling, the Drive Technology profile provides the following
stop modes:
STW1 bit 0 = 0 (OFF1): Stop with ramp.
The drive travels with a speed ramp with adjustable deceleration to zero
velocity. The stopping process can be interrupted and the drive switched on
again. After stopping, the pulses are suppressed and the status changes to
ready to start.
STW1 bit 1 = 0 (OFF2): Coast down
The drive immediately goes to pulse suppression and the status changes to
switch-on inhibit.
STW1 bit 2 = 0: Quick stop
The drive travels to zero velocity at the torque limit. The stopping process
cannot be interrupted. After stopping, the pulses are suppressed and the
status changes to switch-on inhibit.

SITRAIN Training for

Automation and drive technology

Page 14

MC-SMO-SYS
Axes and Drives in SIMOTION

Calling the Expert List

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.15

SITRAIN Training for


Automation and Drive Technology

General

After the configuration the next step is to set the parameters for the technology
object. Parameterization involves defining numerous functions in detail.
Like the configuration, parameterization is carried out using the SCOUT
engineering system. Below the object in the project navigator window, there are
the appropriate entries, via which the individual screen forms can be called for
parameterization (making the appropriate parameter settings).
The result of the parameter assignment is stored in configuration data and
system variables for the object and included in the download to the target
system.

Expert List

In addition to access to the configuration data and system variables via the
wizards and parameter screen forms, you can also access the data directly via
an expert list. The expert list for an object can be called via the entry "Expert list"
of the axis TO.
Within the "Expert list", lists for the following parameters can be selected using
the tab symbol:
Configuration data: Configuration data are used to parameterize the
properties of a machine. As a consequence, mechanical properties, for
example, gearbox ratios, hardware limit switches, maximum dynamic values,
closed-loop control parameters, etc. are defined.
System variables: System variables are generally used to display status
information about the selected TO. For axes, this involves positions,
velocities etc. From the user perspective, such data can only be read. Using
system variables that can be written to, a basic parameterizing interface to
the TO is also implemented. These include, for example, velocity override,
preassigned values (default values) of velocity, acceleration etc. for
traversing commands
User-defined lists: From V4.0 and higher, there are user-defined expert lists
and the option of calling default lists with the most important configuration
data and system variables.

SITRAIN Training for

Automation and drive technology

Page 15

MC-SMO-SYS
Axes and Drives in SIMOTION

Specifying Mechanical Data

Load gear:
transmission ratio

Measuring gear:
transmission ratio

Automatically adapted; if
TypeOfAxis.DriveControlConfig.dataAdaption = YES
TypeOfAxis.NumberOfEncoders.Encoder_1.dataAdaption = YES
TypeOfAxis.NumberOfEncoders.Encoder_1.encoderMode = PROFIDRIVE

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.16

SITRAIN Training for


Automation and Drive Technology

General

After the configuration the next step is to set the parameters for the technology
object. Parameterization involves defining numerous functions in detail.
Like the configuration, parameterization is carried out using the SCOUT
engineering system. Below the object in the project navigator window, is a row
of tabs for displaying the individual screens for parameter settings.
The result of the parameter assignment is stored in configuration data and
system variables for the object and included in the download to the target
system.

Mechanical
Properties

When controlling a drive by means of the "Axis" technology object, SIMOTION


uses only the speed setpoint interface and not the positioning interface. The
drive therefore has no information about traversing paths, etc. All mechanical
data regarding lengths, leadscrew pitch, etc., must be defined in SIMOTION.

Automatic
adaptation

Using automatic adaptation, from V4.2 SP1, the relevant drive data (drive and
encoder data, as well as reference variables, maximum variables, torque limits,
and the selectivity associated with torque reduction of the SINAMICS S120 from
v2.6.2) are transferred into the TO configuration when the CPU boots and do not
have to be manually set.
For a "Copy current data to RAM" or "Copy RAM to ROM", in a dialog, it is
possible to load the adapted values to the PG and therefore into the offline
project.
If required, the adaptation can be activated in the expert list using the following
Config data:
TypeOfAxis.DriveControlConfig.dataAdaption = YES
TypeOfAxis.NumberOfEncoders.Encoder_1.dataAdaption = YES
TypeOfAxis.NumberOfEncoders.Encoder_1.encoderMode = PROFIDRIVE

SITRAIN Training for

Automation and drive technology

Page 16

MC-SMO-SYS
Axes and Drives in SIMOTION

Parameterizing Default Settings

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.17

SITRAIN Training for


Automation and Drive Technology

Default value for


Dynamic response

The system always uses the default values if, when calling the system functions,
USER_DEFAULT is specified.
This means that the dynamic values for each axis can be defined centrally just
once and do not have to be re-entered whenever the system function is called.
The following dynamic variables of an axis can be assigned as default values in
this dialog
Velocity
Acceleration
Deceleration
Jerk
Velocity profile
Stopping time

Stopping Time

The time specified under Stopping time applies if a moving axis is stopped via
"Emergency stop in pre-defined time", for example.

Velocity
profile

The velocity profile defines the axis response during approach, braking, and
velocity changes.
You can choose between the following profiles:
Trapezoidal: The trapezoidal profile is used for linear acceleration in a
positive and negative direction of travel.
Smooth: The profile displays a smooth acceleration character and the jerk
characteristic is controllable.

Presetting the
dynamic response

Depending on the settings for maximum dynamic response, dynamic response


values can be preset as default values in the system. You specify the settings
regarding maximum dynamic response using "Maximum velocity" and "Rampup/acceleration time up to maximum velocity".

SITRAIN Training for

Automation and drive technology

Page 17

MC-SMO-SYS
Axes and Drives in SIMOTION

Specifying Limit Switches and Maximum Velocities


Assign

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.18

SITRAIN Training for


Automation and Drive Technology

Hardware
limit switches

Traversing range limits are monitored by means of digital inputs and limit
switches. Hardware limit switches are always NC contacts and should always
be active outside the permissible travel range. When a limit switch is
approached, a technology alarm is triggered.
The logical address of the input which the hardware limit switch for negative/
positive direction of travel is connected to is entered in "Hardware limit switch".
The address must be outside the process image (>= 64). With the bit number,
the input is specified to which the hardware limit switch for negative/positive
direction of travel is connected.
From V4.2 and higher, the inputs for the hardware limit switches can also be
easily connected with the inputs of the CU of SINAMICS_Integrated. By clicking
on the "" button, the assignment dialog is opened, in which the interconnection
with the CU inputs can be made.
"Save and compile" is used to create the necessary message frames between
the CU and SIMOTION.

Software
limit switches

Software limit switches can be specified and activated. They are activated via
system variables (Swlimit.State). You can also specify in the "Homing" tab in the
configuration data: Homing.referencingNecessary whether the software limit
switch is always active, or only after referencing/homing:
Homing.referencingNecessary = NO software limit switch always active
Homing.referencingNecessary = YES switch active after referencing/homing

Maximum
velocities

In SIMOTION there are two velocity limits. SIMOTION automatically reduces to


the minimum of the two values
Maximum velocity (configuration data): Defines the maximum axis velocity as a
result of the mechanical system and the drive.
Maximum programmed velocity (system variable): Permits a product-dependent
reduction of the maximum velocity.

SITRAIN Training for

Automation and drive technology

Page 18

MC-SMO-SYS
Axes and Drives in SIMOTION

Specifying the Maximum Acceleration and Jerk

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.19

SITRAIN Training for


Automation and Drive Technology

Acceleration,
jerk

SIMOTION makes a distinction for acceleration and jerk between hardware


limits in configuration data and software limits in system variables, which, for
example depending on the product, can be easily overwritten from the user
program.
For programmed motion, the TO automatically reduces the acceleration and/or
the jerk to the minimum from the limits specified by the hardware and/or
software. Jerk limiting is only active for jerk-controlled motion, i.e. motion
sequences with continuous acceleration.
If the "Direction dependent dynamic response" option is activated, then different
limits for acceleration and jerk can be entered depending on the direction of
motion.

Stopping with
pre-parameterized
braking ramp

The set value is effective, if a moving axis is stopped in the "EMERGENCY OFF
mode" with the setting "Quick stop with actual value-related emergency stop
ramp".

Time constant ...

From V4.0 and higher, a time constant can be entered for smoothing the
manipulated variable changes as a result of controller switching operations.
This switchover smoothing filter is active for all status transitions/switchovers in
which an offset in the manipulated variable can occur due to the switchover.
Gearbox change operations in the data block are not smoothed

SITRAIN Training for

Automation and drive technology

Page 19

MC-SMO-SYS
Axes and Drives in SIMOTION

Filtering the Actual Value for Master Value Coupling

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.20

SITRAIN Training for


Automation and Drive Technology

Master value
coupling via
actual value

For a synchronous group within a control system, synchronous operation is


realized taking into account the master value position, the velocity and
acceleration. For distributed synchronous operation, the master value position
and master value velocity are transferred between the master value and
synchronous object. At the synchronous object, acceleration is generated
through differentiation
If an encoder actual value is used as master value, then the measured actual
value can be smoothed and extrapolated in order to compensate deadtimes.
Deadtimes, occur when acquiring the actual values through bus communication
in the system and as result of the finite processing duration within the system.

Filtering the
actual position

From V 4.1, the actual position value for the synchronous operation can be
filtered separately for the extrapolation using a PT2 filter. The filter for the
position actual value of the axes is set using the option "Filter on the actual
position value" and the two time constants "T1" and "T2".
The filter acts on the actual position for the extrapolation before the
differentiation of the position for the extrapolation velocity.

Filtering the
actual velocity

The position is extrapolated based on the filtered or averaged velocity actual


value. This filter can be activated using the option "Filter on the actual velocity
value": The time for the average value generation or the PT1 filter time is
entered under "Time constant.
The time for the extrapolation is entered under "Extrapolation time".
Extrapolation is not performed if 0.0 is entered.
The extrapolated values (position and velocity) can be monitored in the system
variable extrapolationData....
In addition, the velocity master value can be optionally generated from the
extrapolated position master value through differentiation or the extrapolated
velocity master value can be used for synchronous operation.

SITRAIN Training for

Automation and drive technology

Page 20

MC-SMO-SYS
Axes and Drives in SIMOTION

Position Control in SIMOTION

DSC operation
Servo gain factor

IPO

Feedforward control

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.21

SITRAIN Training for


Automation and Drive Technology

Interpolator

The interpolator processes the traversing commands which are issued e.g. from
the user program to an axis. In each IPO cycle it calculates the position setpoint
of the axis while including the dynamic values such as acceleration, velocity etc.
in its calculation. This position setpoint is then entered into the position controller
after fine interpolation.

Fine interpolation

If there is a different sampling ratio between interpolator and position controller,


the fine interpolator (FIPO)'s task is to generate intermediary setpoints.
For the configuration you can select in the "Fine interpolation" box between no,
linear and constant speed interpolation.

Position control

The position controller is responsible for controlling the actual position of the
axis. It is usually designed as P controller for electrical axes. The difference
between the position setpoint and position actual value is used as the control
deviation value (following error). Multiplied with the servo gain factor, the result
the velocity setpoint of the axis is output at the position controller output.
The dynamic response and therefore the rise time in the position control loop is
determined in this case by the servo gain factor (or more precisely: 1/sg = rise
time). The maximum possible servo gain depends on the dynamic properties of
the drive (e.g. rise time, etc.) and mechanical properties of the axis (moment of
inertia, backlash, etc.) as well as on the set position control cycle (sampling
theorem).

SITRAIN Training for

Automation and drive technology

Page 21

MC-SMO-SYS
Axes and Drives in SIMOTION

Position Controller Optimization without Precontrol


Unoptimized position control

Velocity setpoint:
motionstatedata.commandvelocity
Actual velocity:
motionstatedata.actualvelocity

Optimized position control

Servo gain factor

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Optimizing the
position controller

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.22

SITRAIN Training for


Automation and Drive Technology

Prerequisite for optimizing the position controller is that the current and speed
controller have already been optimized for the drive. Then the setpoint and
actual velocity of the axis can be optimized for the position controllers using
trace recording.
The axis can be moved via an MCC program or via the function generator of the
trace tool. The axis should accelerate, alternating between positive and negative
velocity. The axis acceleration should be selected so that the current limit is not
reached.
The position control can then be optimized by increasing the servo gain factor.
Good optimization of the servo gain was achieved if the actual velocity follows
the specified setpoint velocity during axis acceleration without any overshoot.
In this case the setpoint and actual velocity/actual velocity and following error of
axis can be recorded in the trace tool via the following system variables:
<Axis>.motionstatedata.commandvelocity
<Axis>.motionstatedata.actualvelocity
<Axis>.positioningstate.differencecommandtoactual
These system values are determined in the interpolation. In particular, this
means that all values which refer to the actual position/velocity are outdated
compared to the associated values of the position control.

Automation and drive technology

Page 22

MC-SMO-SYS
Axes and Drives in SIMOTION

Position Control with Precontrol


servoData.compensatedServoCommandValue

Velocity
setpoint

Interpolator

Position
setpoint

Feedforward control

* KPC
balancing
filter

SA

* KV

nset

servoData.controllerOutput
servoData.followingerror

Expert mode

servoData.preControlValue

Symmetrization
time constant

servoData.controllerDifference
servoData.symmetricServoCommandVelocity
servoData.symmetricServoCommandPosition

sensorData.sensorData[1].actual velocity
sensorData.sensorData[1].position

Act. position val.


Dead time (transfer on
PROFIBUS, rise time, ...)

Configurationdata.TypeOfAxis.NumberOfDataSets.DataSet_1.DynamicData.velocityTimeConstant
= vTc (velocityTimeConstant)

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.23

SITRAIN Training for


Automation and Drive Technology

Precontrol

The conventional position control concept (P controller) always requires a


deviation (following error = FE) between position setpoint and actual position
value. This deviation can lead to unwanted axis behavior, e.g. contour errors, poor
dynamics (performance characteristics during rise time) etc.
The task of the precontrol is to compensate these disadvantages. The precontrol
calculates the axis (setpoint) velocity directly from the position setpoints by
differentiation, multiplies it with the KPC factor, then transfers it directly to the
position controller output. In the best case, the precontrol setpoint will cause the
axis to move at the velocity calculated by the interpolator.
If the actual axis position was immediately returned to the position controller, then
the following error would be 0. The position controller would then only have to deal
with the task of correcting disturbance-induced fluctuations of the real actual axis
position with respect to the position setpoint.

Delay times

Unfortunately, data processing and transfer as well as the rise time of the drive
lead to delay times which have a considerable negative impact on the
conventional position control concept with precontrol.
There is a time lapse which cannot be neglected between supplying the position
setpoint to the following error and returning the first actual position values to the
position control. This delay time is mainly as a result of:
The dead times for transferring the setpoint/act. value (2xDPcycles + Ti + To)
Equivalent time for the speed control loop of the drive (approx. 1-5 ms).
If this time delay would not be compensated in one form or another, then the
speed setpoint output to the drive when the axis starts would be too high. This
excessive speed setpoint would result in overshoot and/or unstable performance
characteristics during drive rise time.
The increased speed setpoint is a result of the speed setpoint of the precontrol
and a component originating from the position setpoint supplied to the following
error. The actual value "missing" at the beginning of the motion will inevitably
result in an increase of the following error and therefore output of an additional
speed setpoint.

SITRAIN Training for

Automation and drive technology

Page 23

MC-SMO-SYS
Axes and Drives in SIMOTION

Selecting a Suitable Balancing Filter Type


Selection in the input field "Balancing filter"
"Extended balancing filter active"

or via expert list (configuration data):


TypeOfAxis.NumberOfDataSets.DataSet_1.ControllerStruct.
PVController.balancedFilterMode

nact
PT1- filter
Mode_1

Command value
Actual value

time

time
nact

Extended
balancing
filter

Command value

Actual value
Mode_2

SIMOTION

time
Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.24

time
SITRAIN Training for
Automation and Drive Technology

Balancing time
vTc

Delay in returning the actual position value output compared to input of the
position setpoint in the following error and resulting undesirable increase in the
output speed setpoint which can be compensated by means of delayed input of
the position setpoint to the following error.
The delay (balancing time vTc) of the input of the position setpoint to the
following error should exactly compensate for the delay in the return of the
actual position. This is the approximately the case if the balancing time vTc is
set to the same value as the calculated delay time Tequiv.

Filter mode

In the first version of SIMOTION, a pure PT1 filter was used This type has the
disadvantage, that when accelerating, the delayed setpoints at the output do not
match the characteristics of the actual values returned from the encoder.
In the initial phase of the acceleration, a PT1 filter already supplies setpoints;
however there are still no actual values from the encoder as a result of the
deadtime in the position control loop. As a consequence, there is a small
positive following error at the output, and therefore an additional and positive
value added to the speed setpoint that is output.
Vice versa, in the final acceleration phase, the actual values of the encoder
system have already been fed back into the position control, while the PT1 filter
is still delaying the setpoints that are applied. As a consequence, in the final
phase, there is a negative contribution added to the following error, and
therefore a negative contribution added to the speed setpoint that is output.
The result is generally an overshoot or undershoot of the speed setpoint that is
output, and therefore the velocity actual value that cannot be resolved through
optimization.

Expanded
balancing filter

In SIMOTION, an additional filter was integrated, which better matches the


characteristics of the actual values returned from the encoder system. Using this
filter (expanded balancing filter or Mode_2) the undesirable undershoot or
overshoot issue can, to a large extent, be avoided.

SITRAIN Training for

Automation and drive technology

Page 24

MC-SMO-SYS
Axes and Drives in SIMOTION

Optimizing the Balancing Time Constant (vTc)


motionstatedata.commandvelocity

KV = 80/s
vTc = 7.5 ms
Without DSC

sensorData.sensorData[1].actual velocity
servoData.symmetricServoCommandVelocity
motionstatedata.actualvelocity

vTc optimum

KV = 80/s
vTc = 1 ms
Without DSC
vTc too small

sensorData.sensorData[1].actual velocity
servoData.symmetricServoCommandVelocity

KV = 80/s
vTc = 25 ms
Without DSC

vTc too large

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.25

SITRAIN Training for


Automation and Drive Technology

Continuation

The filter can be activated using the following configuration data in the expert
list:
<Axis>.NumberOfDataSets.DataSet[1].ControllerStruct.PV_Controller.
balanceFilterMode = Mode_2
With "Mode_2", a dead time + PT1 filter is used, while Mode_1 uses a pure PT1
filter.

Type of fine
Interpolation

For selecting the precontrol, constant velocity fine interpolation must also be
selected. The type of fine interpolation is set in the dialog "Axis -> Fine
interpolation" in the "Fine interpolator" selection field:
"Fine interpolator = constant velocity interpolation"
If "No interpolation" or "Linear interpolation" would be selected, undesired speed
jumps would take place at the drive in the acceleration phase of the axis.

Determining the
start values for vTc

Then, the start values for the balancing filter time can be determined. These
times essentially depend on whether DSC operation has been selected or not:
without DSC operation:
vTc = 2 x DP cycle time + Ti +To + rise time of the drive
with DSC operation:
vTc = rise time of the drive (equivalent time of the speed control loop)

Optimizing
vTc

Then you can proceed to optimize the servo gain Kv for the axis in the usual
manner. However, if an optimum rise time behavior is not achieved, then this
must be compensated by modifying vTc.
Axis not dynamic enough: In this case, vTc must be reduced. Selecting
vTc to be equal to Tequiv is only a first approximation.
Axis overshoots: In this case, vTc must be increased.

SITRAIN Training for

Automation and drive technology

Page 25

MC-SMO-SYS
Axes and Drives in SIMOTION

Position Control with DSC the PROFIdrive DSC Structure


n set
nset (precontrol)

Position
calculation
(interpolator) xset

xDiff

Speed
filter

Deceleration Fine interpolation Position


(1 DP cycle)
controller

ndrive

xact,SIMOTION

Speed
controller

Speed
calculation

3
2

Xact,SIMOTION

Tpc

xact, drive
Tpc

Tsc
xact,motor

Zero offset
and compensations

SIMOTION

Speed controller cycle 125 us

Position controller cycle 1-2 ms

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.26

Drive

SITRAIN Training for


Automation and Drive Technology

Dynamic Servo
Control (DSC)

With the "Dynamic Servo Control" function, the dynamically active part of the
position controller is transferred to the drive and performed using the sampling
time of the speed control loop.
This allows a higher servo gain factor and consequently greater dynamic response
in the position control loop. Better dynamic performance is achieved both for the
command variable and for eliminating disturbances.
The structure of the DSC contains 3 branches for the feedback of the actual
position (nos. 1, 2 and 3). The feedback no.2 totally compensates the actual value
Xact, which is transferred from SIMOTION to the drive (no. 1). Therefore the only
relevant feedback of the actual position is branch no. 3.
The DSC structure allows a dynamic switchover between conventional position
control and operation with DSC. All monitoring functions as well as knowledge
about the actual position (reference point) must be - independent of DSC implemented only in SIMOTION.

SIMODRIVE 611 U
MASTERDRIVES
SINAMICS S120

DSC is supported by MASTERDRIVES (standard message frames 5 and 6


PROFIdrive) and SIMODRIVE 611U or SINAMICS S120 (in addition, message
frames 105 and 106).
Scripts on the AddOn - CD (4_Accessories\Masterdrives\Scripts) are available to
support commissioning of MASTERDRIVES.

Compensations

The DSC function is not only used in the SIMOTION system, but also in all of the
SIEMENS motion control systems, for example SINUMERIK. The SINUMERIK
system uses, in the actual value branch, a wide range of compensations, for
example spindle pitch error, sag compensation etc. This means that in the position
control loop of SINUMERIK, actual values from the drive are not directly input, but
an actual value that is compensated according to tables.
The DSC function has now been designed, so that these compensations can be
kept in their original form. Precisely, branch number 2 only compensates the noncompensated actual value in the following error, i.e. the compensation "survives".

SITRAIN Training for

Automation and drive technology

Page 26

MC-SMO-SYS
Axes and Drives in SIMOTION

Position Controller Optimization with Precontrol and DSC


Settings:

Activate precontrol,

Weighting factor: KPC = 100

Activate DSC operation

Activate expanded balancing filter (FilterMode = Mode_2)


Balancing time vTc = equivalent time of the speed control loop

motionstatedata.commandvelocity

servoData. precontrolvalue
sensorData.sensorData[1].actual velocity
servoData.symmetricServoCommandVelocity

KV = 200/s
vTc = 2.5 ms
with DSC

motionstatedata.actualvelocity

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.27

SITRAIN Training for


Automation and Drive Technology

Start value for VTc


with DSC operation

Using DSC and precontrol, it is only necessary to take into account the
equivalent time constant of the lower-level speed control loop. In this case, delay
times resulting from data processing or transfer are not included in the balancing
time constant.
vTc = rise time of the drive (equivalent time of the speed control loop)

Optimizing
vTc

The optimum performance characteristics during rise time can be achieved by


changing vTc. vTc is set to the optimum value if the actual velocity of the axis
(<Axis>.servodata.actualvelocity) follows the "delayed" setpoint velocity
(<Axis>.servodata.symmetricservocommandvelocity) by approx. 2 DP cycles.
The servo gain Kv can then be optimized in the usual manner.

SITRAIN Training for

Automation and drive technology

Page 27

MC-SMO-SYS
Axes and Drives in SIMOTION

Dynamic Adaptation for Synchronous Axes


servoData.compensatedServoCommandValue

Precontrol

servoData.TotalServoCommandValue

Interpolator

* KPC

Dynamic
adaptation T1, T2
and deadtime

Sym.
filter

SA

* KV

n set

Dead time

Position actual value


Dead time
Configuration data.TypeOfAxis.NumberOfDataSets.DataSet_1.DynamicComp.enable = activation
Configuration data.TypeOfAxis.NumberOfDataSets.DataSet_1.DynamicComp.T1 = time constant T1
Configuration data.TypeOfAxis.NumberOfDataSets.DataSet_1.DynamicComp.T2 = time constant T2
Configuration data.TypeOfAxis.NumberOfDataSets.DataSet_1.DynamicComp.deadTime = dead time

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.28

SITRAIN Training for


Automation and Drive Technology

Dynamic adaptation
for synchronous
axes

If, for the position controller optimization of axes, that will be subsequently
operated in a synchronous group, different time constants were set, then the
resulting time difference must be compensated; if this is not done, then the
actual axis contours will differ in synchronous operation.
These different time constants can be caused by:
different balancing times vTc for 100% precontrol
different servo gain factors without precontrol
In the first case, the position difference is a sequence of different time delays
when entering the position setpoints into the position control. For example, the
position actual value of an axis in the constant velocity phase would always be
obtained so that in the position controller the resulting system deviation is equal
to 0, i.e. the delayed position setpoint fed in minus the position actual value.
In a second case, the difference is caused by different servo gain factors. Thus,
for example in the constant velocity phase, the actual position of the axis always
moves a time 1/Kv = TLR after the position setpoint.
Further, it must always be observed, that either all axes are traversed in the
synchronous group with DSC or without DSC.

T1, T2, TRes

As a result of the dynamic adaptation, a delay is created in the position setpoint


of the axis. The delay is caused by two PT1 elements and a resulting dead time.
Using the configuration data:
TypeOfAxis.NumberOfDataSets.DataSet_1.DynamicComp.enable
the dynamic adaptation can either be activated or deactivated.
As resulting total time constant TRes the equivalent time constant of the axis with
the poorest dynamic performance is selected. T1, T2 and/or the dead time must
then be set, so that the resulting equivalent time TRes is identical for all axes in
the synchronous group, i.e.:
TRes = T1 + T2 + dead time + vTc (1st case)
TRes = T1 + T2 + dead time + TLR (2nd case)

SITRAIN Training for

Automation and drive technology

Page 28

MC-SMO-SYS
Axes and Drives in SIMOTION

Checking the Dynamic Adaptation Using the Circularity Test


Programmed
radius

"good" dynamic response adaptation

"Actual"
radius

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Circularity test

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.29

"Poor" dynamic response adaptation

SITRAIN Training for


Automation and Drive Technology

From V4.0, the SIMOTION trace tool also includes a circularity test. For a
circularity test, two axes are traversed along a circular path and the actual path
is compared with the program path. This allows the dynamic response and the
synchronous operating behavior of the axes to be tested.
Essentially, the circularity test can be executed in the two following
configurations:
The two axes interpolating with one another are real positioning axes:
The deviation between the programmed and actual radius provides a
measure of the following error (pythagoras). A deviation from a pure circular
shape (rotated ellipse) indicates different following errors of the two axes
when interpolating and therefore a poor dynamic response adaptation.
A good dynamic performance adaptation has been achieved, if the actual
path keeps its circular shape.
One of the axes is a real positioning axes, the other axis is a virtual axis.
In this particular case, the dynamic response of the real positioning axes is
tested. The best setting is achieved, if the resulting path is a circle where
the programmed radius is the same as the actual radius.
This can only be achieved, if the axis precisely traverses without any
following error even in the acceleration phase.

Automation and drive technology

Page 29

MC-SMO-SYS
Axes and Drives in SIMOTION

Positioning and Standstill Monitoring

servoMonitoring.positioningState
ACTUAL_VALUE_OUT_OF_POSITIONING_WINDOW
ACTUAL_VALUE_INSIDE_POSITIONING_WINDOW
STANDSTILL_MONITORING_ACTIVE

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.30

SITRAIN Training for


Automation and Drive Technology

Positioning
monitoring

At the end of the positioning movement the movement of the axis into the
pre-defined position is monitored on the basis of a positioning window.
A positioning window and a time interval are used for this purpose.
At the end of position setpoint interpolation, a timer is started with the runtime
specified in "Positioning tolerance time". After the timer has expired, the actual
position value and the setpoint position value are compared. If the deviation is
greater than the value specified in the tolerance window "Positioning tolerance
window", then fault message "Fault 50106: position monitoring" is output.

Standstill
monitoring

Standstill monitoring monitors the actual position of the axis at the end of a
traversing movement. Two time windows and a tolerance window are provided
for standstill monitoring.
At the end of position setpoint interpolation, if the actual position of the axis has
reached the tolerance window for position monitoring, a timer is started with the
"Minimum dwell time" runtime. After the time has expired, the standstill
monitoring is active and the motion is considered as having been completed
(MOTION_DONE).
Now, the position actual value is compared with the setpoint position. If the
actual position leaves the "standstill window" for longer than the time specified in
"Tolerance time", then the error message: "Alarm 50107: Standstill monitoring"
is output. If the time intervals for "Minimum dwell time" and "Tolerance time" are
equal to 0, the tolerance position window for standstill monitoring must be
greater than or equal to the tolerance window for position monitoring.

Note

From V4.1 and higher, in the system variables servoMonitoring.positioningState


the status of the axis position is displayed during positioning:
INACTIVE (motion is active)
ACTUAL_VALUE_OUT_OF_POSITIONING_WINDOW
ACTUAL_VALUE_INSIDE_POSITIONING_WINDOW
STANDSTILL_MONITORING_ACTIVE

SITRAIN Training for

Automation and drive technology

Page 30

MC-SMO-SYS
Axes and Drives in SIMOTION

Open-Loop Speed Controlled Motion - Standstill Signal

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Standstill signal

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.31

SITRAIN Training for


Automation and Drive Technology

For traversing motion of speed-controlled, positioning and synchronous axes,


the standstill signal (motionStateData.stillstandVelocity = ACTIVE) is generated,
if the actual velocity is less than a configured velocity threshold for, as a
minimum, the duration of the delay time.
For an Emergency Stop, below this velocity, motion is stopped with setpoint 0
without an emergency stop ramp. If the command with "Attach" is
parameterized, then the transition is realized with the output of the standstill
signal.

Automation and drive technology

Page 31

MC-SMO-SYS
Axes and Drives in SIMOTION

Following Error and Velocity Error Monitoring

Dynamic following error


monitoring

Velocity error
monitoring

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.32

SITRAIN Training for


Automation and Drive Technology

Dynamic
following error
monitoring

The task of the following error monitoring is to monitor for changes to the
following error in the traversing phase. Particularly noticeable changes occur
when e.g. the axis unintentionally moves against an obstacle.
The following error monitoring on the position-controlled axis is performed using
the calculated following error. The maximum permissible following error is
calculated from the setpoint speed and the straight lines parameterized in the
dialog box above. If this limit is exceeded, "Error 50102: dynamic following error
monitoring window was exceeded" is triggered.
With velocities less than the specifiable minimum velocity, a parameterizable
constant following error is monitored.
If several data sets are configured on the axis, the setting for the following error
monitoring must be identical in all data sets.

Velocity
error monitoring

The velocity error monitoring monitors for possible deviations between the
programmed setpoint and actual velocity. This monitoring function is active for
speed-controlled axes or for speed-controlled motion of positioning or
synchronous axes. For this monitoring function, an encoder must be connected
to the axis and be configured.
A PT1 model is emulated to monitor the controlled system. The input of the PT1
element is supplied with the programmed setpoint velocity. The emulated
"velocity actual value" is available at the output. The monitoring function is
initiated if the deviation between the emulated "velocity actual value" and the
actual velocity value is greater than the value that has been entered under
"Maximum velocity deviation".
The time constant for the PT1 model is set during axis configuration in the
configuration data dynamicData.velocityTimeConstant or for hydraulic axes in
dynamicQFData.velocityTimeConstant.
When the velocity error monitoring response, "Alarm 50101 Window for
reference model monitoring exceeded" is output.

SITRAIN Training for

Automation and drive technology

Page 32

MC-SMO-SYS
Axes and Drives in SIMOTION

Signal Flow Representation of the Closed-Loop Axis Control

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Signal flow

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.33

SITRAIN Training for


Automation and Drive Technology

The dialogs under the "Signal flow" entry provide a functional view of the closedloop control and the parameters of the SIMOTION TO "Axis".
Using the individual screen forms, the path from the setpoint position calculated
by the interpolator and the actual position sensed by the encoder system can be
tracked via the position control up to the manipulated variable output. The
variables prepared in the individual intermediate steps, for example positions,
velocities, speed etc., are displayed in the various screen forms.
The names of the associated system variables from the expert list are displayed
at the cursor tool tip (this is important for trace recordings). Further, the
parameter settings (configuration data), relevant for the control, can be directly
entered in the screen forms.
The functional view of the control in SIMOTION provides:
Identical visualization of the SIMOTION and SINAMICS functionality
A better understanding of the internal functions
Parameterization and online diagnostics in a functional view

Automation and drive technology

Page 33

MC-SMO-SYS
Axes and Drives in SIMOTION

Programming Traversing Motion


Single-axes commands to traverse axes

Set axis enable

Withdraw axis enable

Positioning to a target position

Start axis speed-controlled

Start axis position-controlled

Stop an axis

Reference an axis

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Overview

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.34

SITRAIN Training for


Automation and Drive Technology

To traverse the axes that have been created, what are known as single-axis
commands are available in SCOUT. These commands can be inserted in the
MCC chart via the associated toolbar in the MCC editor.
The group of single-axis commands especially includes the commands for openloop or closed-loop controlled traversing of axes, as well as commands to
enable axes, reference axes etc.
The commands to activate and deactivate cams as well as handle external
encoders are also included in this group.

Automation and drive technology

Page 34

MC-SMO-SYS
Axes and Drives in SIMOTION

Enabling and Disabling Axes

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.35

SITRAIN Training for


Automation and Drive Technology

Switching axis
enables signals

This command switches the enable signals at the axis. The axis goes into
the follow-up mode if any of the enable signals are missing. Following enable
signals can be switched.
Position controller enable: The position controller enable activates position
control for the axis. You can query the state of the position control using the
system variable <axis>.servoMonitorings.controlState.
The position controller enable is ignored for speed-controlled axes.
Switch drive enable: This checkbox switches the drive enable. You can query
the state of the current drive enable for real axes using the the system variable
<axis>.actorMonitorings.driveState.
Switch pulse enable: This checkbox switches the pulse enable in the drive
module. You can query the state of the current pulse enable for real axes using
the system variable <axis>.actorMonitorings.power.
The enable signals in STW1 according to the PROFIdrive profile can be
individually switched. All of the enable signals must be set for position-controlled
drive operation.

Follow-up mode

An axis can be switched into the follow-up mode using this check box. No
motion commands are executed in the follow-up mode. For positioning axes, in
the follow-up mode, the position control is canceled and the position setpoint
tracks the position actual value. After the follow-up mode has been deselected,
the axes must be re-referenced.

Traversing mode

The axis can be enabled for position or speed controlled operation via the
traversing mode. In the speed-controlled mode, the axis can be traversed if an
encoder fails.

Remove axis
enable

This command automatically removes the position control enable for the
selected axis. In addition you can specify whether the drive enable and pulse
enable are to be removed too. In the selection box "Follow-up mode", follow-up
mode for the axis can be activated.

SITRAIN Training for

Automation and drive technology

Page 35

MC-SMO-SYS
Axes and Drives in SIMOTION

Processing Motion Commands


MotionTask 1

Start
Axis 1

Axis 2

Command
buffer

Pos(axis1)

Command
buffer

Pos(axis2)

Pos(axis1)

Interpolator

Interpolator

Fine
interpolator
Fine
interpolator

End

Position
controller

Position
controller

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.36

SITRAIN Training for


Automation and Drive Technology

General

Commands can be issued from all user program tasks of the system. The
execution time of a command at the technology object is the only factor that
determines whether the command is effective.
A technology object does not have a task context, and therefore the priority of
the task, which issued the command, has no significance for actually executing
the command. If commands are issued from multiple tasks, the user program
must ensure a consistent sequence of the processing.

Command buffer

In order that several commands can be issued to an axis TO, every axis has a
command buffer. This buffer actually comprises four command group-specific
subbuffers, which can buffer a command from the one of the following command
groups
Emergency Stop and Stop Continue commands
Enable and disable commands
Sequential traversing motion (motion in the basis coordinate system)
Superimposed traversing motion (motion in the superimposed coordinate
system)
The interpolator at the axis reads out the command at the command buffer
(possibly in the interpolator clock cycle) and processes it. Commands from
various command groups are, to a certain extent, processed in parallel by the
axis TO.

SITRAIN Training for

Automation and drive technology

Page 36

MC-SMO-SYS
Axes and Drives in SIMOTION

Transitional Behavior of Motion Commands


Position axis
Attach
Attach - delete
pending command

Substitute

Blending

Transitional behavior
Superimpose

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.37

SITRAIN Training for


Automation and Drive Technology

Transitional
behavior

If a motion command is issued from a MCC chart and if a traversing motion is


already active, you can specify in the "Transition behavior" parameter how to
process the issued motion command.
Substitute: The motion specified in the issued command becomes active
immediately. The motion command being interpolated is interrupted.
If the command buffer contains a command, it is cleared.
Attach and discard existing command: The issued command is entered in
the command buffer. If the command buffer contains a command, it is
cleared. The active traversing motion (interpolator) is not affected.
Attach: The issued command is entered if the command buffer is empty.
If the command buffer already contains a command, the call waits until the
command buffer is empty and enters the command.
Blending: (like attach) blending is a particular form of two consecutive
positioning movements. Contrary to substitution, the motion in the previous
command is traversed at the programmed velocity until the target position is
reached, the transition takes place in the target position of the previous
movement.
The setpoint velocity specified in the command for the respective movement
is adhered to at all times.
Superimpose: The issued motion is executed as a superimposed movement.
Superimposed movements are independent movements that can cancel
each other and can be independently stopped/resumed.
The superimposed motion is carried out in a superimposed coordinate
system as relative or absolute movement depending on how it was
programmed. Analogously, the basic movement is carried out in the basic
coordinate system as relative or absolute movement depending on how it
was programmed.

TO Alarm

Aborted commands in the interpolator trigger a technological alarm "30002


Command aborted".

SITRAIN Training for

Automation and drive technology

Page 37

MC-SMO-SYS
Axes and Drives in SIMOTION

Program Advance for Motion Commands


Position axis

Step to next command


immediately

Motion start

Acceleration end

Start of
decleration phase
Setpoint

Delay program execution

Actual

End of the setpoint


interpolation

Actual

Motion completed,
i.e. position window
reached

Setpoint

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.38

SITRAIN Training for


Automation and Drive Technology

Program
advance

To synchronize programmed sequence and command processing in the


logical object, using the parameter "one command advance" it can be specified
as to when, after the command is issued, the program execution should be
continued. In this way, the system can wait until the motion has been partially or
completely executed.
Do not wait: If, for a pos command in an MCC chart, the checkbox for the
option "Delay program execution" is not selected, only when selecting the
transition behavior "Substitute" does the system advance to the next
command.
If "Attach - delete pending command", "Blending" or "Superimpose" is
selected in the transition behavior "Attach", then the system waits until the
issued command has been entered in the command buffer.
When the option "Wait for program execution" is selected, the following settings
are available:
Start motion
End of acceleration
Start of braking phase
End of setpoint interpolation
Motion completed, i.e. position window reached

Notes

SITRAIN Training for

Automation and drive technology

The full control over the immediate advance after issuing a motion command
is only possible using the system function calls in the ST language.
Interrogating the state of the command buffer is also only possible with ST
calls (system function:_getstateofmotionbuffer(...)).
In MCC the command buffer can be cleared using the "Clear command
queue" command.

Page 38

MC-SMO-SYS
Axes and Drives in SIMOTION

Synchronous and Asynchronous Program Execution


Task x

POS (axis1,...)

Start of axis positioning;

POS (axis2,...)

Task x: wait e.g. until motion


has been completed

Synchronous execution
(e.g. for MotionTasks)

Task x

Asynchronous execution
(e.g. for BackgroundTask,
IPOSynchronousTask, etc.)

POS (axis1,...)
POS (axis2,...)

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.39

Start of axis positioning;


Program changes to the next
command, without waiting for
positioning to be completed

SITRAIN Training for


Automation and Drive Technology

Asynchronous
processing

For asynchronous execution, program processing and the process sequences


are synchronized with one another. After a motion command is issued, then the
next command in the program is immediately executed.
This type of programming must be taken into account in all cyclic tasks, for
example, the BackgroundTask. When issuing a motion command, the
monitoring of the task run time is not withdrawn. If a program is generated using
motion commands, then in this case, the programmer must ensure that all of the
calls issued immediately advance to the next command.
In the ST language, this is relatively simple, as each motion command has its
own "nextCommand" parameter, which controls the advance to the next
command. Using the setting (nextCommand := IMMEDIATELY) it is reliably
ensured that the system immediately advances to the next command. In MCC,
the immediate advance is only ensured for substituting-type transition behavior.

Note

If a program with motion is generated for a cyclic task, then instead of the
motion commands from the toolbar the blocks in conformance with PLC-OPEN,
available in the library supplied, should be used. These blocks have been
specifically designed for use in cyclic tasks.

Synchronous
processing

For synchronous execution, program processing and the sequences of the


processes are synchronized with one another in some form. After issuing a
motion command, the system waits until a special state has occurred in the
process (e.g. position reached, velocity reached, etc.) and only then does the
program advance to the next command.
This type of program generation is only possible in tasks, which are not subject
to any runtime monitoring MotionTasks, UserInterruptTasks, etc.
MCC with its diagnostic functions specially supports this type of "eventtriggered" programming. Further, this programming style as a whole has a
higher level of performance than cyclic programming, as waiting for "events"
does not use up any unnecessary CPU time.

SITRAIN Training for

Automation and drive technology

Page 39

MC-SMO-SYS
Axes and Drives in SIMOTION

Dynamic Settings for the Positioning Command


Velocity profile

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.40

Smooth

Trapezoidal

SITRAIN Training for


Automation and Drive Technology

Velocity
profile

You can select a velocity profile for the programmed axis motion. The velocity
profile defines the transitions between the individual motion phases. The
following are available:
Smooth: In this case the acceleration and jerk can be specified.
Trapezoidal (default setting): With this velocity profile you can only specify
the acceleration. The input fields for the jerk are grayed out.
The selectable velocity profiles influence the motion transitions between the
start and end of the acceleration phase, between constant velocity and
acceleration phase/deceleration phase, and the transitions from start and end of
the deceleration phase.
In addition to direct input of the velocity profile, you can also select from the
following options:
Last programmed: The last programmed command becomes effective
with this velocity profile
Default: The velocity profile configured in the "Default" dialog when
commissioning becomes effective for the command. You can overwrite the
default setting of the velocity profile using the MCC command "Set axis
parameter".

Entries for Jerk


and acceleration

You can define the jerk and acceleration values via the individual combo boxes.
boxes. In addition to the two options "Last programmed" and "Default" freely
editable values or variables can be directly entered or as expression (formula).
You can use drag and drop to copy variables from the symbol browser to the
input field or copy commands and functions from the command library to the
input field.
In the selection list you can select whether the programmed jerk or the
acceleration should be effective in the configured unit or as a % referred to the
standard value.

SITRAIN Training for

Automation and drive technology

Page 40

MC-SMO-SYS
Axes and Drives in SIMOTION

Start Axis, Position Contolled or Speed Controlled

Time

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.41

SITRAIN Training for


Automation and Drive Technology

Start axis
position controlled

Using this command, positioned controlled traversing of an axis started.


A velocity is entered. The axis traverses in this motion, until it is replaced by
another motion or is stopped. Time limiting is possible as an alternative.

Time duration

Under the "Dynamics" tab, the checkbox can be activated to parameterize a


duration. A time can be entered in the "Time" entry field. The time refers to the
start of the constant velocity phase up to the start of the deceleration phase.
If no time is specified, then the axis moves until it receives a new command.

Speed input

An axis is traversed, speed controlled, with this command. A setpoint is entered


to which the axis can be ramped up via a velocity profile.
Also in this case, a time can be entered just the same as for the "Start axis
position-controlled" command. If no time is specified, then the axis moves until it
receives a new command.

SITRAIN Training for

Automation and drive technology

Page 41

MC-SMO-SYS
Axes and Drives in SIMOTION

Stop Axis

Stop mode

Selection

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.42

SITRAIN Training for


Automation and Drive Technology

Stop Axis

The command stops the axis moving. It can be used both for positioning and
speed movements. The motion can be stopped with Normal stop or Quick stop.
You define this in the "Stop mode" dropdown list.

Normal Stop

With a normal stop, the motion is decelerated along the parameterized


deceleration ramp.
Without Abort: The motion can be resumed with the MCC command "Resume
motion". In this case, no other commands can be issued to the axis between the
stop command and the resume command.
With Abort: The motion cannot be continued.
With a normal stop you can also define whether the entire motion, the basic
motion or only the superimposed motion should be stopped. You define this in
the "Selection" dropdown list.

Quick stop

With quick stop the axis is stopped by the interpolator and is not switched into
the follow-up mode. The motion cannot be continued. In addition, the axis is
disabled for further motion commands. This state can be removed using
"Remove axis enable" or "Reset object".
Quick stop within defined period: The motion is stopped within the
parameterized time frame (tab: "Dynamics", parameter: "Time for deceleration").
Quick stop with actual value-related emergency stop ramp: The motion is
stopped by the interpolator via the Emergency OFF ramp (dialog box: "Limits",
tab: "Dynamic response", parameter: "Stop with preconfigured ramp").
A following error is taken into account before stopping.
Quick stop with maximum deceleration: The motion is stopped by the
interpolator with the max. dynamic values (dialog box "Limits", tab "Dynamic
response", parameter "Acceleration").
Quick stop with dynamic values: The motion is stopped with the parameterized
dynamic values (tab: "Dynamics").

SITRAIN Training for

Automation and drive technology

Page 42

MC-SMO-SYS
Axes and Drives in SIMOTION

Continue Motion

Selection

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Continue
motion

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.43

All motion

Basic motion

Superimposed motion

SITRAIN Training for


Automation and Drive Technology

Using the "Continue motion" command, interrupted motion can be resumed. It is


only possible to resume motion, which was stopped using the stop mode
"Normal stop without abort".
You can choose whether to resume all motion, only the basic motion or only the
superimposed motion. The axis must not receive any new motion commands
between interruption and resumption of the motion.

Automation and drive technology

Page 43

MC-SMO-SYS
Axes and Drives in SIMOTION

Homing Axes with Incremental Measuring Systems

Homing type

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.44

Active homing
Passive homing
Set home position
Set home position relative

SITRAIN Training for


Automation and Drive Technology

Home axis

In the case of an incremental measuring system, the machine must be homed


every time it is switched on. Homing is initiated with the "Home axis" command.
Additional settings can be made in the "Homing" dialog for the axis configuration
An axis is allocated the homed status, if the axis coordinate system of the
control was aligned with the homing signal.

Homing type

For incremental measuring systems, the command selects the following homing
types:
Active homing (default value) In this case, via the configuration in the wizards for
the axis configuration (Dialog: "Homing") it is defined which of the three
following homing types will be executed (see the next page):
Homing only with zero mark
Homing with reference cam and zero mark
Homing only with external zero mark
Setting the current position value: The current axis position is assigned to the
value of the home coordinates. No active traversing motion takes place.
Relative direct homing: In this particular case, the axis coordinate system is
shifted by the value of the home position coordinate. The axis does not move.
Passive homing: Contrary to active homing, as a result of the homing command,
no active traversing motion takes place. In fact, the homing command is now
effective in parallel to the traversing commands, which must be issued from the
user program. The motion command can be triggered before or after the homing
command.
If the conditions for detecting the homing mark are fulfilled, then the axis is
homed corresponding to the sequence defined when configuring.

SITRAIN Training for

Automation and drive technology

Page 44

MC-SMO-SYS
Axes and Drives in SIMOTION

Active Homing with/without Zero Mark . . .

Travel range
Left travel
limit

Homing mode
Homing output cam and
encoder zero mark
Zero mark only
External zero mark only

SIMOTION

Zero marker

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.45

Right travel
limit

Position encoder

SITRAIN Training for


Automation and Drive Technology

Homing mode

With active homing of an incremental measuring system the settings in the axis
configuration are evaluated. You can choose from the following possibilities in
the "Homing mode" selection box:
Homing with homing output cam and zero mark: The homing command initiates
motion towards the homing cam. After passing the reference cam, SIMOTION
synchronizes with the next encoder zero mark. After this, the axis is traversed
through the home position offset and then the actual position is set to the
"homing position coordinate) .
When homing with "Bero and reference cam" the homing cam signal must be
connected to an input on the control (outside the process image, i.e. >= 64).
The homing cam is "1"- active.
Homing with zero mark only: This type of homing is valid for axes with only one
zero mark over the complete traversing range (usually rotary axes). The homing
command initiates motion towards the homing cam. When the zero mark is
passed, the measuring system of the axis is synchronized.
After this, the axis is traversed through the home position offset and then the
actual position is set to the "homing position coordinate".
Homing with external zero mark: The homing command triggers a movement.
The measuring system of the axis is synchronized once the parameterized edge
of the external zero mark signal is detected. The axis is then moved by the
amount of the home position offset.
When referencing with "External zero mark only", the signal must be connected
there where the encoder value is also detected, i.e. at the drive, at the ADI4 or
at the intended Bero inputs of the C2xx.

Reversing cams

From V4.1, for active homing it can be selected as to whether a dedicated


reversing cam is used or the hardware limit switch is used as reversing cam.
If, when homing, the axis reaches the reversing cam, then the axis is
automatically traversed in the opposite direction.

SITRAIN Training for

Automation and drive technology

Page 45

MC-SMO-SYS
Axes and Drives in SIMOTION

Passive Homing with/without Zero Mark . . .

Homing mode
External zero mark only

Parameterization on the drive:


P495: Encoder 1 substitute zero mark:
e.g. DI 9

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.46

SITRAIN Training for


Automation and Drive Technology

Note

For a digital coupling, drive homing is initiated via the encoder control word_1.
Drive parameters are used to define whether the drive synchronizes to the
encoder zero mark or to an external signal at the drive.
SINAMICS S120: P495[n]: External zero mark for encoder n
In addition, P490 of the CU to invert the signal
SIMODRIVE 611U: P879.13, in addition P660 = 79 (I0.n external zero mark).

Data transfer
from the drive

From V4.0 and higher, by pressing the button "Accept data from the drive",
parameter settings from SINAMICS drives can be transferred from the offline
data management all the "Start to" into SIMOTION SCOUT.
Depending on the setting of parameter P495, the associated selection in the
homing mode to zero mark or external zero mark is set.

Homing
required

Homing required "Yes": Software limit switches only become active after
homing. Absolute motion and synchronous motion commands are rejected
(error 40108: Axis not homed. Relative motion is permissible.
Homing required "No": Software limit switches are always active (if activated).
All motion and synchronous motion commands are permissible.

System variables

In the system variable <axis>.positioningState.homed it can be queried as to


whether an axis was homed with incremental encoder. For axes with absolute
encoders, this system variable is statically set to "Yes" Using this system
variable, it is not possible to evaluate whether an absolute encoder was
adjusted.

TO restart

Using a TO restart, the axis is reset to the state:


<axis>.positioningState.homed = no
Such a restart can be initiated from the user program or from SIMOTION
SCOUT using the following system variable:
<axis>.restartactivation = activateRestart

SITRAIN Training for

Automation and drive technology

Page 46

MC-SMO-SYS
Axes and Drives in SIMOTION

Adjusting an Absolute Encoder

Homing type

Absolute encoder adjustment


with specification of the
position value
Absolute encoder adjustment

SIMOTION

Absolute encoder offset

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.47

SITRAIN Training for


Automation and Drive Technology

Absolute encoder
adjustment

When commissioning the axis, if it was assigned an encoder type "Absolute


encoder" or "Absolute encoder, cyclic absolute", then the "Absolute encoder
adjustment" entry can be selected in the selection field "Homing type". When
issuing this command, the absolute encoder offset from the "Homing" tab is
taken into account in the instantaneous encoder actual value.
For the "Absolute encoder calibration with specification of the position value",
the specified position actual value is calculated with the actual axis position. The
difference is saved as absolute encoder offset in the retentive memory area.
There is no active traversing motion.
The adjustment must generally be repeated in the following situations:
After an OVERALL RESET of the control
After downloading the relevant access configuration data
When the offset data is lost, e.g. when the battery voltage fails (D4x5, )
After separating the mechanical connection between encoder and load,
if the connection could not be reproduced exactly.

System variables

Using the following system variables it can be evaluated as to whether an


adjustment was performed for an axis with absolute encoder:
<axis>. AbsoluteEncoder.AbsoluteEncoder[1]. ActivationState
Further, in the following system variables, the total offset that has been included
can be read out
<axis>. AbsoluteEncoder.AbsoluteEncoder[1]. TotalOffsetValue

Notes

SITRAIN Training for

Automation and drive technology

In the "Homing" dialog it can be set whether the value has been taken into
account in absolute terms or in addition ("Absolute encoder offset is used").
An axis with absolute encoder should not be homed using the function
"Setting the position actual value" as the offset between the encoder value
and the position actual value is not saved in the retentive data and displayed
in the corresponding system variables as is the case for the absolute
encoder adjustment.
Page 47

MC-SMO-SYS
Axes and Drives in SIMOTION

Setting the Reference System


Shift measuring system

Reference system

Setpoint reference

Actual value reference

Relative

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.48

SITRAIN Training for


Automation and Drive Technology

Shift
measuring system

Using the command, shift measuring system, you can redefine the actual and
setpoint position of an axis. The command can either be programmed, referred
to the actual value or the setpoint. Both values are always changed.

Axis

Here, the axis is specified, for which the position should be newly set. All
positioning and synchronous axes, which are configured on the device are
listed.

Position

The new position value is entered here. The value can be directly entered or as
a variable or formula.

Typ

The position type is selected here.


absolute / actual value reference
The programmed position is set as a new actual value, and the setpoint is
corrected, taking into account the following error, and set.
absolute/setpoint reference (default value)
The programmed position is set as a new setpoint, and the actual value is
corrected, taking into account the following error, and set.
relative
The programmed position is added to the actual setpoint or actual value.

Note

By setting the actual value system using the command "Shift measuring
system", contrary to the command "homing, set the actual position value", the
original positions of the software limit switch are not changed.
The permissible traversing range therefore remains unchanged.

SITRAIN Training for

Automation and drive technology

Page 48

MC-SMO-SYS
Axes and Drives in SIMOTION

Diagnostics of Axes or Drives - Service Overview


Target system -> Service overview

Extended...

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.49

SITRAIN Training for


Automation and Drive Technology

Service Overview

With this function it is possible in the online mode to quickly obtain an overview
of the state of all configured axes. Selected system variables are displayed here
together with their respective status. The status is displayed using colored
lamps.
Green lamp: Axis (system variable) is active/on or axis is stopped.
Red lamp: An error is present.
Yellow lamp: Axis is in motion (constant velocity, acceleration, deceleration) or
an alarm is present.
Gray (no LED): Axis (system variable) is not active.

Example:

Status of the position control (servomonitoring.controlstate):


Green lamp: position control is active
Gray: Position control is not active

Extended...

A list with additional system variables is displayed when you click the
"Expanded..." button. You can select additional system variables from this list for
which you want to display the status in the "Service overview".
You can select them in the open screen by checking the checkbox in front of the
system variable.

SITRAIN Training for

Automation and drive technology

Page 49

MC-SMO-SYS
Axes and Drives in SIMOTION

Diagnostics of a TO - Querying the System Variables

1. Select axis

2. Symbol browser

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.50

SITRAIN Training for


Automation and Drive Technology

System Variables

You can monitor and modify system variables via the symbol browser. You can
query for example the entire status of a command execution or of an axis motion
via system variables. This allows you to carry out a detailed analysis of all types
of motion and execution, in particular if you use it together with the trace
function.
You can access system variables:
Within the SIMOTION device from all programs
From HMI devices
System variables can be monitored and controlled via the symbol browser.
System variables can be also combined in separate application-specific watch
tables, for example when commissioning.

Procedure

To monitor the actual values of system variables of the technology object,


proceed as follows:
1. Switch SIMOTION SCOUT into the online mode.
2. Select the required technology object in the project navigator.
3. Select the "Symbol browser" in the detail view. The system variables are
displayed for the TOs.

Online Help

You can display the associated online help for the individual system variables.
To do that, proceed as follows:
1. Press the key combination <Shift> + <F1>.
A question mark is displayed next to the mouse cursor.
2. Now click on the row with the system variable for which you required
extended help.
The online help for the selected system variable is displayed.

SITRAIN Training for

Automation and drive technology

Page 50

MC-SMO-SYS
Axes and Drives in SIMOTION

Significance of the Service Display


Name

Significance

Position control status


(servomonitoring.controlstate):

Green: position control is active for the axis


Gray: position control is not active. Setpoint at the pos. control output is 0.

Operational status
(control)
Technological alarm on axis
(error)

Green: axis can be moved by motion commands


Gray: axis is in follow-up mode
Red: Technological alarm present on the axis
Gray: There is no technological alarm

Cycl. drive interface active


(actormonitoring.cyclicinterface)

Green: cyclic data transmission to drive active via PROFIBUS


Gray: drive is not in cyclic operation

Drive enable
(actormonitoring.drivestate)

Green: drive enable (ramp-function generator) is active


Gray: no drive enable

Power enable
(actormonitoring.power)

Green: power enable (enable OFF1, OFF2 and OFF3 and operation)
Gray: no power enable

Drive error
(actormonitoring.driveerror)

Red: error on drive (error active/power-on disable)


Gray: no error on drive

Status of axis motion


(motionstatedata.motioncommand)

Green: axis is not moving


Yellow: axis is moving

Velocity-related standstill signal


(motionstatedata.Stillstandvelocity)
Axis homing status
(positioningstate.homed)

Green: axis is not moving (signal mainly used for speed-controlled axes)
Gray: axis is moving
Green: axis is homed (only for axes with incremental encoders)
Gray: Axis is not homed

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.51

Automation and Drive Technology

System Variables

In the system variables a technology object, e.g. an axis, provides information


about its current status. The system data of an axis TO will therefore display
information such as position setpoint, actual position value, following error in
what is referred to as system variables.
In addition to the above listed system variables, additional information is
displayed about the setpoint and actual positions or following error. Further,
clicking on the "Extended..." button displays more information about the axes.

Actual Position

Displays the current actual position of the axis. The actual position is derived
from the actual value transferred by the encoder system of the drive.

Setpoint Position

Displays the setpoint position of the axis as calculated by the interpolator. The
difference between setpoint and actual position is called following error. The
following error is the reference variable within the position controller for
calculating the speed setpoint.

Difference between
Setpoint and
Actual Position

Displays the following error within the interpolator level.

SITRAIN Training for

Automation and drive technology

Page 51

MC-SMO-SYS
Axes and Drives in SIMOTION

Technological Alarms
Alarm display and
acknowledgement:

Display and acknowledge in


SCOUT

Display and acknowledge via


HMI

Acknowledge via the user


program

Query and evaluate in the user


program

Software limit switch

Alarm 40106: SW limit switch reached

Alarms

Position encoder (linear scale)

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.52

SITRAIN Training for


Automation and Drive Technology

General

The complete technological functionality of SIMOTION is provided in the form of


TOs. For example, the TO positioning axis has the complete functionality for the
position control of an axis.
To use this functionality in the user program, the TO provides various system
functions (commands), e.g. "Position axis" to position an axis.
In this constellation, two basic fault possibilities can occur:
The command at a TO cannot be executed.
In this case, the return value of the function provides information about the
cause.
When processing the command, the TOA itself identifies when the function
required by the application cannot be executed or not completely and then
returns certain events or states.
In this case, a TO alarm is generated.
Example:
50102: Following error monitoring window has been exceeded" (fault)
50006: Activation/deactivation of synchronous operation executed directly"
(note)

Technological
alarms

If an event (fault, note) occurs at a technology object, then this outputs a


"Technological Alarm". TO alarms can be evaluated and acknowledged in
different ways:
Displaying and acknowledging in the online mode of SIMOTION SCOUT
Displaying and acknowledging via HMI
Acknowledging via the user program
Querying and evaluating in the user program (TechnologicalFaultTask).

SITRAIN Training for

Automation and drive technology

Page 52

MC-SMO-SYS
Axes and Drives in SIMOTION

Configuring Technological Alarms

2. TechnologicalFaultTask

3. Alarm configuration

4. Select TO

5. Configure alarm

1. Execution system

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.53

SITRAIN Training for


Automation and Drive Technology

Alarm configuration

Generally, alarms that occur at a technology object have an impact on the


system. After creating the technology object, for each alarm a certain behavior is
preset (default setting).
Depending on the TO alarm, it is possible to modify the preset behavior. For the
TO alarms, a distinction is made between effects on the technology object itself
(local behavior) and the effects on other technology objects and/or the execution
system (global behavior).
By specifying the error activation it can be defined as to whether the alarm is to
be activated immediately, after repeated occurrences of an error or after a
certain period of time. Some alarms can be completely suppressed, for example
to suppress unimportant messages.
Example: Alarm: 30002: Command aborted.

Local behavior

With the local behavior you define how the technology object involved should
behave when an alarm occurs and how additional commands for the TO should
be handled.
When an alarm response occurs (except for NONE), the command decoder is
always stopped. Any programmed commands issued subsequently are rejected.
Command execution can continue after the alarm has been acknowledged in
cases where the global error response for the alarm does not automatically
require a Power ON.

Global behavior

With the global behavior, the impact of a TO alarm on the execution systems
described. The following actions can be set depending on the respective TO
alarm.
NONE: no response
START TechnologicalFaultTask With this task, the user can respond to the
TO alarm with an application-specific response. If there is no program
assigned to this task, the system switches to the STOP state.
STOP: All technology objects and the user program are inactive.
STOPU: Only the user program is inactive.

SITRAIN Training for

Automation and drive technology

Page 53

MC-SMO-SYS
Axes and Drives in SIMOTION

Acknowledging Technological Alarms

Acknowledge specific
TO alarms
Acknowledge TO alarms

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.54

SITRAIN Training for


Automation and Drive Technology

Acknowledge
TO alarm

This command can be used to acknowledge all alarms of one or more


technology objects (such as axes, cams, etc.).
You can specify the axes, cams, etc. for which the alarms are to be
acknowledged via checkboxes in the individual parameter dialogs.
Several objects can be simultaneously selected.
All of the objects, which are defined on the device, can be selected.
The checkbox "Acknowledge all alarms" means that all alarms for all
technological objects can be acknowledged.

Acknowledge
specific TO alarm

The command acknowledges all or one specific alarm at a technology


object.
With alarm-specific acknowledgement, you can enter the required alarm number
in the "Alarm No." entry field. The associated alarm text is then automatically
displayed in the "Alarm text" dropdown list.
Conversely, you can also select an alarm text from the alarm list. The
corresponding number is then automatically displayed in the "Alarm No." box.

Note

From V4.0, using the system function _getAxisErrorState(..) alarms present at a


TO axis can be read out. This function provides information on whether axis
alarms have occurred and how many. Further, supplementary information on
this error are returned as LREAL value.

SITRAIN Training for

Automation and drive technology

Page 54

MC-SMO-SYS
Axes and Drives in SIMOTION

Using the Technology Object Trace (1)


TO trace

Start trace
recording

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.55

Event selection, TO trace

SITRAIN Training for


Automation and Drive Technology

TO trace

The commands at a technology object and accesses to system variables and


configuration data of the technology object can be traced using the TO trace
function.
In SIMOTION, technology objects can be influenced by configuration data,
system variables, and commands during runtime. With the new TO trace, all
events affecting a technology object can be recorded in real-time and displayed
in detail in a chronological sequence in SIMOTION SCOUT. This results in a
significantly improved detection of sporadic errors in the application and as a
consequence, commissioning is speeded up.

Procedure

1. Activate an online connection to the target system and select the required
SIMOTION device in the project navigator.
2. Call the window of the TO trace from the entry "TO Trace" of the context
menu or using the corresponding button in the toolbar.
3. In the "Technology object" list, select the required TOs for the trace
recording.
4. Using the button: . . . at the end of the line for each TO, the dialog to
parameterize the trace function can be opened.
5. Under the individual tabs, parameterize: settings, commands, configuration
data and system variables, how many and which events are to be recorded.
Commands, configuration data, and system variables are always selected as
the default setting. Signals can be deselected at the individual tabs.
6. Load the parameterization into the target system and start the trace by
pressing the "Start TO trace" button.

SITRAIN Training for

Automation and drive technology

Page 55

MC-SMO-SYS
Axes and Drives in SIMOTION

Using the Technology Object Trace (2)

Uploading trace data

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.56

SITRAIN Training for


Automation and Drive Technology

Continued

7. Select the "Recorded data" tab to be able to evaluate the recorded events.
Load the recorded data into SIMOTION SCOUT by pressing the "Upload
data" button.
The events (writing configuration data or system variables, commands to the
TO) are displayed in the correct sequence with timestamp and actual
execution status.

Note

When displaying the execution status of a command, pay special attention to the
following:
As command execution advances, the more information can be read out
concerning the relevant commands. This means that for commands that have
already been completed, the execution status (EXECUTED or ABORTED) and a
possible error code can be determined.
As the TO trace takes a snapshot, this information is based on the situation at
the time that data is read out. The status is not updated automatically once the
command has been completed. The status can be updated by reading out
again.

SITRAIN Training for

Automation and drive technology

Page 56

MC-SMO-SYS
Axes and Drives in SIMOTION

If You Want to Know Even More

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Note

SITRAIN Training for

09.02.2012
MC-SMO-SYS_05.57

SITRAIN Training for


Automation and Drive Technology

The following pages either contain additional information or are used as


reference to complete a specific topic.

Automation and drive technology

Page 57

MC-SMO-SYS
Axes and Drives in SIMOTION

Using Axis Data Sets


Configuration -> axis data sets

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.58

SITRAIN Training for


Automation and Drive Technology

Axis data sets

For the TO axis, SIMOTION supports the concept of data sets as well as data
set changeover. Various data sets are used, if during the runtime:
the actual encoder must be changed
parameter settings of the controller data must be changed
The configuration data, which belong to the axis data set(ADS), can be viewed
under the axis data sets of the configuration dialog of the axis tab.
Data sets must be defined and activated as a group because some data, for
example, controller data, can only be activated simultaneously in groups to
ensure consistency of the controller and function.
When configuring, several data sets can be created for one axis. Further, it can
be defined as to which data set should be active after powering up.

Activate data set

Using the ST system function _setAxisDataSetActive() or the MCC function


"other data sets can be selected during the runtime. If another encoding is
assigned in the new data set, then the system changes over to the active
measuring system. From this point in time, the actual positions of the position
control are supplied from the new encoder system.
Using the system function _setAndGetEncoderValue() or using the MCC
function "Synchronize measuring systems", both measuring systems can be
synchronized before the changeover. This will avoid unwanted compensating
motion of the position controller if differences in position are identified.
If the encoder systems are not adapted, then the resulting speed setpoint step
(jump) at the position control output via the time constant "Time constant for
smoothing of manipulated variable changes as a result of controller switchover"
will be smoothed in the dialog box "Axis_n -> Limits -> Dynamic response".

SITRAIN Training for

Automation and drive technology

Page 58

MC-SMO-SYS
Axes and Drives in SIMOTION

Adding an Encoder to an Axis


Configuration -> Encoder configuration
3. Assign encoder
1. Add

2. Create new encoder

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.59

SITRAIN Training for


Automation and Drive Technology

Encoder
configuration

Frequently, a data set changeover is required, if, for an axis, various encoders
are used, for example.
Motor measuring system (motor encoder)
Additional direct measuring systems (linear scale)
This means that up to 8 encoders can be created for the axis. All of the created
encoders are internally active, and the measured values are updated cyclically.
Using the "Encoder number" entry, in the axis data sets you can define which
encoder is used for the position control.

Automatic
adaptation

The adaptation of relevant drive and encoder data is, from SIMOTION V4.2 in
conjunction with SINAMICS S120 from V2.6.2 and higher, automatically
activated. The encoder parameters are automatically determined and adapted
during the runtime.
This is not possible for "older" drives (SIMODRIVE, MASTERDRIVES) or for
encoders that are directly connected to PROFIBUS DP, and which are supplied
via message frame 81 (see the above example). In this case, the encoder must
be manually configured.

Add 2nd encoder

To create a 2nd encoder for an axis, to start a message frame must have been
configured with the encoder values for the encoder in HW Config. This can
either be done by directly inserting a PROFIBUS encoder (for example
SIMODRIVE sensor isochrone via message frame 81) from the HW catalog or
providing additional encoder values via one of the message frames (message
frames) 4, 6, 106, to a drive system with a 2nd encoder.
A 2nd encoder is configured in SIMOTION SCOUT using the screen form:
Configuration -> Encoder configuration. A new encoder can be added to the axis
TO using the "Add" button. The new encoder can be connected with the
message frame data in HW Config via the "Assign encoder" dialog.
For encoders, which cannot be automatically adapted during the runtime, then
the necessary settings must be made for the encoder type, mode and encoder
resolution (see the following pages).

SITRAIN Training for

Automation and drive technology

Page 59

MC-SMO-SYS
Axes and Drives in SIMOTION

Basic Configuration - Encoder Type and Mode

Encoder type:
Absolute encoder
Absolute encoder, cyclic absolute
Incremental encoder

Encoder mode

For incorrect parameterization (compare with r979 in the drive):

Square wave TTL


Resolvers
Sine/cosine
Endat

Error 20005: Device type: 2, log.address: 1234 faulty. (Bit: 0, reason: 0x80h)

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.60

SITRAIN Training for


Automation and Drive Technology

Encoder type

From V4.2 and higher, for SINAMICS drives it is possible to directly align the
encoder configuration dynamically with the encoder settings for SINAMICS during
the runtime. This is not possible for "older" drive systems, for example
SIMODRIVE and MASTERDRIVES or for third-party drives. In this case, the
encoder must be manually configured.
The required encoder type must first be selected:
Absolute encoder
Absolute encoder, cyclic absolute
Incremental encoder

Encoder mode

The actual encoder type is set in the "Encoder mode" selection field. The following
settings are available for absolute encoders:
Endat encoder (encoder data interface)
SSI encoder (synchronous serial interface)
The following incremental encoders are supported:
Sine/cosine encoder
Square-wave TTL encoder
Resolvers
Endat encoder

Alarm for incorrect


parameterization

If the encoder parameterization in SIMOTION and in the drive differ from one
another, the following technology alarm is triggered as soon as an online
connection is established between the control and drive/encoder and the TO is
loaded to the control.
"Error 20005: Device type: 2, log.address: 1234 faulty. (Bit: 0, reason: 0x80h)"
The comparison of the parameterization for drives is realized according to the
PROFIdrive via a parameter: r979 (SensorFormat). For drives, which do not
support parameter r979, the configuration without alarm is considered to be valid.

SITRAIN Training for

Automation and drive technology

Page 60

MC-SMO-SYS
Axes and Drives in SIMOTION

Mode of Operation of an Incremental, Optical Sin/Cos Encoder


Capacitor

Scanning plate

Output signals:

Indexing disk

2048 periods per revolution

Photo elements

Light source

Spur B

Spur R

Spur C

Type: ERN 1387


ERN 1381

Reference
mark

"Raw signal"

Spur D
Additional inverted tracks

A, B, R, C , D

8 ramps per cycle


Each ramp is subdivided into 256 steps

2048 cycles

Spur A
Resolution with SINAMICS S120 : 2048 * 8 * 256 4 million

Spur B

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.61

SITRAIN Training for


Automation and Drive Technology

Principle

The optical encoder is based on the following principle. Parallel light passes
through the lattice grid of a scanning plate opposite the light source onto the grid
serving as the measuring standard. The lattice grid distribution on the scanning
plate and on the indexing disk are identical
The lattice grid on the scanning plate is split up into 4 fields, which, regarding
the grid distribution, have spatial offsets of 0, 90, 180 and 270. For relative
motion, a bright-dark modulation is created due to the alternating coverage.
This modulation is evaluated using 4 photo elements (4 field scanning). These
photo elements supply currents that are proportional to the illumination intensity.
If the 0 and 180, as well as the 90 and 270 signals are combined, then 2 sin
or cos sequences are obtained.

Raw signals

Encoder output signals, which supply a voltage that can be evaluated (raw
voltage signals) have 1 Vpp - raw current signals supply 11App.

Resolution

Internally an additional resolution is realized through interpolation (2048 pulses


per period).
For interpolation with 2048 subdivisions, the resolution is again 11 bits, i.e. 22
bits, which means 222 = 4194.304 signals per revolution.
Example: Ballscrew 10mm pitch, no gear,
2048 pulses per revolution x 2048 sinusoidal oscillation /10mm, i.e.
419 signals/m or 0.0023 m/pulse.
However, this resolution is only required when determining the actual speed for
the closed-speed control inside the drive. In this case, even at low speeds (up to
1 revolution/minute) it must be possible to sensibly determine the actual speed.
However, this high-resolution is transferred to SIMOTION (refer to the next
page).

SITRAIN Training for

Automation and drive technology

Page 61

MC-SMO-SYS
Axes and Drives in SIMOTION

ERN 1387

ERN 1381

Spur A

Settings for Incremental Encoders - "Cyclic Actual Value"

Number of pulses per revolution


Fine resolution

G1_XIST 1
31

30

29

28

27 26

25

24

23

Overflows: 0 - 1023

SIMOTION

22

21

20 19

18

17

14

13

12

11 10

Encoder pulse number: 2048 Fine resolution: 2048

Date:
File:

Siemens AG 2012. All rights reserved.

16 15

09.02.2012
MC-SMO-SYS_05.62

SITRAIN Training for


Automation and Drive Technology

Cyclic actual value

The cyclic actual value in Gn_XIST_1 (n = 1 or 2, encoder number) is used by


incremental as well as absolute encoders to send the actual position value of the
axis in cyclic operation to SIMOTION. SIMOTION cyclically calculates the actual
position value of the axis from this value, the leadscrew pitch and the reference
point value (with incremental encoders) or the absolute value, which is passed on
by absolute encoders after activation.
After the converter has been switched on, Gn_XIST_1 = 0 is always output
independent of the actual position of the axis. Each traversing movement of the
axis is passed on via Gn_XIST_1.
SIMOTION interprets the bits in this Gn_XIST_1 in accordance with the settings in
"encoder pulse number" and "fine resolution". This interpretation is correct only if
the settings in SIMOTION correspond to the settings for Gn_XIST_1 in the
converter and, of course, also correspond to the actual data of the encoder.

Fine resolution

The converter does not only output the information on the pulse number to
Gn_XIST_1 but also increases the total resolution of the connected encoder by
internally sampling the sin/cos signal with sin/cos encoders or resolvers.
Resolution: Encoder pulses x 2n (n: fine resolution, no. of bits for internal
multiplication
The following applies for the No. of encoder marks:
Encoder marks = number of sine signal periods (sine/cos encoder with 1 Vpp)
No. of encoder marks = 1024 x pole pair no. (resolver with 12 bit resolution)
No. of encoder marks = 4096 x pole pair no. (resolver with 14 bit resolution)
The pulse number and fine resolution are entered in parameters in the
converter.
The fine resolution for the cyclic actual value Gn_XIST_1 in the converter must
be entered in SIMOTION as value = 2n in the input field.
An input value of 0 is interpreted as standard multiplication factor of 211 =
2048. In this case 0 is equal to 2048.

SITRAIN Training for

Automation and drive technology

Page 62

MC-SMO-SYS
Axes and Drives in SIMOTION

Mode of Operation of an Absolute Encoder


Capacitor
Indexing disk

Hall-effect
element

Photocouples
Light source
Scanning plate

Coded disk
Gear box

Resolution:
16
revolutions

Binary coding of a
mechanical revolution
with 8192 positions

Incremental tracks

16:1

Multiturn absolute encoder

Date:
File:

Siemens AG 2012. All rights reserved.

Resolution:
4096
revolutions

Motor
speed

Singleturn encoder

SIMOTION

Resolution:
256
revolutions

09.02.2012
MC-SMO-SYS_05.63

16:1

16:1

Type: EQN 1325

SITRAIN Training for


Automation and Drive Technology

Principle

The optical design corresponds to a sin/cos encoder. In addition, the disks have
binary coded tracks, which can be interpreted as coded number of pulses in the
incremental track.
For 2048 pulses, then at least 11 additional tracks are required, in order to code
the position within one revolution (single turn encoder). The absolute traversing
distance that can be measured is therefore too low for most applications (for
example, 10 mm for a ballscrew with 10 mm pitch/revolution and directly
mounted onto the motor).
This is the reason that the measuring range has been extended using a 3-stage
gearbox. Every step down stage has a ratio of 16:1. As a consequence, the
position information only repeats itself after 4096 revolutions or after a traversing
distance of 40.96m. The position of the gear wheels in the gearbox are
evaluated using Hall elements.

EnDat interface

In order that the traversing distance through the 4096 revolutions can be
uniquely represented, the following information must be known.
Gearbox position: 3 x 4 bits (16 x 16 x 16 = 4096 revolutions)
Pulse number:
11 binary tracks
When the control system is switched on, this 23-bit information is transferred
from the encoder using the EnDat protocol (EncoderData Protocol).
The precise position information is retrieved using the interpolation technique
described for sin/cos encoders.

SITRAIN Training for

Automation and drive technology

Page 63

MC-SMO-SYS
Axes and Drives in SIMOTION

Settings for Absolute Encoders - "Absolute Actual Value"

Number of pulses per revolution


Fine resolution for act. value in Gn_XIST_1
Fine resolution for act. value in Gn_XIST_2
Number of bits for multiturn resolution
+ no. of encoder pulses
Gn_XIST 2

not
evaluated

Multiturn resolution: 4096

Encoder pulse
number: 512

Fine resolution: 512

Number of data bits: 21

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.64

SITRAIN Training for


Automation and Drive Technology

Absolute
actual value

When an absolute encoder is connected, SIMOTION retrieves the absolute


position of the axis via Gn_XIST_2 (n = 1 or 2, encoder number) after the
control/converter has been switched on. From the transmitted value or the
stored overflows of the multiturn information, SIMOTION calculates the actual
position value of the axis.
SIMOTION interprets the bits in Gn_XIST_2 in accordance with the settings for
"Data width of absolute value without fine resolution" and the "Fine resolution of
absolute value in Gn_XIST2".

Number of data bits

The "Data width absolute value without fine resolution" is obtained from the total
of the bits for multiturn resolution and encoder pulse number. The settings in
SIMOTION must match the corresponding settings in the converter, otherwise
the actual position will not be calculated and displayed correctly after switch on.

Fine resolution

Just the same as for "cyclic actual value", the converter not only transmits
information about the number of encoder revolutions (for multiturn encoders)
and the encoder pulse number to the higher-level control, but also performs fine
resolution. This fine resolution is lower with the "absolute actual value" than with
the "cyclic actual value" as the entire information must be stored in a 32-bit
double word.
This means only 9 bits, i.e. a factor of 512, remain for the fine resolution for
standard multiturn encoders with a multiturn resolution of 4096 (12 bits) and an
encoder pulse number of 2048 (11 bits). This is the reason that for the "Fine
resolution absolute value in Gn_XIST_2" an entered value of 0 is interpreted as
a multiplication factor of 29 = 512.

Note

The encoder position word Gn_XIST_2 is used not only for transferring the
absolute actual value after switch on but also for transferring the position in the
functions: "Measuring input" and "Homing". In this case, however, the position
value is coded in accordance with the format settings for the "cyclic actual
value", i.e. in accordance with the multiplication factor for the cyclic actual value.

SITRAIN Training for

Automation and drive technology

Page 64

MC-SMO-SYS
Axes and Drives in SIMOTION

Settings for Absolute Encoders - Encoder Type

Encoder type:

"Absolute encoder"
Overflows of the multiturn information are not saved in
SIMOTION when it is switched off

"Absolute encoder, cyclic absolute":


Overflows of the multiturn information are saved in
SIMOTION when it is switched off

....

Overflows of multiturn information

Multiturn resolution

Encoder pulses
per revolution

Fine resolution

Number of data bits: 23

Encoder information in Gn_XIST 2

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

Encoder mode

09.02.2012
MC-SMO-SYS_05.65

SITRAIN Training for


Automation and Drive Technology

The following two settings are available in the "Axis configuration - Encoder
assignment" dialog box in the "Encoder type" field:
Absolute encoder:
With this setting, the entire overflows of the absolute actual value, i.e. overflows of the multiturn information are not saved when the SIMOTION is
switched off.
The next time SIMOTION is switched on, the actual position value is
formed from the absolute actual value which is passed from the converter in
Gn_XIST_2 to SIMOTION.
With a multiturn resolution of 4096 and a leadscrew pitch of 10mm/rev. The
result is always a value between 0 m and approx. 40 m.
Absolute encoder, cyclic absolute
With this setting, at switched off, the overflows of the multiturn information
are stored in the retentive memory area of SIMOTION. The next time
SIMOTION is switched on, this information is taken into account for
calculating the actual position value.
This setting must be made if the absolute encoder with it's multiturn
resolution does not cover the complete traversing range of the axis or if, as a
result of an unfavorable mounting of the absolute encoder, overflows of the
multiturn information occur within the traversing range.

Note

SITRAIN Training for

The overflows of the multiturn information and the value for the absolute
encoder adjustment of an axis are deleted in the following situations:
OVERALL RESET of SIMOTION
Download of modified configuration data for the encoder settings for the axis.

Automation and drive technology

Page 65

MC-SMO-SYS
Axes and Drives in SIMOTION

Settings for Travel to Fixed Endstop

Maximum motor torque --> TypeOfAxis.SetPointDriverInfo.DriveData.maxTorque

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.66

SITRAIN Training for


Automation and Drive Technology

Travel to
fixed endstop

As a result of the "travel to fix stop" command, the monitoring of "traversing


to fixed endstop" is activated in parallel to axis motion started using a motion
command. In addition, the maximum torque at the drive is restricted to the value
specified in the command. Further, the active following error monitoring usual for
traversing motion is deactivated.
The "Travel to fixed endstop" function assumes that the torque limiting at the
drive is supported, i.e. this function can only be performed when using one of
the message frames 103, 104, 105, or 106.
The command also ensures that a specific clamping torque is maintained after
the fixed endstop has been reached. This command can also be used to switch
over the clamping torque during active clamping.

Fixed endstop
detection

In the dialog "Limits", "Fixed endstop" tab, in the "Fixed endstop detection" field,
it can be selected as to how it can be detected when the fixed endstop is
reached:
when the following error is exceeded. In this case, in the entry field
"Following error to the fixed endstop detection", the required value should be
entered, which results in the status "Fixed endstop reached".
when the torque is exceeded: In this case, when reaching the torque
programmed at the command for the status "Fixed endstop reached".
If the criterion "Fixed endstop reached" is reached, then the interpolator is
stopped; however the position control remains active. The axis is now clamped
with the torque programmed at the command. The usual traversing commands
in the same direction are rejected by the TO, only traversing commands in the
opposite direction are permitted.
In the system variables moveToEndStopCommand. ClampingState the state
"Fixed endstop reached" is displayed. The state "Fixed endstop reached" is
canceled if the actual axis position deviates by more than the value specified in
the "Position tolerance after fixed endstop detection" (e.g. because the clamping
force is overcome, traversing command in the direction opposite to the clamping
direction).

SITRAIN Training for

Automation and drive technology

Page 66

MC-SMO-SYS
Axes and Drives in SIMOTION

Travel to Fixed Endstop - "Determining the Reference Torque"

Max. drive torque--> TypeOfAxis.SetPointDriverInfo.DriveData.maxTorque

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.67

SITRAIN Training for


Automation and Drive Technology

Determining the
reference torque

For SINAMICS from V2.6.2 and higher, the reference torque of the motor
is automatically adapted by SIMOTION and entered into the corresponding
configuration data.
<Axis>.TypeOfAxis.SetPointDriverInfo.driveData.maxTorque
All of the reference variables of an axis are listed in the screen form:
Configuration -> Reference variables.

Resolution

For the resolution of the torque reduction, from V4.0 two options are available.
The setting in SIMOTION is made in the configuration data
SetPointDriverInfo.driveData.torqueReductionGranularity (standard motor)
or in
SetPointDriverInfo.linearMotorDriveData.forceReductionGranularity
(linear motor).
1. Setting: "STANDARD" (default setting) - resolution 0.006 %
The value of 4000H or 16384 (dec.) in the message frame corresponds to a
torque reduction of 100%.
In SINAMICS, P1544 must be set to 100 (default setting).
2. Setting: "BASIC" - resolution 1 %
The value of 64H or 100 (dec.) in the message frame corresponds to a
torque reduction of 100%.
In SINAMICS, P1544 must be set to 16384.

SITRAIN Training for

Automation and drive technology

Page 67

MC-SMO-SYS
Axes and Drives in SIMOTION

Travel to Fixed Endstop - "Settings in the Command"

For linear axes:


F = Torquemotor x 2 x x (spindle/ S) x (motor revolution / load revolution)
F : Force in N
Torquemotor : Motor torque in Nm
spindle : Efficiency of the spindle (no dimensions)
S: Spindle pitch in m

SIMOTION

Date:
File:

Siemens AG 2012. All rights reserved.

09.02.2012
MC-SMO-SYS_05.68

SITRAIN Training for


Automation and Drive Technology

Clamping value
(without unit)

The clamping value is entered in the force unit for the particular axis type,
i.e. in N, kN, ... (Newton) for linear axes or in Nm, kNm for rotary axes.
If a linear axis is implemented using a standard motor and a ballscrew, then the
motor reference torque must be converted to the "reference force" of the linear
axis. The following relationship is used for the conversion:
F = torquemotor x 2 x x (spindle / S) x (motor revolution/load revolution)
F = force
M = torque
S = spindle pitch (leadscrew.pitchVal)
= spindle efficiency (leadScrew.efficiency)
Motor revolution (Gear.numFactor)
Load revolution (Gear.denFactor)

Example

In the following example, the reference torque 3.68 Nm of a motor is converted


into a reference torque. In this example, the conversion is made without any
additional load gearbox, the spindle pitch is assumed to be 10 mm/revolution
F = 3.68 Nm x 6.28 / 0.01 m = 2312, 21 N
When 231.22 is entered as clamping value in the command, this corresponds to
a torque reduction of 90% in the message frame. As a consequence, the drive
generates a maximum torque of 0.368 Nm at the motor.

Clamping value
(as a percentage %)

When selecting the clamping value as a %, the required max. torque at the
drive can be directly entered in units of 0.01. The required maximum torque at
the drive of 0.37 Nm then corresponds to an input of 37.
When implementing a linear axes via a ballscrew at the motor, then a value of
628.0 must be entered into the system variable
userdefaultclamping.clampingvalue.

SITRAIN Training for

Automation and drive technology

Page 68

MC-SMO-SYS
Axes and Drives in SIMOTION

S-ar putea să vă placă și