2 digit output has a limit from 0-99, hence subtraction is performed to set the preset value of T4:1 timer
which is OFF time of output O:2/0.
This input is BCD number.
Data stored in any registers in PLC are in the form of Hexadecimal. So BCD input from I:5 has to be
converted into Hexadecimal which is performed by FRD instruction and moved to address T4:0.PRE.
Now when 2 digit input is set as a preset of Timer T4:0, it is subtracted from 100 and the output is set as a
preset of Timer T4:1.
100 – ON time = OFF time. (ON time = 0-99)
If the input is 50, then both the timers hold the same value, hence square wave of 50% duty cycle is
obtained.
So by varying input from 0-99, width of pulse (ON time of output) is varied.
However, when input from I:5 is 0 and OFF time is completed, output O:2/0 blinks for a while. To eliminate
this error, LIM instruction is used.
We can even use 3 and 4 digit inputs but then these digits must be subtracted from 1000 and 10000
respectively.
Runtime Test Cases
PLC Program to Jump to Other Process
This is a PLC Program to Jump to Other Process.
Problem Description
Implement Jumping from one process to another process in PLC using
Ladder Diagram programing
language.
Dostları ilə paylaş: