9 Motion Control Functions
9-20
NJ/NX-series CPU Unit Motion Control Userās Manual (W507)
An error will occur if the specified cam table does not exist in the Controller. You can also specify the
same cam table for more than one axis.
You can switch cam tables by re-executing the cam operation instruction during cam operation. After
switching, cam operation will be performed with the cam table you specified for re-execution of the
instruction. The EndOfProfile and Index output variables from the MC_CamIn instruction are output
according to the new cam table.
Precautions for Correct UsePrecautions for Correct Use
⢠The cam table you want to switch to must be saved to non-volatile memory before it can be
used.
⢠Switching cam tables during cam operation will cause discontinuous velocities. Adjust the tim-
ing for switching the cam table to avoid excessive velocity discontinuity.
Cam data can be loaded and saved from the user program just like any other variables. For example,
you can use MyCam1[0].Phase to specify the phase and MyCam1[0].Distance to specify the displace-
ment in the first array elements of a cam table named MyCam1. Cam data overwritten from the user
program can be saved to the non-volatile memory in the CPU Unit as a cam table by executing the
MC_SaveCamTable instruction.
Precautions for Correct UsePrecautions for Correct Use
⢠Overwritten cam data will be lost if the CPU Unit is turned OFF or the cam data is downloaded
from the Sysmac Studio before the Save Cam Table instruction is executed or if the instruction
fails to save the data for any reason.
⢠Be careful not to lose the overwritten data when overwriting cam data from the user program in
the CPU Unit.
⢠Cam data saved to non-volatile memory can be loaded by using the upload function of the
Sysmac Studio.
⢠Use the Synchronization menu command of the Sysmac Studio to upload and download the
project.
For details on arrays, refer to the NJ/NX-series CPU Unit Software Userās Manual (Cat. No. W501).
For details on the Save Cam Table instruction, refer to the MC_SaveCamTable instruction in the NJ/NX-
series Motion Control Instructions Reference Manual (Cat. No. W508).
Switching Cam Tables
Loading/Saving Cam Data and Saving Cam Tables
PhaseRe-executed
Cam table 2Cam table 1
Displacement
Slave
(Slave axis)
Master
(Master axis)