Delta DVP-ES3 — 6.2.2 Explanation of Arithmetic Instructions

DVP-ES3 Series Programming Manual Symbol S 1 : Augend S 2 : Addend D : Sum _6 Explanation 1. This instruction adds the 32-bit single-precision floating-point numbers in S 2 and S 1 , and stores the sum in D . 2. Instruction flags: SM600 (zero flag), SM601 (borrow flag), and SM602 (carry flag)  When the operation result is zero, SM600 is ON. Otherwise, it is OFF.  When the absolute value of the operation result is less than the value that can be represented by the minimum floating-point number, the value in D is 16#FF800000 and SM601 is ON.

 When the absolute value of the operation result is larger than the value that can be represented by the maximum floating-point number, the value in D is 16#7F800000 and SM602 is ON. Example Adding single-precision floating-point numbers: when M0 is ON, the instruction adds the addend 16#4046B852 in (D21, D20) to the augend 16#3FB9999A in (D11, D10), and stores the sum 16#4091C28F in (D31, D30). 16#4046B852, 16#3FB9999A, and 16#4091C28F represent the floating point numbers 3.105, 1.450, and 4.555 respectively.

6-56 API Instruction code Operand Function 0104 F+ P S1,S2,D Adding floating-point numbers Device X Y M S T C HC D FR SM SR E K 16# “$” F S1       S2       D     BOOL WORD DWORD LWORD UINT INT DINT LINT REAL LREAL TMR CNT STRING Data type S1  S2  D  Pulse instruction 16-bit instruction 32-bit instruction ES3 - ES3