PLC OPERATION
Let us consider the typical operation of a PLC. Programmer should always keep in mind that the operation is not simultaneous for the entire ladder diagram and is not continuous as it is for relay sequencers. This is of great significance and can have significant impact if not taken into consideration during logic design. Operation of the programmable controller can be considered in two modes
-
The I/O scan mode
-
The Execution mode.
I/O Scan Mode
During the I/O scan mode, the processor updates all outputs and inputs state of the system taking one input at a time. The time required for updation of I/O depends on the speed of the processor.
Execution Mode
During execution mode, the processor evaluates each rung of the ladder diagram program that is being executed sequentially, starting from the first rung and proceeding to the last rung. As a rung is evaluated, the last known state of each of the input and/or output elements in the rung is considered, and if any true path to the output device is detected, then that output is indicated to be energized- that is, set to ON.
At the end of the ladder diagram, the I/P mode is entered again, and all output device are provided with the on or off state determined from execution of the ladder diagram program. All inputs are sampled, and the execution mode starts again.
Scan Time
An important characteristic of the programmable controller is, how much time is required for one complete cycle of I/O scan and execution. Of course, this depends on how many inputs and output channels are involved and on the length of the ladder diagram program.
The speed of the programmable controller depends on the clock frequency of the processor The higher the clock frequency, the greater the speed and faster the scan/execution time.
The length of time for one scan consists of three parts:
-
Input scan time
- Execution time
-
Output scan time
Most of the scan time comes from the execution phase. The scan time may have an impact on the ability of the PLC to detect events that occur on the inputs.
PLC PROGRAMMING
PLC can be programmed (reprogrammed) through a computer, if the software needed for programming is available or through manual programmers (consoles). Through regular checking of programs in PLC, execution only of good programs can be insured.
Almost every program for programming a PLC controller possesses various useful options such as: Forced switching on and off of the systems inputs/outputs (I/O lines), program follow up in real time as well as documenting a diagram. There are some special considerations in programming which includes the availability of special functions and the relation between external I/O devices and their programmed representations,
Ladder diagram Interpretation
There is an important difference between the interpretation of physical ladder diagram and a programmed ladder diagram. This difference arises from the fact that the programmed diagram bases the state of a rung on a logical interpretation of the symbol rather than its physical state.
In a programmed diagram rung, the ON or OFF state of the output of the rung is determined by testing the elements of the rung for a TRUE or FALSE condition. If a complete TRUE element path to output exists in the rung, then the output will be made TRUE or ON.
Addressing
The programmable controller identifies the different elements such as inputs, outputs, flags etc. with some unique number called as address. The addresses are used to identify both the physical and software devices according to the following categories:
-
Physical input devices- ON or OFF
-
Physical output devices- energized (ON) or de-energized (OFF)
-
Programmed control relay coils and contacts
-
Programmed time-delay relay coils and contacts
-
Programmed counters and contacts
-
Special Functions
The address designation depends on the type of programmable controller. Some
controllers may reserve certain addresses for physical I/O devices, other addresses for software control relays, and yet others for special function.
BACK
|