Chapter 6 Applied Instructions 3. The figures: BAND is executed. BAND is not executed. Output value Output value The lower limit value of the deadband Input value Input value The upper limit value of the deadband 4. The minimum value of the deadband in S 1 , the maximum value of the deadband in S 2 , the input value in S 3 , and the output value in D should be within the range described below. If the instruction BAND is executed, the minimum value of the deadband in S 1 , the maximum value of the deadband in S 2 , the input value in S 3 , and the output value in D is within the range between -32768 and 32767.
Suppose the minimum value of the deadband in S 1 is 10 and the maximum value of the deadband in S 3 is -32768. The output value in D is calculated as follows. Output value in D =-32768-10=16#8000-16#000A=16#7FF6=32758 If the instruction DBAND is executed, the minimum value of the deadband in S 1 , the maximum value of the deadband in S 2 , the input value in S 3 , and the output value in D is within the range between -2147483648 and 2147483647. Suppose the minimum value of the deadband in ( S 1 +1, S 1 ) is 1000 and the maximum value of the deadband in ( S 3 +1, S 3 ) is -2147483648. The output value in ( D +1, D ) is calculated as follows.
Output value in ( D +1, D) =-2147483648-1000=16#80000000-16#000003E8=16#7FFFFC18 =2147482648 Example 1: When X0.0 is ON, -1000 or 1000 is subtracted from the binary-coded decimal value in X1, and the difference is stored in D1. The execution results: 6-303 Minimum Maximum Input value in Output value value of the value of the Function D0 in D1 deadband deadband -1000 1000 -1200 D0 D1=D0-(-1000) -200 1200 D0>1000=>D1=D0-1000 200 500 -1000≦D0≦1000=>D0=0 0