The following are examples of data-handling instructions to be found with PLCs.
For moving data from one location or register to another, Figure illustrates a common practice of using one rung of a ladder program for each move operation, showing the formused by three manufacturers: Mitsubishi, Allen-Bradley, and Siemens. For the rung shown, when there is an input to | | in the rung, the move occurs from the designated source address to the designated destination address. For data handling with these PLCs, the typical ladder program data-handling instruction contains the data-handling instruction, the source (S)address from where the data is to be obtained, and the destination (D) address to where it is to be moved. The approach that is used by some manufacturers, such as Siemens, is to regard data movement as two separate instructions, loading data from the source into an accumulator and then transferring the data from the accumulator to the destination.
Figure shows the Siemens symbol for the MOVE function. The data is moved fromthe IN input to the OUT output when EN is enabled.
Data transfers might be to move a preset value to a timer or counter, or a time or counter value to some register for storage, or data from an input to a register or a register to output.
Figure shows the rung, in the Allen-Bradley format, that might be used to transfer a number held at address N7:0 to the preset of timer T4:6 when the input conditions for that rung are met. A data transfer from the accumulated value in a counter to a register would have a source address of the form C5:18.ACC and a destination address of the form N7:0. A data transfer from an input to a register might have a source address of the form I:012 and a destination address of the form N7:0. A data transfer from a register to an output might have a source address of the form N7:0 and a destination address of the form O:030.
The data comparison instruction gets the PLC to compare two data values. Thus it might be to compare a digital value read from some input device with a second value contained in a register. For example, we might want some action to be initiated when the input from a temperature sensor gives a digital value that is less than a set value stored in a data register in the PLC. PLCs generally can make comparisons for less than (< or LT or LES), equalto (¼ or ¼ ¼ or EQ or EQU), less than or equal to ( or <¼ or LE or LEQ), greater than.(> or GT or GRT), greater than or equal to (! or >¼ or GE or GEQ), and not equal to (6¼ or <> or NE or NEQ). The parentheses alongside each of the terms indicates common abbreviations used in programming. As an illustration, in structured text we might have: (*Check that boiler pressure P2 is less than pressure P1*)Output :¼ P2 < P1; With ladder programs, for data comparison the typical instruction will contain the data transfer instruction to compare data, the source (S) address from which the data is to be obtained for the comparison, and the destination (D) address of the data against which it is to be compared. The instructions commonly used for the comparison are the terms indicated in the preceding parentheses. Figure shows the type of formats used by three manufacturers using the greater-than form of comparison. Similar forms apply to the other forms of comparison. In Figure the format is that used by Mitsubishi, S indicating the source of the data value for the comparison and D the destination or value against which the comparison is to be made. Thus if the source value is greater than the destination value, the output is 1. In Figure the Allen-Bradley format has been used. Here the source of the data being compared is given as the accumulated value in timer 4.0 and the data against which it is being compared is the number 400. Figure shows the Siemens format.
The values to be compared are at inputs IN1 and IN2 and the result of the comparison is at the output: 1 if the comparison is successful, otherwise 0. The R is used to indicate real numbers, that is, floating point numbers, I being used for integers, that is, fixed-point numbers involving 16 bits, and D for fixed-point numbers involving 32 bits. Both the inputs need to be of the same data type, such as REAL.
As an illustration of the use of such a comparison, consider the task of sounding an alarm if a sensor indicates that a temperature has risen above some value, say, 100oC. The alarm is to remain sounding until the temperature falls below 90oC. Figure shows the ladder diagram that might be used. When the temperature rises to become equal to or greater than 100oC, the greater-than comparison element gives a 1 output and so sets an internal relay.
There is then an output. This output latches the greater-than comparison element, so the output remains on, even when the temperature falls below 100oC. The output is not switched off until the less-than 90oC element gives an output and resets the internal relay.
Another example of the use of comparison is when, say, four outputs need to be started in sequence, that is, output 1 starts when the initial switch is closed, followed sometime later by output 2, sometime later by output 3, and sometime later by output 4. Though this could be done using three timers, another possibility is to use one timer with greater-than or equal elements. Figure 12.6 shows a possible ladder diagram. When the X401 contacts close, the output Y430 starts. The timer is also started. When the timer-accumulated value reaches 5 s,the greater-than or equal-to element switches on Y431. When the timer-accumulated value reaches 15 s, the greater-than or equal-to element switches on Y432. When the timer reaches 25 s, its contacts switch on Y433.
There are a number of selection function blocks available with PLCs. Figure shows the standard IEC symbols.
Programmable Logic controllers Related Interview Questions
|Electrical Engineering Interview Questions||Instrumentational Engineering Interview Questions|
|BHEL Interview Questions||Variable Frequency Drive(VFD) Interview Questions|
|HMI Development Interview Questions||Electrician Assistant Interview Questions|
|Plc Scada Interview Questions||Control Valves Interview Questions|
|Electrical Power System Interview Questions|
Programmable Logic Controllers Tutorial
Programmable Logic Controllers
Ladder And Functional Block Programming
Il, Sfc, And St Programming Methods
Jump And Call
All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd
Wisdomjobs.com is one of the best job search sites in India.