Sample Program For Coding Practice - Omron SYSMAC C Series User Manual

Hide thumbs Also See for SYSMAC C Series:
Table of Contents

Advertisement

Sample program for coding
practice
Preset counter
5 counts
X2
[ag
O
O
1
Solenoid
0000
1000
CNT47
5 counts
CNT47
TIMOO
i
peie-
1000
1000
i
2s
END
In the figure is a control circuit for a packaging machine. The circuit is
used to detect and count the number of products being carried on an
assembly tine. When it counts five products, the circuit energizes a
solenoid. The solenoid receives electrical current for a period of two
seconds and is then shut off.
Using Step 1 we determine that there is an input device (a limit switch), an
output device (a solenoid), a control relay (an internal auxiliary relay), a
timer, and a counter.
To carry out Step 2, we have to assign numbers to the components
constituting this circuit.
This is how our assignment looks:
Input device (limit switch)
: Input relay No. 0000
Output to solenoid
: Output relay No. 0500
Control relay (X1)
: Internal auxiliary relay No. 1000
Counter CC
: CNT47
Timer T
: TIMOO
The ladder diagram that represents this circuit using the numbers we
assigned looks like the one at left.
Be sure to use the assigned input number.
Since the timers and counters must be assigned numbers from a range of
0 to 47, a convenient way to make this assignment is to begin at one end
of the range for timers and the other end for counters. That's why we gave
Timer T the number 00, while Counter CC was assigned the number 47.
This helps to prevent possible use of the same number for both a timer
and a counter.
This relay contact can be reused as often as desired, but the coil cannot
be reassigned.
The assigned output relay plays the role of the load in this example.
The right bus bar does not need to be written.
Each logic line must be ended with a relay coil, timer/counter, or special
instruction.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sysmac c20

Table of Contents