User`s manual

16-36 Motion Mate DSM314 for Series 90-30 PLCs User's Manual
January 2001 GFK-1742A
16
// Local Logic Program for CAM Example
CTL01 := 0; // Outputs written when logic completes initialize to
zero to allow toggle to true
CTL08 := 0;
// Outputs written when logic completes initialize to
zero to allow toggle to true
// Control Logic for Program 1 and 2
// Program 1 = Slave
// Program 2 = Master
IF PROGRAM_ACTIVE_2=1 THEN // Make sure Program 2 is active
IF BLOCK_2=210 THEN // Indicates Master is Ready to Start CAM
IF PROGRAM_ACTIVE_1=1 THEN // Check that Program on Axis 1 is active
IF BLOCK_1=100 THEN // Block indicates Slave ready for CAM-Load
Sequence
CTL01:=1; // Signal Slave to perform CAM Load sequence
END_IF;
IF BLOCK_1=130 THEN // Block indicates Slave has completed initialization
and CAM-Load Sequence
CTL08:=1; // Signal Master and Slave that both Axes are ready
to start CAM sequence
END_IF;
END_IF;
END_IF;
END_IF;
// End Control Logic for Program 1 & 2
After completing the program entry, the resulting VersaPro screen should look similar to the figure
shown below (Figure 16-26).