Emerson EZMotion User Manual page 178

Table of Contents

Advertisement

Example:
Do While (TRUE)
Index.0.Initiate'Incremetal,Dist=25.000in,Vel=25in/s
Dwell For Time 1.000 'Seconds
Loop
Example:
Do While (TRUE)
Index.0.Initiate
Dwell For Time 1.000 'Seconds
Index.1.Initiate
Dwell For Time 0.500 'Seconds
Loop
Dwell For MasterDist
This motion instruction is used to pause program execution for a precise change in distance on the master encoder signal. This is
typically used in synchronized motion applications. This dwell does not begin until all other motion has completed. When the dwell
begins, program flow will wait until the specified master distance has passed. The units for the dwell value are specified in the
Master Units View.
Example:
Do While (TRUE)
Index.0.Initiate
Dwell For MasterDist 12.00 'MstrInch
Loop
IndexInitiate by Expression
This motion instruction is used to initiate a single index. The index is preset to include an acceleration up to speed, a run at speed
and a deceleration to a stop. IndexInitiate by Expression is used to initiate different indexes with the same line of code in a program.
One notable change from a standard Index.#.Initiate is that Wait for Index.AnyCommandComplete line of code normally inserted
after the initiate will not be inserted after IndexInitiate by Expression. No comments will be added to this instruction as the index
selected can change anytime before the initiate command is encountered.
The following example will initiate index.0, wait for complete, initiate index.1, wait for complete, index.2... etc.
Example:
var.var0 = 0
a:
IndexInitiate var.var0
Var.var0 = 1 + var.var0
Wait for Index.AnyCommandComplete
goto a:
CompoundIndexInitiate By Expression
This motion instruction is used to vary the index numbers making up a compound index. No comments will be added to this
instruction as the index selected can change anytime before the initiate command is encountered.
The following code will continuously compound Initiate Index.0 and Index.1 in a loop.
Example:
a:
if var.var0 = 0 then
var.var0 = 1
else
var.var0 = 0
endif
CompoundIndexInitiate var.var0
goto a:
CamInitiateByExpression
This motion instruction is used to initiate a cam. The cam is preset to include cam type, time base, direction, any chaining
requirements, and a deceleration to a stop, optional. CamInitiate by Expression is used to initiate different Cams with the same line
of code in a program.
The following example will initiate Cam Table 0, wait for cam complete, initiate Cam Table.1, wait for cam complete, index.2... etc.
Example:
var.var0 = 0
a:
CamInitiate var.var0
Var.var0 = 1 + var.var0
Wait For Cam.CommandComplete
goto a:
Cam.Initiate
Cam.#.Initiate has two forms - Program Instruction and Assignment (as a Destination). Both are used to initiate a specific Cam. For
the Destination, the Cam is initiated on the rising edge of this event. Using the Destination, an Cam cannot be initiated if there is an
Index, Home, Jog, or Program in progress, or if the Cam.#.Initiate is an instruction. If any motion is active, the program will hold on
this instruction until that motion is complete (unless it is run on a different profile).
Cam.Resume
Resumes the cam execution from a Cam.Suspend command (or SetCamMasterOffset(MasterPosn), or SetCamFollowerOffset
166
www.controltechniques.com
EZMotion User/Programming Guide
Revision: A8

Advertisement

Table of Contents
loading

Table of Contents