3. Programming a PLC:

PLCs are programmed through concept of ladder logic. In general there exists a graphical user interface (GUI) to program a PLC that makes it different from other processers. Ladder logic comprises of two columns. Left column shows input devices like switches, sensors while in output column is at right side which shows actuators like cylinders, motors.

Meanings of symbols used in PLC Program:

] [

This instruction is called as “examine on” or “normally opened” as input functions or storage bits. If the corresponding memory bit is a “1” then the respective ‘rung’ will continuously be executed and the corresponding outputs will be energized. Rung is one of the multiple horizontal programming lines in a ladder logic diagram.

NOTE: Other factors may also affect rung simultaneously.

If the corresponding bit is “0” then the rung will not be executed continuously and outputs will be de-energized. If this instruction is used as input bit, its status should be according to the status of the real world input devices connected to the input table by identical addresses.

Addressing Sample:  I: 3/1

This indicates address of a sample. I indicates input image table, 3 indicates slot no. 3 of input port and 1 indicates bit three of 3rd slot of input port.

]/[

This instruction is called “examine off” or “normally closed” as input functions or storage bits. If the corresponding memory bit is a “1” then the respective ‘rung’ will continuously be executed and the corresponding outputs will be energized.


NOTE: Other factors may also affect this rung simultaneously.


If the corresponding bit is “0” this instruction will not allow rung continuously and outputs will be energized. If used as input bit, its status should correspond to the status of the real world input devices tied to the input table by identical addresses.

This is called as ‘output energize'. This instruction sets the specified bit when rung continuity is achieved. Under normal operating conditions, if the set bit corresponds to an output device, output device will be energized when rung goes true.

Addressing Example O:3/1

O -- output image table

3 -- slot three

1 -- bit one of slot three

This is called as ‘output latch'. This instruction functions similar to output energize except that once a bit is set with OTL, it is latched on. Once an OTL bit has been set ON (1 on the memory) it will remain ON even if the rung condition goes false. The bit must be reset.

 (U)

This is called as ‘output unlatch’. This is used to unlatch (reset) a latched bit. Its address must be same as latched one.

Timer

This is also called as “TON”. Figure 3.3.3 shows the schematic of a Timer. It is used to turn an output ON or OFF after the timer has been ON for preset time interval. This output instruction begins timing when rung goes true. It waits the specified amount of time (As specified in Preset), keeps track of accumulated intervals which have occurred (ACCUM), and sets DN (Done) bit when ACCUM time equals preset time.

As long as rung condition remains true, Timer adjusts its accumulated value to each evaluation until it reaches the preset value. The accumulated value is reset when rung condition go false, regardless of whether timer has timed out. ” TIME BASE” is an amount of time after which accumulator increases its value by 1.

Figure 3.3.3 Schematic of a Timer


Last modified: Wednesday, 26 September 2018, 1:54 PM