557
BAND, BANDP, DBAND, DBANDP
1
2
3
4
4
6
7
8
7.13
Data C
ontrol Instructio
ns
7.13.2
BAND, BANDP, D
B
AND
, DBANDP
(3) The output value stored at , +1 is a signed 32-bit BIN value. Therefore, if the operation results exceed the range of
from -2147483648 to 2147483647, the following takes place:
Operat
i
on
E
rror
(1) In the following case, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into SD0.
Program
E
xamp
l
e
(1) The following program performs the dead band control by applying the lower and upper limits of 0 and 1000 for the data
set in BCD at X20 to X2F and stores the result of control at D1 when X0 is turned ON.
[Ladder Mode]
[List Mode]
[Operation]
• "0" is stored at D1 if 0 D0 1000.
D0 500 D1 0
• The value of (D0) 1000 is stored at D1 if 1000 D0.
D0 7000 D1 6000
(2) The following program performs the dead band control by applying the lower and upper limits of -10000 and 10000 for
the data set at D0 and D1 and stores the result of control at D10 and D11 when X0 is turned ON
[Ladder Mode]
[List Mode]
[Operation]
• The value (D1, D0) - (-10000) is stored at (D11, D10) if (D1, D0) ( 10000).
(D1, D0) -12345 (D11, D10) -2345
• The value 0 is stored at (D11, D10) if -10000 (D1, D0) 10000.
(D1, D0) 6789 (D11, D10) 0
• The value (D1, D0) -10000 is stored at (D11, D10) if 10000 (D1, D0).
(D1, D0) 50000 (D11, D10) 40000
When :
Dead band lower limit value ( , +1)
................
1000
Input value ( , +1)
...................................................
-2147483648
Output value -2147483648-1000 80000000
H
-000003E8
H
7FFFFC18
H
2147482648
Error
code
Error details
Q00J/
Q00/
Q01
QnH
QnPH QnPRH
QnU
LCPU
4100
The lower limit value specified in is greater than the upper limit value
specified in .
––
––
––
––
D
D
S1
S1
S3
S3
S1
S2
Step
I
nstruct
i
on
De
vi
ce
Example
Example
Step
I
nstruct
i
on
De
vi
ce
Example
Example
Example