If the cam table start point position (zero phase position) is 20°, the slave axis starts operation
when the master axis reaches a position where the relative angle from that point is 40°. Cam
operation operates in a periodic motion.
If Periodic is TRUE, periodic operation is performed.
2 Ending Cam Operation
When the actual position of the slave axis MC_Axis001.Act.Pos exceeds 1000.0, cam operation is
ended and the slave axis is stopped at deceleration rate DecRate2.
Ladder Diagram
Main Variables
Name Data type Default Comment
MC_Axis000 _sAXIS_REF --- Axis Variable for the master axis, axis 1.
MC_Axis000.MFaultLvl.Active BOOL FALSE TRUE while there is a minor fault level
error for axis 1.
MC_Axis000.Details.Homed BOOL FALSE TRUE when home is defined for axis 1.
MC_Axis001 _sAXIS_REF --- Axis Variable for the slave axis, axis 2.
MC_Axis001.MFaultLvl.Active BOOL FALSE TRUE while there is a minor fault level
error for axis 2.
MC_Axis001.Details.Homed BOOL FALSE TRUE when home is defined for axis 2.
Pwr1_S BOOL FALSE This variable is assigned to the Status
output variable from the PWR1 instance
of the MC_Power instruction. This varia-
ble changes to TRUE when the Servo is
turned ON.
Pwr2_S BOOL FALSE This variable is assigned to the Status
output variable from the PWR2 instance
of the MC_Power instruction. This varia-
ble changes to TRUE when the Servo is
turned ON.
CamProfile0 ARRAY[0..360] OF
_sMC_CAM_REF
--- This is the cam data variable.
The array elements ARRA
Y[0..N] are set
with the Cam Editor. In this sample, 0 to
360 are used, but the number of array el-
ements depends on the settings that you
make with the Cam Editor.
DecRate2 LREAL 10000.0 This variable sets the deceleration rate
for execution of MC_CamOut.
Vel_InVel BOOL FALSE This variable is assigned to the InV
elocity
output variable from the VEL instance of
the MC_MoveVelocity instruction. It is
TRUE when the target velocity is
reached.
Camin_InCam0 BOOL FALSE This variable is assigned to the InCam
output variable from the CAMIN instance
of the MC_CamIn instruction. It is TRUE
during cam operation.
3 Axis Command Instructions
3-203
NY-series Motion Control Instructions Reference Manual (W561)
MC_CamIn
3
Sample Programming 1