Chapter 6 Applied Instructions Symbol S 1 : Data source1 S 2 : Data source2 Taking FOR= and DFOR= for example Explanation 1. These instructions compare the 32-bit single precision floating point numbers. 6_ 2. Compare values in S 1 and S 2. Take the FOR= instruction for example. When the comparison result is that the value in S 1 is equal to that in S 2 , the continuity condition of the instruction is met. When the comparison result is that the value in S 1 is not equal to that in S 2 , the discontinuity condition of the instruction is met.
6-17 API Instruction code Operand Function 0030-0035 FOR※ S1,S2 Comparing floating-point numbers OR※ Device X Y M S T C HC D FR SM SR E K 16# “$” F S1 S2 BOOL WORD DWORD LWORD UINT INT DINT LINT REAL LREAL TMR CNT STRING Data type S1 S2 Pulse Instruction 16-bit instruction 32-bit instruction - - ES3 32-bit Continuity Discontinuity API number instruction condition condition 0030 FOR= S1=S2 S1≠S2 0031 FOR<> S1≠S2 S1=S2 0032 FOR> S1>S2 S1≦S2 0033 FOR>= S1≧S2 S1<S2 0034 FOR< S1<S2 S1≧S2 0035 FOR<= S1≦S2 S1>S2