FX Series Programmable Controllers Assigning System Devices 9
9-15
Example Application Program #5
If using an analog range from 4 ~ 20mA to obtain an output range from A ~ B, the normal
output range of 0 ~ 2000 must be converted to the new range.
To convert the normal output range of 0 ~ 2000 to the range of A ~ B, please see below.
D80 = (B - A) x (D8112 or D8113) / (2000 - 0) + A; if A = 4000 and B = 20000
D80 = (20000 - 4000) x (D8112 or D8113) / (2000) + 4000
D80 = 8 x (D8112 or D8113) + 4000
Example Application Program #6
If using an analog range from A ~ B to obtain an output range from C ~ D, both the current and
the digital ranges must be converted from the standard ranges.
To convert both ranges, please see the programming example below. More details can be
found from the previous examples.
D90 = (D - C) x (D8112 or D8113) / (B’ -A’)+(B’ xC-A’ xD)/(B’ -A’)
D90 = (D - C) x (D8112 or D8113) / [(125 x B - 500) - (125 x A -500)] + [(125 x B - 500) x C -
(125 x A - 500) x D] / [(125 x B - 500) - (125 x A - 500)]
(A’ = 125 x A - 500; B’ = 125 x B - 500)
D90=(D-C)x(D8112orD8113)/[125x(B-A)]+[(B-A)xC-(A-4)xD]/(B-A)
If A = 5, B = 15, C = 5000, and D = 15000
D90 = (15000 - 5000) x (D8112 or D8113) / [125 x (15 - 5)] +
[(15 - 4) x 5000 - (5 - 4) x 15000] / (15 - 5)
0
0
B
2000
Digital value (D80)
used on the program
A
Digital values (D8112 and D8113) practically AD-converted
0
0
2000
20mA
Analog input
Digital value
AD-converted
(D8112,D8113)
4mA
M8000
FNC 22
MUL
K8 D8113
FNC 20
ADD
D82 K4000
M8113
D82
D80
D
0
0
4000
20mA
Analog input
A'
B'
AB
4mA
Digital value
AD-converted
(D8112,D8113)
0
0
D
2000
Digital value (D90)
used on the program
C
A' B'
Digital values (D8112 and D8113) practically AD-converted