Page 49 - Programmable Logic Controllers, Fifth Edition - Mobile version
P. 49
PLC controls the amount of fluid placed in a holding
tank by adjusting the percentage of the valve open- temperature value in degrees Celsius can be summarized
as follows:
ing. The analog output from the PLC is used to control
the flow by controlling the amount of the valve open- • The Input parameter is the value to be scaled (in this
ing. The valve is initially open 100%. As the fluid level case analog input I:1.1)
in the tank approaches the preset point, the processor • The Input Min parameter is the value that is read by
modifies the output, which adjusts the valve to maintain the analog card when the input is − 10V ( in this
a set point. case −32768 )
Transducers produce either voltage or current proportional • The Input Max parameter is the value that is read
to some engineering units such as temperature (°C or °F), by the analog card when the input is 10V ( in this
2
pressure (lb/in ), distance (cm), etc. Scaling refers to chang- case 32767 )
ing a quantity from one notation to another and involves: • The Scaled Min parameter is the lowest value you
Engineering units: The units a human uses and want the SCP to calculate (in this case −100)
understands • The Scaled Max parameter is the highest value you
Transducer units: Either a voltage or current want the SCP to calculate (in this case 200)
Binary, raw, or machine units: The units the processor • The Scaled Output parameter is the address where
requires you want to store the result of the SCP (in this
case N7:60)
The SCP (Scale with Parameters) instruction in RSLogix
500 is used to produce a scaled output value that has a The SCP instruction in Figure 2-29 is used to scale the
linear relationship between the input and scaled values. It analog output to a proportional valve. The instruction di-
allows you to take an analog input from a sensor and scale rects the analog output to provide a 4 to 20mA signal,
it to the output units you require. Figure 2-28 illustrates which is scaled to the valve position based on a percent-
a typical application involving temperature measurement. age between 0 and 100. The module is scaled to represent
Setting up the SCP instruction to calculate the scaled 4 mA as the low signal and 20 mA as the high signal.
10
Degrees centigrade
(engineering units)
200 ± DC voltage 0 Analog SCP
from transducer module Scale with parameters
32,767 SCP
100 –10 Input I:1.1
+
Input_Min –32768
Transducer Input
0 – Information Input_Max 32767
stored in –100
binary units Scaled_Min
–100 Scaled_Max 200
Probe Output N7:60
–32,768 SCP
Scale with parameters
SCP
Input N7:21
+200
Input_Min 0
Input_Max 100
100 Scaled_Min 6242
Scaled_Max 31208
Output O:1.0
Input –10V +10V Input
minimum –32,768 +32,767 maximum
–100 Figure 2-29 Scaling
the analog output to a
Figure 2-28 Measuring temperature. proportional valve.
30 Chapter 2 PLC Hardware Components
pet73842_ch02_017-045.indd 30 03/11/15 3:43 PM