Delta Electronics AH — 3.23 String Processing Instructions

AH Motion Controller – Standard Instructions Manual 7. The value in S 2 should be within the range between 0 and 7. Example: floating-point number. When the conditional contact MO is ON, the binary-coded decimal floating-point number is converted into the 0 D0 16#1234570 D1 D12 D11 D2 _3 1 3 D3 D4 3 D10  The value in D0 is 0 because the binary-coded decimal floating-point number is a positive number.  16#1234570 is stored in (D2, D1).  The value in D3 is 1 because the exponent is a negative number.  The value in D4 is 3.  1234570E-3, the binary-coded decimal floating-point number in D0~D4, is converted into the 1234.57.

 Since the value in D10 is 3, the decimal point in 1234.57 in is moved to the left by three places. The Additional remark: result is 1.23457, and is stored in (D12, D11). 1. If the value in S 1 is neither 0 nor 1, the instruction is not executed, SM0 is ON, and the error code in SR0 is 16#2003. 2. If the number of digits in ( S 1 +2, S 1 +1) is larger than 7, the instruction is not executed, SM0 is ON, and the error code in SR0 is 16#2003. 3.

If the value in ( S 1 +2, S 1 +1) is not a binary-coded decimal value (The value is represented by the hexadecimal number, but one of digits is not within the range between 0 and 9.), the operation error occurs, the instruction is not executed, SM0 is ON, and the error code in SR0 is 16#200D. 4. If the value in S 1 +3 is neither 0 nor 1, the instruction is not executed, SM0 is ON, and the error code in SR0 is 16#2003. 5. If the value in S 1 +4 is less than 0 or larger than 38, the instruction is not executed, SM0 is ON, and the error code in SR0 is 16#2003 6. If the value in S 2 is less than 0 or larger than 7, the instruction is not executed, SM0 is ON, and the error code in SR0 is 16#2003.

7. If the operand S 1 used during the execution of the 32-bit instruction is declared in ISPSoft, the data type will be ARRAY [5] of WORD/INTT. 3-556 1.23 457