2-17
2 Motion Control Configuration and Principles
NJ/NX-series CPU Unit Motion Control Userās Manual (W507)
2-3 Motion Control Principles
2
2-3-2 Example of Task Operations for Motion Control
If high speed motion control is not required and/or your user program is too large, place motion control
instructions in a priority-16 periodic task.
ļ¬ Timing of Processing
Motion control processing (MC) for the motion control instructions (FB) that are executed in the
same task period as the priority-16 periodic task are performed at the same time. Therefore, pro-
cessing for multiple axes can be simultaneously executed or stopped.
1
Loading Data
The input data from the EtherCAT slaves (slave A) is loaded during the I/O refresh (IO).
2
Instruction Execution
The motion control instructions (FB) are executed based on the data that was loaded during
user program execution (UPG) in the priority-16 periodic task.
The output variables of the motion control instructions are refreshed at this point.
3
Command Generation
Motion control instructions (FB) are executed in the task period of the priority-16 periodic task
according to the motion control instructions (FB) that were executed. Motion processing is per-
formed during motion control processing (MC) in the next primary periodic task after the periodic
task. During this processing, execution commands for the Servo Drives or other devices are
generated.
4
Sending Commands
The execution commands that were generated are sent to the Servo Drive or other device
during the I/O refresh (IO) in the next period.
Using Motion Control Instructions in a Priority-16 Periodic Task
Primary period
Execution of motion control instructions
Servo
Execution command
Priority-16
periodic task
Task period (primary period Ć 3)
Primary
periodic task
Slave A
IN
UPG
FB
UPGIO MC UPGIO MC UPGIO MC UPGIO MC UPGIO MC
Primary period
Servo
Execution command
Priority-16
periodic task
Task period (primary period Ć 3)
Primary
periodic task
FB
IN
UPG
UPG
IO MC UPGIO MC UPGIO MC UPGIO MC UPGIO MC
Slave A
Execution of motion control instructions