Sheet (4) : Problem
Sheet (4) : Problem
Sheet (4)
Problem (1):
A PLC counter program used to stop a motor from running after 10 operations.
The operation of the program can be summarized as follows:
• Up-counter C5:0 counts the number of off/on operations of the motor.
• The preset value of the counter is set to 10.
• A counter done bit examine-off instruction is programmed in series with the motor
output instruction.
• A motor output examine-on instruction is used to increment the accumulated value
of the counter for each off/on operation.
• After the count of 10 is reached the counter done bit examine-off instruction goes
false preventing the motor from being started.
• Closure of the reset pushbutton resets the accumu-lated count to zero.
Problem (2):
shows a counter program used for length measurement. This system accumulates the
total length of random pieces of bar stock moved on a conveyor. The operation of the
program can be summarized as follows:
• Count input pulses are generated by the magnetic sensor, which detects passing
teeth on a conveyor drive sprocket.
• If 10 teeth per foot of conveyor motion pass the sensor, the accumulated count
of the counter would indicate feet in tenths.
• The photoelectric sensor monitors a reference point on the conveyor. When
activated, it pre-vents the unit from counting, thus permitting the counter to
accumulate counts only when bar stock is moving.
• The counter is reset by closing the reset button.
Sprocket
Magnetic
sensor Photoelectric
sensor
Conveyor fl
Reflector
Problem (3):
A PLC Case-counting program that uses the conveyor motor and up-counter. The counter
counts the number of cases coming off the conveyor. When the total number of cases reaches
50, the conveyor motor stops automatically. The trucks being loaded will take a total of only
50 cases of this particular product; however, the count can be changed for different product
lines. The operation of the program can be sum-marized as follows
• The momentary start button is pressed to start the conveyor motor M1.
• The passage of cases is sensed by the proximity switch.
• Cases move past the proximity switch and incre-ment the counter’s accumulated value
with each false-to-true transition of the switch.
• After a count of 50, the done bit of the counter changes state to stop the conveyor motor
automatically and reset the counter’s accumulated value to zero.
• The conveyor motor can be stopped and started manually at any time without loss of the
accumu-lated count.
• The accumulated count of the counter can be reset manually at any time by means of the
count reset button.