Chapter 6 Applied Instructions Symbol S : Source value D : Device where the operation result is stored Explanation 1. This instruction calculates the natural logarithm of the operand S in a single-precision floating-point operation. 2. The value in S only can be a positive value. 6_ 3. e D = S .→The value in D =ln S . 4. If the operation result stored in D is 0, SM600 is ON. Example 1. When M0 is ON, the DFLT instruction converts the value in (D1, D0) into the floating-point number, and stores the conversion result in (D11, D10). 2. When M1 is ON, the FLN instruction calculates the natural logarithm of the floating-point number in (D11, D10), and stores the operation result in (D21, D20).
6-471 API Instruction code Operand Function 1515 FLN P S, D Natural logarithm of a binary floating-point number Device X Y M S T C HC D FR SM SR E K 16# “$” F S D BOOL WORD DWORD LWORD UINT INT DINT LINT REAL LREAL TMR CNT STRING Data type S D Pulse instruction 16-bit instruction 32-bit instruction ES3 - ES3