Guidelines For Using The Motion Subroutines - Siemens SIMATIC S7 System Manual

Hide thumbs Also See for SIMATIC S7:
Table of Contents

Advertisement

12.6.1

Guidelines for using the Motion subroutines

You must ensure that only one motion subroutine is active at a time.
You can execute the AXISx_RUN and AXISx_GOTO from an interrupt routine as long as the
interrupt is called cyclically. However, it is very important that you do not attempt to start a
motion subroutine in an interrupt routine if the Axis of Motion is busy processing another
command. If you start a subroutine in an interrupt routine, then you can use the outputs of
the AXISx_CTRL subroutine to monitor when the Axis of Motion has completed the
movement.
The Motion wizard automatically configures the values for the speed parameters (Speed and
C_Speed) and the position parameters (Pos or C_Pos) according to the measurement
system that you selected. For pulses, these parameters are DINT values. For engineering
units, the parameters are REAL values for the type of unit that you selected. For example:
selecting centimeters (cm) stores the position parameters as REAL values in centimeters
and stores the speed parameters as REAL values in centimeters per second (cm/sec).
Some "generate" guidelines when using motion subroutines are as follows:
● Insert the AXISx_CTRL subroutine in your program, and use the SM0.0 contact to
execute it every scan.
● To specify motion to an absolute position, you must first use either an AXISx_RSEEK or
an AXISx_LDPOS subroutine to establish the zero position.
● To move to a specific location, based upon inputs from your program, use the
AXISx_GOTO subroutine.
● To run the motion profiles you configured with the Motion wizard, use the AXISx_RUN
subroutine.
S7-200 SMART
System Manual, V2.3, 07/2017, A5E03822230-AF
12.6 Subroutines created by the Motion wizard for the Axis of Motion
Open loop motion control
621

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic s7-200 smart

Table of Contents